]> git.sur5r.net Git - openldap/blob - configure
Fix version strings
[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 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 MKINSTALLDIRS MSGFMT GMSGFMT XGETTEXT MSGMERGE CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT USE_NLS LIBICONV LTLIBICONV INTLLIBS LIBINTL LTLIBINTL POSUB AR 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   --disable-rpath         do not hardcode runtime library paths
1054   --disable-nls           do not use Native Language Support
1055   --enable-fast-install=PKGS  optimize for fast installation default=yes
1056   --disable-libtool-lock  avoid locking (might break parallel builds)
1057
1058 Optional Packages:
1059   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1060   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1061   --with-subdir=DIR       change default subdirectory used for installs
1062   --with-cyrus-sasl       with Cyrus SASL support auto
1063   --with-fetch            with fetch(3) URL support auto
1064   --with-kerberos         with Kerberos support auto
1065   --with-readline         with readline support auto
1066   --with-threads          with threads auto
1067   --with-tls              with TLS/SSL support auto
1068   --with-yielding-select  with implicitly yielding select auto
1069
1070 SLAPD (Standalone LDAP Daemon) Options:
1071     --with-bdb-module     module type static|dynamic static
1072     --with-dnssrv-module  module type static|dynamic static
1073     --with-ldap-module    module type static|dynamic static
1074     --with-ldbm-api       with LDBM API auto|berkeley|bcompat|mdbm|gdbm auto
1075     --with-ldbm-module    module type static|dynamic static
1076     --with-ldbm-type      use LDBM type auto|btree|hash auto
1077     --with-meta-module    module type static|dynamic static
1078     --with-monitor-module module type static|dynamic static
1079     --with-null-module    module type static|dynamic static
1080     --with-passwd-module  module type static|dynamic static
1081     --with-perl-module    module type static|dynamic static
1082     --with-shell-module   module type static|dynamic static
1083     --with-sql-module     module type static|dynamic static
1084     --with-tcl-module     module type static|dynamic static
1085
1086 SLURPD (Replication Daemon) Options:
1087
1088 Library Generation & Linking Options
1089   --with-gnu-ld           assume the C compiler uses GNU ld default=no
1090   --with-libiconv-prefix=DIR  search for libiconv in DIR/include and DIR/lib
1091   --without-libiconv-prefix     don't search for libiconv in includedir and libdir
1092   --with-libintl-prefix=DIR  search for libintl in DIR/include and DIR/lib
1093   --without-libintl-prefix     don't search for libintl in includedir and libdir
1094   --with-pic              try to use only PIC/non-PIC objects default=use both
1095
1096 See INSTALL file for further details.
1097
1098 Some influential environment variables:
1099   CC          C compiler command
1100   CFLAGS      C compiler flags
1101   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1102               nonstandard directory <lib dir>
1103   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1104               headers in a nonstandard directory <include dir>
1105   CPP         C preprocessor
1106
1107 Use these variables to override the choices made by `configure' or to help
1108 it to find libraries and programs with nonstandard names/locations.
1109
1110 _ACEOF
1111 fi
1112
1113 if test "$ac_init_help" = "recursive"; then
1114   # If there are subdirs, report their specific --help.
1115   ac_popdir=`pwd`
1116   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1117     test -d $ac_dir || continue
1118     ac_builddir=.
1119
1120 if test "$ac_dir" != .; then
1121   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1122   # A "../" for each directory in $ac_dir_suffix.
1123   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1124 else
1125   ac_dir_suffix= ac_top_builddir=
1126 fi
1127
1128 case $srcdir in
1129   .)  # No --srcdir option.  We are building in place.
1130     ac_srcdir=.
1131     if test -z "$ac_top_builddir"; then
1132        ac_top_srcdir=.
1133     else
1134        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1135     fi ;;
1136   [\\/]* | ?:[\\/]* )  # Absolute path.
1137     ac_srcdir=$srcdir$ac_dir_suffix;
1138     ac_top_srcdir=$srcdir ;;
1139   *) # Relative path.
1140     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1141     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1142 esac
1143 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
1144 # absolute.
1145 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
1146 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
1147 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
1148 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
1149
1150     cd $ac_dir
1151     # Check for guested configure; otherwise get Cygnus style configure.
1152     if test -f $ac_srcdir/configure.gnu; then
1153       echo
1154       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1155     elif test -f $ac_srcdir/configure; then
1156       echo
1157       $SHELL $ac_srcdir/configure  --help=recursive
1158     elif test -f $ac_srcdir/configure.ac ||
1159            test -f $ac_srcdir/configure.in; then
1160       echo
1161       $ac_configure --help
1162     else
1163       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1164     fi
1165     cd $ac_popdir
1166   done
1167 fi
1168
1169 test -n "$ac_init_help" && exit 0
1170 if $ac_init_version; then
1171   cat <<\_ACEOF
1172
1173 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
1174 Free Software Foundation, Inc.
1175 This configure script is free software; the Free Software Foundation
1176 gives unlimited permission to copy, distribute and modify it.
1177
1178 Copyright 1998-2003 The OpenLDAP Foundation. All Rights Reserved.
1179
1180 Redistribution and use in source and binary forms, with or without
1181 modification, are permitted only as authorized by the OpenLDAP
1182 Public License.  A copy of this license is available at
1183 http://www.OpenLDAP.org/license.html or in file LICENSE in the
1184 top-level directory of the distribution.
1185
1186 _ACEOF
1187   exit 0
1188 fi
1189 exec 5>config.log
1190 cat >&5 <<_ACEOF
1191 This file contains any messages produced by compilers while
1192 running configure, to aid debugging if configure makes a mistake.
1193
1194 It was created by $as_me, which was
1195 generated by GNU Autoconf 2.57.  Invocation command line was
1196
1197   $ $0 $@
1198
1199 _ACEOF
1200 {
1201 cat <<_ASUNAME
1202 ## --------- ##
1203 ## Platform. ##
1204 ## --------- ##
1205
1206 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1207 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1208 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1209 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1210 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1211
1212 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1213 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1214
1215 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1216 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1217 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1218 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1219 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1220 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1221 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1222
1223 _ASUNAME
1224
1225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1226 for as_dir in $PATH
1227 do
1228   IFS=$as_save_IFS
1229   test -z "$as_dir" && as_dir=.
1230   echo "PATH: $as_dir"
1231 done
1232
1233 } >&5
1234
1235 cat >&5 <<_ACEOF
1236
1237
1238 ## ----------- ##
1239 ## Core tests. ##
1240 ## ----------- ##
1241
1242 _ACEOF
1243
1244
1245 # Keep a trace of the command line.
1246 # Strip out --no-create and --no-recursion so they do not pile up.
1247 # Strip out --silent because we don't want to record it for future runs.
1248 # Also quote any args containing shell meta-characters.
1249 # Make two passes to allow for proper duplicate-argument suppression.
1250 ac_configure_args=
1251 ac_configure_args0=
1252 ac_configure_args1=
1253 ac_sep=
1254 ac_must_keep_next=false
1255 for ac_pass in 1 2
1256 do
1257   for ac_arg
1258   do
1259     case $ac_arg in
1260     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1261     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1262     | -silent | --silent | --silen | --sile | --sil)
1263       continue ;;
1264     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1265       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1266     esac
1267     case $ac_pass in
1268     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1269     2)
1270       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1271       if test $ac_must_keep_next = true; then
1272         ac_must_keep_next=false # Got value, back to normal.
1273       else
1274         case $ac_arg in
1275           *=* | --config-cache | -C | -disable-* | --disable-* \
1276           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1277           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1278           | -with-* | --with-* | -without-* | --without-* | --x)
1279             case "$ac_configure_args0 " in
1280               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1281             esac
1282             ;;
1283           -* ) ac_must_keep_next=true ;;
1284         esac
1285       fi
1286       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1287       # Get rid of the leading space.
1288       ac_sep=" "
1289       ;;
1290     esac
1291   done
1292 done
1293 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1294 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1295
1296 # When interrupted or exit'd, cleanup temporary files, and complete
1297 # config.log.  We remove comments because anyway the quotes in there
1298 # would cause problems or look ugly.
1299 # WARNING: Be sure not to use single quotes in there, as some shells,
1300 # such as our DU 5.0 friend, will then `close' the trap.
1301 trap 'exit_status=$?
1302   # Save into config.log some information that might help in debugging.
1303   {
1304     echo
1305
1306     cat <<\_ASBOX
1307 ## ---------------- ##
1308 ## Cache variables. ##
1309 ## ---------------- ##
1310 _ASBOX
1311     echo
1312     # The following way of writing the cache mishandles newlines in values,
1313 {
1314   (set) 2>&1 |
1315     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1316     *ac_space=\ *)
1317       sed -n \
1318         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1319           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1320       ;;
1321     *)
1322       sed -n \
1323         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1324       ;;
1325     esac;
1326 }
1327     echo
1328
1329     cat <<\_ASBOX
1330 ## ----------------- ##
1331 ## Output variables. ##
1332 ## ----------------- ##
1333 _ASBOX
1334     echo
1335     for ac_var in $ac_subst_vars
1336     do
1337       eval ac_val=$`echo $ac_var`
1338       echo "$ac_var='"'"'$ac_val'"'"'"
1339     done | sort
1340     echo
1341
1342     if test -n "$ac_subst_files"; then
1343       cat <<\_ASBOX
1344 ## ------------- ##
1345 ## Output files. ##
1346 ## ------------- ##
1347 _ASBOX
1348       echo
1349       for ac_var in $ac_subst_files
1350       do
1351         eval ac_val=$`echo $ac_var`
1352         echo "$ac_var='"'"'$ac_val'"'"'"
1353       done | sort
1354       echo
1355     fi
1356
1357     if test -s confdefs.h; then
1358       cat <<\_ASBOX
1359 ## ----------- ##
1360 ## confdefs.h. ##
1361 ## ----------- ##
1362 _ASBOX
1363       echo
1364       sed "/^$/d" confdefs.h | sort
1365       echo
1366     fi
1367     test "$ac_signal" != 0 &&
1368       echo "$as_me: caught signal $ac_signal"
1369     echo "$as_me: exit $exit_status"
1370   } >&5
1371   rm -f core core.* *.core &&
1372   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1373     exit $exit_status
1374      ' 0
1375 for ac_signal in 1 2 13 15; do
1376   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1377 done
1378 ac_signal=0
1379
1380 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1381 rm -rf conftest* confdefs.h
1382 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1383 echo >confdefs.h
1384
1385 # Predefined preprocessor variables.
1386
1387 cat >>confdefs.h <<_ACEOF
1388 #define PACKAGE_NAME "$PACKAGE_NAME"
1389 _ACEOF
1390
1391
1392 cat >>confdefs.h <<_ACEOF
1393 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1394 _ACEOF
1395
1396
1397 cat >>confdefs.h <<_ACEOF
1398 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1399 _ACEOF
1400
1401
1402 cat >>confdefs.h <<_ACEOF
1403 #define PACKAGE_STRING "$PACKAGE_STRING"
1404 _ACEOF
1405
1406
1407 cat >>confdefs.h <<_ACEOF
1408 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1409 _ACEOF
1410
1411
1412 # Let the site file select an alternate cache file if it wants to.
1413 # Prefer explicitly selected file to automatically selected ones.
1414 if test -z "$CONFIG_SITE"; then
1415   if test "x$prefix" != xNONE; then
1416     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1417   else
1418     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1419   fi
1420 fi
1421 for ac_site_file in $CONFIG_SITE; do
1422   if test -r "$ac_site_file"; then
1423     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1424 echo "$as_me: loading site script $ac_site_file" >&6;}
1425     sed 's/^/| /' "$ac_site_file" >&5
1426     . "$ac_site_file"
1427   fi
1428 done
1429
1430 if test -r "$cache_file"; then
1431   # Some versions of bash will fail to source /dev/null (special
1432   # files actually), so we avoid doing that.
1433   if test -f "$cache_file"; then
1434     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1435 echo "$as_me: loading cache $cache_file" >&6;}
1436     case $cache_file in
1437       [\\/]* | ?:[\\/]* ) . $cache_file;;
1438       *)                      . ./$cache_file;;
1439     esac
1440   fi
1441 else
1442   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1443 echo "$as_me: creating cache $cache_file" >&6;}
1444   >$cache_file
1445 fi
1446
1447 # Check that the precious variables saved in the cache have kept the same
1448 # value.
1449 ac_cache_corrupted=false
1450 for ac_var in `(set) 2>&1 |
1451                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1452   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1453   eval ac_new_set=\$ac_env_${ac_var}_set
1454   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1455   eval ac_new_val="\$ac_env_${ac_var}_value"
1456   case $ac_old_set,$ac_new_set in
1457     set,)
1458       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1459 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1460       ac_cache_corrupted=: ;;
1461     ,set)
1462       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1463 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1464       ac_cache_corrupted=: ;;
1465     ,);;
1466     *)
1467       if test "x$ac_old_val" != "x$ac_new_val"; then
1468         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1469 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1470         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1471 echo "$as_me:   former value:  $ac_old_val" >&2;}
1472         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1473 echo "$as_me:   current value: $ac_new_val" >&2;}
1474         ac_cache_corrupted=:
1475       fi;;
1476   esac
1477   # Pass precious variables to config.status.
1478   if test "$ac_new_set" = set; then
1479     case $ac_new_val in
1480     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1481       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1482     *) ac_arg=$ac_var=$ac_new_val ;;
1483     esac
1484     case " $ac_configure_args " in
1485       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1486       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1487     esac
1488   fi
1489 done
1490 if $ac_cache_corrupted; then
1491   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1492 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1493   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1494 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1495    { (exit 1); exit 1; }; }
1496 fi
1497
1498 ac_ext=c
1499 ac_cpp='$CPP $CPPFLAGS'
1500 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1501 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1502 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522 ac_aux_dir=
1523 for ac_dir in build $srcdir/build; do
1524   if test -f $ac_dir/install-sh; then
1525     ac_aux_dir=$ac_dir
1526     ac_install_sh="$ac_aux_dir/install-sh -c"
1527     break
1528   elif test -f $ac_dir/install.sh; then
1529     ac_aux_dir=$ac_dir
1530     ac_install_sh="$ac_aux_dir/install.sh -c"
1531     break
1532   elif test -f $ac_dir/shtool; then
1533     ac_aux_dir=$ac_dir
1534     ac_install_sh="$ac_aux_dir/shtool install -c"
1535     break
1536   fi
1537 done
1538 if test -z "$ac_aux_dir"; then
1539   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1540 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1541    { (exit 1); exit 1; }; }
1542 fi
1543 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1544 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1545 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1546
1547 eval `$ac_aux_dir/version.sh`
1548 if test -z "$OL_STRING"; then
1549         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1550 echo "$as_me: error: could not determine version" >&2;}
1551    { (exit 1); exit 1; }; }
1552 fi
1553
1554 if test -f "$ac_aux_dir/shtool" -a ! -d $ac_aux_dir/shtool; then
1555         ac_cv_shtool="$ac_aux_dir/shtool"
1556 else
1557         { { echo "$as_me:$LINENO: error: no shtool found in $ac_aux_dir" >&5
1558 echo "$as_me: error: no shtool found in $ac_aux_dir" >&2;}
1559    { (exit 1); exit 1; }; }
1560 fi
1561
1562 SHTOOL="$ac_cv_shtool"
1563
1564 TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1565 TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1566
1567 OPENLDAP_CVS=""
1568 if test -d $ac_aux_dir/CVS; then
1569         OPENLDAP_CVS="(from CVS sources) "
1570 fi
1571
1572 echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
1573
1574 # Make sure we can run config.sub.
1575 $ac_config_sub sun4 >/dev/null 2>&1 ||
1576   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1577 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1578    { (exit 1); exit 1; }; }
1579
1580 echo "$as_me:$LINENO: checking build system type" >&5
1581 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1582 if test "${ac_cv_build+set}" = set; then
1583   echo $ECHO_N "(cached) $ECHO_C" >&6
1584 else
1585   ac_cv_build_alias=$build_alias
1586 test -z "$ac_cv_build_alias" &&
1587   ac_cv_build_alias=`$ac_config_guess`
1588 test -z "$ac_cv_build_alias" &&
1589   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1590 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1591    { (exit 1); exit 1; }; }
1592 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1593   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1594 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1595    { (exit 1); exit 1; }; }
1596
1597 fi
1598 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1599 echo "${ECHO_T}$ac_cv_build" >&6
1600 build=$ac_cv_build
1601 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1602 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1603 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1604
1605
1606 echo "$as_me:$LINENO: checking host system type" >&5
1607 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1608 if test "${ac_cv_host+set}" = set; then
1609   echo $ECHO_N "(cached) $ECHO_C" >&6
1610 else
1611   ac_cv_host_alias=$host_alias
1612 test -z "$ac_cv_host_alias" &&
1613   ac_cv_host_alias=$ac_cv_build_alias
1614 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1615   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1616 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1617    { (exit 1); exit 1; }; }
1618
1619 fi
1620 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1621 echo "${ECHO_T}$ac_cv_host" >&6
1622 host=$ac_cv_host
1623 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1624 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1625 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1626
1627
1628 echo "$as_me:$LINENO: checking target system type" >&5
1629 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1630 if test "${ac_cv_target+set}" = set; then
1631   echo $ECHO_N "(cached) $ECHO_C" >&6
1632 else
1633   ac_cv_target_alias=$target_alias
1634 test "x$ac_cv_target_alias" = "x" &&
1635   ac_cv_target_alias=$ac_cv_host_alias
1636 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1637   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1638 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1639    { (exit 1); exit 1; }; }
1640
1641 fi
1642 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1643 echo "${ECHO_T}$ac_cv_target" >&6
1644 target=$ac_cv_target
1645 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1646 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1647 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1648
1649
1650 # The aliases save the names the user supplied, while $host etc.
1651 # will get canonicalized.
1652 test -n "$target_alias" &&
1653   test "$program_prefix$program_suffix$program_transform_name" = \
1654     NONENONEs,x,x, &&
1655   program_prefix=${target_alias}-
1656
1657 OPENLDAP_PACKAGE=$OL_PACKAGE
1658 OPENLDAP_VERSION=$OL_VERSION
1659
1660
1661
1662
1663
1664 cat >>confdefs.h <<_ACEOF
1665 #define OPENLDAP_PACKAGE "$OL_PACKAGE"
1666 _ACEOF
1667
1668
1669 cat >>confdefs.h <<_ACEOF
1670 #define OPENLDAP_VERSION "$OL_VERSION"
1671 _ACEOF
1672
1673
1674
1675 cat >>confdefs.h <<_ACEOF
1676 #define LDAP_VENDOR_VERSION $OL_API_INC
1677 _ACEOF
1678
1679
1680 cat >>confdefs.h <<_ACEOF
1681 #define LDAP_VENDOR_VERSION_MAJOR $OL_MAJOR
1682 _ACEOF
1683
1684
1685 cat >>confdefs.h <<_ACEOF
1686 #define LDAP_VENDOR_VERSION_MINOR $OL_MINOR
1687 _ACEOF
1688
1689
1690 cat >>confdefs.h <<_ACEOF
1691 #define LDAP_VENDOR_VERSION_PATCH $OL_PATCH
1692 _ACEOF
1693
1694
1695 OPENLDAP_LIBVERSION=$OL_API_LIB
1696
1697 OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
1698
1699
1700                               ac_config_headers="$ac_config_headers include/portable.h include/ldap_features.h include/lber_types.h"
1701
1702 echo "$as_me:$LINENO: checking configure arguments" >&5
1703 echo $ECHO_N "checking configure arguments... $ECHO_C" >&6
1704
1705
1706 top_builddir=`pwd`
1707
1708 ldap_subdir="/openldap"
1709
1710
1711 # Check whether --with-subdir or --without-subdir was given.
1712 if test "${with_subdir+set}" = set; then
1713   withval="$with_subdir"
1714   case "$withval" in
1715         no) ldap_subdir=""
1716                 ;;
1717         yes)
1718                 ;;
1719         /*|\\*)
1720                 ldap_subdir="$withval"
1721                 ;;
1722         *)
1723                 ldap_subdir="/$withval"
1724                 ;;
1725 esac
1726
1727 fi;
1728
1729 # OpenLDAP --enable-debug
1730         # Check whether --enable-debug or --disable-debug was given.
1731 if test "${enable_debug+set}" = set; then
1732   enableval="$enable_debug"
1733
1734         ol_arg=invalid
1735         for ol_val in auto yes no ; do
1736                 if test "$enableval" = "$ol_val" ; then
1737                         ol_arg="$ol_val"
1738                 fi
1739         done
1740         if test "$ol_arg" = "invalid" ; then
1741                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-debug" >&5
1742 echo "$as_me: error: bad value $enableval for --enable-debug" >&2;}
1743    { (exit 1); exit 1; }; }
1744         fi
1745         ol_enable_debug="$ol_arg"
1746
1747 else
1748         ol_enable_debug="yes"
1749 fi; # end --enable-debug
1750 # OpenLDAP --enable-dynamic
1751         # Check whether --enable-dynamic or --disable-dynamic was given.
1752 if test "${enable_dynamic+set}" = set; then
1753   enableval="$enable_dynamic"
1754
1755         ol_arg=invalid
1756         for ol_val in auto yes no ; do
1757                 if test "$enableval" = "$ol_val" ; then
1758                         ol_arg="$ol_val"
1759                 fi
1760         done
1761         if test "$ol_arg" = "invalid" ; then
1762                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynamic" >&5
1763 echo "$as_me: error: bad value $enableval for --enable-dynamic" >&2;}
1764    { (exit 1); exit 1; }; }
1765         fi
1766         ol_enable_dynamic="$ol_arg"
1767
1768 else
1769         ol_enable_dynamic="no"
1770 fi; # end --enable-dynamic
1771 # OpenLDAP --enable-syslog
1772         # Check whether --enable-syslog or --disable-syslog was given.
1773 if test "${enable_syslog+set}" = set; then
1774   enableval="$enable_syslog"
1775
1776         ol_arg=invalid
1777         for ol_val in auto yes no ; do
1778                 if test "$enableval" = "$ol_val" ; then
1779                         ol_arg="$ol_val"
1780                 fi
1781         done
1782         if test "$ol_arg" = "invalid" ; then
1783                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syslog" >&5
1784 echo "$as_me: error: bad value $enableval for --enable-syslog" >&2;}
1785    { (exit 1); exit 1; }; }
1786         fi
1787         ol_enable_syslog="$ol_arg"
1788
1789 else
1790         ol_enable_syslog="auto"
1791 fi; # end --enable-syslog
1792 # OpenLDAP --enable-proctitle
1793         # Check whether --enable-proctitle or --disable-proctitle was given.
1794 if test "${enable_proctitle+set}" = set; then
1795   enableval="$enable_proctitle"
1796
1797         ol_arg=invalid
1798         for ol_val in auto yes no ; do
1799                 if test "$enableval" = "$ol_val" ; then
1800                         ol_arg="$ol_val"
1801                 fi
1802         done
1803         if test "$ol_arg" = "invalid" ; then
1804                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proctitle" >&5
1805 echo "$as_me: error: bad value $enableval for --enable-proctitle" >&2;}
1806    { (exit 1); exit 1; }; }
1807         fi
1808         ol_enable_proctitle="$ol_arg"
1809
1810 else
1811         ol_enable_proctitle="yes"
1812 fi; # end --enable-proctitle
1813 ol_enable_referrals=${ol_enable_referrals-no}
1814 ol_enable_kbind=${ol_enable_kbind-no}
1815 # OpenLDAP --enable-ipv6
1816         # Check whether --enable-ipv6 or --disable-ipv6 was given.
1817 if test "${enable_ipv6+set}" = set; then
1818   enableval="$enable_ipv6"
1819
1820         ol_arg=invalid
1821         for ol_val in auto yes no ; do
1822                 if test "$enableval" = "$ol_val" ; then
1823                         ol_arg="$ol_val"
1824                 fi
1825         done
1826         if test "$ol_arg" = "invalid" ; then
1827                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
1828 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
1829    { (exit 1); exit 1; }; }
1830         fi
1831         ol_enable_ipv6="$ol_arg"
1832
1833 else
1834         ol_enable_ipv6="auto"
1835 fi; # end --enable-ipv6
1836 # OpenLDAP --enable-local
1837         # Check whether --enable-local or --disable-local was given.
1838 if test "${enable_local+set}" = set; then
1839   enableval="$enable_local"
1840
1841         ol_arg=invalid
1842         for ol_val in auto yes no ; do
1843                 if test "$enableval" = "$ol_val" ; then
1844                         ol_arg="$ol_val"
1845                 fi
1846         done
1847         if test "$ol_arg" = "invalid" ; then
1848                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
1849 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
1850    { (exit 1); exit 1; }; }
1851         fi
1852         ol_enable_local="$ol_arg"
1853
1854 else
1855         ol_enable_local="auto"
1856 fi; # end --enable-local
1857 # OpenLDAP --enable-x_compile
1858         # Check whether --enable-x_compile or --disable-x_compile was given.
1859 if test "${enable_x_compile+set}" = set; then
1860   enableval="$enable_x_compile"
1861
1862         ol_arg=invalid
1863         for ol_val in yes no ; do
1864                 if test "$enableval" = "$ol_val" ; then
1865                         ol_arg="$ol_val"
1866                 fi
1867         done
1868         if test "$ol_arg" = "invalid" ; then
1869                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-x_compile" >&5
1870 echo "$as_me: error: bad value $enableval for --enable-x_compile" >&2;}
1871    { (exit 1); exit 1; }; }
1872         fi
1873         ol_enable_x_compile="$ol_arg"
1874
1875 else
1876         ol_enable_x_compile="no"
1877 fi; # end --enable-x_compile
1878
1879
1880 # OpenLDAP --with-cyrus_sasl
1881
1882 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
1883 if test "${with_cyrus_sasl+set}" = set; then
1884   withval="$with_cyrus_sasl"
1885
1886         ol_arg=invalid
1887         for ol_val in auto yes no  ; do
1888                 if test "$withval" = "$ol_val" ; then
1889                         ol_arg="$ol_val"
1890                 fi
1891         done
1892         if test "$ol_arg" = "invalid" ; then
1893                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
1894 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
1895    { (exit 1); exit 1; }; }
1896         fi
1897         ol_with_cyrus_sasl="$ol_arg"
1898
1899 else
1900         ol_with_cyrus_sasl="auto"
1901 fi; # end --with-cyrus_sasl
1902
1903 # OpenLDAP --with-fetch
1904
1905 # Check whether --with-fetch or --without-fetch was given.
1906 if test "${with_fetch+set}" = set; then
1907   withval="$with_fetch"
1908
1909         ol_arg=invalid
1910         for ol_val in auto yes no  ; do
1911                 if test "$withval" = "$ol_val" ; then
1912                         ol_arg="$ol_val"
1913                 fi
1914         done
1915         if test "$ol_arg" = "invalid" ; then
1916                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
1917 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
1918    { (exit 1); exit 1; }; }
1919         fi
1920         ol_with_fetch="$ol_arg"
1921
1922 else
1923         ol_with_fetch="auto"
1924 fi; # end --with-fetch
1925
1926 # OpenLDAP --with-kerberos
1927
1928 # Check whether --with-kerberos or --without-kerberos was given.
1929 if test "${with_kerberos+set}" = set; then
1930   withval="$with_kerberos"
1931
1932         ol_arg=invalid
1933         for ol_val in auto k5 k5only k425 kth k4 afs yes no ; do
1934                 if test "$withval" = "$ol_val" ; then
1935                         ol_arg="$ol_val"
1936                 fi
1937         done
1938         if test "$ol_arg" = "invalid" ; then
1939                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-kerberos" >&5
1940 echo "$as_me: error: bad value $withval for --with-kerberos" >&2;}
1941    { (exit 1); exit 1; }; }
1942         fi
1943         ol_with_kerberos="$ol_arg"
1944
1945 else
1946         ol_with_kerberos="auto"
1947 fi; # end --with-kerberos
1948
1949 # OpenLDAP --with-readline
1950
1951 # Check whether --with-readline or --without-readline was given.
1952 if test "${with_readline+set}" = set; then
1953   withval="$with_readline"
1954
1955         ol_arg=invalid
1956         for ol_val in auto yes no  ; do
1957                 if test "$withval" = "$ol_val" ; then
1958                         ol_arg="$ol_val"
1959                 fi
1960         done
1961         if test "$ol_arg" = "invalid" ; then
1962                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-readline" >&5
1963 echo "$as_me: error: bad value $withval for --with-readline" >&2;}
1964    { (exit 1); exit 1; }; }
1965         fi
1966         ol_with_readline="$ol_arg"
1967
1968 else
1969         ol_with_readline="auto"
1970 fi; # end --with-readline
1971
1972 # OpenLDAP --with-threads
1973
1974 # Check whether --with-threads or --without-threads was given.
1975 if test "${with_threads+set}" = set; then
1976   withval="$with_threads"
1977
1978         ol_arg=invalid
1979         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
1980                 if test "$withval" = "$ol_val" ; then
1981                         ol_arg="$ol_val"
1982                 fi
1983         done
1984         if test "$ol_arg" = "invalid" ; then
1985                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
1986 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
1987    { (exit 1); exit 1; }; }
1988         fi
1989         ol_with_threads="$ol_arg"
1990
1991 else
1992         ol_with_threads="auto"
1993 fi; # end --with-threads
1994
1995 # OpenLDAP --with-tls
1996
1997 # Check whether --with-tls or --without-tls was given.
1998 if test "${with_tls+set}" = set; then
1999   withval="$with_tls"
2000
2001         ol_arg=invalid
2002         for ol_val in auto ssleay openssl yes no  ; do
2003                 if test "$withval" = "$ol_val" ; then
2004                         ol_arg="$ol_val"
2005                 fi
2006         done
2007         if test "$ol_arg" = "invalid" ; then
2008                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2009 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2010    { (exit 1); exit 1; }; }
2011         fi
2012         ol_with_tls="$ol_arg"
2013
2014 else
2015         ol_with_tls="auto"
2016 fi; # end --with-tls
2017
2018 # OpenLDAP --with-yielding_select
2019
2020 # Check whether --with-yielding_select or --without-yielding_select was given.
2021 if test "${with_yielding_select+set}" = set; then
2022   withval="$with_yielding_select"
2023
2024         ol_arg=invalid
2025         for ol_val in auto yes no manual  ; do
2026                 if test "$withval" = "$ol_val" ; then
2027                         ol_arg="$ol_val"
2028                 fi
2029         done
2030         if test "$ol_arg" = "invalid" ; then
2031                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2032 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2033    { (exit 1); exit 1; }; }
2034         fi
2035         ol_with_yielding_select="$ol_arg"
2036
2037 else
2038         ol_with_yielding_select="auto"
2039 fi; # end --with-yielding_select
2040
2041
2042
2043
2044 # Check whether --with-xxslapdoptions or --without-xxslapdoptions was given.
2045 if test "${with_xxslapdoptions+set}" = set; then
2046   withval="$with_xxslapdoptions"
2047
2048 fi;
2049 # OpenLDAP --enable-slapd
2050         # Check whether --enable-slapd or --disable-slapd was given.
2051 if test "${enable_slapd+set}" = set; then
2052   enableval="$enable_slapd"
2053
2054         ol_arg=invalid
2055         for ol_val in auto yes no ; do
2056                 if test "$enableval" = "$ol_val" ; then
2057                         ol_arg="$ol_val"
2058                 fi
2059         done
2060         if test "$ol_arg" = "invalid" ; then
2061                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2062 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2063    { (exit 1); exit 1; }; }
2064         fi
2065         ol_enable_slapd="$ol_arg"
2066
2067 else
2068         ol_enable_slapd="yes"
2069 fi; # end --enable-slapd
2070 # OpenLDAP --enable-aci
2071         # Check whether --enable-aci or --disable-aci was given.
2072 if test "${enable_aci+set}" = set; then
2073   enableval="$enable_aci"
2074
2075         ol_arg=invalid
2076         for ol_val in auto yes no ; do
2077                 if test "$enableval" = "$ol_val" ; then
2078                         ol_arg="$ol_val"
2079                 fi
2080         done
2081         if test "$ol_arg" = "invalid" ; then
2082                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2083 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2084    { (exit 1); exit 1; }; }
2085         fi
2086         ol_enable_aci="$ol_arg"
2087
2088 else
2089         ol_enable_aci="no"
2090 fi; # end --enable-aci
2091 # OpenLDAP --enable-cleartext
2092         # Check whether --enable-cleartext or --disable-cleartext was given.
2093 if test "${enable_cleartext+set}" = set; then
2094   enableval="$enable_cleartext"
2095
2096         ol_arg=invalid
2097         for ol_val in auto yes no ; do
2098                 if test "$enableval" = "$ol_val" ; then
2099                         ol_arg="$ol_val"
2100                 fi
2101         done
2102         if test "$ol_arg" = "invalid" ; then
2103                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2104 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2105    { (exit 1); exit 1; }; }
2106         fi
2107         ol_enable_cleartext="$ol_arg"
2108
2109 else
2110         ol_enable_cleartext="yes"
2111 fi; # end --enable-cleartext
2112 # OpenLDAP --enable-crypt
2113         # Check whether --enable-crypt or --disable-crypt was given.
2114 if test "${enable_crypt+set}" = set; then
2115   enableval="$enable_crypt"
2116
2117         ol_arg=invalid
2118         for ol_val in auto yes no ; do
2119                 if test "$enableval" = "$ol_val" ; then
2120                         ol_arg="$ol_val"
2121                 fi
2122         done
2123         if test "$ol_arg" = "invalid" ; then
2124                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2125 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2126    { (exit 1); exit 1; }; }
2127         fi
2128         ol_enable_crypt="$ol_arg"
2129
2130 else
2131         ol_enable_crypt="no"
2132 fi; # end --enable-crypt
2133 # OpenLDAP --enable-kpasswd
2134         # Check whether --enable-kpasswd or --disable-kpasswd was given.
2135 if test "${enable_kpasswd+set}" = set; then
2136   enableval="$enable_kpasswd"
2137
2138         ol_arg=invalid
2139         for ol_val in auto yes no ; do
2140                 if test "$enableval" = "$ol_val" ; then
2141                         ol_arg="$ol_val"
2142                 fi
2143         done
2144         if test "$ol_arg" = "invalid" ; then
2145                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-kpasswd" >&5
2146 echo "$as_me: error: bad value $enableval for --enable-kpasswd" >&2;}
2147    { (exit 1); exit 1; }; }
2148         fi
2149         ol_enable_kpasswd="$ol_arg"
2150
2151 else
2152         ol_enable_kpasswd="no"
2153 fi; # end --enable-kpasswd
2154 # OpenLDAP --enable-lmpasswd
2155         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2156 if test "${enable_lmpasswd+set}" = set; then
2157   enableval="$enable_lmpasswd"
2158
2159         ol_arg=invalid
2160         for ol_val in auto yes no ; do
2161                 if test "$enableval" = "$ol_val" ; then
2162                         ol_arg="$ol_val"
2163                 fi
2164         done
2165         if test "$ol_arg" = "invalid" ; then
2166                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2167 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2168    { (exit 1); exit 1; }; }
2169         fi
2170         ol_enable_lmpasswd="$ol_arg"
2171
2172 else
2173         ol_enable_lmpasswd="no"
2174 fi; # end --enable-lmpasswd
2175 # OpenLDAP --enable-spasswd
2176         # Check whether --enable-spasswd or --disable-spasswd was given.
2177 if test "${enable_spasswd+set}" = set; then
2178   enableval="$enable_spasswd"
2179
2180         ol_arg=invalid
2181         for ol_val in auto yes no ; do
2182                 if test "$enableval" = "$ol_val" ; then
2183                         ol_arg="$ol_val"
2184                 fi
2185         done
2186         if test "$ol_arg" = "invalid" ; then
2187                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2188 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2189    { (exit 1); exit 1; }; }
2190         fi
2191         ol_enable_spasswd="$ol_arg"
2192
2193 else
2194         ol_enable_spasswd="no"
2195 fi; # end --enable-spasswd
2196 # OpenLDAP --enable-modules
2197         # Check whether --enable-modules or --disable-modules was given.
2198 if test "${enable_modules+set}" = set; then
2199   enableval="$enable_modules"
2200
2201         ol_arg=invalid
2202         for ol_val in auto yes no ; do
2203                 if test "$enableval" = "$ol_val" ; then
2204                         ol_arg="$ol_val"
2205                 fi
2206         done
2207         if test "$ol_arg" = "invalid" ; then
2208                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2209 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2210    { (exit 1); exit 1; }; }
2211         fi
2212         ol_enable_modules="$ol_arg"
2213
2214 else
2215         ol_enable_modules="no"
2216 fi; # end --enable-modules
2217 ol_enable_multimaster=${ol_enable_multimaster-no}
2218 # OpenLDAP --enable-phonetic
2219         # Check whether --enable-phonetic or --disable-phonetic was given.
2220 if test "${enable_phonetic+set}" = set; then
2221   enableval="$enable_phonetic"
2222
2223         ol_arg=invalid
2224         for ol_val in auto yes no ; do
2225                 if test "$enableval" = "$ol_val" ; then
2226                         ol_arg="$ol_val"
2227                 fi
2228         done
2229         if test "$ol_arg" = "invalid" ; then
2230                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-phonetic" >&5
2231 echo "$as_me: error: bad value $enableval for --enable-phonetic" >&2;}
2232    { (exit 1); exit 1; }; }
2233         fi
2234         ol_enable_phonetic="$ol_arg"
2235
2236 else
2237         ol_enable_phonetic="no"
2238 fi; # end --enable-phonetic
2239 # OpenLDAP --enable-rewrite
2240         # Check whether --enable-rewrite or --disable-rewrite was given.
2241 if test "${enable_rewrite+set}" = set; then
2242   enableval="$enable_rewrite"
2243
2244         ol_arg=invalid
2245         for ol_val in auto yes no ; do
2246                 if test "$enableval" = "$ol_val" ; then
2247                         ol_arg="$ol_val"
2248                 fi
2249         done
2250         if test "$ol_arg" = "invalid" ; then
2251                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2252 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2253    { (exit 1); exit 1; }; }
2254         fi
2255         ol_enable_rewrite="$ol_arg"
2256
2257 else
2258         ol_enable_rewrite="no"
2259 fi; # end --enable-rewrite
2260 # OpenLDAP --enable-rlookups
2261         # Check whether --enable-rlookups or --disable-rlookups was given.
2262 if test "${enable_rlookups+set}" = set; then
2263   enableval="$enable_rlookups"
2264
2265         ol_arg=invalid
2266         for ol_val in auto yes no ; do
2267                 if test "$enableval" = "$ol_val" ; then
2268                         ol_arg="$ol_val"
2269                 fi
2270         done
2271         if test "$ol_arg" = "invalid" ; then
2272                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2273 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2274    { (exit 1); exit 1; }; }
2275         fi
2276         ol_enable_rlookups="$ol_arg"
2277
2278 else
2279         ol_enable_rlookups="no"
2280 fi; # end --enable-rlookups
2281 # OpenLDAP --enable-slapi
2282         # Check whether --enable-slapi or --disable-slapi was given.
2283 if test "${enable_slapi+set}" = set; then
2284   enableval="$enable_slapi"
2285
2286         ol_arg=invalid
2287         for ol_val in auto yes no ; do
2288                 if test "$enableval" = "$ol_val" ; then
2289                         ol_arg="$ol_val"
2290                 fi
2291         done
2292         if test "$ol_arg" = "invalid" ; then
2293                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2294 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2295    { (exit 1); exit 1; }; }
2296         fi
2297         ol_enable_slapi="$ol_arg"
2298
2299 else
2300         ol_enable_slapi="no"
2301 fi; # end --enable-slapi
2302 # OpenLDAP --enable-slp
2303         # Check whether --enable-slp or --disable-slp was given.
2304 if test "${enable_slp+set}" = set; then
2305   enableval="$enable_slp"
2306
2307         ol_arg=invalid
2308         for ol_val in auto yes no ; do
2309                 if test "$enableval" = "$ol_val" ; then
2310                         ol_arg="$ol_val"
2311                 fi
2312         done
2313         if test "$ol_arg" = "invalid" ; then
2314                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2315 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2316    { (exit 1); exit 1; }; }
2317         fi
2318         ol_enable_slp="$ol_arg"
2319
2320 else
2321         ol_enable_slp="no"
2322 fi; # end --enable-slp
2323 # OpenLDAP --enable-wrappers
2324         # Check whether --enable-wrappers or --disable-wrappers was given.
2325 if test "${enable_wrappers+set}" = set; then
2326   enableval="$enable_wrappers"
2327
2328         ol_arg=invalid
2329         for ol_val in auto yes no ; do
2330                 if test "$enableval" = "$ol_val" ; then
2331                         ol_arg="$ol_val"
2332                 fi
2333         done
2334         if test "$ol_arg" = "invalid" ; then
2335                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2336 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2337    { (exit 1); exit 1; }; }
2338         fi
2339         ol_enable_wrappers="$ol_arg"
2340
2341 else
2342         ol_enable_wrappers="no"
2343 fi; # end --enable-wrappers
2344
2345
2346 # OpenLDAP --enable-bdb
2347         # Check whether --enable-bdb or --disable-bdb was given.
2348 if test "${enable_bdb+set}" = set; then
2349   enableval="$enable_bdb"
2350
2351         ol_arg=invalid
2352         for ol_val in auto yes no ; do
2353                 if test "$enableval" = "$ol_val" ; then
2354                         ol_arg="$ol_val"
2355                 fi
2356         done
2357         if test "$ol_arg" = "invalid" ; then
2358                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2359 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2360    { (exit 1); exit 1; }; }
2361         fi
2362         ol_enable_bdb="$ol_arg"
2363
2364 else
2365         ol_enable_bdb="yes"
2366 fi; # end --enable-bdb
2367 # OpenLDAP --with-bdb_module
2368
2369 # Check whether --with-bdb_module or --without-bdb_module was given.
2370 if test "${with_bdb_module+set}" = set; then
2371   withval="$with_bdb_module"
2372
2373         ol_arg=invalid
2374         for ol_val in static dynamic ; do
2375                 if test "$withval" = "$ol_val" ; then
2376                         ol_arg="$ol_val"
2377                 fi
2378         done
2379         if test "$ol_arg" = "invalid" ; then
2380                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-bdb_module" >&5
2381 echo "$as_me: error: bad value $withval for --with-bdb_module" >&2;}
2382    { (exit 1); exit 1; }; }
2383         fi
2384         ol_with_bdb_module="$ol_arg"
2385
2386 else
2387         ol_with_bdb_module="static"
2388 fi; # end --with-bdb_module
2389
2390 # OpenLDAP --enable-dnssrv
2391         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2392 if test "${enable_dnssrv+set}" = set; then
2393   enableval="$enable_dnssrv"
2394
2395         ol_arg=invalid
2396         for ol_val in auto yes no ; do
2397                 if test "$enableval" = "$ol_val" ; then
2398                         ol_arg="$ol_val"
2399                 fi
2400         done
2401         if test "$ol_arg" = "invalid" ; then
2402                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2403 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2404    { (exit 1); exit 1; }; }
2405         fi
2406         ol_enable_dnssrv="$ol_arg"
2407
2408 else
2409         ol_enable_dnssrv="no"
2410 fi; # end --enable-dnssrv
2411 # OpenLDAP --with-dnssrv_module
2412
2413 # Check whether --with-dnssrv_module or --without-dnssrv_module was given.
2414 if test "${with_dnssrv_module+set}" = set; then
2415   withval="$with_dnssrv_module"
2416
2417         ol_arg=invalid
2418         for ol_val in static dynamic ; do
2419                 if test "$withval" = "$ol_val" ; then
2420                         ol_arg="$ol_val"
2421                 fi
2422         done
2423         if test "$ol_arg" = "invalid" ; then
2424                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-dnssrv_module" >&5
2425 echo "$as_me: error: bad value $withval for --with-dnssrv_module" >&2;}
2426    { (exit 1); exit 1; }; }
2427         fi
2428         ol_with_dnssrv_module="$ol_arg"
2429
2430 else
2431         ol_with_dnssrv_module="static"
2432 fi; # end --with-dnssrv_module
2433
2434 # OpenLDAP --enable-ldap
2435         # Check whether --enable-ldap or --disable-ldap was given.
2436 if test "${enable_ldap+set}" = set; then
2437   enableval="$enable_ldap"
2438
2439         ol_arg=invalid
2440         for ol_val in auto yes no ; do
2441                 if test "$enableval" = "$ol_val" ; then
2442                         ol_arg="$ol_val"
2443                 fi
2444         done
2445         if test "$ol_arg" = "invalid" ; then
2446                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2447 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2448    { (exit 1); exit 1; }; }
2449         fi
2450         ol_enable_ldap="$ol_arg"
2451
2452 else
2453         ol_enable_ldap="no"
2454 fi; # end --enable-ldap
2455 # OpenLDAP --with-ldap_module
2456
2457 # Check whether --with-ldap_module or --without-ldap_module was given.
2458 if test "${with_ldap_module+set}" = set; then
2459   withval="$with_ldap_module"
2460
2461         ol_arg=invalid
2462         for ol_val in static dynamic ; do
2463                 if test "$withval" = "$ol_val" ; then
2464                         ol_arg="$ol_val"
2465                 fi
2466         done
2467         if test "$ol_arg" = "invalid" ; then
2468                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldap_module" >&5
2469 echo "$as_me: error: bad value $withval for --with-ldap_module" >&2;}
2470    { (exit 1); exit 1; }; }
2471         fi
2472         ol_with_ldap_module="$ol_arg"
2473
2474 else
2475         ol_with_ldap_module="static"
2476 fi; # end --with-ldap_module
2477
2478 # OpenLDAP --enable-ldbm
2479         # Check whether --enable-ldbm or --disable-ldbm was given.
2480 if test "${enable_ldbm+set}" = set; then
2481   enableval="$enable_ldbm"
2482
2483         ol_arg=invalid
2484         for ol_val in auto yes no ; do
2485                 if test "$enableval" = "$ol_val" ; then
2486                         ol_arg="$ol_val"
2487                 fi
2488         done
2489         if test "$ol_arg" = "invalid" ; then
2490                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldbm" >&5
2491 echo "$as_me: error: bad value $enableval for --enable-ldbm" >&2;}
2492    { (exit 1); exit 1; }; }
2493         fi
2494         ol_enable_ldbm="$ol_arg"
2495
2496 else
2497         ol_enable_ldbm="no"
2498 fi; # end --enable-ldbm
2499 # OpenLDAP --with-ldbm_api
2500
2501 # Check whether --with-ldbm_api or --without-ldbm_api was given.
2502 if test "${with_ldbm_api+set}" = set; then
2503   withval="$with_ldbm_api"
2504
2505         ol_arg=invalid
2506         for ol_val in auto berkeley bcompat mdbm gdbm ; do
2507                 if test "$withval" = "$ol_val" ; then
2508                         ol_arg="$ol_val"
2509                 fi
2510         done
2511         if test "$ol_arg" = "invalid" ; then
2512                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_api" >&5
2513 echo "$as_me: error: bad value $withval for --with-ldbm_api" >&2;}
2514    { (exit 1); exit 1; }; }
2515         fi
2516         ol_with_ldbm_api="$ol_arg"
2517
2518 else
2519         ol_with_ldbm_api="auto"
2520 fi; # end --with-ldbm_api
2521
2522 # OpenLDAP --with-ldbm_module
2523
2524 # Check whether --with-ldbm_module or --without-ldbm_module was given.
2525 if test "${with_ldbm_module+set}" = set; then
2526   withval="$with_ldbm_module"
2527
2528         ol_arg=invalid
2529         for ol_val in static dynamic ; do
2530                 if test "$withval" = "$ol_val" ; then
2531                         ol_arg="$ol_val"
2532                 fi
2533         done
2534         if test "$ol_arg" = "invalid" ; then
2535                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_module" >&5
2536 echo "$as_me: error: bad value $withval for --with-ldbm_module" >&2;}
2537    { (exit 1); exit 1; }; }
2538         fi
2539         ol_with_ldbm_module="$ol_arg"
2540
2541 else
2542         ol_with_ldbm_module="static"
2543 fi; # end --with-ldbm_module
2544
2545 # OpenLDAP --with-ldbm_type
2546
2547 # Check whether --with-ldbm_type or --without-ldbm_type was given.
2548 if test "${with_ldbm_type+set}" = set; then
2549   withval="$with_ldbm_type"
2550
2551         ol_arg=invalid
2552         for ol_val in auto btree hash ; do
2553                 if test "$withval" = "$ol_val" ; then
2554                         ol_arg="$ol_val"
2555                 fi
2556         done
2557         if test "$ol_arg" = "invalid" ; then
2558                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_type" >&5
2559 echo "$as_me: error: bad value $withval for --with-ldbm_type" >&2;}
2560    { (exit 1); exit 1; }; }
2561         fi
2562         ol_with_ldbm_type="$ol_arg"
2563
2564 else
2565         ol_with_ldbm_type="auto"
2566 fi; # end --with-ldbm_type
2567
2568 # OpenLDAP --enable-meta
2569         # Check whether --enable-meta or --disable-meta was given.
2570 if test "${enable_meta+set}" = set; then
2571   enableval="$enable_meta"
2572
2573         ol_arg=invalid
2574         for ol_val in auto yes no ; do
2575                 if test "$enableval" = "$ol_val" ; then
2576                         ol_arg="$ol_val"
2577                 fi
2578         done
2579         if test "$ol_arg" = "invalid" ; then
2580                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2581 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2582    { (exit 1); exit 1; }; }
2583         fi
2584         ol_enable_meta="$ol_arg"
2585
2586 else
2587         ol_enable_meta="no"
2588 fi; # end --enable-meta
2589 # OpenLDAP --with-meta_module
2590
2591 # Check whether --with-meta_module or --without-meta_module was given.
2592 if test "${with_meta_module+set}" = set; then
2593   withval="$with_meta_module"
2594
2595         ol_arg=invalid
2596         for ol_val in static dynamic ; do
2597                 if test "$withval" = "$ol_val" ; then
2598                         ol_arg="$ol_val"
2599                 fi
2600         done
2601         if test "$ol_arg" = "invalid" ; then
2602                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-meta_module" >&5
2603 echo "$as_me: error: bad value $withval for --with-meta_module" >&2;}
2604    { (exit 1); exit 1; }; }
2605         fi
2606         ol_with_meta_module="$ol_arg"
2607
2608 else
2609         ol_with_meta_module="static"
2610 fi; # end --with-meta_module
2611
2612 # OpenLDAP --enable-monitor
2613         # Check whether --enable-monitor or --disable-monitor was given.
2614 if test "${enable_monitor+set}" = set; then
2615   enableval="$enable_monitor"
2616
2617         ol_arg=invalid
2618         for ol_val in auto yes no ; do
2619                 if test "$enableval" = "$ol_val" ; then
2620                         ol_arg="$ol_val"
2621                 fi
2622         done
2623         if test "$ol_arg" = "invalid" ; then
2624                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2625 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2626    { (exit 1); exit 1; }; }
2627         fi
2628         ol_enable_monitor="$ol_arg"
2629
2630 else
2631         ol_enable_monitor="no"
2632 fi; # end --enable-monitor
2633 # OpenLDAP --with-monitor_module
2634
2635 # Check whether --with-monitor_module or --without-monitor_module was given.
2636 if test "${with_monitor_module+set}" = set; then
2637   withval="$with_monitor_module"
2638
2639         ol_arg=invalid
2640         for ol_val in static dynamic ; do
2641                 if test "$withval" = "$ol_val" ; then
2642                         ol_arg="$ol_val"
2643                 fi
2644         done
2645         if test "$ol_arg" = "invalid" ; then
2646                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-monitor_module" >&5
2647 echo "$as_me: error: bad value $withval for --with-monitor_module" >&2;}
2648    { (exit 1); exit 1; }; }
2649         fi
2650         ol_with_monitor_module="$ol_arg"
2651
2652 else
2653         ol_with_monitor_module="static"
2654 fi; # end --with-monitor_module
2655
2656 # OpenLDAP --enable-null
2657         # Check whether --enable-null or --disable-null was given.
2658 if test "${enable_null+set}" = set; then
2659   enableval="$enable_null"
2660
2661         ol_arg=invalid
2662         for ol_val in auto yes no ; do
2663                 if test "$enableval" = "$ol_val" ; then
2664                         ol_arg="$ol_val"
2665                 fi
2666         done
2667         if test "$ol_arg" = "invalid" ; then
2668                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2669 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
2670    { (exit 1); exit 1; }; }
2671         fi
2672         ol_enable_null="$ol_arg"
2673
2674 else
2675         ol_enable_null="no"
2676 fi; # end --enable-null
2677 # OpenLDAP --with-null_module
2678
2679 # Check whether --with-null_module or --without-null_module was given.
2680 if test "${with_null_module+set}" = set; then
2681   withval="$with_null_module"
2682
2683         ol_arg=invalid
2684         for ol_val in static dynamic ; do
2685                 if test "$withval" = "$ol_val" ; then
2686                         ol_arg="$ol_val"
2687                 fi
2688         done
2689         if test "$ol_arg" = "invalid" ; then
2690                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-null_module" >&5
2691 echo "$as_me: error: bad value $withval for --with-null_module" >&2;}
2692    { (exit 1); exit 1; }; }
2693         fi
2694         ol_with_null_module="$ol_arg"
2695
2696 else
2697         ol_with_null_module="static"
2698 fi; # end --with-null_module
2699
2700 # OpenLDAP --enable-passwd
2701         # Check whether --enable-passwd or --disable-passwd was given.
2702 if test "${enable_passwd+set}" = set; then
2703   enableval="$enable_passwd"
2704
2705         ol_arg=invalid
2706         for ol_val in auto yes no ; do
2707                 if test "$enableval" = "$ol_val" ; then
2708                         ol_arg="$ol_val"
2709                 fi
2710         done
2711         if test "$ol_arg" = "invalid" ; then
2712                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
2713 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
2714    { (exit 1); exit 1; }; }
2715         fi
2716         ol_enable_passwd="$ol_arg"
2717
2718 else
2719         ol_enable_passwd="no"
2720 fi; # end --enable-passwd
2721 # OpenLDAP --with-passwd_module
2722
2723 # Check whether --with-passwd_module or --without-passwd_module was given.
2724 if test "${with_passwd_module+set}" = set; then
2725   withval="$with_passwd_module"
2726
2727         ol_arg=invalid
2728         for ol_val in static dynamic ; do
2729                 if test "$withval" = "$ol_val" ; then
2730                         ol_arg="$ol_val"
2731                 fi
2732         done
2733         if test "$ol_arg" = "invalid" ; then
2734                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-passwd_module" >&5
2735 echo "$as_me: error: bad value $withval for --with-passwd_module" >&2;}
2736    { (exit 1); exit 1; }; }
2737         fi
2738         ol_with_passwd_module="$ol_arg"
2739
2740 else
2741         ol_with_passwd_module="static"
2742 fi; # end --with-passwd_module
2743
2744 # OpenLDAP --enable-perl
2745         # Check whether --enable-perl or --disable-perl was given.
2746 if test "${enable_perl+set}" = set; then
2747   enableval="$enable_perl"
2748
2749         ol_arg=invalid
2750         for ol_val in auto yes no ; do
2751                 if test "$enableval" = "$ol_val" ; then
2752                         ol_arg="$ol_val"
2753                 fi
2754         done
2755         if test "$ol_arg" = "invalid" ; then
2756                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
2757 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
2758    { (exit 1); exit 1; }; }
2759         fi
2760         ol_enable_perl="$ol_arg"
2761
2762 else
2763         ol_enable_perl="no"
2764 fi; # end --enable-perl
2765 # OpenLDAP --with-perl_module
2766
2767 # Check whether --with-perl_module or --without-perl_module was given.
2768 if test "${with_perl_module+set}" = set; then
2769   withval="$with_perl_module"
2770
2771         ol_arg=invalid
2772         for ol_val in static dynamic ; do
2773                 if test "$withval" = "$ol_val" ; then
2774                         ol_arg="$ol_val"
2775                 fi
2776         done
2777         if test "$ol_arg" = "invalid" ; then
2778                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-perl_module" >&5
2779 echo "$as_me: error: bad value $withval for --with-perl_module" >&2;}
2780    { (exit 1); exit 1; }; }
2781         fi
2782         ol_with_perl_module="$ol_arg"
2783
2784 else
2785         ol_with_perl_module="static"
2786 fi; # end --with-perl_module
2787
2788 # OpenLDAP --enable-shell
2789         # Check whether --enable-shell or --disable-shell was given.
2790 if test "${enable_shell+set}" = set; then
2791   enableval="$enable_shell"
2792
2793         ol_arg=invalid
2794         for ol_val in auto yes no ; do
2795                 if test "$enableval" = "$ol_val" ; then
2796                         ol_arg="$ol_val"
2797                 fi
2798         done
2799         if test "$ol_arg" = "invalid" ; then
2800                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
2801 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
2802    { (exit 1); exit 1; }; }
2803         fi
2804         ol_enable_shell="$ol_arg"
2805
2806 else
2807         ol_enable_shell="no"
2808 fi; # end --enable-shell
2809 # OpenLDAP --with-shell_module
2810
2811 # Check whether --with-shell_module or --without-shell_module was given.
2812 if test "${with_shell_module+set}" = set; then
2813   withval="$with_shell_module"
2814
2815         ol_arg=invalid
2816         for ol_val in static dynamic ; do
2817                 if test "$withval" = "$ol_val" ; then
2818                         ol_arg="$ol_val"
2819                 fi
2820         done
2821         if test "$ol_arg" = "invalid" ; then
2822                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-shell_module" >&5
2823 echo "$as_me: error: bad value $withval for --with-shell_module" >&2;}
2824    { (exit 1); exit 1; }; }
2825         fi
2826         ol_with_shell_module="$ol_arg"
2827
2828 else
2829         ol_with_shell_module="static"
2830 fi; # end --with-shell_module
2831
2832 # OpenLDAP --enable-sql
2833         # Check whether --enable-sql or --disable-sql was given.
2834 if test "${enable_sql+set}" = set; then
2835   enableval="$enable_sql"
2836
2837         ol_arg=invalid
2838         for ol_val in auto yes no ; do
2839                 if test "$enableval" = "$ol_val" ; then
2840                         ol_arg="$ol_val"
2841                 fi
2842         done
2843         if test "$ol_arg" = "invalid" ; then
2844                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
2845 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
2846    { (exit 1); exit 1; }; }
2847         fi
2848         ol_enable_sql="$ol_arg"
2849
2850 else
2851         ol_enable_sql="no"
2852 fi; # end --enable-sql
2853 # OpenLDAP --with-sql_module
2854
2855 # Check whether --with-sql_module or --without-sql_module was given.
2856 if test "${with_sql_module+set}" = set; then
2857   withval="$with_sql_module"
2858
2859         ol_arg=invalid
2860         for ol_val in static dynamic ; do
2861                 if test "$withval" = "$ol_val" ; then
2862                         ol_arg="$ol_val"
2863                 fi
2864         done
2865         if test "$ol_arg" = "invalid" ; then
2866                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-sql_module" >&5
2867 echo "$as_me: error: bad value $withval for --with-sql_module" >&2;}
2868    { (exit 1); exit 1; }; }
2869         fi
2870         ol_with_sql_module="$ol_arg"
2871
2872 else
2873         ol_with_sql_module="static"
2874 fi; # end --with-sql_module
2875
2876 # OpenLDAP --enable-tcl
2877         # Check whether --enable-tcl or --disable-tcl was given.
2878 if test "${enable_tcl+set}" = set; then
2879   enableval="$enable_tcl"
2880
2881         ol_arg=invalid
2882         for ol_val in auto yes no ; do
2883                 if test "$enableval" = "$ol_val" ; then
2884                         ol_arg="$ol_val"
2885                 fi
2886         done
2887         if test "$ol_arg" = "invalid" ; then
2888                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-tcl" >&5
2889 echo "$as_me: error: bad value $enableval for --enable-tcl" >&2;}
2890    { (exit 1); exit 1; }; }
2891         fi
2892         ol_enable_tcl="$ol_arg"
2893
2894 else
2895         ol_enable_tcl="no"
2896 fi; # end --enable-tcl
2897 # OpenLDAP --with-tcl_module
2898
2899 # Check whether --with-tcl_module or --without-tcl_module was given.
2900 if test "${with_tcl_module+set}" = set; then
2901   withval="$with_tcl_module"
2902
2903         ol_arg=invalid
2904         for ol_val in static dynamic ; do
2905                 if test "$withval" = "$ol_val" ; then
2906                         ol_arg="$ol_val"
2907                 fi
2908         done
2909         if test "$ol_arg" = "invalid" ; then
2910                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tcl_module" >&5
2911 echo "$as_me: error: bad value $withval for --with-tcl_module" >&2;}
2912    { (exit 1); exit 1; }; }
2913         fi
2914         ol_with_tcl_module="$ol_arg"
2915
2916 else
2917         ol_with_tcl_module="static"
2918 fi; # end --with-tcl_module
2919
2920
2921
2922 # Check whether --with-xxslurpdoptions or --without-xxslurpdoptions was given.
2923 if test "${with_xxslurpdoptions+set}" = set; then
2924   withval="$with_xxslurpdoptions"
2925
2926 fi;
2927 # OpenLDAP --enable-slurpd
2928         # Check whether --enable-slurpd or --disable-slurpd was given.
2929 if test "${enable_slurpd+set}" = set; then
2930   enableval="$enable_slurpd"
2931
2932         ol_arg=invalid
2933         for ol_val in auto yes no ; do
2934                 if test "$enableval" = "$ol_val" ; then
2935                         ol_arg="$ol_val"
2936                 fi
2937         done
2938         if test "$ol_arg" = "invalid" ; then
2939                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slurpd" >&5
2940 echo "$as_me: error: bad value $enableval for --enable-slurpd" >&2;}
2941    { (exit 1); exit 1; }; }
2942         fi
2943         ol_enable_slurpd="$ol_arg"
2944
2945 else
2946         ol_enable_slurpd="auto"
2947 fi; # end --enable-slurpd
2948
2949
2950 # Check whether --with-xxliboptions or --without-xxliboptions was given.
2951 if test "${with_xxliboptions+set}" = set; then
2952   withval="$with_xxliboptions"
2953
2954 fi;
2955 # Check whether --enable-static or --disable-static was given.
2956 if test "${enable_static+set}" = set; then
2957   enableval="$enable_static"
2958   p=${PACKAGE-default}
2959 case $enableval in
2960 yes) enable_static=yes ;;
2961 no) enable_static=no ;;
2962 *)
2963   enable_static=no
2964   # Look at the argument we got.  We use all the common list separators.
2965   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2966   for pkg in $enableval; do
2967     if test "X$pkg" = "X$p"; then
2968       enable_static=yes
2969     fi
2970   done
2971   IFS="$ac_save_ifs"
2972   ;;
2973 esac
2974 else
2975   enable_static=yes
2976 fi;
2977 # Check whether --enable-shared or --disable-shared was given.
2978 if test "${enable_shared+set}" = set; then
2979   enableval="$enable_shared"
2980   p=${PACKAGE-default}
2981 case $enableval in
2982 yes) enable_shared=yes ;;
2983 no) enable_shared=no ;;
2984 *)
2985   enable_shared=no
2986   # Look at the argument we got.  We use all the common list separators.
2987   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2988   for pkg in $enableval; do
2989     if test "X$pkg" = "X$p"; then
2990       enable_shared=yes
2991     fi
2992   done
2993   IFS="$ac_save_ifs"
2994   ;;
2995 esac
2996 else
2997   enable_shared=yes
2998 fi;
2999
3000
3001 # validate options
3002 if test $ol_enable_slapd = no ; then
3003                 if test $ol_enable_slapi = yes ; then
3004                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3005 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3006         fi
3007         if test $ol_enable_bdb = yes ; then
3008                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-bdb argument" >&5
3009 echo "$as_me: WARNING: slapd disabled, ignoring --enable-bdb argument" >&2;}
3010         fi
3011         if test $ol_enable_dnssrv = yes ; then
3012                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dnssrv argument" >&5
3013 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dnssrv argument" >&2;}
3014         fi
3015         if test $ol_enable_ldap = yes ; then
3016                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-ldap argument" >&5
3017 echo "$as_me: WARNING: slapd disabled, ignoring --enable-ldap argument" >&2;}
3018         fi
3019         if test $ol_enable_ldbm = yes ; then
3020                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-ldbm argument" >&5
3021 echo "$as_me: WARNING: slapd disabled, ignoring --enable-ldbm argument" >&2;}
3022         fi
3023         if test $ol_enable_meta = yes ; then
3024                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-meta argument" >&5
3025 echo "$as_me: WARNING: slapd disabled, ignoring --enable-meta argument" >&2;}
3026         fi
3027         if test $ol_enable_monitor = yes ; then
3028                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-monitor argument" >&5
3029 echo "$as_me: WARNING: slapd disabled, ignoring --enable-monitor argument" >&2;}
3030         fi
3031         if test $ol_enable_null = yes ; then
3032                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-null argument" >&5
3033 echo "$as_me: WARNING: slapd disabled, ignoring --enable-null argument" >&2;}
3034         fi
3035         if test $ol_enable_passwd = yes ; then
3036                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-passwd argument" >&5
3037 echo "$as_me: WARNING: slapd disabled, ignoring --enable-passwd argument" >&2;}
3038         fi
3039         if test $ol_enable_perl = yes ; then
3040                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-perl argument" >&5
3041 echo "$as_me: WARNING: slapd disabled, ignoring --enable-perl argument" >&2;}
3042         fi
3043         if test $ol_enable_shell = yes ; then
3044                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-shell argument" >&5
3045 echo "$as_me: WARNING: slapd disabled, ignoring --enable-shell argument" >&2;}
3046         fi
3047         if test $ol_enable_tcl = yes ; then
3048                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-tcl argument" >&5
3049 echo "$as_me: WARNING: slapd disabled, ignoring --enable-tcl argument" >&2;}
3050         fi
3051         if test $ol_enable_sql = yes ; then
3052                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-sql argument" >&5
3053 echo "$as_me: WARNING: slapd disabled, ignoring --enable-sql argument" >&2;}
3054         fi
3055         if test $ol_enable_modules = yes ; then
3056                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3057 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3058         fi
3059         if test $ol_enable_multimaster = yes ; then
3060                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-multimaster argument" >&5
3061 echo "$as_me: WARNING: slapd disabled, ignoring --enable-multimaster argument" >&2;}
3062         fi
3063         if test $ol_enable_wrappers = yes ; then
3064                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3065 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3066         fi
3067         if test $ol_enable_phonetic = yes ; then
3068                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-phonetic argument" >&5
3069 echo "$as_me: WARNING: slapd disabled, ignoring --enable-phonetic argument" >&2;}
3070         fi
3071         if test $ol_enable_rlookups = yes ; then
3072                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3073 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3074         fi
3075         if test $ol_enable_aci = yes ; then
3076                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3077 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3078         fi
3079         if test $ol_with_ldbm_api != auto ; then
3080                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-api argument" >&5
3081 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-api argument" >&2;}
3082         fi
3083         if test $ol_with_ldbm_type != auto ; then
3084                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-type argument" >&5
3085 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-type argument" >&2;}
3086         fi
3087         if test $ol_with_bdb_module != static ; then
3088                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-bdb-module argument" >&5
3089 echo "$as_me: WARNING: slapd disabled, ignoring --with-bdb-module argument" >&2;}
3090         fi
3091         if test $ol_with_dnssrv_module != static ; then
3092                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-dnssrv-module argument" >&5
3093 echo "$as_me: WARNING: slapd disabled, ignoring --with-dnssrv-module argument" >&2;}
3094         fi
3095         if test $ol_with_ldap_module != static ; then
3096                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldap-module argument" >&5
3097 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldap-module argument" >&2;}
3098         fi
3099         if test $ol_with_ldbm_module != static ; then
3100                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-module argument" >&5
3101 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-module argument" >&2;}
3102         fi
3103         if test $ol_with_meta_module != static ; then
3104                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-meta-module argument" >&5
3105 echo "$as_me: WARNING: slapd disabled, ignoring --with-meta-module argument" >&2;}
3106         fi
3107         if test $ol_with_monitor_module != static ; then
3108                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-monitor-module argument" >&5
3109 echo "$as_me: WARNING: slapd disabled, ignoring --with-monitor-module argument" >&2;}
3110         fi
3111         if test $ol_with_null_module != static ; then
3112                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-null-module argument" >&5
3113 echo "$as_me: WARNING: slapd disabled, ignoring --with-null-module argument" >&2;}
3114         fi
3115         if test $ol_with_passwd_module != static ; then
3116                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-passwd-module argument" >&5
3117 echo "$as_me: WARNING: slapd disabled, ignoring --with-passwd-module argument" >&2;}
3118         fi
3119         if test $ol_with_perl_module != static ; then
3120                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-perl-module argument" >&5
3121 echo "$as_me: WARNING: slapd disabled, ignoring --with-perl-module argument" >&2;}
3122         fi
3123         if test $ol_with_shell_module != static ; then
3124                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-shell-module argument" >&5
3125 echo "$as_me: WARNING: slapd disabled, ignoring --with-shell-module argument" >&2;}
3126         fi
3127         if test $ol_with_tcl_module != static ; then
3128                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-tcl-module argument" >&5
3129 echo "$as_me: WARNING: slapd disabled, ignoring --with-tcl-module argument" >&2;}
3130         fi
3131         if test $ol_with_sql_module != static ; then
3132                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-sql-module argument" >&5
3133 echo "$as_me: WARNING: slapd disabled, ignoring --with-sql-module argument" >&2;}
3134         fi
3135         if test $ol_enable_slurpd = yes ; then
3136                 { { echo "$as_me:$LINENO: error: slurpd requires slapd" >&5
3137 echo "$as_me: error: slurpd requires slapd" >&2;}
3138    { (exit 1); exit 1; }; }
3139         fi
3140         if test $ol_enable_rewrite = yes ; then
3141                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3142 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3143         fi
3144
3145         # force settings to no
3146         ol_enable_slapi=no
3147         ol_enable_bdb=no
3148         ol_enable_dnssrv=no
3149         ol_enable_ldap=no
3150         ol_enable_ldbm=no
3151         ol_enable_meta=no
3152         ol_enable_monitor=no
3153         ol_enable_null=no
3154         ol_enable_passwd=no
3155         ol_enable_perl=no
3156         ol_enable_shell=no
3157         ol_enable_tcl=no
3158         ol_enable_sql=no
3159
3160         ol_enable_modules=no
3161         ol_enable_multimaster=no
3162         ol_enable_phonetic=no
3163         ol_enable_rlookups=no
3164         ol_enable_aci=no
3165         ol_enable_wrappers=no
3166         ol_enable_dynamic=no
3167
3168         ol_with_ldbm_api=no
3169         ol_with_ldbm_type=no
3170
3171         ol_with_bdb_module=static
3172         ol_with_dnssrv_module=static
3173         ol_with_ldap_module=static
3174         ol_with_ldbm_module=static
3175         ol_with_meta_module=static
3176         ol_with_monitor_module=static
3177         ol_with_null_module=static
3178         ol_with_passwd_module=static
3179         ol_with_perl_module=static
3180         ol_with_shell_module=static
3181         ol_with_tcl_module=static
3182         ol_with_sql_module=static
3183
3184         ol_enable_slurpd=no
3185
3186         ol_enable_rewrite=no
3187
3188 elif test $ol_enable_ldbm = no ; then
3189
3190         if test $ol_with_ldbm_api != auto ; then
3191                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-api argument" >&5
3192 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-api argument" >&2;}
3193         fi
3194
3195         if test $ol_with_ldbm_type != auto ; then
3196                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-type argument" >&5
3197 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-type argument" >&2;}
3198         fi
3199
3200         if test $ol_with_ldbm_module != static ; then
3201                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-module argument" >&5
3202 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-module argument" >&2;}
3203         fi
3204
3205         if test $ol_enable_modules != yes -a \
3206                 $ol_enable_bdb = no -a \
3207                 $ol_enable_dnssrv = no -a \
3208                 $ol_enable_ldap = no -a \
3209                 $ol_enable_meta = no -a \
3210                 $ol_enable_monitor = no -a \
3211                 $ol_enable_null = no -a \
3212                 $ol_enable_passwd = no -a \
3213                 $ol_enable_perl = no -a \
3214                 $ol_enable_shell = no -a \
3215                 $ol_enable_sql = no -a \
3216                 $ol_enable_tcl = no ; then
3217
3218                 if test $ol_enable_slapd = yes ; then
3219                         { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3220 echo "$as_me: error: slapd requires a backend" >&2;}
3221    { (exit 1); exit 1; }; }
3222                 else
3223                         { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3224 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3225                         ol_enable_slapd=no
3226                 fi
3227         fi
3228
3229         ol_with_ldbm_api=no
3230         ol_with_ldbm_type=no
3231         ol_with_ldbm_module=static
3232
3233         if test $ol_enable_bdb != no ; then
3234                 ol_with_ldbm_api=berkeley
3235         fi
3236
3237 else
3238                 if test $ol_with_ldbm_api = gdbm -a \
3239                 $ol_with_ldbm_type = btree ; then
3240                 { { echo "$as_me:$LINENO: error: GDBM only supports LDBM type hash" >&5
3241 echo "$as_me: error: GDBM only supports LDBM type hash" >&2;}
3242    { (exit 1); exit 1; }; }
3243         fi
3244         if test $ol_with_ldbm_api = mdbm -a \
3245                 $ol_with_ldbm_type = btree ; then
3246                 { { echo "$as_me:$LINENO: error: MDBM only supports LDBM type hash" >&5
3247 echo "$as_me: error: MDBM only supports LDBM type hash" >&2;}
3248    { (exit 1); exit 1; }; }
3249         fi
3250         if test $ol_with_ldbm_api = ndbm -a \
3251                 $ol_with_ldbm_type = btree ; then
3252                 { { echo "$as_me:$LINENO: error: NDBM only supports LDBM type hash" >&5
3253 echo "$as_me: error: NDBM only supports LDBM type hash" >&2;}
3254    { (exit 1); exit 1; }; }
3255         fi
3256
3257         if test $ol_enable_bdb = yes ; then
3258                 if test $ol_with_ldbm_api = auto ; then
3259                         ol_with_ldbm_api=berkeley
3260                 elif test $ol_with_ldbm_api != berkeley ; then
3261                         { { echo "$as_me:$LINENO: error: LDBM API not compatible with BDB" >&5
3262 echo "$as_me: error: LDBM API not compatible with BDB" >&2;}
3263    { (exit 1); exit 1; }; }
3264                 fi
3265
3266         elif test $ol_enable_bdb = auto ; then
3267                 if test $ol_with_ldbm_api != berkeley \
3268                         -o $ol_with_ldbm_api != auto ; then
3269                         { echo "$as_me:$LINENO: WARNING: LDBM API not compatible with BDB, disabling BDB" >&5
3270 echo "$as_me: WARNING: LDBM API not compatible with BDB, disabling BDB" >&2;}
3271                         ol_enable_bdb=no
3272                 fi
3273         fi
3274 fi
3275
3276 if test $ol_enable_slurpd = yes ; then
3277                 if test $ol_with_threads = no ; then
3278                 { { echo "$as_me:$LINENO: error: slurpd requires threads" >&5
3279 echo "$as_me: error: slurpd requires threads" >&2;}
3280    { (exit 1); exit 1; }; }
3281         fi
3282 fi
3283
3284 if test $ol_enable_lmpasswd = yes ; then
3285         if test $ol_with_tls = no ; then
3286                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3287 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3288    { (exit 1); exit 1; }; }
3289         fi
3290 fi
3291
3292 if test $ol_enable_kbind = yes -o $ol_enable_kpasswd = yes ; then
3293         if test $ol_with_kerberos = no ; then
3294                 { { echo "$as_me:$LINENO: error: options require --with-kerberos" >&5
3295 echo "$as_me: error: options require --with-kerberos" >&2;}
3296    { (exit 1); exit 1; }; }
3297         elif test $ol_with_kerberos = auto ; then
3298                 ol_with_kerberos=yes
3299         fi
3300
3301 elif test $ol_enable_kbind = no -o $ol_enable_kpasswd = no ; then
3302         if test $ol_with_kerberos = auto ; then
3303                 ol_with_kerberos=no
3304         elif test $ol_with_kerberos != no ; then
3305                 { echo "$as_me:$LINENO: WARNING: Kerberos detection enabled unnecessarily" >&5
3306 echo "$as_me: WARNING: Kerberos detection enabled unnecessarily" >&2;};
3307                 ol_with_kerberos=no
3308         fi
3309 fi
3310
3311 if test $ol_enable_spasswd = yes ; then
3312         if test $ol_with_cyrus_sasl = no ; then
3313                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3314 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3315    { (exit 1); exit 1; }; }
3316         fi
3317         ol_with_cyrus_sasl=yes
3318 fi
3319
3320 echo "$as_me:$LINENO: result: done" >&5
3321 echo "${ECHO_T}done" >&6
3322
3323 LDAP_LIBS=
3324 LDIF_LIBS=
3325 LDBM_LIBS=
3326 LTHREAD_LIBS=
3327 LUTIL_LIBS=
3328
3329 SLAPD_LIBS=
3330 SLURPD_LIBS=
3331
3332 BUILD_SLAPD=no
3333 BUILD_SLURPD=no
3334
3335 BUILD_THREAD=no
3336
3337 BUILD_SLAPI=no
3338 SLAPD_SLAPI_DEPEND=
3339
3340 BUILD_BDB=no
3341 BUILD_DNSSRV=no
3342 BUILD_LDAP=no
3343 BUILD_LDBM=no
3344 BUILD_META=no
3345 BUILD_MONITOR=no
3346 BUILD_NULL=no
3347 BUILD_PASSWD=no
3348 BUILD_PERL=no
3349 BUILD_SHELL=no
3350 BUILD_SQL=no
3351 BUILD_TCL=no
3352
3353 BUILD_BDB_DYNAMIC=static
3354 BUILD_DNSSRV_DYNAMIC=static
3355 BUILD_LDAP_DYNAMIC=static
3356 BUILD_LDBM_DYNAMIC=static
3357 BUILD_META_DYNAMIC=static
3358 BUILD_MONITOR_DYNAMIC=static
3359 BUILD_NULL_DYNAMIC=static
3360 BUILD_PASSWD_DYNAMIC=static
3361 BUILD_PERL_DYNAMIC=static
3362 BUILD_SHELL_DYNAMIC=static
3363 BUILD_TCL_DYNAMIC=static
3364 BUILD_SQL_DYNAMIC=static
3365
3366 SLAPD_MODULES_LDFLAGS=
3367 SLAPD_MODULES_CPPFLAGS=
3368
3369 SLAPD_STATIC_BACKENDS=
3370 SLAPD_DYNAMIC_BACKENDS=
3371
3372 SLAPD_PERL_LDFLAGS=
3373 MOD_PERL_LDFLAGS=
3374 PERL_CPPFLAGS=
3375
3376 SLAPD_SQL_LDFLAGS=
3377 SLAPD_SQL_LIBS=
3378 SLAPD_SQL_INCLUDES=
3379
3380 MOD_TCL_LIB=
3381 KRB4_LIBS=
3382 KRB5_LIBS=
3383 READLINE_LIBS=
3384 SASL_LIBS=
3385 TERMCAP_LIBS=
3386 TLS_LIBS=
3387 MODULES_LIBS=
3388 SLAPI_LIBS=
3389 LIBSLAPI=
3390 LIBSLAPITOOLS=
3391 AUTH_LIBS=
3392
3393 SLAPD_SLP_LIBS=
3394
3395
3396 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3397 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
3398 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3399 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3400   echo $ECHO_N "(cached) $ECHO_C" >&6
3401 else
3402   cat >conftest.make <<\_ACEOF
3403 all:
3404         @echo 'ac_maketemp="$(MAKE)"'
3405 _ACEOF
3406 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3407 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3408 if test -n "$ac_maketemp"; then
3409   eval ac_cv_prog_make_${ac_make}_set=yes
3410 else
3411   eval ac_cv_prog_make_${ac_make}_set=no
3412 fi
3413 rm -f conftest.make
3414 fi
3415 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3416   echo "$as_me:$LINENO: result: yes" >&5
3417 echo "${ECHO_T}yes" >&6
3418   SET_MAKE=
3419 else
3420   echo "$as_me:$LINENO: result: no" >&5
3421 echo "${ECHO_T}no" >&6
3422   SET_MAKE="MAKE=${MAKE-make}"
3423 fi
3424
3425 # Find a good install program.  We prefer a C program (faster),
3426 # so one script is as good as another.  But avoid the broken or
3427 # incompatible versions:
3428 # SysV /etc/install, /usr/sbin/install
3429 # SunOS /usr/etc/install
3430 # IRIX /sbin/install
3431 # AIX /bin/install
3432 # AmigaOS /C/install, which installs bootblocks on floppy discs
3433 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3434 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3435 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3436 # ./install, which can be erroneously created by make from ./install.sh.
3437 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3438 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
3439 if test -z "$INSTALL"; then
3440 if test "${ac_cv_path_install+set}" = set; then
3441   echo $ECHO_N "(cached) $ECHO_C" >&6
3442 else
3443   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3444 for as_dir in $PATH
3445 do
3446   IFS=$as_save_IFS
3447   test -z "$as_dir" && as_dir=.
3448   # Account for people who put trailing slashes in PATH elements.
3449 case $as_dir/ in
3450   ./ | .// | /cC/* | \
3451   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3452   /usr/ucb/* ) ;;
3453   *)
3454     # OSF1 and SCO ODT 3.0 have their own names for install.
3455     # Don't use installbsd from OSF since it installs stuff as root
3456     # by default.
3457     for ac_prog in ginstall scoinst install; do
3458       for ac_exec_ext in '' $ac_executable_extensions; do
3459         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3460           if test $ac_prog = install &&
3461             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3462             # AIX install.  It has an incompatible calling convention.
3463             :
3464           elif test $ac_prog = install &&
3465             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3466             # program-specific install script used by HP pwplus--don't use.
3467             :
3468           else
3469             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3470             break 3
3471           fi
3472         fi
3473       done
3474     done
3475     ;;
3476 esac
3477 done
3478
3479
3480 fi
3481   if test "${ac_cv_path_install+set}" = set; then
3482     INSTALL=$ac_cv_path_install
3483   else
3484     # As a last resort, use the slow shell script.  We don't cache a
3485     # path for INSTALL within a source directory, because that will
3486     # break other packages using the cache if that directory is
3487     # removed, or if the path is relative.
3488     INSTALL=$ac_install_sh
3489   fi
3490 fi
3491 echo "$as_me:$LINENO: result: $INSTALL" >&5
3492 echo "${ECHO_T}$INSTALL" >&6
3493
3494 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3495 # It thinks the first close brace ends the variable substitution.
3496 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3497
3498 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3499
3500 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3501
3502
3503         MKINSTALLDIRS=
3504   if test -n "$ac_aux_dir"; then
3505     MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
3506   fi
3507   if test -z "$MKINSTALLDIRS"; then
3508     MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
3509   fi
3510
3511
3512
3513
3514
3515         # Extract the first word of "msgfmt", so it can be a program name with args.
3516 set dummy msgfmt; ac_word=$2
3517 echo "$as_me:$LINENO: checking for $ac_word" >&5
3518 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3519 if test "${ac_cv_path_MSGFMT+set}" = set; then
3520   echo $ECHO_N "(cached) $ECHO_C" >&6
3521 else
3522   case "$MSGFMT" in
3523   /*)
3524   ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
3525   ;;
3526   *)
3527   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3528   for ac_dir in $PATH; do
3529     test -z "$ac_dir" && ac_dir=.
3530     if test -f $ac_dir/$ac_word; then
3531       if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
3532      (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
3533         ac_cv_path_MSGFMT="$ac_dir/$ac_word"
3534         break
3535       fi
3536     fi
3537   done
3538   IFS="$ac_save_ifs"
3539   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
3540   ;;
3541 esac
3542 fi
3543 MSGFMT="$ac_cv_path_MSGFMT"
3544 if test "$MSGFMT" != ":"; then
3545   echo "$as_me:$LINENO: result: $MSGFMT" >&5
3546 echo "${ECHO_T}$MSGFMT" >&6
3547 else
3548   echo "$as_me:$LINENO: result: no" >&5
3549 echo "${ECHO_T}no" >&6
3550 fi
3551
3552   # Extract the first word of "gmsgfmt", so it can be a program name with args.
3553 set dummy gmsgfmt; 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_path_GMSGFMT+set}" = set; then
3557   echo $ECHO_N "(cached) $ECHO_C" >&6
3558 else
3559   case $GMSGFMT in
3560   [\\/]* | ?:[\\/]*)
3561   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
3562   ;;
3563   *)
3564   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3565 for as_dir in $PATH
3566 do
3567   IFS=$as_save_IFS
3568   test -z "$as_dir" && as_dir=.
3569   for ac_exec_ext in '' $ac_executable_extensions; do
3570   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3571     ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
3572     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3573     break 2
3574   fi
3575 done
3576 done
3577
3578   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
3579   ;;
3580 esac
3581 fi
3582 GMSGFMT=$ac_cv_path_GMSGFMT
3583
3584 if test -n "$GMSGFMT"; then
3585   echo "$as_me:$LINENO: result: $GMSGFMT" >&5
3586 echo "${ECHO_T}$GMSGFMT" >&6
3587 else
3588   echo "$as_me:$LINENO: result: no" >&5
3589 echo "${ECHO_T}no" >&6
3590 fi
3591
3592
3593         # Extract the first word of "xgettext", so it can be a program name with args.
3594 set dummy xgettext; ac_word=$2
3595 echo "$as_me:$LINENO: checking for $ac_word" >&5
3596 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3597 if test "${ac_cv_path_XGETTEXT+set}" = set; then
3598   echo $ECHO_N "(cached) $ECHO_C" >&6
3599 else
3600   case "$XGETTEXT" in
3601   /*)
3602   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
3603   ;;
3604   *)
3605   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3606   for ac_dir in $PATH; do
3607     test -z "$ac_dir" && ac_dir=.
3608     if test -f $ac_dir/$ac_word; then
3609       if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 &&
3610      (if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
3611         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
3612         break
3613       fi
3614     fi
3615   done
3616   IFS="$ac_save_ifs"
3617   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
3618   ;;
3619 esac
3620 fi
3621 XGETTEXT="$ac_cv_path_XGETTEXT"
3622 if test "$XGETTEXT" != ":"; then
3623   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
3624 echo "${ECHO_T}$XGETTEXT" >&6
3625 else
3626   echo "$as_me:$LINENO: result: no" >&5
3627 echo "${ECHO_T}no" >&6
3628 fi
3629
3630     rm -f messages.po
3631
3632     # Extract the first word of "msgmerge", so it can be a program name with args.
3633 set dummy msgmerge; ac_word=$2
3634 echo "$as_me:$LINENO: checking for $ac_word" >&5
3635 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3636 if test "${ac_cv_path_MSGMERGE+set}" = set; then
3637   echo $ECHO_N "(cached) $ECHO_C" >&6
3638 else
3639   case "$MSGMERGE" in
3640   /*)
3641   ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
3642   ;;
3643   *)
3644   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3645   for ac_dir in $PATH; do
3646     test -z "$ac_dir" && ac_dir=.
3647     if test -f $ac_dir/$ac_word; then
3648       if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
3649         ac_cv_path_MSGMERGE="$ac_dir/$ac_word"
3650         break
3651       fi
3652     fi
3653   done
3654   IFS="$ac_save_ifs"
3655   test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
3656   ;;
3657 esac
3658 fi
3659 MSGMERGE="$ac_cv_path_MSGMERGE"
3660 if test "$MSGMERGE" != ":"; then
3661   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
3662 echo "${ECHO_T}$MSGMERGE" >&6
3663 else
3664   echo "$as_me:$LINENO: result: no" >&5
3665 echo "${ECHO_T}no" >&6
3666 fi
3667
3668
3669       if test "$GMSGFMT" != ":"; then
3670             if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
3671        (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
3672       : ;
3673     else
3674       GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
3675       echo "$as_me:$LINENO: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
3676 echo "${ECHO_T}found $GMSGFMT program is not GNU msgfmt; ignore it" >&6
3677       GMSGFMT=":"
3678     fi
3679   fi
3680
3681       if test "$XGETTEXT" != ":"; then
3682             if $XGETTEXT --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 &&
3683        (if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
3684       : ;
3685     else
3686       echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5
3687 echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6
3688       XGETTEXT=":"
3689     fi
3690         rm -f messages.po
3691   fi
3692
3693             ac_config_commands="$ac_config_commands default-1"
3694
3695
3696
3697       if test "X$prefix" = "XNONE"; then
3698     acl_final_prefix="$ac_default_prefix"
3699   else
3700     acl_final_prefix="$prefix"
3701   fi
3702   if test "X$exec_prefix" = "XNONE"; then
3703     acl_final_exec_prefix='${prefix}'
3704   else
3705     acl_final_exec_prefix="$exec_prefix"
3706   fi
3707   acl_save_prefix="$prefix"
3708   prefix="$acl_final_prefix"
3709   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
3710   prefix="$acl_save_prefix"
3711
3712 ac_ext=c
3713 ac_cpp='$CPP $CPPFLAGS'
3714 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3715 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3716 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3717 if test -n "$ac_tool_prefix"; then
3718   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3719 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3720 echo "$as_me:$LINENO: checking for $ac_word" >&5
3721 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3722 if test "${ac_cv_prog_CC+set}" = set; then
3723   echo $ECHO_N "(cached) $ECHO_C" >&6
3724 else
3725   if test -n "$CC"; then
3726   ac_cv_prog_CC="$CC" # Let the user override the test.
3727 else
3728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3729 for as_dir in $PATH
3730 do
3731   IFS=$as_save_IFS
3732   test -z "$as_dir" && as_dir=.
3733   for ac_exec_ext in '' $ac_executable_extensions; do
3734   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3735     ac_cv_prog_CC="${ac_tool_prefix}gcc"
3736     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3737     break 2
3738   fi
3739 done
3740 done
3741
3742 fi
3743 fi
3744 CC=$ac_cv_prog_CC
3745 if test -n "$CC"; then
3746   echo "$as_me:$LINENO: result: $CC" >&5
3747 echo "${ECHO_T}$CC" >&6
3748 else
3749   echo "$as_me:$LINENO: result: no" >&5
3750 echo "${ECHO_T}no" >&6
3751 fi
3752
3753 fi
3754 if test -z "$ac_cv_prog_CC"; then
3755   ac_ct_CC=$CC
3756   # Extract the first word of "gcc", so it can be a program name with args.
3757 set dummy gcc; ac_word=$2
3758 echo "$as_me:$LINENO: checking for $ac_word" >&5
3759 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3760 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3761   echo $ECHO_N "(cached) $ECHO_C" >&6
3762 else
3763   if test -n "$ac_ct_CC"; then
3764   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3765 else
3766 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3767 for as_dir in $PATH
3768 do
3769   IFS=$as_save_IFS
3770   test -z "$as_dir" && as_dir=.
3771   for ac_exec_ext in '' $ac_executable_extensions; do
3772   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3773     ac_cv_prog_ac_ct_CC="gcc"
3774     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3775     break 2
3776   fi
3777 done
3778 done
3779
3780 fi
3781 fi
3782 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3783 if test -n "$ac_ct_CC"; then
3784   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3785 echo "${ECHO_T}$ac_ct_CC" >&6
3786 else
3787   echo "$as_me:$LINENO: result: no" >&5
3788 echo "${ECHO_T}no" >&6
3789 fi
3790
3791   CC=$ac_ct_CC
3792 else
3793   CC="$ac_cv_prog_CC"
3794 fi
3795
3796 if test -z "$CC"; then
3797   if test -n "$ac_tool_prefix"; then
3798   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3799 set dummy ${ac_tool_prefix}cc; ac_word=$2
3800 echo "$as_me:$LINENO: checking for $ac_word" >&5
3801 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3802 if test "${ac_cv_prog_CC+set}" = set; then
3803   echo $ECHO_N "(cached) $ECHO_C" >&6
3804 else
3805   if test -n "$CC"; then
3806   ac_cv_prog_CC="$CC" # Let the user override the test.
3807 else
3808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3809 for as_dir in $PATH
3810 do
3811   IFS=$as_save_IFS
3812   test -z "$as_dir" && as_dir=.
3813   for ac_exec_ext in '' $ac_executable_extensions; do
3814   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3815     ac_cv_prog_CC="${ac_tool_prefix}cc"
3816     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3817     break 2
3818   fi
3819 done
3820 done
3821
3822 fi
3823 fi
3824 CC=$ac_cv_prog_CC
3825 if test -n "$CC"; then
3826   echo "$as_me:$LINENO: result: $CC" >&5
3827 echo "${ECHO_T}$CC" >&6
3828 else
3829   echo "$as_me:$LINENO: result: no" >&5
3830 echo "${ECHO_T}no" >&6
3831 fi
3832
3833 fi
3834 if test -z "$ac_cv_prog_CC"; then
3835   ac_ct_CC=$CC
3836   # Extract the first word of "cc", so it can be a program name with args.
3837 set dummy cc; ac_word=$2
3838 echo "$as_me:$LINENO: checking for $ac_word" >&5
3839 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3840 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3841   echo $ECHO_N "(cached) $ECHO_C" >&6
3842 else
3843   if test -n "$ac_ct_CC"; then
3844   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3845 else
3846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3847 for as_dir in $PATH
3848 do
3849   IFS=$as_save_IFS
3850   test -z "$as_dir" && as_dir=.
3851   for ac_exec_ext in '' $ac_executable_extensions; do
3852   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3853     ac_cv_prog_ac_ct_CC="cc"
3854     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3855     break 2
3856   fi
3857 done
3858 done
3859
3860 fi
3861 fi
3862 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3863 if test -n "$ac_ct_CC"; then
3864   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3865 echo "${ECHO_T}$ac_ct_CC" >&6
3866 else
3867   echo "$as_me:$LINENO: result: no" >&5
3868 echo "${ECHO_T}no" >&6
3869 fi
3870
3871   CC=$ac_ct_CC
3872 else
3873   CC="$ac_cv_prog_CC"
3874 fi
3875
3876 fi
3877 if test -z "$CC"; then
3878   # Extract the first word of "cc", so it can be a program name with args.
3879 set dummy cc; ac_word=$2
3880 echo "$as_me:$LINENO: checking for $ac_word" >&5
3881 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3882 if test "${ac_cv_prog_CC+set}" = set; then
3883   echo $ECHO_N "(cached) $ECHO_C" >&6
3884 else
3885   if test -n "$CC"; then
3886   ac_cv_prog_CC="$CC" # Let the user override the test.
3887 else
3888   ac_prog_rejected=no
3889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3890 for as_dir in $PATH
3891 do
3892   IFS=$as_save_IFS
3893   test -z "$as_dir" && as_dir=.
3894   for ac_exec_ext in '' $ac_executable_extensions; do
3895   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3896     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3897        ac_prog_rejected=yes
3898        continue
3899      fi
3900     ac_cv_prog_CC="cc"
3901     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3902     break 2
3903   fi
3904 done
3905 done
3906
3907 if test $ac_prog_rejected = yes; then
3908   # We found a bogon in the path, so make sure we never use it.
3909   set dummy $ac_cv_prog_CC
3910   shift
3911   if test $# != 0; then
3912     # We chose a different compiler from the bogus one.
3913     # However, it has the same basename, so the bogon will be chosen
3914     # first if we set CC to just the basename; use the full file name.
3915     shift
3916     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3917   fi
3918 fi
3919 fi
3920 fi
3921 CC=$ac_cv_prog_CC
3922 if test -n "$CC"; then
3923   echo "$as_me:$LINENO: result: $CC" >&5
3924 echo "${ECHO_T}$CC" >&6
3925 else
3926   echo "$as_me:$LINENO: result: no" >&5
3927 echo "${ECHO_T}no" >&6
3928 fi
3929
3930 fi
3931 if test -z "$CC"; then
3932   if test -n "$ac_tool_prefix"; then
3933   for ac_prog in cl
3934   do
3935     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3936 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3937 echo "$as_me:$LINENO: checking for $ac_word" >&5
3938 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3939 if test "${ac_cv_prog_CC+set}" = set; then
3940   echo $ECHO_N "(cached) $ECHO_C" >&6
3941 else
3942   if test -n "$CC"; then
3943   ac_cv_prog_CC="$CC" # Let the user override the test.
3944 else
3945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3946 for as_dir in $PATH
3947 do
3948   IFS=$as_save_IFS
3949   test -z "$as_dir" && as_dir=.
3950   for ac_exec_ext in '' $ac_executable_extensions; do
3951   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3952     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3953     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3954     break 2
3955   fi
3956 done
3957 done
3958
3959 fi
3960 fi
3961 CC=$ac_cv_prog_CC
3962 if test -n "$CC"; then
3963   echo "$as_me:$LINENO: result: $CC" >&5
3964 echo "${ECHO_T}$CC" >&6
3965 else
3966   echo "$as_me:$LINENO: result: no" >&5
3967 echo "${ECHO_T}no" >&6
3968 fi
3969
3970     test -n "$CC" && break
3971   done
3972 fi
3973 if test -z "$CC"; then
3974   ac_ct_CC=$CC
3975   for ac_prog in cl
3976 do
3977   # Extract the first word of "$ac_prog", so it can be a program name with args.
3978 set dummy $ac_prog; ac_word=$2
3979 echo "$as_me:$LINENO: checking for $ac_word" >&5
3980 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3981 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3982   echo $ECHO_N "(cached) $ECHO_C" >&6
3983 else
3984   if test -n "$ac_ct_CC"; then
3985   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3986 else
3987 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3988 for as_dir in $PATH
3989 do
3990   IFS=$as_save_IFS
3991   test -z "$as_dir" && as_dir=.
3992   for ac_exec_ext in '' $ac_executable_extensions; do
3993   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3994     ac_cv_prog_ac_ct_CC="$ac_prog"
3995     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3996     break 2
3997   fi
3998 done
3999 done
4000
4001 fi
4002 fi
4003 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4004 if test -n "$ac_ct_CC"; then
4005   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4006 echo "${ECHO_T}$ac_ct_CC" >&6
4007 else
4008   echo "$as_me:$LINENO: result: no" >&5
4009 echo "${ECHO_T}no" >&6
4010 fi
4011
4012   test -n "$ac_ct_CC" && break
4013 done
4014
4015   CC=$ac_ct_CC
4016 fi
4017
4018 fi
4019
4020
4021 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4022 See \`config.log' for more details." >&5
4023 echo "$as_me: error: no acceptable C compiler found in \$PATH
4024 See \`config.log' for more details." >&2;}
4025    { (exit 1); exit 1; }; }
4026
4027 # Provide some information about the compiler.
4028 echo "$as_me:$LINENO:" \
4029      "checking for C compiler version" >&5
4030 ac_compiler=`set X $ac_compile; echo $2`
4031 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4032   (eval $ac_compiler --version </dev/null >&5) 2>&5
4033   ac_status=$?
4034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4035   (exit $ac_status); }
4036 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4037   (eval $ac_compiler -v </dev/null >&5) 2>&5
4038   ac_status=$?
4039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4040   (exit $ac_status); }
4041 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4042   (eval $ac_compiler -V </dev/null >&5) 2>&5
4043   ac_status=$?
4044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4045   (exit $ac_status); }
4046
4047 cat >conftest.$ac_ext <<_ACEOF
4048 #line $LINENO "configure"
4049 /* confdefs.h.  */
4050 _ACEOF
4051 cat confdefs.h >>conftest.$ac_ext
4052 cat >>conftest.$ac_ext <<_ACEOF
4053 /* end confdefs.h.  */
4054
4055 int
4056 main ()
4057 {
4058
4059   ;
4060   return 0;
4061 }
4062 _ACEOF
4063 ac_clean_files_save=$ac_clean_files
4064 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4065 # Try to create an executable without -o first, disregard a.out.
4066 # It will help us diagnose broken compilers, and finding out an intuition
4067 # of exeext.
4068 echo "$as_me:$LINENO: checking for C compiler default output" >&5
4069 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
4070 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4071 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4072   (eval $ac_link_default) 2>&5
4073   ac_status=$?
4074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4075   (exit $ac_status); }; then
4076   # Find the output, starting from the most likely.  This scheme is
4077 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4078 # resort.
4079
4080 # Be careful to initialize this variable, since it used to be cached.
4081 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4082 ac_cv_exeext=
4083 # b.out is created by i960 compilers.
4084 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4085 do
4086   test -f "$ac_file" || continue
4087   case $ac_file in
4088     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4089         ;;
4090     conftest.$ac_ext )
4091         # This is the source file.
4092         ;;
4093     [ab].out )
4094         # We found the default executable, but exeext='' is most
4095         # certainly right.
4096         break;;
4097     *.* )
4098         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4099         # FIXME: I believe we export ac_cv_exeext for Libtool,
4100         # but it would be cool to find out if it's true.  Does anybody
4101         # maintain Libtool? --akim.
4102         export ac_cv_exeext
4103         break;;
4104     * )
4105         break;;
4106   esac
4107 done
4108 else
4109   echo "$as_me: failed program was:" >&5
4110 sed 's/^/| /' conftest.$ac_ext >&5
4111
4112 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4113 See \`config.log' for more details." >&5
4114 echo "$as_me: error: C compiler cannot create executables
4115 See \`config.log' for more details." >&2;}
4116    { (exit 77); exit 77; }; }
4117 fi
4118
4119 ac_exeext=$ac_cv_exeext
4120 echo "$as_me:$LINENO: result: $ac_file" >&5
4121 echo "${ECHO_T}$ac_file" >&6
4122
4123 # Check the compiler produces executables we can run.  If not, either
4124 # the compiler is broken, or we cross compile.
4125 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4126 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4127 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4128 # If not cross compiling, check that we can run a simple program.
4129 if test "$cross_compiling" != yes; then
4130   if { ac_try='./$ac_file'
4131   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4132   (eval $ac_try) 2>&5
4133   ac_status=$?
4134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4135   (exit $ac_status); }; }; then
4136     cross_compiling=no
4137   else
4138     if test "$cross_compiling" = maybe; then
4139         cross_compiling=yes
4140     else
4141         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4142 If you meant to cross compile, use \`--host'.
4143 See \`config.log' for more details." >&5
4144 echo "$as_me: error: cannot run C compiled programs.
4145 If you meant to cross compile, use \`--host'.
4146 See \`config.log' for more details." >&2;}
4147    { (exit 1); exit 1; }; }
4148     fi
4149   fi
4150 fi
4151 echo "$as_me:$LINENO: result: yes" >&5
4152 echo "${ECHO_T}yes" >&6
4153
4154 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4155 ac_clean_files=$ac_clean_files_save
4156 # Check the compiler produces executables we can run.  If not, either
4157 # the compiler is broken, or we cross compile.
4158 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4159 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4160 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4161 echo "${ECHO_T}$cross_compiling" >&6
4162
4163 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4164 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4165 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4166   (eval $ac_link) 2>&5
4167   ac_status=$?
4168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4169   (exit $ac_status); }; then
4170   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4171 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4172 # work properly (i.e., refer to `conftest.exe'), while it won't with
4173 # `rm'.
4174 for ac_file in conftest.exe conftest conftest.*; do
4175   test -f "$ac_file" || continue
4176   case $ac_file in
4177     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4178     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4179           export ac_cv_exeext
4180           break;;
4181     * ) break;;
4182   esac
4183 done
4184 else
4185   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4186 See \`config.log' for more details." >&5
4187 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4188 See \`config.log' for more details." >&2;}
4189    { (exit 1); exit 1; }; }
4190 fi
4191
4192 rm -f conftest$ac_cv_exeext
4193 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4194 echo "${ECHO_T}$ac_cv_exeext" >&6
4195
4196 rm -f conftest.$ac_ext
4197 EXEEXT=$ac_cv_exeext
4198 ac_exeext=$EXEEXT
4199 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4200 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4201 if test "${ac_cv_objext+set}" = set; then
4202   echo $ECHO_N "(cached) $ECHO_C" >&6
4203 else
4204   cat >conftest.$ac_ext <<_ACEOF
4205 #line $LINENO "configure"
4206 /* confdefs.h.  */
4207 _ACEOF
4208 cat confdefs.h >>conftest.$ac_ext
4209 cat >>conftest.$ac_ext <<_ACEOF
4210 /* end confdefs.h.  */
4211
4212 int
4213 main ()
4214 {
4215
4216   ;
4217   return 0;
4218 }
4219 _ACEOF
4220 rm -f conftest.o conftest.obj
4221 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4222   (eval $ac_compile) 2>&5
4223   ac_status=$?
4224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4225   (exit $ac_status); }; then
4226   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4227   case $ac_file in
4228     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4229     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4230        break;;
4231   esac
4232 done
4233 else
4234   echo "$as_me: failed program was:" >&5
4235 sed 's/^/| /' conftest.$ac_ext >&5
4236
4237 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4238 See \`config.log' for more details." >&5
4239 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4240 See \`config.log' for more details." >&2;}
4241    { (exit 1); exit 1; }; }
4242 fi
4243
4244 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4245 fi
4246 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4247 echo "${ECHO_T}$ac_cv_objext" >&6
4248 OBJEXT=$ac_cv_objext
4249 ac_objext=$OBJEXT
4250 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4251 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4252 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4253   echo $ECHO_N "(cached) $ECHO_C" >&6
4254 else
4255   cat >conftest.$ac_ext <<_ACEOF
4256 #line $LINENO "configure"
4257 /* confdefs.h.  */
4258 _ACEOF
4259 cat confdefs.h >>conftest.$ac_ext
4260 cat >>conftest.$ac_ext <<_ACEOF
4261 /* end confdefs.h.  */
4262
4263 int
4264 main ()
4265 {
4266 #ifndef __GNUC__
4267        choke me
4268 #endif
4269
4270   ;
4271   return 0;
4272 }
4273 _ACEOF
4274 rm -f conftest.$ac_objext
4275 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4276   (eval $ac_compile) 2>&5
4277   ac_status=$?
4278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4279   (exit $ac_status); } &&
4280          { ac_try='test -s conftest.$ac_objext'
4281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4282   (eval $ac_try) 2>&5
4283   ac_status=$?
4284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4285   (exit $ac_status); }; }; then
4286   ac_compiler_gnu=yes
4287 else
4288   echo "$as_me: failed program was:" >&5
4289 sed 's/^/| /' conftest.$ac_ext >&5
4290
4291 ac_compiler_gnu=no
4292 fi
4293 rm -f conftest.$ac_objext conftest.$ac_ext
4294 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4295
4296 fi
4297 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4298 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4299 GCC=`test $ac_compiler_gnu = yes && echo yes`
4300 ac_test_CFLAGS=${CFLAGS+set}
4301 ac_save_CFLAGS=$CFLAGS
4302 CFLAGS="-g"
4303 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4304 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4305 if test "${ac_cv_prog_cc_g+set}" = set; then
4306   echo $ECHO_N "(cached) $ECHO_C" >&6
4307 else
4308   cat >conftest.$ac_ext <<_ACEOF
4309 #line $LINENO "configure"
4310 /* confdefs.h.  */
4311 _ACEOF
4312 cat confdefs.h >>conftest.$ac_ext
4313 cat >>conftest.$ac_ext <<_ACEOF
4314 /* end confdefs.h.  */
4315
4316 int
4317 main ()
4318 {
4319
4320   ;
4321   return 0;
4322 }
4323 _ACEOF
4324 rm -f conftest.$ac_objext
4325 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4326   (eval $ac_compile) 2>&5
4327   ac_status=$?
4328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4329   (exit $ac_status); } &&
4330          { ac_try='test -s conftest.$ac_objext'
4331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4332   (eval $ac_try) 2>&5
4333   ac_status=$?
4334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4335   (exit $ac_status); }; }; then
4336   ac_cv_prog_cc_g=yes
4337 else
4338   echo "$as_me: failed program was:" >&5
4339 sed 's/^/| /' conftest.$ac_ext >&5
4340
4341 ac_cv_prog_cc_g=no
4342 fi
4343 rm -f conftest.$ac_objext conftest.$ac_ext
4344 fi
4345 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4346 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4347 if test "$ac_test_CFLAGS" = set; then
4348   CFLAGS=$ac_save_CFLAGS
4349 elif test $ac_cv_prog_cc_g = yes; then
4350   if test "$GCC" = yes; then
4351     CFLAGS="-g -O2"
4352   else
4353     CFLAGS="-g"
4354   fi
4355 else
4356   if test "$GCC" = yes; then
4357     CFLAGS="-O2"
4358   else
4359     CFLAGS=
4360   fi
4361 fi
4362 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4363 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4364 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4365   echo $ECHO_N "(cached) $ECHO_C" >&6
4366 else
4367   ac_cv_prog_cc_stdc=no
4368 ac_save_CC=$CC
4369 cat >conftest.$ac_ext <<_ACEOF
4370 #line $LINENO "configure"
4371 /* confdefs.h.  */
4372 _ACEOF
4373 cat confdefs.h >>conftest.$ac_ext
4374 cat >>conftest.$ac_ext <<_ACEOF
4375 /* end confdefs.h.  */
4376 #include <stdarg.h>
4377 #include <stdio.h>
4378 #include <sys/types.h>
4379 #include <sys/stat.h>
4380 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4381 struct buf { int x; };
4382 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4383 static char *e (p, i)
4384      char **p;
4385      int i;
4386 {
4387   return p[i];
4388 }
4389 static char *f (char * (*g) (char **, int), char **p, ...)
4390 {
4391   char *s;
4392   va_list v;
4393   va_start (v,p);
4394   s = g (p, va_arg (v,int));
4395   va_end (v);
4396   return s;
4397 }
4398 int test (int i, double x);
4399 struct s1 {int (*f) (int a);};
4400 struct s2 {int (*f) (double a);};
4401 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4402 int argc;
4403 char **argv;
4404 int
4405 main ()
4406 {
4407 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4408   ;
4409   return 0;
4410 }
4411 _ACEOF
4412 # Don't try gcc -ansi; that turns off useful extensions and
4413 # breaks some systems' header files.
4414 # AIX                   -qlanglvl=ansi
4415 # Ultrix and OSF/1      -std1
4416 # HP-UX 10.20 and later -Ae
4417 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4418 # SVR4                  -Xc -D__EXTENSIONS__
4419 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4420 do
4421   CC="$ac_save_CC $ac_arg"
4422   rm -f conftest.$ac_objext
4423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4424   (eval $ac_compile) 2>&5
4425   ac_status=$?
4426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4427   (exit $ac_status); } &&
4428          { ac_try='test -s conftest.$ac_objext'
4429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4430   (eval $ac_try) 2>&5
4431   ac_status=$?
4432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4433   (exit $ac_status); }; }; then
4434   ac_cv_prog_cc_stdc=$ac_arg
4435 break
4436 else
4437   echo "$as_me: failed program was:" >&5
4438 sed 's/^/| /' conftest.$ac_ext >&5
4439
4440 fi
4441 rm -f conftest.$ac_objext
4442 done
4443 rm -f conftest.$ac_ext conftest.$ac_objext
4444 CC=$ac_save_CC
4445
4446 fi
4447
4448 case "x$ac_cv_prog_cc_stdc" in
4449   x|xno)
4450     echo "$as_me:$LINENO: result: none needed" >&5
4451 echo "${ECHO_T}none needed" >&6 ;;
4452   *)
4453     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4454 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4455     CC="$CC $ac_cv_prog_cc_stdc" ;;
4456 esac
4457
4458 # Some people use a C++ compiler to compile C.  Since we use `exit',
4459 # in C++ we need to declare it.  In case someone uses the same compiler
4460 # for both compiling C and C++ we need to have the C++ compiler decide
4461 # the declaration of exit, since it's the most demanding environment.
4462 cat >conftest.$ac_ext <<_ACEOF
4463 #ifndef __cplusplus
4464   choke me
4465 #endif
4466 _ACEOF
4467 rm -f conftest.$ac_objext
4468 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4469   (eval $ac_compile) 2>&5
4470   ac_status=$?
4471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4472   (exit $ac_status); } &&
4473          { ac_try='test -s conftest.$ac_objext'
4474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4475   (eval $ac_try) 2>&5
4476   ac_status=$?
4477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4478   (exit $ac_status); }; }; then
4479   for ac_declaration in \
4480    ''\
4481    '#include <stdlib.h>' \
4482    'extern "C" void std::exit (int) throw (); using std::exit;' \
4483    'extern "C" void std::exit (int); using std::exit;' \
4484    'extern "C" void exit (int) throw ();' \
4485    'extern "C" void exit (int);' \
4486    'void exit (int);'
4487 do
4488   cat >conftest.$ac_ext <<_ACEOF
4489 #line $LINENO "configure"
4490 /* confdefs.h.  */
4491 _ACEOF
4492 cat confdefs.h >>conftest.$ac_ext
4493 cat >>conftest.$ac_ext <<_ACEOF
4494 /* end confdefs.h.  */
4495 #include <stdlib.h>
4496 $ac_declaration
4497 int
4498 main ()
4499 {
4500 exit (42);
4501   ;
4502   return 0;
4503 }
4504 _ACEOF
4505 rm -f conftest.$ac_objext
4506 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4507   (eval $ac_compile) 2>&5
4508   ac_status=$?
4509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4510   (exit $ac_status); } &&
4511          { ac_try='test -s conftest.$ac_objext'
4512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4513   (eval $ac_try) 2>&5
4514   ac_status=$?
4515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4516   (exit $ac_status); }; }; then
4517   :
4518 else
4519   echo "$as_me: failed program was:" >&5
4520 sed 's/^/| /' conftest.$ac_ext >&5
4521
4522 continue
4523 fi
4524 rm -f conftest.$ac_objext conftest.$ac_ext
4525   cat >conftest.$ac_ext <<_ACEOF
4526 #line $LINENO "configure"
4527 /* confdefs.h.  */
4528 _ACEOF
4529 cat confdefs.h >>conftest.$ac_ext
4530 cat >>conftest.$ac_ext <<_ACEOF
4531 /* end confdefs.h.  */
4532 $ac_declaration
4533 int
4534 main ()
4535 {
4536 exit (42);
4537   ;
4538   return 0;
4539 }
4540 _ACEOF
4541 rm -f conftest.$ac_objext
4542 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4543   (eval $ac_compile) 2>&5
4544   ac_status=$?
4545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4546   (exit $ac_status); } &&
4547          { ac_try='test -s conftest.$ac_objext'
4548   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4549   (eval $ac_try) 2>&5
4550   ac_status=$?
4551   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4552   (exit $ac_status); }; }; then
4553   break
4554 else
4555   echo "$as_me: failed program was:" >&5
4556 sed 's/^/| /' conftest.$ac_ext >&5
4557
4558 fi
4559 rm -f conftest.$ac_objext conftest.$ac_ext
4560 done
4561 rm -f conftest*
4562 if test -n "$ac_declaration"; then
4563   echo '#ifdef __cplusplus' >>confdefs.h
4564   echo $ac_declaration      >>confdefs.h
4565   echo '#endif'             >>confdefs.h
4566 fi
4567
4568 else
4569   echo "$as_me: failed program was:" >&5
4570 sed 's/^/| /' conftest.$ac_ext >&5
4571
4572 fi
4573 rm -f conftest.$ac_objext conftest.$ac_ext
4574 ac_ext=c
4575 ac_cpp='$CPP $CPPFLAGS'
4576 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4577 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4578 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4579
4580
4581 # Check whether --with-gnu-ld or --without-gnu-ld was given.
4582 if test "${with_gnu_ld+set}" = set; then
4583   withval="$with_gnu_ld"
4584   test "$withval" = no || with_gnu_ld=yes
4585 else
4586   with_gnu_ld=no
4587 fi;
4588 ac_prog=ld
4589 if test "$GCC" = yes; then
4590   # Check if gcc -print-prog-name=ld gives a path.
4591   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4592 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
4593   case $host in
4594   *-*-mingw*)
4595     # gcc leaves a trailing carriage return which upsets mingw
4596     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4597   *)
4598     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4599   esac
4600   case $ac_prog in
4601     # Accept absolute paths.
4602     [\\/]* | [A-Za-z]:[\\/]*)
4603       re_direlt='/[^/][^/]*/\.\./'
4604       # Canonicalize the path of ld
4605       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4606       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4607         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4608       done
4609       test -z "$LD" && LD="$ac_prog"
4610       ;;
4611   "")
4612     # If it fails, then pretend we aren't using GCC.
4613     ac_prog=ld
4614     ;;
4615   *)
4616     # If it is relative, then search for the first ld in PATH.
4617     with_gnu_ld=unknown
4618     ;;
4619   esac
4620 elif test "$with_gnu_ld" = yes; then
4621   echo "$as_me:$LINENO: checking for GNU ld" >&5
4622 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
4623 else
4624   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4625 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
4626 fi
4627 if test "${acl_cv_path_LD+set}" = set; then
4628   echo $ECHO_N "(cached) $ECHO_C" >&6
4629 else
4630   if test -z "$LD"; then
4631   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
4632   for ac_dir in $PATH; do
4633     test -z "$ac_dir" && ac_dir=.
4634     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4635       acl_cv_path_LD="$ac_dir/$ac_prog"
4636       # Check to see if the program is GNU ld.  I'd rather use --version,
4637       # but apparently some GNU ld's only accept -v.
4638       # Break only if it was the GNU/non-GNU ld that we prefer.
4639       if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
4640         test "$with_gnu_ld" != no && break
4641       else
4642         test "$with_gnu_ld" != yes && break
4643       fi
4644     fi
4645   done
4646   IFS="$ac_save_ifs"
4647 else
4648   acl_cv_path_LD="$LD" # Let the user override the test with a path.
4649 fi
4650 fi
4651
4652 LD="$acl_cv_path_LD"
4653 if test -n "$LD"; then
4654   echo "$as_me:$LINENO: result: $LD" >&5
4655 echo "${ECHO_T}$LD" >&6
4656 else
4657   echo "$as_me:$LINENO: result: no" >&5
4658 echo "${ECHO_T}no" >&6
4659 fi
4660 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4661 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4662    { (exit 1); exit 1; }; }
4663 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4664 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4665 if test "${acl_cv_prog_gnu_ld+set}" = set; then
4666   echo $ECHO_N "(cached) $ECHO_C" >&6
4667 else
4668   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4669 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
4670   acl_cv_prog_gnu_ld=yes
4671 else
4672   acl_cv_prog_gnu_ld=no
4673 fi
4674 fi
4675 echo "$as_me:$LINENO: result: $acl_cv_prog_gnu_ld" >&5
4676 echo "${ECHO_T}$acl_cv_prog_gnu_ld" >&6
4677 with_gnu_ld=$acl_cv_prog_gnu_ld
4678
4679
4680
4681                                                 echo "$as_me:$LINENO: checking for shared library run path origin" >&5
4682 echo $ECHO_N "checking for shared library run path origin... $ECHO_C" >&6
4683 if test "${acl_cv_rpath+set}" = set; then
4684   echo $ECHO_N "(cached) $ECHO_C" >&6
4685 else
4686
4687     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
4688     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
4689     . ./conftest.sh
4690     rm -f ./conftest.sh
4691     acl_cv_rpath=done
4692
4693 fi
4694 echo "$as_me:$LINENO: result: $acl_cv_rpath" >&5
4695 echo "${ECHO_T}$acl_cv_rpath" >&6
4696   wl="$acl_cv_wl"
4697   libext="$acl_cv_libext"
4698   shlibext="$acl_cv_shlibext"
4699   hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
4700   hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
4701   hardcode_direct="$acl_cv_hardcode_direct"
4702   hardcode_minus_L="$acl_cv_hardcode_minus_L"
4703   sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec"
4704   sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec"
4705     # Check whether --enable-rpath or --disable-rpath was given.
4706 if test "${enable_rpath+set}" = set; then
4707   enableval="$enable_rpath"
4708   :
4709 else
4710   enable_rpath=yes
4711 fi;
4712
4713
4714
4715
4716
4717
4718
4719     use_additional=yes
4720
4721   acl_save_prefix="$prefix"
4722   prefix="$acl_final_prefix"
4723   acl_save_exec_prefix="$exec_prefix"
4724   exec_prefix="$acl_final_exec_prefix"
4725
4726     eval additional_includedir=\"$includedir\"
4727     eval additional_libdir=\"$libdir\"
4728
4729   exec_prefix="$acl_save_exec_prefix"
4730   prefix="$acl_save_prefix"
4731
4732
4733 # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
4734 if test "${with_libiconv_prefix+set}" = set; then
4735   withval="$with_libiconv_prefix"
4736
4737     if test "X$withval" = "Xno"; then
4738       use_additional=no
4739     else
4740       if test "X$withval" = "X"; then
4741
4742   acl_save_prefix="$prefix"
4743   prefix="$acl_final_prefix"
4744   acl_save_exec_prefix="$exec_prefix"
4745   exec_prefix="$acl_final_exec_prefix"
4746
4747           eval additional_includedir=\"$includedir\"
4748           eval additional_libdir=\"$libdir\"
4749
4750   exec_prefix="$acl_save_exec_prefix"
4751   prefix="$acl_save_prefix"
4752
4753       else
4754         additional_includedir="$withval/include"
4755         additional_libdir="$withval/lib"
4756       fi
4757     fi
4758
4759 fi;
4760       LIBICONV=
4761   LTLIBICONV=
4762   INCICONV=
4763   rpathdirs=
4764   ltrpathdirs=
4765   names_already_handled=
4766   names_next_round='iconv '
4767   while test -n "$names_next_round"; do
4768     names_this_round="$names_next_round"
4769     names_next_round=
4770     for name in $names_this_round; do
4771       already_handled=
4772       for n in $names_already_handled; do
4773         if test "$n" = "$name"; then
4774           already_handled=yes
4775           break
4776         fi
4777       done
4778       if test -z "$already_handled"; then
4779         names_already_handled="$names_already_handled $name"
4780                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
4781         eval value=\"\$HAVE_LIB$uppername\"
4782         if test -n "$value"; then
4783           if test "$value" = yes; then
4784             eval value=\"\$LIB$uppername\"
4785             test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
4786             eval value=\"\$LTLIB$uppername\"
4787             test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
4788           else
4789                                     :
4790           fi
4791         else
4792                               found_dir=
4793           found_la=
4794           found_so=
4795           found_a=
4796           if test $use_additional = yes; then
4797             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
4798               found_dir="$additional_libdir"
4799               found_so="$additional_libdir/lib$name.$shlibext"
4800               if test -f "$additional_libdir/lib$name.la"; then
4801                 found_la="$additional_libdir/lib$name.la"
4802               fi
4803             else
4804               if test -f "$additional_libdir/lib$name.$libext"; then
4805                 found_dir="$additional_libdir"
4806                 found_a="$additional_libdir/lib$name.$libext"
4807                 if test -f "$additional_libdir/lib$name.la"; then
4808                   found_la="$additional_libdir/lib$name.la"
4809                 fi
4810               fi
4811             fi
4812           fi
4813           if test "X$found_dir" = "X"; then
4814             for x in $LDFLAGS $LTLIBICONV; do
4815
4816   acl_save_prefix="$prefix"
4817   prefix="$acl_final_prefix"
4818   acl_save_exec_prefix="$exec_prefix"
4819   exec_prefix="$acl_final_exec_prefix"
4820   eval x=\"$x\"
4821   exec_prefix="$acl_save_exec_prefix"
4822   prefix="$acl_save_prefix"
4823
4824               case "$x" in
4825                 -L*)
4826                   dir=`echo "X$x" | sed -e 's/^X-L//'`
4827                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
4828                     found_dir="$dir"
4829                     found_so="$dir/lib$name.$shlibext"
4830                     if test -f "$dir/lib$name.la"; then
4831                       found_la="$dir/lib$name.la"
4832                     fi
4833                   else
4834                     if test -f "$dir/lib$name.$libext"; then
4835                       found_dir="$dir"
4836                       found_a="$dir/lib$name.$libext"
4837                       if test -f "$dir/lib$name.la"; then
4838                         found_la="$dir/lib$name.la"
4839                       fi
4840                     fi
4841                   fi
4842                   ;;
4843               esac
4844               if test "X$found_dir" != "X"; then
4845                 break
4846               fi
4847             done
4848           fi
4849           if test "X$found_dir" != "X"; then
4850                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
4851             if test "X$found_so" != "X"; then
4852                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
4853                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
4854               else
4855                                                                                 haveit=
4856                 for x in $ltrpathdirs; do
4857                   if test "X$x" = "X$found_dir"; then
4858                     haveit=yes
4859                     break
4860                   fi
4861                 done
4862                 if test -z "$haveit"; then
4863                   ltrpathdirs="$ltrpathdirs $found_dir"
4864                 fi
4865                                 if test "$hardcode_direct" = yes; then
4866                                                       LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
4867                 else
4868                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
4869                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
4870                                                             haveit=
4871                     for x in $rpathdirs; do
4872                       if test "X$x" = "X$found_dir"; then
4873                         haveit=yes
4874                         break
4875                       fi
4876                     done
4877                     if test -z "$haveit"; then
4878                       rpathdirs="$rpathdirs $found_dir"
4879                     fi
4880                   else
4881                                                                                 haveit=
4882                     for x in $LDFLAGS $LIBICONV; do
4883
4884   acl_save_prefix="$prefix"
4885   prefix="$acl_final_prefix"
4886   acl_save_exec_prefix="$exec_prefix"
4887   exec_prefix="$acl_final_exec_prefix"
4888   eval x=\"$x\"
4889   exec_prefix="$acl_save_exec_prefix"
4890   prefix="$acl_save_prefix"
4891
4892                       if test "X$x" = "X-L$found_dir"; then
4893                         haveit=yes
4894                         break
4895                       fi
4896                     done
4897                     if test -z "$haveit"; then
4898                       LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
4899                     fi
4900                     if test "$hardcode_minus_L" != no; then
4901                                                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
4902                     else
4903                                                                                                                                                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
4904                     fi
4905                   fi
4906                 fi
4907               fi
4908             else
4909               if test "X$found_a" != "X"; then
4910                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
4911               else
4912                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
4913               fi
4914             fi
4915                         additional_includedir=
4916             case "$found_dir" in
4917               */lib | */lib/)
4918                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
4919                 additional_includedir="$basedir/include"
4920                 ;;
4921             esac
4922             if test "X$additional_includedir" != "X"; then
4923                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
4924                 haveit=
4925                 if test "X$additional_includedir" = "X/usr/local/include"; then
4926                   if test -n "$GCC"; then
4927                     case $host_os in
4928                       linux*) haveit=yes;;
4929                     esac
4930                   fi
4931                 fi
4932                 if test -z "$haveit"; then
4933                   for x in $CPPFLAGS $INCICONV; do
4934
4935   acl_save_prefix="$prefix"
4936   prefix="$acl_final_prefix"
4937   acl_save_exec_prefix="$exec_prefix"
4938   exec_prefix="$acl_final_exec_prefix"
4939   eval x=\"$x\"
4940   exec_prefix="$acl_save_exec_prefix"
4941   prefix="$acl_save_prefix"
4942
4943                     if test "X$x" = "X-I$additional_includedir"; then
4944                       haveit=yes
4945                       break
4946                     fi
4947                   done
4948                   if test -z "$haveit"; then
4949                     if test -d "$additional_includedir"; then
4950                                             INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
4951                     fi
4952                   fi
4953                 fi
4954               fi
4955             fi
4956                         if test -n "$found_la"; then
4957                                                         save_libdir="$libdir"
4958               case "$found_la" in
4959                 */* | *\\*) . "$found_la" ;;
4960                 *) . "./$found_la" ;;
4961               esac
4962               libdir="$save_libdir"
4963                             for dep in $dependency_libs; do
4964                 case "$dep" in
4965                   -L*)
4966                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
4967                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
4968                       haveit=
4969                       if test "X$additional_libdir" = "X/usr/local/lib"; then
4970                         if test -n "$GCC"; then
4971                           case $host_os in
4972                             linux*) haveit=yes;;
4973                           esac
4974                         fi
4975                       fi
4976                       if test -z "$haveit"; then
4977                         haveit=
4978                         for x in $LDFLAGS $LIBICONV; do
4979
4980   acl_save_prefix="$prefix"
4981   prefix="$acl_final_prefix"
4982   acl_save_exec_prefix="$exec_prefix"
4983   exec_prefix="$acl_final_exec_prefix"
4984   eval x=\"$x\"
4985   exec_prefix="$acl_save_exec_prefix"
4986   prefix="$acl_save_prefix"
4987
4988                           if test "X$x" = "X-L$additional_libdir"; then
4989                             haveit=yes
4990                             break
4991                           fi
4992                         done
4993                         if test -z "$haveit"; then
4994                           if test -d "$additional_libdir"; then
4995                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
4996                           fi
4997                         fi
4998                         haveit=
4999                         for x in $LDFLAGS $LTLIBICONV; do
5000
5001   acl_save_prefix="$prefix"
5002   prefix="$acl_final_prefix"
5003   acl_save_exec_prefix="$exec_prefix"
5004   exec_prefix="$acl_final_exec_prefix"
5005   eval x=\"$x\"
5006   exec_prefix="$acl_save_exec_prefix"
5007   prefix="$acl_save_prefix"
5008
5009                           if test "X$x" = "X-L$additional_libdir"; then
5010                             haveit=yes
5011                             break
5012                           fi
5013                         done
5014                         if test -z "$haveit"; then
5015                           if test -d "$additional_libdir"; then
5016                                                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
5017                           fi
5018                         fi
5019                       fi
5020                     fi
5021                     ;;
5022                   -R*)
5023                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
5024                     if test "$enable_rpath" != no; then
5025                                                                   haveit=
5026                       for x in $rpathdirs; do
5027                         if test "X$x" = "X$dir"; then
5028                           haveit=yes
5029                           break
5030                         fi
5031                       done
5032                       if test -z "$haveit"; then
5033                         rpathdirs="$rpathdirs $dir"
5034                       fi
5035                                                                   haveit=
5036                       for x in $ltrpathdirs; do
5037                         if test "X$x" = "X$dir"; then
5038                           haveit=yes
5039                           break
5040                         fi
5041                       done
5042                       if test -z "$haveit"; then
5043                         ltrpathdirs="$ltrpathdirs $dir"
5044                       fi
5045                     fi
5046                     ;;
5047                   -l*)
5048                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
5049                     ;;
5050                   *.la)
5051                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
5052                     ;;
5053                   *)
5054                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
5055                     LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
5056                     ;;
5057                 esac
5058               done
5059             fi
5060           else
5061                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
5062             LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
5063           fi
5064         fi
5065       fi
5066     done
5067   done
5068   if test "X$rpathdirs" != "X"; then
5069     if test -n "$hardcode_libdir_separator"; then
5070                         alldirs=
5071       for found_dir in $rpathdirs; do
5072         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
5073       done
5074             acl_save_libdir="$libdir"
5075       libdir="$alldirs"
5076       eval flag=\"$hardcode_libdir_flag_spec\"
5077       libdir="$acl_save_libdir"
5078       LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
5079     else
5080             for found_dir in $rpathdirs; do
5081         acl_save_libdir="$libdir"
5082         libdir="$found_dir"
5083         eval flag=\"$hardcode_libdir_flag_spec\"
5084         libdir="$acl_save_libdir"
5085         LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
5086       done
5087     fi
5088   fi
5089   if test "X$ltrpathdirs" != "X"; then
5090             for found_dir in $ltrpathdirs; do
5091       LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
5092     done
5093   fi
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112   echo "$as_me:$LINENO: checking whether NLS is requested" >&5
5113 echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6
5114     # Check whether --enable-nls or --disable-nls was given.
5115 if test "${enable_nls+set}" = set; then
5116   enableval="$enable_nls"
5117   USE_NLS=$enableval
5118 else
5119   USE_NLS=yes
5120 fi;
5121   echo "$as_me:$LINENO: result: $USE_NLS" >&5
5122 echo "${ECHO_T}$USE_NLS" >&6
5123
5124
5125
5126   LIBINTL=
5127   LTLIBINTL=
5128   POSUB=
5129
5130     if test "$USE_NLS" = "yes"; then
5131     gt_use_preinstalled_gnugettext=no
5132
5133
5134
5135
5136
5137
5138         echo "$as_me:$LINENO: checking for GNU gettext in libc" >&5
5139 echo $ECHO_N "checking for GNU gettext in libc... $ECHO_C" >&6
5140 if test "${gt_cv_func_gnugettext1_libc+set}" = set; then
5141   echo $ECHO_N "(cached) $ECHO_C" >&6
5142 else
5143   cat >conftest.$ac_ext <<_ACEOF
5144 #line $LINENO "configure"
5145 /* confdefs.h.  */
5146 _ACEOF
5147 cat confdefs.h >>conftest.$ac_ext
5148 cat >>conftest.$ac_ext <<_ACEOF
5149 /* end confdefs.h.  */
5150 #include <libintl.h>
5151 extern int _nl_msg_cat_cntr;
5152 extern int *_nl_domain_bindings;
5153 int
5154 main ()
5155 {
5156 bindtextdomain ("", "");
5157 return (int) gettext ("") + _nl_msg_cat_cntr + *_nl_domain_bindings
5158   ;
5159   return 0;
5160 }
5161 _ACEOF
5162 rm -f conftest.$ac_objext conftest$ac_exeext
5163 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5164   (eval $ac_link) 2>&5
5165   ac_status=$?
5166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5167   (exit $ac_status); } &&
5168          { ac_try='test -s conftest$ac_exeext'
5169   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5170   (eval $ac_try) 2>&5
5171   ac_status=$?
5172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5173   (exit $ac_status); }; }; then
5174   gt_cv_func_gnugettext1_libc=yes
5175 else
5176   echo "$as_me: failed program was:" >&5
5177 sed 's/^/| /' conftest.$ac_ext >&5
5178
5179 gt_cv_func_gnugettext1_libc=no
5180 fi
5181 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5182 fi
5183 echo "$as_me:$LINENO: result: $gt_cv_func_gnugettext1_libc" >&5
5184 echo "${ECHO_T}$gt_cv_func_gnugettext1_libc" >&6
5185
5186         if test "$gt_cv_func_gnugettext1_libc" != "yes"; then
5187
5188
5189
5190
5191
5192           am_save_CPPFLAGS="$CPPFLAGS"
5193
5194   for element in $INCICONV; do
5195     haveit=
5196     for x in $CPPFLAGS; do
5197
5198   acl_save_prefix="$prefix"
5199   prefix="$acl_final_prefix"
5200   acl_save_exec_prefix="$exec_prefix"
5201   exec_prefix="$acl_final_exec_prefix"
5202   eval x=\"$x\"
5203   exec_prefix="$acl_save_exec_prefix"
5204   prefix="$acl_save_prefix"
5205
5206       if test "X$x" = "X$element"; then
5207         haveit=yes
5208         break
5209       fi
5210     done
5211     if test -z "$haveit"; then
5212       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
5213     fi
5214   done
5215
5216
5217   echo "$as_me:$LINENO: checking for iconv" >&5
5218 echo $ECHO_N "checking for iconv... $ECHO_C" >&6
5219 if test "${am_cv_func_iconv+set}" = set; then
5220   echo $ECHO_N "(cached) $ECHO_C" >&6
5221 else
5222
5223     am_cv_func_iconv="no, consider installing GNU libiconv"
5224     am_cv_lib_iconv=no
5225     cat >conftest.$ac_ext <<_ACEOF
5226 #line $LINENO "configure"
5227 /* confdefs.h.  */
5228 _ACEOF
5229 cat confdefs.h >>conftest.$ac_ext
5230 cat >>conftest.$ac_ext <<_ACEOF
5231 /* end confdefs.h.  */
5232 #include <stdlib.h>
5233 #include <iconv.h>
5234 int
5235 main ()
5236 {
5237 iconv_t cd = iconv_open("","");
5238        iconv(cd,NULL,NULL,NULL,NULL);
5239        iconv_close(cd);
5240   ;
5241   return 0;
5242 }
5243 _ACEOF
5244 rm -f conftest.$ac_objext conftest$ac_exeext
5245 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5246   (eval $ac_link) 2>&5
5247   ac_status=$?
5248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5249   (exit $ac_status); } &&
5250          { ac_try='test -s conftest$ac_exeext'
5251   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5252   (eval $ac_try) 2>&5
5253   ac_status=$?
5254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5255   (exit $ac_status); }; }; then
5256   am_cv_func_iconv=yes
5257 else
5258   echo "$as_me: failed program was:" >&5
5259 sed 's/^/| /' conftest.$ac_ext >&5
5260
5261 fi
5262 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5263     if test "$am_cv_func_iconv" != yes; then
5264       am_save_LIBS="$LIBS"
5265       LIBS="$LIBS $LIBICONV"
5266       cat >conftest.$ac_ext <<_ACEOF
5267 #line $LINENO "configure"
5268 /* confdefs.h.  */
5269 _ACEOF
5270 cat confdefs.h >>conftest.$ac_ext
5271 cat >>conftest.$ac_ext <<_ACEOF
5272 /* end confdefs.h.  */
5273 #include <stdlib.h>
5274 #include <iconv.h>
5275 int
5276 main ()
5277 {
5278 iconv_t cd = iconv_open("","");
5279          iconv(cd,NULL,NULL,NULL,NULL);
5280          iconv_close(cd);
5281   ;
5282   return 0;
5283 }
5284 _ACEOF
5285 rm -f conftest.$ac_objext conftest$ac_exeext
5286 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5287   (eval $ac_link) 2>&5
5288   ac_status=$?
5289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5290   (exit $ac_status); } &&
5291          { ac_try='test -s conftest$ac_exeext'
5292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5293   (eval $ac_try) 2>&5
5294   ac_status=$?
5295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5296   (exit $ac_status); }; }; then
5297   am_cv_lib_iconv=yes
5298         am_cv_func_iconv=yes
5299 else
5300   echo "$as_me: failed program was:" >&5
5301 sed 's/^/| /' conftest.$ac_ext >&5
5302
5303 fi
5304 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5305       LIBS="$am_save_LIBS"
5306     fi
5307
5308 fi
5309 echo "$as_me:$LINENO: result: $am_cv_func_iconv" >&5
5310 echo "${ECHO_T}$am_cv_func_iconv" >&6
5311   if test "$am_cv_func_iconv" = yes; then
5312
5313 cat >>confdefs.h <<\_ACEOF
5314 #define HAVE_ICONV 1
5315 _ACEOF
5316
5317   fi
5318   if test "$am_cv_lib_iconv" = yes; then
5319     echo "$as_me:$LINENO: checking how to link with libiconv" >&5
5320 echo $ECHO_N "checking how to link with libiconv... $ECHO_C" >&6
5321     echo "$as_me:$LINENO: result: $LIBICONV" >&5
5322 echo "${ECHO_T}$LIBICONV" >&6
5323   else
5324             CPPFLAGS="$am_save_CPPFLAGS"
5325     LIBICONV=
5326     LTLIBICONV=
5327   fi
5328
5329
5330
5331
5332
5333
5334     use_additional=yes
5335
5336   acl_save_prefix="$prefix"
5337   prefix="$acl_final_prefix"
5338   acl_save_exec_prefix="$exec_prefix"
5339   exec_prefix="$acl_final_exec_prefix"
5340
5341     eval additional_includedir=\"$includedir\"
5342     eval additional_libdir=\"$libdir\"
5343
5344   exec_prefix="$acl_save_exec_prefix"
5345   prefix="$acl_save_prefix"
5346
5347
5348 # Check whether --with-libintl-prefix or --without-libintl-prefix was given.
5349 if test "${with_libintl_prefix+set}" = set; then
5350   withval="$with_libintl_prefix"
5351
5352     if test "X$withval" = "Xno"; then
5353       use_additional=no
5354     else
5355       if test "X$withval" = "X"; then
5356
5357   acl_save_prefix="$prefix"
5358   prefix="$acl_final_prefix"
5359   acl_save_exec_prefix="$exec_prefix"
5360   exec_prefix="$acl_final_exec_prefix"
5361
5362           eval additional_includedir=\"$includedir\"
5363           eval additional_libdir=\"$libdir\"
5364
5365   exec_prefix="$acl_save_exec_prefix"
5366   prefix="$acl_save_prefix"
5367
5368       else
5369         additional_includedir="$withval/include"
5370         additional_libdir="$withval/lib"
5371       fi
5372     fi
5373
5374 fi;
5375       LIBINTL=
5376   LTLIBINTL=
5377   INCINTL=
5378   rpathdirs=
5379   ltrpathdirs=
5380   names_already_handled=
5381   names_next_round='intl '
5382   while test -n "$names_next_round"; do
5383     names_this_round="$names_next_round"
5384     names_next_round=
5385     for name in $names_this_round; do
5386       already_handled=
5387       for n in $names_already_handled; do
5388         if test "$n" = "$name"; then
5389           already_handled=yes
5390           break
5391         fi
5392       done
5393       if test -z "$already_handled"; then
5394         names_already_handled="$names_already_handled $name"
5395                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
5396         eval value=\"\$HAVE_LIB$uppername\"
5397         if test -n "$value"; then
5398           if test "$value" = yes; then
5399             eval value=\"\$LIB$uppername\"
5400             test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
5401             eval value=\"\$LTLIB$uppername\"
5402             test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
5403           else
5404                                     :
5405           fi
5406         else
5407                               found_dir=
5408           found_la=
5409           found_so=
5410           found_a=
5411           if test $use_additional = yes; then
5412             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
5413               found_dir="$additional_libdir"
5414               found_so="$additional_libdir/lib$name.$shlibext"
5415               if test -f "$additional_libdir/lib$name.la"; then
5416                 found_la="$additional_libdir/lib$name.la"
5417               fi
5418             else
5419               if test -f "$additional_libdir/lib$name.$libext"; then
5420                 found_dir="$additional_libdir"
5421                 found_a="$additional_libdir/lib$name.$libext"
5422                 if test -f "$additional_libdir/lib$name.la"; then
5423                   found_la="$additional_libdir/lib$name.la"
5424                 fi
5425               fi
5426             fi
5427           fi
5428           if test "X$found_dir" = "X"; then
5429             for x in $LDFLAGS $LTLIBINTL; do
5430
5431   acl_save_prefix="$prefix"
5432   prefix="$acl_final_prefix"
5433   acl_save_exec_prefix="$exec_prefix"
5434   exec_prefix="$acl_final_exec_prefix"
5435   eval x=\"$x\"
5436   exec_prefix="$acl_save_exec_prefix"
5437   prefix="$acl_save_prefix"
5438
5439               case "$x" in
5440                 -L*)
5441                   dir=`echo "X$x" | sed -e 's/^X-L//'`
5442                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
5443                     found_dir="$dir"
5444                     found_so="$dir/lib$name.$shlibext"
5445                     if test -f "$dir/lib$name.la"; then
5446                       found_la="$dir/lib$name.la"
5447                     fi
5448                   else
5449                     if test -f "$dir/lib$name.$libext"; then
5450                       found_dir="$dir"
5451                       found_a="$dir/lib$name.$libext"
5452                       if test -f "$dir/lib$name.la"; then
5453                         found_la="$dir/lib$name.la"
5454                       fi
5455                     fi
5456                   fi
5457                   ;;
5458               esac
5459               if test "X$found_dir" != "X"; then
5460                 break
5461               fi
5462             done
5463           fi
5464           if test "X$found_dir" != "X"; then
5465                         LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
5466             if test "X$found_so" != "X"; then
5467                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
5468                                 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
5469               else
5470                                                                                 haveit=
5471                 for x in $ltrpathdirs; do
5472                   if test "X$x" = "X$found_dir"; then
5473                     haveit=yes
5474                     break
5475                   fi
5476                 done
5477                 if test -z "$haveit"; then
5478                   ltrpathdirs="$ltrpathdirs $found_dir"
5479                 fi
5480                                 if test "$hardcode_direct" = yes; then
5481                                                       LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
5482                 else
5483                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
5484                                                             LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
5485                                                             haveit=
5486                     for x in $rpathdirs; do
5487                       if test "X$x" = "X$found_dir"; then
5488                         haveit=yes
5489                         break
5490                       fi
5491                     done
5492                     if test -z "$haveit"; then
5493                       rpathdirs="$rpathdirs $found_dir"
5494                     fi
5495                   else
5496                                                                                 haveit=
5497                     for x in $LDFLAGS $LIBINTL; do
5498
5499   acl_save_prefix="$prefix"
5500   prefix="$acl_final_prefix"
5501   acl_save_exec_prefix="$exec_prefix"
5502   exec_prefix="$acl_final_exec_prefix"
5503   eval x=\"$x\"
5504   exec_prefix="$acl_save_exec_prefix"
5505   prefix="$acl_save_prefix"
5506
5507                       if test "X$x" = "X-L$found_dir"; then
5508                         haveit=yes
5509                         break
5510                       fi
5511                     done
5512                     if test -z "$haveit"; then
5513                       LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
5514                     fi
5515                     if test "$hardcode_minus_L" != no; then
5516                                                                                         LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
5517                     else
5518                                                                                                                                                                                 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
5519                     fi
5520                   fi
5521                 fi
5522               fi
5523             else
5524               if test "X$found_a" != "X"; then
5525                                 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
5526               else
5527                                                 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
5528               fi
5529             fi
5530                         additional_includedir=
5531             case "$found_dir" in
5532               */lib | */lib/)
5533                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
5534                 additional_includedir="$basedir/include"
5535                 ;;
5536             esac
5537             if test "X$additional_includedir" != "X"; then
5538                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
5539                 haveit=
5540                 if test "X$additional_includedir" = "X/usr/local/include"; then
5541                   if test -n "$GCC"; then
5542                     case $host_os in
5543                       linux*) haveit=yes;;
5544                     esac
5545                   fi
5546                 fi
5547                 if test -z "$haveit"; then
5548                   for x in $CPPFLAGS $INCINTL; do
5549
5550   acl_save_prefix="$prefix"
5551   prefix="$acl_final_prefix"
5552   acl_save_exec_prefix="$exec_prefix"
5553   exec_prefix="$acl_final_exec_prefix"
5554   eval x=\"$x\"
5555   exec_prefix="$acl_save_exec_prefix"
5556   prefix="$acl_save_prefix"
5557
5558                     if test "X$x" = "X-I$additional_includedir"; then
5559                       haveit=yes
5560                       break
5561                     fi
5562                   done
5563                   if test -z "$haveit"; then
5564                     if test -d "$additional_includedir"; then
5565                                             INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
5566                     fi
5567                   fi
5568                 fi
5569               fi
5570             fi
5571                         if test -n "$found_la"; then
5572                                                         save_libdir="$libdir"
5573               case "$found_la" in
5574                 */* | *\\*) . "$found_la" ;;
5575                 *) . "./$found_la" ;;
5576               esac
5577               libdir="$save_libdir"
5578                             for dep in $dependency_libs; do
5579                 case "$dep" in
5580                   -L*)
5581                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
5582                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
5583                       haveit=
5584                       if test "X$additional_libdir" = "X/usr/local/lib"; then
5585                         if test -n "$GCC"; then
5586                           case $host_os in
5587                             linux*) haveit=yes;;
5588                           esac
5589                         fi
5590                       fi
5591                       if test -z "$haveit"; then
5592                         haveit=
5593                         for x in $LDFLAGS $LIBINTL; do
5594
5595   acl_save_prefix="$prefix"
5596   prefix="$acl_final_prefix"
5597   acl_save_exec_prefix="$exec_prefix"
5598   exec_prefix="$acl_final_exec_prefix"
5599   eval x=\"$x\"
5600   exec_prefix="$acl_save_exec_prefix"
5601   prefix="$acl_save_prefix"
5602
5603                           if test "X$x" = "X-L$additional_libdir"; then
5604                             haveit=yes
5605                             break
5606                           fi
5607                         done
5608                         if test -z "$haveit"; then
5609                           if test -d "$additional_libdir"; then
5610                                                         LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
5611                           fi
5612                         fi
5613                         haveit=
5614                         for x in $LDFLAGS $LTLIBINTL; do
5615
5616   acl_save_prefix="$prefix"
5617   prefix="$acl_final_prefix"
5618   acl_save_exec_prefix="$exec_prefix"
5619   exec_prefix="$acl_final_exec_prefix"
5620   eval x=\"$x\"
5621   exec_prefix="$acl_save_exec_prefix"
5622   prefix="$acl_save_prefix"
5623
5624                           if test "X$x" = "X-L$additional_libdir"; then
5625                             haveit=yes
5626                             break
5627                           fi
5628                         done
5629                         if test -z "$haveit"; then
5630                           if test -d "$additional_libdir"; then
5631                                                         LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
5632                           fi
5633                         fi
5634                       fi
5635                     fi
5636                     ;;
5637                   -R*)
5638                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
5639                     if test "$enable_rpath" != no; then
5640                                                                   haveit=
5641                       for x in $rpathdirs; do
5642                         if test "X$x" = "X$dir"; then
5643                           haveit=yes
5644                           break
5645                         fi
5646                       done
5647                       if test -z "$haveit"; then
5648                         rpathdirs="$rpathdirs $dir"
5649                       fi
5650                                                                   haveit=
5651                       for x in $ltrpathdirs; do
5652                         if test "X$x" = "X$dir"; then
5653                           haveit=yes
5654                           break
5655                         fi
5656                       done
5657                       if test -z "$haveit"; then
5658                         ltrpathdirs="$ltrpathdirs $dir"
5659                       fi
5660                     fi
5661                     ;;
5662                   -l*)
5663                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
5664                     ;;
5665                   *.la)
5666                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
5667                     ;;
5668                   *)
5669                                         LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
5670                     LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
5671                     ;;
5672                 esac
5673               done
5674             fi
5675           else
5676                                                             LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
5677             LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
5678           fi
5679         fi
5680       fi
5681     done
5682   done
5683   if test "X$rpathdirs" != "X"; then
5684     if test -n "$hardcode_libdir_separator"; then
5685                         alldirs=
5686       for found_dir in $rpathdirs; do
5687         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
5688       done
5689             acl_save_libdir="$libdir"
5690       libdir="$alldirs"
5691       eval flag=\"$hardcode_libdir_flag_spec\"
5692       libdir="$acl_save_libdir"
5693       LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
5694     else
5695             for found_dir in $rpathdirs; do
5696         acl_save_libdir="$libdir"
5697         libdir="$found_dir"
5698         eval flag=\"$hardcode_libdir_flag_spec\"
5699         libdir="$acl_save_libdir"
5700         LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
5701       done
5702     fi
5703   fi
5704   if test "X$ltrpathdirs" != "X"; then
5705             for found_dir in $ltrpathdirs; do
5706       LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
5707     done
5708   fi
5709
5710           echo "$as_me:$LINENO: checking for GNU gettext in libintl" >&5
5711 echo $ECHO_N "checking for GNU gettext in libintl... $ECHO_C" >&6
5712 if test "${gt_cv_func_gnugettext1_libintl+set}" = set; then
5713   echo $ECHO_N "(cached) $ECHO_C" >&6
5714 else
5715   gt_save_CPPFLAGS="$CPPFLAGS"
5716             CPPFLAGS="$CPPFLAGS $INCINTL"
5717             gt_save_LIBS="$LIBS"
5718             LIBS="$LIBS $LIBINTL"
5719                         cat >conftest.$ac_ext <<_ACEOF
5720 #line $LINENO "configure"
5721 /* confdefs.h.  */
5722 _ACEOF
5723 cat confdefs.h >>conftest.$ac_ext
5724 cat >>conftest.$ac_ext <<_ACEOF
5725 /* end confdefs.h.  */
5726 #include <libintl.h>
5727 extern int _nl_msg_cat_cntr;
5728 extern
5729 #ifdef __cplusplus
5730 "C"
5731 #endif
5732 const char *_nl_expand_alias ();
5733 int
5734 main ()
5735 {
5736 bindtextdomain ("", "");
5737 return (int) gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias (0)
5738   ;
5739   return 0;
5740 }
5741 _ACEOF
5742 rm -f conftest.$ac_objext conftest$ac_exeext
5743 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5744   (eval $ac_link) 2>&5
5745   ac_status=$?
5746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5747   (exit $ac_status); } &&
5748          { ac_try='test -s conftest$ac_exeext'
5749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5750   (eval $ac_try) 2>&5
5751   ac_status=$?
5752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5753   (exit $ac_status); }; }; then
5754   gt_cv_func_gnugettext1_libintl=yes
5755 else
5756   echo "$as_me: failed program was:" >&5
5757 sed 's/^/| /' conftest.$ac_ext >&5
5758
5759 gt_cv_func_gnugettext1_libintl=no
5760 fi
5761 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5762                         if test "$gt_cv_func_gnugettext1_libintl" != yes && test -n "$LIBICONV"; then
5763               LIBS="$LIBS $LIBICONV"
5764               cat >conftest.$ac_ext <<_ACEOF
5765 #line $LINENO "configure"
5766 /* confdefs.h.  */
5767 _ACEOF
5768 cat confdefs.h >>conftest.$ac_ext
5769 cat >>conftest.$ac_ext <<_ACEOF
5770 /* end confdefs.h.  */
5771 #include <libintl.h>
5772 extern int _nl_msg_cat_cntr;
5773 extern
5774 #ifdef __cplusplus
5775 "C"
5776 #endif
5777 const char *_nl_expand_alias ();
5778 int
5779 main ()
5780 {
5781 bindtextdomain ("", "");
5782 return (int) gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias (0)
5783   ;
5784   return 0;
5785 }
5786 _ACEOF
5787 rm -f conftest.$ac_objext conftest$ac_exeext
5788 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5789   (eval $ac_link) 2>&5
5790   ac_status=$?
5791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5792   (exit $ac_status); } &&
5793          { ac_try='test -s conftest$ac_exeext'
5794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5795   (eval $ac_try) 2>&5
5796   ac_status=$?
5797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5798   (exit $ac_status); }; }; then
5799   LIBINTL="$LIBINTL $LIBICONV"
5800                 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
5801                 gt_cv_func_gnugettext1_libintl=yes
5802
5803 else
5804   echo "$as_me: failed program was:" >&5
5805 sed 's/^/| /' conftest.$ac_ext >&5
5806
5807 fi
5808 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5809             fi
5810             CPPFLAGS="$gt_save_CPPFLAGS"
5811             LIBS="$gt_save_LIBS"
5812 fi
5813 echo "$as_me:$LINENO: result: $gt_cv_func_gnugettext1_libintl" >&5
5814 echo "${ECHO_T}$gt_cv_func_gnugettext1_libintl" >&6
5815         fi
5816
5817                                         if test "$gt_cv_func_gnugettext1_libc" = "yes" \
5818            || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \
5819                 && test "$PACKAGE" != gettext; }; then
5820           gt_use_preinstalled_gnugettext=yes
5821         else
5822                     LIBINTL=
5823           LTLIBINTL=
5824           INCINTL=
5825         fi
5826
5827
5828
5829     if test "$gt_use_preinstalled_gnugettext" = "yes" \
5830        || test "$nls_cv_use_gnu_gettext" = "yes"; then
5831
5832 cat >>confdefs.h <<\_ACEOF
5833 #define ENABLE_NLS 1
5834 _ACEOF
5835
5836     else
5837       USE_NLS=no
5838     fi
5839   fi
5840
5841   if test "$USE_NLS" = "yes"; then
5842
5843     if test "$gt_use_preinstalled_gnugettext" = "yes"; then
5844       if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then
5845         echo "$as_me:$LINENO: checking how to link with libintl" >&5
5846 echo $ECHO_N "checking how to link with libintl... $ECHO_C" >&6
5847         echo "$as_me:$LINENO: result: $LIBINTL" >&5
5848 echo "${ECHO_T}$LIBINTL" >&6
5849
5850   for element in $INCINTL; do
5851     haveit=
5852     for x in $CPPFLAGS; do
5853
5854   acl_save_prefix="$prefix"
5855   prefix="$acl_final_prefix"
5856   acl_save_exec_prefix="$exec_prefix"
5857   exec_prefix="$acl_final_exec_prefix"
5858   eval x=\"$x\"
5859   exec_prefix="$acl_save_exec_prefix"
5860   prefix="$acl_save_prefix"
5861
5862       if test "X$x" = "X$element"; then
5863         haveit=yes
5864         break
5865       fi
5866     done
5867     if test -z "$haveit"; then
5868       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
5869     fi
5870   done
5871
5872       fi
5873
5874
5875 cat >>confdefs.h <<\_ACEOF
5876 #define HAVE_GETTEXT 1
5877 _ACEOF
5878
5879
5880 cat >>confdefs.h <<\_ACEOF
5881 #define HAVE_DCGETTEXT 1
5882 _ACEOF
5883
5884     fi
5885
5886         POSUB=po
5887   fi
5888
5889
5890
5891     INTLLIBS="$LIBINTL"
5892
5893
5894
5895
5896
5897
5898
5899
5900 cat >>confdefs.h <<\_ACEOF
5901 #define HAVE_MKVERSION 1
5902 _ACEOF
5903
5904
5905
5906
5907 ol_aix_threads=no
5908 case "$target" in
5909 *-*-aix*)       if test -z "$CC" ; then
5910                 case "$ol_with_threads" in
5911                 auto | yes |  posix) ol_aix_threads=yes ;;
5912                 esac
5913         fi
5914 ;;
5915 esac
5916
5917 if test $ol_aix_threads = yes ; then
5918         if test -z "${CC}" ; then
5919                 for ac_prog in cc_r xlc_r cc
5920 do
5921   # Extract the first word of "$ac_prog", so it can be a program name with args.
5922 set dummy $ac_prog; ac_word=$2
5923 echo "$as_me:$LINENO: checking for $ac_word" >&5
5924 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5925 if test "${ac_cv_prog_CC+set}" = set; then
5926   echo $ECHO_N "(cached) $ECHO_C" >&6
5927 else
5928   if test -n "$CC"; then
5929   ac_cv_prog_CC="$CC" # Let the user override the test.
5930 else
5931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5932 for as_dir in $PATH
5933 do
5934   IFS=$as_save_IFS
5935   test -z "$as_dir" && as_dir=.
5936   for ac_exec_ext in '' $ac_executable_extensions; do
5937   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5938     ac_cv_prog_CC="$ac_prog"
5939     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5940     break 2
5941   fi
5942 done
5943 done
5944
5945 fi
5946 fi
5947 CC=$ac_cv_prog_CC
5948 if test -n "$CC"; then
5949   echo "$as_me:$LINENO: result: $CC" >&5
5950 echo "${ECHO_T}$CC" >&6
5951 else
5952   echo "$as_me:$LINENO: result: no" >&5
5953 echo "${ECHO_T}no" >&6
5954 fi
5955
5956   test -n "$CC" && break
5957 done
5958
5959
5960                 if test "$CC" = cc ; then
5961                                                 if test $ol_with_threads != auto ; then
5962                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
5963 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
5964    { (exit 1); exit 1; }; }
5965                         else
5966                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
5967 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
5968                         fi
5969                         ol_with_threads=no
5970                 fi
5971         fi
5972
5973         if test "${CC}" = "cc_r" -o "${CC}" = "xlc_r" ; then
5974                 ol_with_threads=posix
5975                 ol_cv_pthread_create=yes
5976         fi
5977 fi
5978
5979 if test -z "${CC}"; then
5980         for ac_prog in cc gcc
5981 do
5982   # Extract the first word of "$ac_prog", so it can be a program name with args.
5983 set dummy $ac_prog; ac_word=$2
5984 echo "$as_me:$LINENO: checking for $ac_word" >&5
5985 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5986 if test "${ac_cv_prog_CC+set}" = set; then
5987   echo $ECHO_N "(cached) $ECHO_C" >&6
5988 else
5989   if test -n "$CC"; then
5990   ac_cv_prog_CC="$CC" # Let the user override the test.
5991 else
5992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5993 for as_dir in $PATH
5994 do
5995   IFS=$as_save_IFS
5996   test -z "$as_dir" && as_dir=.
5997   for ac_exec_ext in '' $ac_executable_extensions; do
5998   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5999     ac_cv_prog_CC="$ac_prog"
6000     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6001     break 2
6002   fi
6003 done
6004 done
6005
6006 fi
6007 fi
6008 CC=$ac_cv_prog_CC
6009 if test -n "$CC"; then
6010   echo "$as_me:$LINENO: result: $CC" >&5
6011 echo "${ECHO_T}$CC" >&6
6012 else
6013   echo "$as_me:$LINENO: result: no" >&5
6014 echo "${ECHO_T}no" >&6
6015 fi
6016
6017   test -n "$CC" && break
6018 done
6019 test -n "$CC" || CC="missing"
6020
6021
6022         if test "${CC}" = "missing" ; then
6023                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
6024 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
6025    { (exit 1); exit 1; }; }
6026         fi
6027 fi
6028
6029 if test -z "${AR}"; then
6030         for ac_prog in ar gar
6031 do
6032   # Extract the first word of "$ac_prog", so it can be a program name with args.
6033 set dummy $ac_prog; ac_word=$2
6034 echo "$as_me:$LINENO: checking for $ac_word" >&5
6035 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6036 if test "${ac_cv_prog_AR+set}" = set; then
6037   echo $ECHO_N "(cached) $ECHO_C" >&6
6038 else
6039   if test -n "$AR"; then
6040   ac_cv_prog_AR="$AR" # Let the user override the test.
6041 else
6042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6043 for as_dir in $PATH
6044 do
6045   IFS=$as_save_IFS
6046   test -z "$as_dir" && as_dir=.
6047   for ac_exec_ext in '' $ac_executable_extensions; do
6048   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6049     ac_cv_prog_AR="$ac_prog"
6050     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6051     break 2
6052   fi
6053 done
6054 done
6055
6056 fi
6057 fi
6058 AR=$ac_cv_prog_AR
6059 if test -n "$AR"; then
6060   echo "$as_me:$LINENO: result: $AR" >&5
6061 echo "${ECHO_T}$AR" >&6
6062 else
6063   echo "$as_me:$LINENO: result: no" >&5
6064 echo "${ECHO_T}no" >&6
6065 fi
6066
6067   test -n "$AR" && break
6068 done
6069 test -n "$AR" || AR="missing"
6070
6071
6072         if test "${AR}" = "missing" ; then
6073                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
6074 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
6075    { (exit 1); exit 1; }; }
6076         fi
6077 fi
6078
6079
6080
6081 # Check whether --enable-fast-install or --disable-fast-install was given.
6082 if test "${enable_fast_install+set}" = set; then
6083   enableval="$enable_fast_install"
6084   p=${PACKAGE-default}
6085 case $enableval in
6086 yes) enable_fast_install=yes ;;
6087 no) enable_fast_install=no ;;
6088 *)
6089   enable_fast_install=no
6090   # Look at the argument we got.  We use all the common list separators.
6091   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
6092   for pkg in $enableval; do
6093     if test "X$pkg" = "X$p"; then
6094       enable_fast_install=yes
6095     fi
6096   done
6097   IFS="$ac_save_ifs"
6098   ;;
6099 esac
6100 else
6101   enable_fast_install=yes
6102 fi;
6103 # Find the correct PATH separator.  Usually this is `:', but
6104 # DJGPP uses `;' like DOS.
6105 if test "X${PATH_SEPARATOR+set}" != Xset; then
6106   UNAME=${UNAME-`uname 2>/dev/null`}
6107   case X$UNAME in
6108     *-DOS) lt_cv_sys_path_separator=';' ;;
6109     *)     lt_cv_sys_path_separator=':' ;;
6110   esac
6111   PATH_SEPARATOR=$lt_cv_sys_path_separator
6112 fi
6113
6114
6115 # Check whether --with-gnu-ld or --without-gnu-ld was given.
6116 if test "${with_gnu_ld+set}" = set; then
6117   withval="$with_gnu_ld"
6118   test "$withval" = no || with_gnu_ld=yes
6119 else
6120   with_gnu_ld=no
6121 fi;
6122 ac_prog=ld
6123 if test "$GCC" = yes; then
6124   # Check if gcc -print-prog-name=ld gives a path.
6125   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
6126 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
6127   case $host in
6128   *-*-mingw*)
6129     # gcc leaves a trailing carriage return which upsets mingw
6130     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
6131   *)
6132     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
6133   esac
6134   case $ac_prog in
6135     # Accept absolute paths.
6136     [\\/]* | [A-Za-z]:[\\/]*)
6137       re_direlt='/[^/][^/]*/\.\./'
6138       # Canonicalize the path of ld
6139       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
6140       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
6141         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
6142       done
6143       test -z "$LD" && LD="$ac_prog"
6144       ;;
6145   "")
6146     # If it fails, then pretend we aren't using GCC.
6147     ac_prog=ld
6148     ;;
6149   *)
6150     # If it is relative, then search for the first ld in PATH.
6151     with_gnu_ld=unknown
6152     ;;
6153   esac
6154 elif test "$with_gnu_ld" = yes; then
6155   echo "$as_me:$LINENO: checking for GNU ld" >&5
6156 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
6157 else
6158   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
6159 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
6160 fi
6161 if test "${lt_cv_path_LD+set}" = set; then
6162   echo $ECHO_N "(cached) $ECHO_C" >&6
6163 else
6164   if test -z "$LD"; then
6165   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6166   for ac_dir in $PATH; do
6167     test -z "$ac_dir" && ac_dir=.
6168     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
6169       lt_cv_path_LD="$ac_dir/$ac_prog"
6170       # Check to see if the program is GNU ld.  I'd rather use --version,
6171       # but apparently some GNU ld's only accept -v.
6172       # Break only if it was the GNU/non-GNU ld that we prefer.
6173       if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
6174         test "$with_gnu_ld" != no && break
6175       else
6176         test "$with_gnu_ld" != yes && break
6177       fi
6178     fi
6179   done
6180   IFS="$ac_save_ifs"
6181 else
6182   lt_cv_path_LD="$LD" # Let the user override the test with a path.
6183 fi
6184 fi
6185
6186 LD="$lt_cv_path_LD"
6187 if test -n "$LD"; then
6188   echo "$as_me:$LINENO: result: $LD" >&5
6189 echo "${ECHO_T}$LD" >&6
6190 else
6191   echo "$as_me:$LINENO: result: no" >&5
6192 echo "${ECHO_T}no" >&6
6193 fi
6194 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
6195 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
6196    { (exit 1); exit 1; }; }
6197 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
6198 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
6199 if test "${lt_cv_prog_gnu_ld+set}" = set; then
6200   echo $ECHO_N "(cached) $ECHO_C" >&6
6201 else
6202   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
6203 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
6204   lt_cv_prog_gnu_ld=yes
6205 else
6206   lt_cv_prog_gnu_ld=no
6207 fi
6208 fi
6209 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
6210 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
6211 with_gnu_ld=$lt_cv_prog_gnu_ld
6212
6213
6214 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
6215 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
6216 if test "${lt_cv_ld_reload_flag+set}" = set; then
6217   echo $ECHO_N "(cached) $ECHO_C" >&6
6218 else
6219   lt_cv_ld_reload_flag='-r'
6220 fi
6221 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
6222 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
6223 reload_flag=$lt_cv_ld_reload_flag
6224 test -n "$reload_flag" && reload_flag=" $reload_flag"
6225
6226 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
6227 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
6228 if test "${lt_cv_path_NM+set}" = set; then
6229   echo $ECHO_N "(cached) $ECHO_C" >&6
6230 else
6231   if test -n "$NM"; then
6232   # Let the user override the test.
6233   lt_cv_path_NM="$NM"
6234 else
6235   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6236   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
6237     test -z "$ac_dir" && ac_dir=.
6238     tmp_nm=$ac_dir/${ac_tool_prefix}nm
6239     if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
6240       # Check to see if the nm accepts a BSD-compat flag.
6241       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
6242       #   nm: unknown option "B" ignored
6243       # Tru64's nm complains that /dev/null is an invalid object file
6244       if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
6245         lt_cv_path_NM="$tmp_nm -B"
6246         break
6247       elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
6248         lt_cv_path_NM="$tmp_nm -p"
6249         break
6250       else
6251         lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
6252         continue # so that we can try to find one that supports BSD flags
6253       fi
6254     fi
6255   done
6256   IFS="$ac_save_ifs"
6257   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
6258 fi
6259 fi
6260
6261 NM="$lt_cv_path_NM"
6262 echo "$as_me:$LINENO: result: $NM" >&5
6263 echo "${ECHO_T}$NM" >&6
6264
6265 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
6266 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
6267 if test "${lt_cv_path_SED+set}" = set; then
6268   echo $ECHO_N "(cached) $ECHO_C" >&6
6269 else
6270   # Loop through the user's path and test for sed and gsed.
6271 # Then use that list of sed's as ones to test for truncation.
6272 as_executable_p="test -f"
6273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6274 for as_dir in $PATH
6275 do
6276   IFS=$as_save_IFS
6277   test -z "$as_dir" && as_dir=.
6278   for ac_prog in sed gsed; do
6279     for ac_exec_ext in '' $ac_executable_extensions; do
6280       if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
6281         _sed_list="$_sed_list $as_dir/$ac_prog$ac_exec_ext"
6282       fi
6283     done
6284   done
6285 done
6286
6287   # Create a temporary directory, and hook for its removal unless debugging.
6288 $debug ||
6289 {
6290   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
6291   trap '{ (exit 1); exit 1; }' 1 2 13 15
6292 }
6293
6294 # Create a (secure) tmp directory for tmp files.
6295 : ${TMPDIR=/tmp}
6296 {
6297   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/sedXXXXXX") 2>/dev/null` &&
6298   test -n "$tmp" && test -d "$tmp"
6299 }  ||
6300 {
6301   tmp=$TMPDIR/sed$$-$RANDOM
6302   (umask 077 && mkdir $tmp)
6303 } ||
6304 {
6305    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
6306    { (exit 1); exit 1; }
6307 }
6308   _max=0
6309   _count=0
6310   # Add /usr/xpg4/bin/sed as it is typically found on Solaris
6311   # along with /bin/sed that truncates output.
6312   for _sed in $_sed_list /usr/xpg4/bin/sed; do
6313     test ! -f ${_sed} && break
6314     cat /dev/null > "$tmp/sed.in"
6315     _count=0
6316     echo ${ECHO_N-$ac_n} "0123456789${ECHO_C-$ac_c}" >"$tmp/sed.in"
6317     # Check for GNU sed and select it if it is found.
6318     if "${_sed}" --version 2>&1 < /dev/null | egrep '(GNU)' > /dev/null; then
6319       lt_cv_path_SED=${_sed}
6320       break
6321     fi
6322     while true; do
6323       cat "$tmp/sed.in" "$tmp/sed.in" >"$tmp/sed.tmp"
6324       mv "$tmp/sed.tmp" "$tmp/sed.in"
6325       cp "$tmp/sed.in" "$tmp/sed.nl"
6326       echo >>"$tmp/sed.nl"
6327       ${_sed} -e 's/a$//' < "$tmp/sed.nl" >"$tmp/sed.out" || break
6328       cmp -s "$tmp/sed.out" "$tmp/sed.nl" || break
6329       # 40000 chars as input seems more than enough
6330       test $_count -gt 10 && break
6331       _count=`expr $_count + 1`
6332       if test $_count -gt $_max; then
6333         _max=$_count
6334         lt_cv_path_SED=$_sed
6335       fi
6336     done
6337   done
6338   rm -rf "$tmp"
6339
6340 fi
6341
6342 if test "X$SED" != "X"; then
6343   lt_cv_path_SED=$SED
6344 else
6345   SED=$lt_cv_path_SED
6346 fi
6347 echo "$as_me:$LINENO: result: $SED" >&5
6348 echo "${ECHO_T}$SED" >&6
6349
6350 echo "$as_me:$LINENO: checking whether ln -s works" >&5
6351 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
6352 LN_S=$as_ln_s
6353 if test "$LN_S" = "ln -s"; then
6354   echo "$as_me:$LINENO: result: yes" >&5
6355 echo "${ECHO_T}yes" >&6
6356 else
6357   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6358 echo "${ECHO_T}no, using $LN_S" >&6
6359 fi
6360
6361 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
6362 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
6363 if test "${lt_cv_deplibs_check_method+set}" = set; then
6364   echo $ECHO_N "(cached) $ECHO_C" >&6
6365 else
6366   lt_cv_file_magic_cmd='$MAGIC_CMD'
6367 lt_cv_file_magic_test_file=
6368 lt_cv_deplibs_check_method='unknown'
6369 # Need to set the preceding variable on all platforms that support
6370 # interlibrary dependencies.
6371 # 'none' -- dependencies not supported.
6372 # `unknown' -- same as none, but documents that we really don't know.
6373 # 'pass_all' -- all dependencies passed with no checks.
6374 # 'test_compile' -- check by making test program.
6375 # 'file_magic [[regex]]' -- check by looking for files in library path
6376 # which responds to the $file_magic_cmd with a given egrep regex.
6377 # If you have `file' or equivalent on your system and you're not sure
6378 # whether `pass_all' will *always* work, you probably want this one.
6379
6380 case $host_os in
6381 aix4* | aix5*)
6382   lt_cv_deplibs_check_method=pass_all
6383   ;;
6384
6385 beos*)
6386   lt_cv_deplibs_check_method=pass_all
6387   ;;
6388
6389 bsdi4*)
6390   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
6391   lt_cv_file_magic_cmd='/usr/bin/file -L'
6392   lt_cv_file_magic_test_file=/shlib/libc.so
6393   ;;
6394
6395 cygwin* | mingw* | pw32*)
6396   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
6397   lt_cv_file_magic_cmd='$OBJDUMP -f'
6398   ;;
6399
6400 darwin* | rhapsody*)
6401   lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
6402   lt_cv_file_magic_cmd='/usr/bin/file -L'
6403   case "$host_os" in
6404   rhapsody* | darwin1.[012])
6405     lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
6406     ;;
6407   *) # Darwin 1.3 on
6408     lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
6409     ;;
6410   esac
6411   ;;
6412
6413 freebsd*)
6414   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
6415     case $host_cpu in
6416     i*86 )
6417       # Not sure whether the presence of OpenBSD here was a mistake.
6418       # Let's accept both of them until this is cleared up.
6419       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
6420       lt_cv_file_magic_cmd=/usr/bin/file
6421       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
6422       ;;
6423     esac
6424   else
6425     lt_cv_deplibs_check_method=pass_all
6426   fi
6427   ;;
6428
6429 gnu*)
6430   lt_cv_deplibs_check_method=pass_all
6431   ;;
6432
6433 hpux10.20*|hpux11*)
6434   lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
6435   lt_cv_file_magic_cmd=/usr/bin/file
6436   lt_cv_file_magic_test_file=/usr/lib/libc.sl
6437   ;;
6438
6439 irix5* | irix6* | nonstopux*)
6440   case $host_os in
6441   irix5* | nonstopux*)
6442     # this will be overridden with pass_all, but let us keep it just in case
6443     lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
6444     ;;
6445   *)
6446     case $LD in
6447     *-32|*"-32 ") libmagic=32-bit;;
6448     *-n32|*"-n32 ") libmagic=N32;;
6449     *-64|*"-64 ") libmagic=64-bit;;
6450     *) libmagic=never-match;;
6451     esac
6452     # this will be overridden with pass_all, but let us keep it just in case
6453     lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
6454     ;;
6455   esac
6456   lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
6457   lt_cv_deplibs_check_method=pass_all
6458   ;;
6459
6460 # This must be Linux ELF.
6461 linux-gnu*)
6462   case $host_cpu in
6463   alpha* | hppa* | i*86 | mips | mipsel | powerpc* | sparc* | ia64*)
6464     lt_cv_deplibs_check_method=pass_all ;;
6465   *)
6466     # glibc up to 2.1.1 does not perform some relocations on ARM
6467     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
6468   esac
6469   lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
6470   ;;
6471
6472 netbsd*)
6473   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
6474     lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
6475   else
6476     lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
6477   fi
6478   ;;
6479
6480 newos6*)
6481   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
6482   lt_cv_file_magic_cmd=/usr/bin/file
6483   lt_cv_file_magic_test_file=/usr/lib/libnls.so
6484   ;;
6485
6486 openbsd*)
6487   lt_cv_file_magic_cmd=/usr/bin/file
6488   lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
6489   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6490     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object'
6491   else
6492     lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
6493   fi
6494   ;;
6495
6496 osf3* | osf4* | osf5*)
6497   # this will be overridden with pass_all, but let us keep it just in case
6498   lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
6499   lt_cv_file_magic_test_file=/shlib/libc.so
6500   lt_cv_deplibs_check_method=pass_all
6501   ;;
6502
6503 sco3.2v5*)
6504   lt_cv_deplibs_check_method=pass_all
6505   ;;
6506
6507 solaris*)
6508   lt_cv_deplibs_check_method=pass_all
6509   lt_cv_file_magic_test_file=/lib/libc.so
6510   ;;
6511
6512 sysv5uw[78]* | sysv4*uw2*)
6513   lt_cv_deplibs_check_method=pass_all
6514   ;;
6515
6516 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6517   case $host_vendor in
6518   motorola)
6519     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]'
6520     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
6521     ;;
6522   ncr)
6523     lt_cv_deplibs_check_method=pass_all
6524     ;;
6525   sequent)
6526     lt_cv_file_magic_cmd='/bin/file'
6527     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
6528     ;;
6529   sni)
6530     lt_cv_file_magic_cmd='/bin/file'
6531     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
6532     lt_cv_file_magic_test_file=/lib/libc.so
6533     ;;
6534   siemens)
6535     lt_cv_deplibs_check_method=pass_all
6536     ;;
6537   esac
6538   ;;
6539 esac
6540
6541 fi
6542 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
6543 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
6544 file_magic_cmd=$lt_cv_file_magic_cmd
6545 deplibs_check_method=$lt_cv_deplibs_check_method
6546
6547
6548
6549
6550
6551
6552
6553 # Check for command to grab the raw symbol name followed by C symbol from nm.
6554 echo "$as_me:$LINENO: checking command to parse $NM output" >&5
6555 echo $ECHO_N "checking command to parse $NM output... $ECHO_C" >&6
6556 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
6557   echo $ECHO_N "(cached) $ECHO_C" >&6
6558 else
6559
6560 # These are sane defaults that work on at least a few old systems.
6561 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6562
6563 # Character class describing NM global symbol codes.
6564 symcode='[BCDEGRST]'
6565
6566 # Regexp to match symbols that can be accessed directly from C.
6567 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6568
6569 # Transform the above into a raw symbol and a C symbol.
6570 symxfrm='\1 \2\3 \3'
6571
6572 # Transform an extracted symbol line into a proper C declaration
6573 lt_cv_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
6574
6575 # Transform an extracted symbol line into symbol name and symbol address
6576 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'"
6577
6578 # Define system-specific variables.
6579 case $host_os in
6580 aix*)
6581   symcode='[BCDT]'
6582   ;;
6583 cygwin* | mingw* | pw32*)
6584   symcode='[ABCDGISTW]'
6585   ;;
6586 hpux*) # Its linker distinguishes data from code symbols
6587   lt_cv_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6588   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'"
6589   ;;
6590 irix* | nonstopux*)
6591   symcode='[BCDEGRST]'
6592   ;;
6593 osf*)
6594   symcode='[BCDEGQRST]'
6595   ;;
6596 solaris* | sysv5*)
6597   symcode='[BDT]'
6598   ;;
6599 sysv4)
6600   symcode='[DFNSTU]'
6601   ;;
6602 esac
6603
6604 # Handle CRLF in mingw tool chain
6605 opt_cr=
6606 case $host_os in
6607 mingw*)
6608   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6609   ;;
6610 esac
6611
6612 # If we're using GNU nm, then use its standard symbol codes.
6613 if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
6614   symcode='[ABCDGISTW]'
6615 fi
6616
6617 # Try without a prefix undercore, then with it.
6618 for ac_symprfx in "" "_"; do
6619
6620   # Write the raw and C identifiers.
6621 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[         ]\($symcode$symcode*\)[         ][      ]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
6622
6623   # Check to see that the pipe works correctly.
6624   pipe_works=no
6625   rm -f conftest*
6626   cat > conftest.$ac_ext <<EOF
6627 #ifdef __cplusplus
6628 extern "C" {
6629 #endif
6630 char nm_test_var;
6631 void nm_test_func(){}
6632 #ifdef __cplusplus
6633 }
6634 #endif
6635 int main(){nm_test_var='a';nm_test_func();return(0);}
6636 EOF
6637
6638   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6639   (eval $ac_compile) 2>&5
6640   ac_status=$?
6641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6642   (exit $ac_status); }; then
6643     # Now try to grab the symbols.
6644     nlist=conftest.nm
6645     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
6646   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
6647   ac_status=$?
6648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6649   (exit $ac_status); } && test -s "$nlist"; then
6650       # Try sorting and uniquifying the output.
6651       if sort "$nlist" | uniq > "$nlist"T; then
6652         mv -f "$nlist"T "$nlist"
6653       else
6654         rm -f "$nlist"T
6655       fi
6656
6657       # Make sure that we snagged all the symbols we need.
6658       if egrep ' nm_test_var$' "$nlist" >/dev/null; then
6659         if egrep ' nm_test_func$' "$nlist" >/dev/null; then
6660           cat <<EOF > conftest.$ac_ext
6661 #ifdef __cplusplus
6662 extern "C" {
6663 #endif
6664
6665 EOF
6666           # Now generate the symbol file.
6667           eval "$lt_cv_global_symbol_to_cdecl"' < "$nlist" >> conftest.$ac_ext'
6668
6669           cat <<EOF >> conftest.$ac_ext
6670 #if defined (__STDC__) && __STDC__
6671 # define lt_ptr void *
6672 #else
6673 # define lt_ptr char *
6674 # define const
6675 #endif
6676
6677 /* The mapping between symbol names and symbols. */
6678 const struct {
6679   const char *name;
6680   lt_ptr address;
6681 }
6682 lt_preloaded_symbols[] =
6683 {
6684 EOF
6685           sed "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr) \&\2},/" < "$nlist" >> conftest.$ac_ext
6686           cat <<\EOF >> conftest.$ac_ext
6687   {0, (lt_ptr) 0}
6688 };
6689
6690 #ifdef __cplusplus
6691 }
6692 #endif
6693 EOF
6694           # Now try linking the two files.
6695           mv conftest.$ac_objext conftstm.$ac_objext
6696           save_LIBS="$LIBS"
6697           save_CFLAGS="$CFLAGS"
6698           LIBS="conftstm.$ac_objext"
6699           CFLAGS="$CFLAGS$no_builtin_flag"
6700           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6701   (eval $ac_link) 2>&5
6702   ac_status=$?
6703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6704   (exit $ac_status); } && test -s conftest$ac_exeext; then
6705             pipe_works=yes
6706           fi
6707           LIBS="$save_LIBS"
6708           CFLAGS="$save_CFLAGS"
6709         else
6710           echo "cannot find nm_test_func in $nlist" >&5
6711         fi
6712       else
6713         echo "cannot find nm_test_var in $nlist" >&5
6714       fi
6715     else
6716       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6717     fi
6718   else
6719     echo "$progname: failed program was:" >&5
6720     cat conftest.$ac_ext >&5
6721   fi
6722   rm -f conftest* conftst*
6723
6724   # Do not use the global_symbol_pipe unless it works.
6725   if test "$pipe_works" = yes; then
6726     break
6727   else
6728     lt_cv_sys_global_symbol_pipe=
6729   fi
6730 done
6731
6732 fi
6733
6734 global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
6735 if test -z "$lt_cv_sys_global_symbol_pipe"; then
6736   global_symbol_to_cdecl=
6737   global_symbol_to_c_name_address=
6738 else
6739   global_symbol_to_cdecl="$lt_cv_global_symbol_to_cdecl"
6740   global_symbol_to_c_name_address="$lt_cv_global_symbol_to_c_name_address"
6741 fi
6742 if test -z "$global_symbol_pipe$global_symbol_to_cdec$global_symbol_to_c_name_address";
6743 then
6744   echo "$as_me:$LINENO: result: failed" >&5
6745 echo "${ECHO_T}failed" >&6
6746 else
6747   echo "$as_me:$LINENO: result: ok" >&5
6748 echo "${ECHO_T}ok" >&6
6749 fi
6750
6751 ac_ext=c
6752 ac_cpp='$CPP $CPPFLAGS'
6753 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6754 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6755 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6756 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6757 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
6758 # On Suns, sometimes $CPP names a directory.
6759 if test -n "$CPP" && test -d "$CPP"; then
6760   CPP=
6761 fi
6762 if test -z "$CPP"; then
6763   if test "${ac_cv_prog_CPP+set}" = set; then
6764   echo $ECHO_N "(cached) $ECHO_C" >&6
6765 else
6766       # Double quotes because CPP needs to be expanded
6767     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6768     do
6769       ac_preproc_ok=false
6770 for ac_c_preproc_warn_flag in '' yes
6771 do
6772   # Use a header file that comes with gcc, so configuring glibc
6773   # with a fresh cross-compiler works.
6774   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6775   # <limits.h> exists even on freestanding compilers.
6776   # On the NeXT, cc -E runs the code through the compiler's parser,
6777   # not just through cpp. "Syntax error" is here to catch this case.
6778   cat >conftest.$ac_ext <<_ACEOF
6779 #line $LINENO "configure"
6780 /* confdefs.h.  */
6781 _ACEOF
6782 cat confdefs.h >>conftest.$ac_ext
6783 cat >>conftest.$ac_ext <<_ACEOF
6784 /* end confdefs.h.  */
6785 #ifdef __STDC__
6786 # include <limits.h>
6787 #else
6788 # include <assert.h>
6789 #endif
6790                      Syntax error
6791 _ACEOF
6792 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6793   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6794   ac_status=$?
6795   grep -v '^ *+' conftest.er1 >conftest.err
6796   rm -f conftest.er1
6797   cat conftest.err >&5
6798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6799   (exit $ac_status); } >/dev/null; then
6800   if test -s conftest.err; then
6801     ac_cpp_err=$ac_c_preproc_warn_flag
6802   else
6803     ac_cpp_err=
6804   fi
6805 else
6806   ac_cpp_err=yes
6807 fi
6808 if test -z "$ac_cpp_err"; then
6809   :
6810 else
6811   echo "$as_me: failed program was:" >&5
6812 sed 's/^/| /' conftest.$ac_ext >&5
6813
6814   # Broken: fails on valid input.
6815 continue
6816 fi
6817 rm -f conftest.err conftest.$ac_ext
6818
6819   # OK, works on sane cases.  Now check whether non-existent headers
6820   # can be detected and how.
6821   cat >conftest.$ac_ext <<_ACEOF
6822 #line $LINENO "configure"
6823 /* confdefs.h.  */
6824 _ACEOF
6825 cat confdefs.h >>conftest.$ac_ext
6826 cat >>conftest.$ac_ext <<_ACEOF
6827 /* end confdefs.h.  */
6828 #include <ac_nonexistent.h>
6829 _ACEOF
6830 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6831   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6832   ac_status=$?
6833   grep -v '^ *+' conftest.er1 >conftest.err
6834   rm -f conftest.er1
6835   cat conftest.err >&5
6836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6837   (exit $ac_status); } >/dev/null; then
6838   if test -s conftest.err; then
6839     ac_cpp_err=$ac_c_preproc_warn_flag
6840   else
6841     ac_cpp_err=
6842   fi
6843 else
6844   ac_cpp_err=yes
6845 fi
6846 if test -z "$ac_cpp_err"; then
6847   # Broken: success on invalid input.
6848 continue
6849 else
6850   echo "$as_me: failed program was:" >&5
6851 sed 's/^/| /' conftest.$ac_ext >&5
6852
6853   # Passes both tests.
6854 ac_preproc_ok=:
6855 break
6856 fi
6857 rm -f conftest.err conftest.$ac_ext
6858
6859 done
6860 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6861 rm -f conftest.err conftest.$ac_ext
6862 if $ac_preproc_ok; then
6863   break
6864 fi
6865
6866     done
6867     ac_cv_prog_CPP=$CPP
6868
6869 fi
6870   CPP=$ac_cv_prog_CPP
6871 else
6872   ac_cv_prog_CPP=$CPP
6873 fi
6874 echo "$as_me:$LINENO: result: $CPP" >&5
6875 echo "${ECHO_T}$CPP" >&6
6876 ac_preproc_ok=false
6877 for ac_c_preproc_warn_flag in '' yes
6878 do
6879   # Use a header file that comes with gcc, so configuring glibc
6880   # with a fresh cross-compiler works.
6881   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6882   # <limits.h> exists even on freestanding compilers.
6883   # On the NeXT, cc -E runs the code through the compiler's parser,
6884   # not just through cpp. "Syntax error" is here to catch this case.
6885   cat >conftest.$ac_ext <<_ACEOF
6886 #line $LINENO "configure"
6887 /* confdefs.h.  */
6888 _ACEOF
6889 cat confdefs.h >>conftest.$ac_ext
6890 cat >>conftest.$ac_ext <<_ACEOF
6891 /* end confdefs.h.  */
6892 #ifdef __STDC__
6893 # include <limits.h>
6894 #else
6895 # include <assert.h>
6896 #endif
6897                      Syntax error
6898 _ACEOF
6899 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6900   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6901   ac_status=$?
6902   grep -v '^ *+' conftest.er1 >conftest.err
6903   rm -f conftest.er1
6904   cat conftest.err >&5
6905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6906   (exit $ac_status); } >/dev/null; then
6907   if test -s conftest.err; then
6908     ac_cpp_err=$ac_c_preproc_warn_flag
6909   else
6910     ac_cpp_err=
6911   fi
6912 else
6913   ac_cpp_err=yes
6914 fi
6915 if test -z "$ac_cpp_err"; then
6916   :
6917 else
6918   echo "$as_me: failed program was:" >&5
6919 sed 's/^/| /' conftest.$ac_ext >&5
6920
6921   # Broken: fails on valid input.
6922 continue
6923 fi
6924 rm -f conftest.err conftest.$ac_ext
6925
6926   # OK, works on sane cases.  Now check whether non-existent headers
6927   # can be detected and how.
6928   cat >conftest.$ac_ext <<_ACEOF
6929 #line $LINENO "configure"
6930 /* confdefs.h.  */
6931 _ACEOF
6932 cat confdefs.h >>conftest.$ac_ext
6933 cat >>conftest.$ac_ext <<_ACEOF
6934 /* end confdefs.h.  */
6935 #include <ac_nonexistent.h>
6936 _ACEOF
6937 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6938   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6939   ac_status=$?
6940   grep -v '^ *+' conftest.er1 >conftest.err
6941   rm -f conftest.er1
6942   cat conftest.err >&5
6943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6944   (exit $ac_status); } >/dev/null; then
6945   if test -s conftest.err; then
6946     ac_cpp_err=$ac_c_preproc_warn_flag
6947   else
6948     ac_cpp_err=
6949   fi
6950 else
6951   ac_cpp_err=yes
6952 fi
6953 if test -z "$ac_cpp_err"; then
6954   # Broken: success on invalid input.
6955 continue
6956 else
6957   echo "$as_me: failed program was:" >&5
6958 sed 's/^/| /' conftest.$ac_ext >&5
6959
6960   # Passes both tests.
6961 ac_preproc_ok=:
6962 break
6963 fi
6964 rm -f conftest.err conftest.$ac_ext
6965
6966 done
6967 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6968 rm -f conftest.err conftest.$ac_ext
6969 if $ac_preproc_ok; then
6970   :
6971 else
6972   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
6973 See \`config.log' for more details." >&5
6974 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
6975 See \`config.log' for more details." >&2;}
6976    { (exit 1); exit 1; }; }
6977 fi
6978
6979 ac_ext=c
6980 ac_cpp='$CPP $CPPFLAGS'
6981 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6982 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6983 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6984
6985
6986 echo "$as_me:$LINENO: checking for egrep" >&5
6987 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
6988 if test "${ac_cv_prog_egrep+set}" = set; then
6989   echo $ECHO_N "(cached) $ECHO_C" >&6
6990 else
6991   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
6992     then ac_cv_prog_egrep='grep -E'
6993     else ac_cv_prog_egrep='egrep'
6994     fi
6995 fi
6996 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
6997 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
6998  EGREP=$ac_cv_prog_egrep
6999
7000
7001 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7002 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7003 if test "${ac_cv_header_stdc+set}" = set; then
7004   echo $ECHO_N "(cached) $ECHO_C" >&6
7005 else
7006   cat >conftest.$ac_ext <<_ACEOF
7007 #line $LINENO "configure"
7008 /* confdefs.h.  */
7009 _ACEOF
7010 cat confdefs.h >>conftest.$ac_ext
7011 cat >>conftest.$ac_ext <<_ACEOF
7012 /* end confdefs.h.  */
7013 #include <stdlib.h>
7014 #include <stdarg.h>
7015 #include <string.h>
7016 #include <float.h>
7017
7018 int
7019 main ()
7020 {
7021
7022   ;
7023   return 0;
7024 }
7025 _ACEOF
7026 rm -f conftest.$ac_objext
7027 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7028   (eval $ac_compile) 2>&5
7029   ac_status=$?
7030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7031   (exit $ac_status); } &&
7032          { ac_try='test -s conftest.$ac_objext'
7033   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7034   (eval $ac_try) 2>&5
7035   ac_status=$?
7036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7037   (exit $ac_status); }; }; then
7038   ac_cv_header_stdc=yes
7039 else
7040   echo "$as_me: failed program was:" >&5
7041 sed 's/^/| /' conftest.$ac_ext >&5
7042
7043 ac_cv_header_stdc=no
7044 fi
7045 rm -f conftest.$ac_objext conftest.$ac_ext
7046
7047 if test $ac_cv_header_stdc = yes; then
7048   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7049   cat >conftest.$ac_ext <<_ACEOF
7050 #line $LINENO "configure"
7051 /* confdefs.h.  */
7052 _ACEOF
7053 cat confdefs.h >>conftest.$ac_ext
7054 cat >>conftest.$ac_ext <<_ACEOF
7055 /* end confdefs.h.  */
7056 #include <string.h>
7057
7058 _ACEOF
7059 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7060   $EGREP "memchr" >/dev/null 2>&1; then
7061   :
7062 else
7063   ac_cv_header_stdc=no
7064 fi
7065 rm -f conftest*
7066
7067 fi
7068
7069 if test $ac_cv_header_stdc = yes; then
7070   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7071   cat >conftest.$ac_ext <<_ACEOF
7072 #line $LINENO "configure"
7073 /* confdefs.h.  */
7074 _ACEOF
7075 cat confdefs.h >>conftest.$ac_ext
7076 cat >>conftest.$ac_ext <<_ACEOF
7077 /* end confdefs.h.  */
7078 #include <stdlib.h>
7079
7080 _ACEOF
7081 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7082   $EGREP "free" >/dev/null 2>&1; then
7083   :
7084 else
7085   ac_cv_header_stdc=no
7086 fi
7087 rm -f conftest*
7088
7089 fi
7090
7091 if test $ac_cv_header_stdc = yes; then
7092   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7093   if test "$cross_compiling" = yes; then
7094   :
7095 else
7096   cat >conftest.$ac_ext <<_ACEOF
7097 #line $LINENO "configure"
7098 /* confdefs.h.  */
7099 _ACEOF
7100 cat confdefs.h >>conftest.$ac_ext
7101 cat >>conftest.$ac_ext <<_ACEOF
7102 /* end confdefs.h.  */
7103 #include <ctype.h>
7104 #if ((' ' & 0x0FF) == 0x020)
7105 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7106 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7107 #else
7108 # define ISLOWER(c) \
7109                    (('a' <= (c) && (c) <= 'i') \
7110                      || ('j' <= (c) && (c) <= 'r') \
7111                      || ('s' <= (c) && (c) <= 'z'))
7112 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7113 #endif
7114
7115 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7116 int
7117 main ()
7118 {
7119   int i;
7120   for (i = 0; i < 256; i++)
7121     if (XOR (islower (i), ISLOWER (i))
7122         || toupper (i) != TOUPPER (i))
7123       exit(2);
7124   exit (0);
7125 }
7126 _ACEOF
7127 rm -f conftest$ac_exeext
7128 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7129   (eval $ac_link) 2>&5
7130   ac_status=$?
7131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7132   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7134   (eval $ac_try) 2>&5
7135   ac_status=$?
7136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7137   (exit $ac_status); }; }; then
7138   :
7139 else
7140   echo "$as_me: program exited with status $ac_status" >&5
7141 echo "$as_me: failed program was:" >&5
7142 sed 's/^/| /' conftest.$ac_ext >&5
7143
7144 ( exit $ac_status )
7145 ac_cv_header_stdc=no
7146 fi
7147 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7148 fi
7149 fi
7150 fi
7151 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7152 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7153 if test $ac_cv_header_stdc = yes; then
7154
7155 cat >>confdefs.h <<\_ACEOF
7156 #define STDC_HEADERS 1
7157 _ACEOF
7158
7159 fi
7160
7161 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7162
7163
7164
7165
7166
7167
7168
7169
7170
7171 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7172                   inttypes.h stdint.h unistd.h
7173 do
7174 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7175 echo "$as_me:$LINENO: checking for $ac_header" >&5
7176 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7177 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7178   echo $ECHO_N "(cached) $ECHO_C" >&6
7179 else
7180   cat >conftest.$ac_ext <<_ACEOF
7181 #line $LINENO "configure"
7182 /* confdefs.h.  */
7183 _ACEOF
7184 cat confdefs.h >>conftest.$ac_ext
7185 cat >>conftest.$ac_ext <<_ACEOF
7186 /* end confdefs.h.  */
7187 $ac_includes_default
7188
7189 #include <$ac_header>
7190 _ACEOF
7191 rm -f conftest.$ac_objext
7192 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7193   (eval $ac_compile) 2>&5
7194   ac_status=$?
7195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7196   (exit $ac_status); } &&
7197          { ac_try='test -s conftest.$ac_objext'
7198   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7199   (eval $ac_try) 2>&5
7200   ac_status=$?
7201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7202   (exit $ac_status); }; }; then
7203   eval "$as_ac_Header=yes"
7204 else
7205   echo "$as_me: failed program was:" >&5
7206 sed 's/^/| /' conftest.$ac_ext >&5
7207
7208 eval "$as_ac_Header=no"
7209 fi
7210 rm -f conftest.$ac_objext conftest.$ac_ext
7211 fi
7212 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7213 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7214 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7215   cat >>confdefs.h <<_ACEOF
7216 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7217 _ACEOF
7218
7219 fi
7220
7221 done
7222
7223
7224
7225 for ac_header in dlfcn.h
7226 do
7227 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7228 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7229   echo "$as_me:$LINENO: checking for $ac_header" >&5
7230 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7231 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7232   echo $ECHO_N "(cached) $ECHO_C" >&6
7233 fi
7234 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7235 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7236 else
7237   # Is the header compilable?
7238 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7239 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7240 cat >conftest.$ac_ext <<_ACEOF
7241 #line $LINENO "configure"
7242 /* confdefs.h.  */
7243 _ACEOF
7244 cat confdefs.h >>conftest.$ac_ext
7245 cat >>conftest.$ac_ext <<_ACEOF
7246 /* end confdefs.h.  */
7247 $ac_includes_default
7248 #include <$ac_header>
7249 _ACEOF
7250 rm -f conftest.$ac_objext
7251 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7252   (eval $ac_compile) 2>&5
7253   ac_status=$?
7254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7255   (exit $ac_status); } &&
7256          { ac_try='test -s conftest.$ac_objext'
7257   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7258   (eval $ac_try) 2>&5
7259   ac_status=$?
7260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7261   (exit $ac_status); }; }; then
7262   ac_header_compiler=yes
7263 else
7264   echo "$as_me: failed program was:" >&5
7265 sed 's/^/| /' conftest.$ac_ext >&5
7266
7267 ac_header_compiler=no
7268 fi
7269 rm -f conftest.$ac_objext conftest.$ac_ext
7270 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7271 echo "${ECHO_T}$ac_header_compiler" >&6
7272
7273 # Is the header present?
7274 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7275 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7276 cat >conftest.$ac_ext <<_ACEOF
7277 #line $LINENO "configure"
7278 /* confdefs.h.  */
7279 _ACEOF
7280 cat confdefs.h >>conftest.$ac_ext
7281 cat >>conftest.$ac_ext <<_ACEOF
7282 /* end confdefs.h.  */
7283 #include <$ac_header>
7284 _ACEOF
7285 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7286   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7287   ac_status=$?
7288   grep -v '^ *+' conftest.er1 >conftest.err
7289   rm -f conftest.er1
7290   cat conftest.err >&5
7291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7292   (exit $ac_status); } >/dev/null; then
7293   if test -s conftest.err; then
7294     ac_cpp_err=$ac_c_preproc_warn_flag
7295   else
7296     ac_cpp_err=
7297   fi
7298 else
7299   ac_cpp_err=yes
7300 fi
7301 if test -z "$ac_cpp_err"; then
7302   ac_header_preproc=yes
7303 else
7304   echo "$as_me: failed program was:" >&5
7305 sed 's/^/| /' conftest.$ac_ext >&5
7306
7307   ac_header_preproc=no
7308 fi
7309 rm -f conftest.err conftest.$ac_ext
7310 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7311 echo "${ECHO_T}$ac_header_preproc" >&6
7312
7313 # So?  What about this header?
7314 case $ac_header_compiler:$ac_header_preproc in
7315   yes:no )
7316     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7317 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7318     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7319 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7320     (
7321       cat <<\_ASBOX
7322 ## ------------------------------------ ##
7323 ## Report this to bug-autoconf@gnu.org. ##
7324 ## ------------------------------------ ##
7325 _ASBOX
7326     ) |
7327       sed "s/^/$as_me: WARNING:     /" >&2
7328     ;;
7329   no:yes )
7330     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7331 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7332     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7333 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7334     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7335 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7336     (
7337       cat <<\_ASBOX
7338 ## ------------------------------------ ##
7339 ## Report this to bug-autoconf@gnu.org. ##
7340 ## ------------------------------------ ##
7341 _ASBOX
7342     ) |
7343       sed "s/^/$as_me: WARNING:     /" >&2
7344     ;;
7345 esac
7346 echo "$as_me:$LINENO: checking for $ac_header" >&5
7347 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7348 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7349   echo $ECHO_N "(cached) $ECHO_C" >&6
7350 else
7351   eval "$as_ac_Header=$ac_header_preproc"
7352 fi
7353 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7354 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7355
7356 fi
7357 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7358   cat >>confdefs.h <<_ACEOF
7359 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7360 _ACEOF
7361
7362 fi
7363
7364 done
7365
7366
7367
7368
7369
7370
7371 # Only perform the check for file, if the check method requires it
7372 case $deplibs_check_method in
7373 file_magic*)
7374   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7375     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7376 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
7377 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7378   echo $ECHO_N "(cached) $ECHO_C" >&6
7379 else
7380   case $MAGIC_CMD in
7381   /*)
7382   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7383   ;;
7384   ?:/*)
7385   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
7386   ;;
7387   *)
7388   ac_save_MAGIC_CMD="$MAGIC_CMD"
7389   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7390   ac_dummy="/usr/bin:$PATH"
7391   for ac_dir in $ac_dummy; do
7392     test -z "$ac_dir" && ac_dir=.
7393     if test -f $ac_dir/${ac_tool_prefix}file; then
7394       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7395       if test -n "$file_magic_test_file"; then
7396         case $deplibs_check_method in
7397         "file_magic "*)
7398           file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
7399           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7400           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7401             egrep "$file_magic_regex" > /dev/null; then
7402             :
7403           else
7404             cat <<EOF 1>&2
7405
7406 *** Warning: the command libtool uses to detect shared libraries,
7407 *** $file_magic_cmd, produces output that libtool cannot recognize.
7408 *** The result is that libtool may fail to recognize shared libraries
7409 *** as such.  This will affect the creation of libtool libraries that
7410 *** depend on shared libraries, but programs linked with such libtool
7411 *** libraries will work regardless of this problem.  Nevertheless, you
7412 *** may want to report the problem to your system manager and/or to
7413 *** bug-libtool@gnu.org
7414
7415 EOF
7416           fi ;;
7417         esac
7418       fi
7419       break
7420     fi
7421   done
7422   IFS="$ac_save_ifs"
7423   MAGIC_CMD="$ac_save_MAGIC_CMD"
7424   ;;
7425 esac
7426 fi
7427
7428 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7429 if test -n "$MAGIC_CMD"; then
7430   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7431 echo "${ECHO_T}$MAGIC_CMD" >&6
7432 else
7433   echo "$as_me:$LINENO: result: no" >&5
7434 echo "${ECHO_T}no" >&6
7435 fi
7436
7437 if test -z "$lt_cv_path_MAGIC_CMD"; then
7438   if test -n "$ac_tool_prefix"; then
7439     echo "$as_me:$LINENO: checking for file" >&5
7440 echo $ECHO_N "checking for file... $ECHO_C" >&6
7441 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7442   echo $ECHO_N "(cached) $ECHO_C" >&6
7443 else
7444   case $MAGIC_CMD in
7445   /*)
7446   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7447   ;;
7448   ?:/*)
7449   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
7450   ;;
7451   *)
7452   ac_save_MAGIC_CMD="$MAGIC_CMD"
7453   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7454   ac_dummy="/usr/bin:$PATH"
7455   for ac_dir in $ac_dummy; do
7456     test -z "$ac_dir" && ac_dir=.
7457     if test -f $ac_dir/file; then
7458       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7459       if test -n "$file_magic_test_file"; then
7460         case $deplibs_check_method in
7461         "file_magic "*)
7462           file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
7463           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7464           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7465             egrep "$file_magic_regex" > /dev/null; then
7466             :
7467           else
7468             cat <<EOF 1>&2
7469
7470 *** Warning: the command libtool uses to detect shared libraries,
7471 *** $file_magic_cmd, produces output that libtool cannot recognize.
7472 *** The result is that libtool may fail to recognize shared libraries
7473 *** as such.  This will affect the creation of libtool libraries that
7474 *** depend on shared libraries, but programs linked with such libtool
7475 *** libraries will work regardless of this problem.  Nevertheless, you
7476 *** may want to report the problem to your system manager and/or to
7477 *** bug-libtool@gnu.org
7478
7479 EOF
7480           fi ;;
7481         esac
7482       fi
7483       break
7484     fi
7485   done
7486   IFS="$ac_save_ifs"
7487   MAGIC_CMD="$ac_save_MAGIC_CMD"
7488   ;;
7489 esac
7490 fi
7491
7492 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7493 if test -n "$MAGIC_CMD"; then
7494   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7495 echo "${ECHO_T}$MAGIC_CMD" >&6
7496 else
7497   echo "$as_me:$LINENO: result: no" >&5
7498 echo "${ECHO_T}no" >&6
7499 fi
7500
7501   else
7502     MAGIC_CMD=:
7503   fi
7504 fi
7505
7506   fi
7507   ;;
7508 esac
7509
7510 if test -n "$ac_tool_prefix"; then
7511   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7512 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7513 echo "$as_me:$LINENO: checking for $ac_word" >&5
7514 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7515 if test "${ac_cv_prog_RANLIB+set}" = set; then
7516   echo $ECHO_N "(cached) $ECHO_C" >&6
7517 else
7518   if test -n "$RANLIB"; then
7519   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7520 else
7521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7522 for as_dir in $PATH
7523 do
7524   IFS=$as_save_IFS
7525   test -z "$as_dir" && as_dir=.
7526   for ac_exec_ext in '' $ac_executable_extensions; do
7527   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7528     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7529     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7530     break 2
7531   fi
7532 done
7533 done
7534
7535 fi
7536 fi
7537 RANLIB=$ac_cv_prog_RANLIB
7538 if test -n "$RANLIB"; then
7539   echo "$as_me:$LINENO: result: $RANLIB" >&5
7540 echo "${ECHO_T}$RANLIB" >&6
7541 else
7542   echo "$as_me:$LINENO: result: no" >&5
7543 echo "${ECHO_T}no" >&6
7544 fi
7545
7546 fi
7547 if test -z "$ac_cv_prog_RANLIB"; then
7548   ac_ct_RANLIB=$RANLIB
7549   # Extract the first word of "ranlib", so it can be a program name with args.
7550 set dummy ranlib; ac_word=$2
7551 echo "$as_me:$LINENO: checking for $ac_word" >&5
7552 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7553 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
7554   echo $ECHO_N "(cached) $ECHO_C" >&6
7555 else
7556   if test -n "$ac_ct_RANLIB"; then
7557   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7558 else
7559 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7560 for as_dir in $PATH
7561 do
7562   IFS=$as_save_IFS
7563   test -z "$as_dir" && as_dir=.
7564   for ac_exec_ext in '' $ac_executable_extensions; do
7565   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7566     ac_cv_prog_ac_ct_RANLIB="ranlib"
7567     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7568     break 2
7569   fi
7570 done
7571 done
7572
7573   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
7574 fi
7575 fi
7576 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7577 if test -n "$ac_ct_RANLIB"; then
7578   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
7579 echo "${ECHO_T}$ac_ct_RANLIB" >&6
7580 else
7581   echo "$as_me:$LINENO: result: no" >&5
7582 echo "${ECHO_T}no" >&6
7583 fi
7584
7585   RANLIB=$ac_ct_RANLIB
7586 else
7587   RANLIB="$ac_cv_prog_RANLIB"
7588 fi
7589
7590 if test -n "$ac_tool_prefix"; then
7591   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7592 set dummy ${ac_tool_prefix}strip; ac_word=$2
7593 echo "$as_me:$LINENO: checking for $ac_word" >&5
7594 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7595 if test "${ac_cv_prog_STRIP+set}" = set; then
7596   echo $ECHO_N "(cached) $ECHO_C" >&6
7597 else
7598   if test -n "$STRIP"; then
7599   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7600 else
7601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7602 for as_dir in $PATH
7603 do
7604   IFS=$as_save_IFS
7605   test -z "$as_dir" && as_dir=.
7606   for ac_exec_ext in '' $ac_executable_extensions; do
7607   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7608     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7609     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7610     break 2
7611   fi
7612 done
7613 done
7614
7615 fi
7616 fi
7617 STRIP=$ac_cv_prog_STRIP
7618 if test -n "$STRIP"; then
7619   echo "$as_me:$LINENO: result: $STRIP" >&5
7620 echo "${ECHO_T}$STRIP" >&6
7621 else
7622   echo "$as_me:$LINENO: result: no" >&5
7623 echo "${ECHO_T}no" >&6
7624 fi
7625
7626 fi
7627 if test -z "$ac_cv_prog_STRIP"; then
7628   ac_ct_STRIP=$STRIP
7629   # Extract the first word of "strip", so it can be a program name with args.
7630 set dummy strip; ac_word=$2
7631 echo "$as_me:$LINENO: checking for $ac_word" >&5
7632 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7633 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
7634   echo $ECHO_N "(cached) $ECHO_C" >&6
7635 else
7636   if test -n "$ac_ct_STRIP"; then
7637   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7638 else
7639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7640 for as_dir in $PATH
7641 do
7642   IFS=$as_save_IFS
7643   test -z "$as_dir" && as_dir=.
7644   for ac_exec_ext in '' $ac_executable_extensions; do
7645   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7646     ac_cv_prog_ac_ct_STRIP="strip"
7647     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7648     break 2
7649   fi
7650 done
7651 done
7652
7653   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
7654 fi
7655 fi
7656 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7657 if test -n "$ac_ct_STRIP"; then
7658   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
7659 echo "${ECHO_T}$ac_ct_STRIP" >&6
7660 else
7661   echo "$as_me:$LINENO: result: no" >&5
7662 echo "${ECHO_T}no" >&6
7663 fi
7664
7665   STRIP=$ac_ct_STRIP
7666 else
7667   STRIP="$ac_cv_prog_STRIP"
7668 fi
7669
7670
7671 enable_dlopen=no
7672 enable_win32_dll=no
7673
7674 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
7675 if test "${enable_libtool_lock+set}" = set; then
7676   enableval="$enable_libtool_lock"
7677
7678 fi;
7679 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
7680
7681 # Some flags need to be propagated to the compiler or linker for good
7682 # libtool support.
7683 case $host in
7684 *-*-irix6*)
7685   # Find out which ABI we are using.
7686   echo '#line 7686 "configure"' > conftest.$ac_ext
7687   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7688   (eval $ac_compile) 2>&5
7689   ac_status=$?
7690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7691   (exit $ac_status); }; then
7692     case `/usr/bin/file conftest.$ac_objext` in
7693     *32-bit*)
7694       LD="${LD-ld} -32"
7695       ;;
7696     *N32*)
7697       LD="${LD-ld} -n32"
7698       ;;
7699     *64-bit*)
7700       LD="${LD-ld} -64"
7701       ;;
7702     esac
7703   fi
7704   rm -rf conftest*
7705   ;;
7706
7707 *-*-sco3.2v5*)
7708   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
7709   SAVE_CFLAGS="$CFLAGS"
7710   CFLAGS="$CFLAGS -belf"
7711   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
7712 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
7713 if test "${lt_cv_cc_needs_belf+set}" = set; then
7714   echo $ECHO_N "(cached) $ECHO_C" >&6
7715 else
7716
7717
7718      ac_ext=c
7719 ac_cpp='$CPP $CPPFLAGS'
7720 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7721 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7722 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7723
7724      cat >conftest.$ac_ext <<_ACEOF
7725 #line $LINENO "configure"
7726 /* confdefs.h.  */
7727 _ACEOF
7728 cat confdefs.h >>conftest.$ac_ext
7729 cat >>conftest.$ac_ext <<_ACEOF
7730 /* end confdefs.h.  */
7731
7732 int
7733 main ()
7734 {
7735
7736   ;
7737   return 0;
7738 }
7739 _ACEOF
7740 rm -f conftest.$ac_objext conftest$ac_exeext
7741 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7742   (eval $ac_link) 2>&5
7743   ac_status=$?
7744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7745   (exit $ac_status); } &&
7746          { ac_try='test -s conftest$ac_exeext'
7747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7748   (eval $ac_try) 2>&5
7749   ac_status=$?
7750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7751   (exit $ac_status); }; }; then
7752   lt_cv_cc_needs_belf=yes
7753 else
7754   echo "$as_me: failed program was:" >&5
7755 sed 's/^/| /' conftest.$ac_ext >&5
7756
7757 lt_cv_cc_needs_belf=no
7758 fi
7759 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7760      ac_ext=c
7761 ac_cpp='$CPP $CPPFLAGS'
7762 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7763 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7764 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7765
7766 fi
7767 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
7768 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
7769   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
7770     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
7771     CFLAGS="$SAVE_CFLAGS"
7772   fi
7773   ;;
7774
7775
7776 esac
7777
7778 # Sed substitution that helps us do robust quoting.  It backslashifies
7779 # metacharacters that are still active within double-quoted strings.
7780 Xsed='sed -e s/^X//'
7781 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
7782
7783 # Same as above, but do not quote variable references.
7784 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
7785
7786 # Sed substitution to delay expansion of an escaped shell variable in a
7787 # double_quote_subst'ed string.
7788 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7789
7790 # Constants:
7791 rm="rm -f"
7792
7793 # Global variables:
7794 default_ofile=libtool
7795 can_build_shared=yes
7796
7797 # All known linkers require a `.a' archive for static linking (except M$VC,
7798 # which needs '.lib').
7799 libext=a
7800 ltmain="$ac_aux_dir/ltmain.sh"
7801 ofile="$default_ofile"
7802 with_gnu_ld="$lt_cv_prog_gnu_ld"
7803 need_locks="$enable_libtool_lock"
7804
7805 old_CC="$CC"
7806 old_CFLAGS="$CFLAGS"
7807
7808 # Set sane defaults for various variables
7809 test -z "$AR" && AR=ar
7810 test -z "$AR_FLAGS" && AR_FLAGS=cru
7811 test -z "$AS" && AS=as
7812 test -z "$CC" && CC=cc
7813 test -z "$DLLTOOL" && DLLTOOL=dlltool
7814 test -z "$LD" && LD=ld
7815 test -z "$LN_S" && LN_S="ln -s"
7816 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7817 test -z "$NM" && NM=nm
7818 test -z "$OBJDUMP" && OBJDUMP=objdump
7819 test -z "$RANLIB" && RANLIB=:
7820 test -z "$STRIP" && STRIP=:
7821 test -z "$ac_objext" && ac_objext=o
7822
7823 if test x"$host" != x"$build"; then
7824   ac_tool_prefix=${host_alias}-
7825 else
7826   ac_tool_prefix=
7827 fi
7828
7829 # Transform linux* to *-*-linux-gnu*, to support old configure scripts.
7830 case $host_os in
7831 linux-gnu*) ;;
7832 linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
7833 esac
7834
7835 case $host_os in
7836 aix3*)
7837   # AIX sometimes has problems with the GCC collect2 program.  For some
7838   # reason, if we set the COLLECT_NAMES environment variable, the problems
7839   # vanish in a puff of smoke.
7840   if test "X${COLLECT_NAMES+set}" != Xset; then
7841     COLLECT_NAMES=
7842     export COLLECT_NAMES
7843   fi
7844   ;;
7845 esac
7846
7847 # Determine commands to create old-style static archives.
7848 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
7849 old_postinstall_cmds='chmod 644 $oldlib'
7850 old_postuninstall_cmds=
7851
7852 if test -n "$RANLIB"; then
7853   case $host_os in
7854   openbsd*)
7855     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
7856     ;;
7857   *)
7858     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
7859     ;;
7860   esac
7861   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
7862 fi
7863
7864 # Allow CC to be a program name with arguments.
7865 set dummy $CC
7866 compiler="$2"
7867
7868 echo "$as_me:$LINENO: checking for objdir" >&5
7869 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
7870 rm -f .libs 2>/dev/null
7871 mkdir .libs 2>/dev/null
7872 if test -d .libs; then
7873   objdir=.libs
7874 else
7875   # MS-DOS does not allow filenames that begin with a dot.
7876   objdir=_libs
7877 fi
7878 rmdir .libs 2>/dev/null
7879 echo "$as_me:$LINENO: result: $objdir" >&5
7880 echo "${ECHO_T}$objdir" >&6
7881
7882
7883
7884 # Check whether --with-pic or --without-pic was given.
7885 if test "${with_pic+set}" = set; then
7886   withval="$with_pic"
7887   pic_mode="$withval"
7888 else
7889   pic_mode=default
7890 fi;
7891 test -z "$pic_mode" && pic_mode=default
7892
7893 # We assume here that the value for lt_cv_prog_cc_pic will not be cached
7894 # in isolation, and that seeing it set (from the cache) indicates that
7895 # the associated values are set (in the cache) correctly too.
7896 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7897 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
7898 if test "${lt_cv_prog_cc_pic+set}" = set; then
7899   echo $ECHO_N "(cached) $ECHO_C" >&6
7900 else
7901    lt_cv_prog_cc_pic=
7902   lt_cv_prog_cc_shlib=
7903   lt_cv_prog_cc_wl=
7904   lt_cv_prog_cc_static=
7905   lt_cv_prog_cc_no_builtin=
7906   lt_cv_prog_cc_can_build_shared=$can_build_shared
7907
7908   if test "$GCC" = yes; then
7909     lt_cv_prog_cc_wl='-Wl,'
7910     lt_cv_prog_cc_static='-static'
7911
7912     case $host_os in
7913     aix*)
7914       # Below there is a dirty hack to force normal static linking with -ldl
7915       # The problem is because libdl dynamically linked with both libc and
7916       # libC (AIX C++ library), which obviously doesn't included in libraries
7917       # list by gcc. This cause undefined symbols with -static flags.
7918       # This hack allows C programs to be linked with "-static -ldl", but
7919       # not sure about C++ programs.
7920       lt_cv_prog_cc_static="$lt_cv_prog_cc_static ${lt_cv_prog_cc_wl}-lC"
7921       ;;
7922     amigaos*)
7923       # FIXME: we need at least 68020 code to build shared libraries, but
7924       # adding the `-m68020' flag to GCC prevents building anything better,
7925       # like `-m68040'.
7926       lt_cv_prog_cc_pic='-m68020 -resident32 -malways-restore-a4'
7927       ;;
7928     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7929       # PIC is the default for these OSes.
7930       ;;
7931     darwin* | rhapsody*)
7932       # PIC is the default on this platform
7933       # Common symbols not allowed in MH_DYLIB files
7934       lt_cv_prog_cc_pic='-fno-common'
7935       ;;
7936     cygwin* | mingw* | pw32* | os2*)
7937       # This hack is so that the source file can tell whether it is being
7938       # built for inclusion in a dll (and should export symbols for example).
7939       lt_cv_prog_cc_pic='-DDLL_EXPORT'
7940       ;;
7941     sysv4*MP*)
7942       if test -d /usr/nec; then
7943          lt_cv_prog_cc_pic=-Kconform_pic
7944       fi
7945       ;;
7946     *)
7947       lt_cv_prog_cc_pic='-fPIC'
7948       ;;
7949     esac
7950   else
7951     # PORTME Check for PIC flags for the system compiler.
7952     case $host_os in
7953     aix3* | aix4* | aix5*)
7954       lt_cv_prog_cc_wl='-Wl,'
7955       # All AIX code is PIC.
7956       if test "$host_cpu" = ia64; then
7957         # AIX 5 now supports IA64 processor
7958         lt_cv_prog_cc_static='-Bstatic'
7959       else
7960         lt_cv_prog_cc_static='-bnso -bI:/lib/syscalls.exp'
7961       fi
7962       ;;
7963
7964     hpux9* | hpux10* | hpux11*)
7965       # Is there a better lt_cv_prog_cc_static that works with the bundled CC?
7966       lt_cv_prog_cc_wl='-Wl,'
7967       lt_cv_prog_cc_static="${lt_cv_prog_cc_wl}-a ${lt_cv_prog_cc_wl}archive"
7968       lt_cv_prog_cc_pic='+Z'
7969       ;;
7970
7971     irix5* | irix6* | nonstopux*)
7972       lt_cv_prog_cc_wl='-Wl,'
7973       lt_cv_prog_cc_static='-non_shared'
7974       # PIC (with -KPIC) is the default.
7975       ;;
7976
7977     cygwin* | mingw* | pw32* | os2*)
7978       # This hack is so that the source file can tell whether it is being
7979       # built for inclusion in a dll (and should export symbols for example).
7980       lt_cv_prog_cc_pic='-DDLL_EXPORT'
7981       ;;
7982
7983     newsos6)
7984       lt_cv_prog_cc_pic='-KPIC'
7985       lt_cv_prog_cc_static='-Bstatic'
7986       ;;
7987
7988     osf3* | osf4* | osf5*)
7989       # All OSF/1 code is PIC.
7990       lt_cv_prog_cc_wl='-Wl,'
7991       lt_cv_prog_cc_static='-non_shared'
7992       ;;
7993
7994     sco3.2v5*)
7995       lt_cv_prog_cc_pic='-Kpic'
7996       lt_cv_prog_cc_static='-dn'
7997       lt_cv_prog_cc_shlib='-belf'
7998       ;;
7999
8000     solaris*)
8001       lt_cv_prog_cc_pic='-KPIC'
8002       lt_cv_prog_cc_static='-Bstatic'
8003       lt_cv_prog_cc_wl='-Wl,'
8004       ;;
8005
8006     sunos4*)
8007       lt_cv_prog_cc_pic='-PIC'
8008       lt_cv_prog_cc_static='-Bstatic'
8009       lt_cv_prog_cc_wl='-Qoption ld '
8010       ;;
8011
8012     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
8013       lt_cv_prog_cc_pic='-KPIC'
8014       lt_cv_prog_cc_static='-Bstatic'
8015       lt_cv_prog_cc_wl='-Wl,'
8016       ;;
8017
8018     uts4*)
8019       lt_cv_prog_cc_pic='-pic'
8020       lt_cv_prog_cc_static='-Bstatic'
8021       ;;
8022
8023     sysv4*MP*)
8024       if test -d /usr/nec ;then
8025         lt_cv_prog_cc_pic='-Kconform_pic'
8026         lt_cv_prog_cc_static='-Bstatic'
8027       fi
8028       ;;
8029
8030     *)
8031       lt_cv_prog_cc_can_build_shared=no
8032       ;;
8033     esac
8034   fi
8035
8036 fi
8037
8038 if test -z "$lt_cv_prog_cc_pic"; then
8039   echo "$as_me:$LINENO: result: none" >&5
8040 echo "${ECHO_T}none" >&6
8041 else
8042   echo "$as_me:$LINENO: result: $lt_cv_prog_cc_pic" >&5
8043 echo "${ECHO_T}$lt_cv_prog_cc_pic" >&6
8044
8045   # Check to make sure the pic_flag actually works.
8046   echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_cv_prog_cc_pic works" >&5
8047 echo $ECHO_N "checking if $compiler PIC flag $lt_cv_prog_cc_pic works... $ECHO_C" >&6
8048   if test "${lt_cv_prog_cc_pic_works+set}" = set; then
8049   echo $ECHO_N "(cached) $ECHO_C" >&6
8050 else
8051       save_CFLAGS="$CFLAGS"
8052     CFLAGS="$CFLAGS $lt_cv_prog_cc_pic -DPIC"
8053     cat >conftest.$ac_ext <<_ACEOF
8054 #line $LINENO "configure"
8055 /* confdefs.h.  */
8056 _ACEOF
8057 cat confdefs.h >>conftest.$ac_ext
8058 cat >>conftest.$ac_ext <<_ACEOF
8059 /* end confdefs.h.  */
8060
8061 int
8062 main ()
8063 {
8064
8065   ;
8066   return 0;
8067 }
8068 _ACEOF
8069 rm -f conftest.$ac_objext
8070 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8071   (eval $ac_compile) 2>&5
8072   ac_status=$?
8073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8074   (exit $ac_status); } &&
8075          { ac_try='test -s conftest.$ac_objext'
8076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8077   (eval $ac_try) 2>&5
8078   ac_status=$?
8079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8080   (exit $ac_status); }; }; then
8081         case $host_os in
8082       hpux9* | hpux10* | hpux11*)
8083         # On HP-UX, both CC and GCC only warn that PIC is supported... then
8084         # they create non-PIC objects.  So, if there were any warnings, we
8085         # assume that PIC is not supported.
8086         if test -s conftest.err; then
8087           lt_cv_prog_cc_pic_works=no
8088         else
8089           lt_cv_prog_cc_pic_works=yes
8090         fi
8091         ;;
8092       *)
8093         lt_cv_prog_cc_pic_works=yes
8094         ;;
8095       esac
8096
8097 else
8098   echo "$as_me: failed program was:" >&5
8099 sed 's/^/| /' conftest.$ac_ext >&5
8100
8101       lt_cv_prog_cc_pic_works=no
8102
8103 fi
8104 rm -f conftest.$ac_objext conftest.$ac_ext
8105     CFLAGS="$save_CFLAGS"
8106
8107 fi
8108
8109
8110   if test "X$lt_cv_prog_cc_pic_works" = Xno; then
8111     lt_cv_prog_cc_pic=
8112     lt_cv_prog_cc_can_build_shared=no
8113   else
8114     lt_cv_prog_cc_pic=" $lt_cv_prog_cc_pic"
8115   fi
8116
8117   echo "$as_me:$LINENO: result: $lt_cv_prog_cc_pic_works" >&5
8118 echo "${ECHO_T}$lt_cv_prog_cc_pic_works" >&6
8119 fi
8120
8121 # Check for any special shared library compilation flags.
8122 if test -n "$lt_cv_prog_cc_shlib"; then
8123   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&5
8124 echo "$as_me: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&2;}
8125   if echo "$old_CC $old_CFLAGS " | egrep -e "[  ]$lt_cv_prog_cc_shlib[  ]" >/dev/null; then :
8126   else
8127    { echo "$as_me:$LINENO: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
8128 echo "$as_me: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
8129     lt_cv_prog_cc_can_build_shared=no
8130   fi
8131 fi
8132
8133 echo "$as_me:$LINENO: checking if $compiler static flag $lt_cv_prog_cc_static works" >&5
8134 echo $ECHO_N "checking if $compiler static flag $lt_cv_prog_cc_static works... $ECHO_C" >&6
8135 if test "${lt_cv_prog_cc_static_works+set}" = set; then
8136   echo $ECHO_N "(cached) $ECHO_C" >&6
8137 else
8138     lt_cv_prog_cc_static_works=no
8139   save_LDFLAGS="$LDFLAGS"
8140   LDFLAGS="$LDFLAGS $lt_cv_prog_cc_static"
8141   cat >conftest.$ac_ext <<_ACEOF
8142 #line $LINENO "configure"
8143 /* confdefs.h.  */
8144 _ACEOF
8145 cat confdefs.h >>conftest.$ac_ext
8146 cat >>conftest.$ac_ext <<_ACEOF
8147 /* end confdefs.h.  */
8148
8149 int
8150 main ()
8151 {
8152
8153   ;
8154   return 0;
8155 }
8156 _ACEOF
8157 rm -f conftest.$ac_objext conftest$ac_exeext
8158 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8159   (eval $ac_link) 2>&5
8160   ac_status=$?
8161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8162   (exit $ac_status); } &&
8163          { ac_try='test -s conftest$ac_exeext'
8164   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8165   (eval $ac_try) 2>&5
8166   ac_status=$?
8167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8168   (exit $ac_status); }; }; then
8169   lt_cv_prog_cc_static_works=yes
8170 else
8171   echo "$as_me: failed program was:" >&5
8172 sed 's/^/| /' conftest.$ac_ext >&5
8173
8174 fi
8175 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8176   LDFLAGS="$save_LDFLAGS"
8177
8178 fi
8179
8180
8181 # Belt *and* braces to stop my trousers falling down:
8182 test "X$lt_cv_prog_cc_static_works" = Xno && lt_cv_prog_cc_static=
8183 echo "$as_me:$LINENO: result: $lt_cv_prog_cc_static_works" >&5
8184 echo "${ECHO_T}$lt_cv_prog_cc_static_works" >&6
8185
8186 pic_flag="$lt_cv_prog_cc_pic"
8187 special_shlib_compile_flags="$lt_cv_prog_cc_shlib"
8188 wl="$lt_cv_prog_cc_wl"
8189 link_static_flag="$lt_cv_prog_cc_static"
8190 no_builtin_flag="$lt_cv_prog_cc_no_builtin"
8191 can_build_shared="$lt_cv_prog_cc_can_build_shared"
8192
8193
8194 # Check to see if options -o and -c are simultaneously supported by compiler
8195 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
8196 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
8197 if test "${lt_cv_compiler_c_o+set}" = set; then
8198   echo $ECHO_N "(cached) $ECHO_C" >&6
8199 else
8200
8201 $rm -r conftest 2>/dev/null
8202 mkdir conftest
8203 cd conftest
8204 echo "int some_variable = 0;" > conftest.$ac_ext
8205 mkdir out
8206 # According to Tom Tromey, Ian Lance Taylor reported there are C compilers
8207 # that will create temporary files in the current directory regardless of
8208 # the output directory.  Thus, making CWD read-only will cause this test
8209 # to fail, enabling locking or at least warning the user not to do parallel
8210 # builds.
8211 chmod -w .
8212 save_CFLAGS="$CFLAGS"
8213 CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
8214 compiler_c_o=no
8215 if { (eval echo configure:8215: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
8216   # The compiler can only warn and ignore the option if not recognized
8217   # So say no if there are warnings
8218   if test -s out/conftest.err; then
8219     lt_cv_compiler_c_o=no
8220   else
8221     lt_cv_compiler_c_o=yes
8222   fi
8223 else
8224   # Append any errors to the config.log.
8225   cat out/conftest.err 1>&5
8226   lt_cv_compiler_c_o=no
8227 fi
8228 CFLAGS="$save_CFLAGS"
8229 chmod u+w .
8230 $rm conftest* out/*
8231 rmdir out
8232 cd ..
8233 rmdir conftest
8234 $rm -r conftest 2>/dev/null
8235
8236 fi
8237
8238 compiler_c_o=$lt_cv_compiler_c_o
8239 echo "$as_me:$LINENO: result: $compiler_c_o" >&5
8240 echo "${ECHO_T}$compiler_c_o" >&6
8241
8242 if test x"$compiler_c_o" = x"yes"; then
8243   # Check to see if we can write to a .lo
8244   echo "$as_me:$LINENO: checking if $compiler supports -c -o file.lo" >&5
8245 echo $ECHO_N "checking if $compiler supports -c -o file.lo... $ECHO_C" >&6
8246   if test "${lt_cv_compiler_o_lo+set}" = set; then
8247   echo $ECHO_N "(cached) $ECHO_C" >&6
8248 else
8249
8250   lt_cv_compiler_o_lo=no
8251   save_CFLAGS="$CFLAGS"
8252   CFLAGS="$CFLAGS -c -o conftest.lo"
8253   save_objext="$ac_objext"
8254   ac_objext=lo
8255   cat >conftest.$ac_ext <<_ACEOF
8256 #line $LINENO "configure"
8257 /* confdefs.h.  */
8258 _ACEOF
8259 cat confdefs.h >>conftest.$ac_ext
8260 cat >>conftest.$ac_ext <<_ACEOF
8261 /* end confdefs.h.  */
8262
8263 int
8264 main ()
8265 {
8266 int some_variable = 0;
8267   ;
8268   return 0;
8269 }
8270 _ACEOF
8271 rm -f conftest.$ac_objext
8272 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8273   (eval $ac_compile) 2>&5
8274   ac_status=$?
8275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8276   (exit $ac_status); } &&
8277          { ac_try='test -s conftest.$ac_objext'
8278   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8279   (eval $ac_try) 2>&5
8280   ac_status=$?
8281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8282   (exit $ac_status); }; }; then
8283       # The compiler can only warn and ignore the option if not recognized
8284     # So say no if there are warnings
8285     if test -s conftest.err; then
8286       lt_cv_compiler_o_lo=no
8287     else
8288       lt_cv_compiler_o_lo=yes
8289     fi
8290
8291 else
8292   echo "$as_me: failed program was:" >&5
8293 sed 's/^/| /' conftest.$ac_ext >&5
8294
8295 fi
8296 rm -f conftest.$ac_objext conftest.$ac_ext
8297   ac_objext="$save_objext"
8298   CFLAGS="$save_CFLAGS"
8299
8300 fi
8301
8302   compiler_o_lo=$lt_cv_compiler_o_lo
8303   echo "$as_me:$LINENO: result: $compiler_o_lo" >&5
8304 echo "${ECHO_T}$compiler_o_lo" >&6
8305 else
8306   compiler_o_lo=no
8307 fi
8308
8309 # Check to see if we can do hard links to lock some files if needed
8310 hard_links="nottested"
8311 if test "$compiler_c_o" = no && test "$need_locks" != no; then
8312   # do not overwrite the value of need_locks provided by the user
8313   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
8314 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
8315   hard_links=yes
8316   $rm conftest*
8317   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8318   touch conftest.a
8319   ln conftest.a conftest.b 2>&5 || hard_links=no
8320   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8321   echo "$as_me:$LINENO: result: $hard_links" >&5
8322 echo "${ECHO_T}$hard_links" >&6
8323   if test "$hard_links" = no; then
8324     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
8325 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
8326     need_locks=warn
8327   fi
8328 else
8329   need_locks=no
8330 fi
8331
8332 if test "$GCC" = yes; then
8333   # Check to see if options -fno-rtti -fno-exceptions are supported by compiler
8334   echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
8335 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
8336   echo "int some_variable = 0;" > conftest.$ac_ext
8337   save_CFLAGS="$CFLAGS"
8338   CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
8339   compiler_rtti_exceptions=no
8340   cat >conftest.$ac_ext <<_ACEOF
8341 #line $LINENO "configure"
8342 /* confdefs.h.  */
8343 _ACEOF
8344 cat confdefs.h >>conftest.$ac_ext
8345 cat >>conftest.$ac_ext <<_ACEOF
8346 /* end confdefs.h.  */
8347
8348 int
8349 main ()
8350 {
8351 int some_variable = 0;
8352   ;
8353   return 0;
8354 }
8355 _ACEOF
8356 rm -f conftest.$ac_objext
8357 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8358   (eval $ac_compile) 2>&5
8359   ac_status=$?
8360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8361   (exit $ac_status); } &&
8362          { ac_try='test -s conftest.$ac_objext'
8363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8364   (eval $ac_try) 2>&5
8365   ac_status=$?
8366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8367   (exit $ac_status); }; }; then
8368       # The compiler can only warn and ignore the option if not recognized
8369     # So say no if there are warnings
8370     if test -s conftest.err; then
8371       compiler_rtti_exceptions=no
8372     else
8373       compiler_rtti_exceptions=yes
8374     fi
8375
8376 else
8377   echo "$as_me: failed program was:" >&5
8378 sed 's/^/| /' conftest.$ac_ext >&5
8379
8380 fi
8381 rm -f conftest.$ac_objext conftest.$ac_ext
8382   CFLAGS="$save_CFLAGS"
8383   echo "$as_me:$LINENO: result: $compiler_rtti_exceptions" >&5
8384 echo "${ECHO_T}$compiler_rtti_exceptions" >&6
8385
8386   if test "$compiler_rtti_exceptions" = "yes"; then
8387     no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
8388   else
8389     no_builtin_flag=' -fno-builtin'
8390   fi
8391 fi
8392
8393 # See if the linker supports building shared libraries.
8394 echo "$as_me:$LINENO: checking whether the linker ($LD) supports shared libraries" >&5
8395 echo $ECHO_N "checking whether the linker ($LD) supports shared libraries... $ECHO_C" >&6
8396
8397 allow_undefined_flag=
8398 no_undefined_flag=
8399 need_lib_prefix=unknown
8400 need_version=unknown
8401 # when you set need_version to no, make sure it does not cause -set_version
8402 # flags to be left without arguments
8403 archive_cmds=
8404 archive_expsym_cmds=
8405 old_archive_from_new_cmds=
8406 old_archive_from_expsyms_cmds=
8407 export_dynamic_flag_spec=
8408 whole_archive_flag_spec=
8409 thread_safe_flag_spec=
8410 hardcode_into_libs=no
8411 hardcode_libdir_flag_spec=
8412 hardcode_libdir_separator=
8413 hardcode_direct=no
8414 hardcode_minus_L=no
8415 hardcode_shlibpath_var=unsupported
8416 runpath_var=
8417 link_all_deplibs=unknown
8418 always_export_symbols=no
8419 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
8420 # include_expsyms should be a list of space-separated symbols to be *always*
8421 # included in the symbol list
8422 include_expsyms=
8423 # exclude_expsyms can be an egrep regular expression of symbols to exclude
8424 # it will be wrapped by ` (' and `)$', so one must not match beginning or
8425 # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8426 # as well as any symbol that contains `d'.
8427 exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
8428 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8429 # platforms (ab)use it in PIC code, but their linkers get confused if
8430 # the symbol is explicitly referenced.  Since portable code cannot
8431 # rely on this symbol name, it's probably fine to never include it in
8432 # preloaded symbol tables.
8433 extract_expsyms_cmds=
8434
8435 case $host_os in
8436 cygwin* | mingw* | pw32*)
8437   # FIXME: the MSVC++ port hasn't been tested in a loooong time
8438   # When not using gcc, we currently assume that we are using
8439   # Microsoft Visual C++.
8440   if test "$GCC" != yes; then
8441     with_gnu_ld=no
8442   fi
8443   ;;
8444 openbsd*)
8445   with_gnu_ld=no
8446   ;;
8447 esac
8448
8449 ld_shlibs=yes
8450 if test "$with_gnu_ld" = yes; then
8451   # If archive_cmds runs LD, not CC, wlarc should be empty
8452   wlarc='${wl}'
8453
8454   # See if GNU ld supports shared libraries.
8455   case $host_os in
8456   aix3* | aix4* | aix5*)
8457     # On AIX, the GNU linker is very broken
8458     # Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
8459     ld_shlibs=no
8460     cat <<EOF 1>&2
8461
8462 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8463 *** to be unable to reliably create shared libraries on AIX.
8464 *** Therefore, libtool is disabling shared libraries support.  If you
8465 *** really care for shared libraries, you may want to modify your PATH
8466 *** so that a non-GNU linker is found, and then restart.
8467
8468 EOF
8469     ;;
8470
8471   amigaos*)
8472     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)'
8473     hardcode_libdir_flag_spec='-L$libdir'
8474     hardcode_minus_L=yes
8475
8476     # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
8477     # that the semantics of dynamic libraries on AmigaOS, at least up
8478     # to version 4, is to share data among multiple programs linked
8479     # with the same dynamic library.  Since this doesn't match the
8480     # behavior of shared libraries on other platforms, we can use
8481     # them.
8482     ld_shlibs=no
8483     ;;
8484
8485   beos*)
8486     if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
8487       allow_undefined_flag=unsupported
8488       # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8489       # support --undefined.  This deserves some investigation.  FIXME
8490       archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8491     else
8492       ld_shlibs=no
8493     fi
8494     ;;
8495
8496   cygwin* | mingw* | pw32*)
8497     # hardcode_libdir_flag_spec is actually meaningless, as there is
8498     # no search path for DLLs.
8499     hardcode_libdir_flag_spec='-L$libdir'
8500     allow_undefined_flag=unsupported
8501     always_export_symbols=yes
8502
8503     extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
8504       sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
8505       test -f $output_objdir/impgen.exe || (cd $output_objdir && \
8506       if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
8507       else $CC -o impgen impgen.c ; fi)~
8508       $output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
8509
8510     old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
8511
8512     # cygwin and mingw dlls have different entry points and sets of symbols
8513     # to exclude.
8514     # FIXME: what about values for MSVC?
8515     dll_entry=__cygwin_dll_entry@12
8516     dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
8517     case $host_os in
8518     mingw*)
8519       # mingw values
8520       dll_entry=_DllMainCRTStartup@12
8521       dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
8522       ;;
8523     esac
8524
8525     # mingw and cygwin differ, and it's simplest to just exclude the union
8526     # of the two symbol sets.
8527     dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
8528
8529     # recent cygwin and mingw systems supply a stub DllMain which the user
8530     # can override, but on older systems we have to supply one (in ltdll.c)
8531     if test "x$lt_cv_need_dllmain" = "xyes"; then
8532       ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
8533       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~
8534         test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
8535     else
8536       ltdll_obj=
8537       ltdll_cmds=
8538     fi
8539
8540     # Extract the symbol export list from an `--export-all' def file,
8541     # then regenerate the def file from the symbol export list, so that
8542     # the compiled dll only exports the symbol export list.
8543     # Be careful not to strip the DATA tag left be newer dlltools.
8544     export_symbols_cmds="$ltdll_cmds"'
8545       $DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
8546       sed -e "1,/EXPORTS/d" -e "s/ @ [0-9]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
8547
8548     # If the export-symbols file already is a .def file (1st line
8549     # is EXPORTS), use it as is.
8550     # If DATA tags from a recent dlltool are present, honour them!
8551     archive_expsym_cmds='if test "x`sed 1q $export_symbols`" = xEXPORTS; then
8552         cp $export_symbols $output_objdir/$soname-def;
8553       else
8554         echo EXPORTS > $output_objdir/$soname-def;
8555         _lt_hint=1;
8556         cat $export_symbols | while read symbol; do
8557          set dummy \$symbol;
8558          case \$# in
8559            2) echo "   \$2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
8560            4) echo "   \$2 \$3 \$4 ; " >> $output_objdir/$soname-def; _lt_hint=`expr \$_lt_hint - 1`;;
8561            *) echo "     \$2 @ \$_lt_hint \$3 ; " >> $output_objdir/$soname-def;;
8562          esac;
8563          _lt_hint=`expr 1 + \$_lt_hint`;
8564         done;
8565       fi~
8566       '"$ltdll_cmds"'
8567       $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~
8568       $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~
8569       $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~
8570       $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~
8571       $CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
8572     ;;
8573
8574   netbsd*)
8575     if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8576       archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8577       wlarc=
8578     else
8579       archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8580       archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8581     fi
8582     ;;
8583
8584   solaris* | sysv5*)
8585     if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
8586       ld_shlibs=no
8587       cat <<EOF 1>&2
8588
8589 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8590 *** create shared libraries on Solaris systems.  Therefore, libtool
8591 *** is disabling shared libraries support.  We urge you to upgrade GNU
8592 *** binutils to release 2.9.1 or newer.  Another option is to modify
8593 *** your PATH or compiler configuration so that the native linker is
8594 *** used, and then restart.
8595
8596 EOF
8597     elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
8598       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8599       archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8600     else
8601       ld_shlibs=no
8602     fi
8603     ;;
8604
8605   sunos4*)
8606     archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8607     wlarc=
8608     hardcode_direct=yes
8609     hardcode_shlibpath_var=no
8610     ;;
8611
8612   *)
8613     if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
8614       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8615       archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8616     else
8617       ld_shlibs=no
8618     fi
8619     ;;
8620   esac
8621
8622   if test "$ld_shlibs" = yes; then
8623     runpath_var=LD_RUN_PATH
8624     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
8625     export_dynamic_flag_spec='${wl}--export-dynamic'
8626     case $host_os in
8627     cygwin* | mingw* | pw32*)
8628       # dlltool doesn't understand --whole-archive et. al.
8629       whole_archive_flag_spec=
8630       ;;
8631     *)
8632       # ancient GNU ld didn't support --whole-archive et. al.
8633       if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
8634         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8635       else
8636         whole_archive_flag_spec=
8637       fi
8638       ;;
8639     esac
8640   fi
8641 else
8642   # PORTME fill in a description of your system's linker (not GNU ld)
8643   case $host_os in
8644   aix3*)
8645     allow_undefined_flag=unsupported
8646     always_export_symbols=yes
8647     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'
8648     # Note: this linker hardcodes the directories in LIBPATH if there
8649     # are no directories specified by -L.
8650     hardcode_minus_L=yes
8651     if test "$GCC" = yes && test -z "$link_static_flag"; then
8652       # Neither direct hardcoding nor static linking is supported with a
8653       # broken collect2.
8654       hardcode_direct=unsupported
8655     fi
8656     ;;
8657
8658   aix4* | aix5*)
8659     if test "$host_cpu" = ia64; then
8660       # On IA64, the linker does run time linking by default, so we don't
8661       # have to do anything special.
8662       aix_use_runtimelinking=no
8663       exp_sym_flag='-Bexport'
8664       no_entry_flag=""
8665     else
8666       aix_use_runtimelinking=no
8667
8668       # Test if we are trying to use run time linking or normal
8669       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8670       # need to do runtime linking.
8671       case $host_os in aix4.[23]|aix4.[23].*|aix5*)
8672         for ld_flag in $LDFLAGS; do
8673           case $ld_flag in
8674           *-brtl*)
8675             aix_use_runtimelinking=yes
8676             break
8677           ;;
8678           esac
8679         done
8680       esac
8681
8682       exp_sym_flag='-bexport'
8683       no_entry_flag='-bnoentry'
8684     fi
8685
8686     # When large executables or shared objects are built, AIX ld can
8687     # have problems creating the table of contents.  If linking a library
8688     # or program results in "error TOC overflow" add -mminimal-toc to
8689     # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8690     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8691
8692     hardcode_direct=yes
8693     archive_cmds=''
8694     hardcode_libdir_separator=':'
8695     if test "$GCC" = yes; then
8696       case $host_os in aix4.[012]|aix4.[012].*)
8697         collect2name=`${CC} -print-prog-name=collect2`
8698         if test -f "$collect2name" && \
8699           strings "$collect2name" | grep resolve_lib_name >/dev/null
8700         then
8701           # We have reworked collect2
8702           hardcode_direct=yes
8703         else
8704           # We have old collect2
8705           hardcode_direct=unsupported
8706           # It fails to find uninstalled libraries when the uninstalled
8707           # path is not listed in the libpath.  Setting hardcode_minus_L
8708           # to unsupported forces relinking
8709           hardcode_minus_L=yes
8710           hardcode_libdir_flag_spec='-L$libdir'
8711           hardcode_libdir_separator=
8712         fi
8713       esac
8714
8715       shared_flag='-shared'
8716     else
8717       # not using gcc
8718       if test "$host_cpu" = ia64; then
8719         shared_flag='${wl}-G'
8720       else
8721         if test "$aix_use_runtimelinking" = yes; then
8722           shared_flag='${wl}-G'
8723         else
8724           shared_flag='${wl}-bM:SRE'
8725         fi
8726       fi
8727     fi
8728
8729     # It seems that -bexpall can do strange things, so it is better to
8730     # generate a list of symbols to export.
8731     always_export_symbols=yes
8732     if test "$aix_use_runtimelinking" = yes; then
8733       # Warning - without using the other runtime loading flags (-brtl),
8734       # -berok will link without error, but may produce a broken library.
8735       allow_undefined_flag='-berok'
8736       hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
8737       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"
8738     else
8739       if test "$host_cpu" = ia64; then
8740         hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8741         allow_undefined_flag="-z nodefs"
8742         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"
8743       else
8744         hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
8745         # Warning - without using the other run time loading flags,
8746         # -berok will link without error, but may produce a broken library.
8747         allow_undefined_flag='${wl}-berok'
8748         # This is a bit strange, but is similar to how AIX traditionally builds
8749         # it's shared libraries.
8750         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'
8751       fi
8752     fi
8753     ;;
8754
8755   amigaos*)
8756     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)'
8757     hardcode_libdir_flag_spec='-L$libdir'
8758     hardcode_minus_L=yes
8759     # see comment about different semantics on the GNU ld section
8760     ld_shlibs=no
8761     ;;
8762
8763   cygwin* | mingw* | pw32*)
8764     # When not using gcc, we currently assume that we are using
8765     # Microsoft Visual C++.
8766     # hardcode_libdir_flag_spec is actually meaningless, as there is
8767     # no search path for DLLs.
8768     hardcode_libdir_flag_spec=' '
8769     allow_undefined_flag=unsupported
8770     # Tell ltmain to make .lib files, not .a files.
8771     libext=lib
8772     # FIXME: Setting linknames here is a bad hack.
8773     archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
8774     # The linker will automatically build a .lib file if we build a DLL.
8775     old_archive_from_new_cmds='true'
8776     # FIXME: Should let the user specify the lib program.
8777     old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
8778     fix_srcfile_path='`cygpath -w "$srcfile"`'
8779     ;;
8780
8781   darwin* | rhapsody*)
8782     case "$host_os" in
8783     rhapsody* | darwin1.[012])
8784       allow_undefined_flag='-undefined suppress'
8785       ;;
8786     *) # Darwin 1.3 on
8787       allow_undefined_flag='-flat_namespace -undefined suppress'
8788       ;;
8789     esac
8790     # FIXME: Relying on posixy $() will cause problems for
8791     #        cross-compilation, but unfortunately the echo tests do not
8792     #        yet detect zsh echo's removal of \ escapes.  Also zsh mangles
8793     #        `"' quotes if we put them in here... so don't!
8794     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)'
8795     # We need to add '_' to the symbols in $export_symbols first
8796     #archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
8797     hardcode_direct=yes
8798     hardcode_shlibpath_var=no
8799     whole_archive_flag_spec='-all_load $convenience'
8800     ;;
8801
8802   freebsd1*)
8803     ld_shlibs=no
8804     ;;
8805
8806   # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8807   # support.  Future versions do this automatically, but an explicit c++rt0.o
8808   # does not break anything, and helps significantly (at the cost of a little
8809   # extra space).
8810   freebsd2.2*)
8811     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8812     hardcode_libdir_flag_spec='-R$libdir'
8813     hardcode_direct=yes
8814     hardcode_shlibpath_var=no
8815     ;;
8816
8817   # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8818   freebsd2*)
8819     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8820     hardcode_direct=yes
8821     hardcode_minus_L=yes
8822     hardcode_shlibpath_var=no
8823     ;;
8824
8825   # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8826   freebsd*)
8827     archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8828     hardcode_libdir_flag_spec='-R$libdir'
8829     hardcode_direct=yes
8830     hardcode_shlibpath_var=no
8831     ;;
8832
8833   hpux9* | hpux10* | hpux11*)
8834     case $host_os in
8835     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' ;;
8836     *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
8837     esac
8838     hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8839     hardcode_libdir_separator=:
8840     hardcode_direct=yes
8841     hardcode_minus_L=yes # Not in the search PATH, but as the default
8842                          # location of the library.
8843     export_dynamic_flag_spec='${wl}-E'
8844     ;;
8845
8846   irix5* | irix6* | nonstopux*)
8847     if test "$GCC" = yes; then
8848       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'
8849       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8850     else
8851       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'
8852       hardcode_libdir_flag_spec='-rpath $libdir'
8853     fi
8854     hardcode_libdir_separator=:
8855     link_all_deplibs=yes
8856     ;;
8857
8858   netbsd*)
8859     if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8860       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
8861     else
8862       archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
8863     fi
8864     hardcode_libdir_flag_spec='-R$libdir'
8865     hardcode_direct=yes
8866     hardcode_shlibpath_var=no
8867     ;;
8868
8869   newsos6)
8870     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8871     hardcode_direct=yes
8872     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8873     hardcode_libdir_separator=:
8874     hardcode_shlibpath_var=no
8875     ;;
8876
8877   openbsd*)
8878     hardcode_direct=yes
8879     hardcode_shlibpath_var=no
8880     if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8881       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8882       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8883       export_dynamic_flag_spec='${wl}-E'
8884     else
8885       case "$host_os" in
8886       openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8887         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8888         hardcode_libdir_flag_spec='-R$libdir'
8889         ;;
8890       *)
8891         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8892         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8893         ;;
8894       esac
8895     fi
8896     ;;
8897
8898   os2*)
8899     hardcode_libdir_flag_spec='-L$libdir'
8900     hardcode_minus_L=yes
8901     allow_undefined_flag=unsupported
8902     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'
8903     old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8904     ;;
8905
8906   osf3*)
8907     if test "$GCC" = yes; then
8908       allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8909       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'
8910     else
8911       allow_undefined_flag=' -expect_unresolved \*'
8912       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'
8913     fi
8914     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8915     hardcode_libdir_separator=:
8916     ;;
8917
8918   osf4* | osf5*)        # as osf3* with the addition of -msym flag
8919     if test "$GCC" = yes; then
8920       allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8921       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'
8922       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8923     else
8924       allow_undefined_flag=' -expect_unresolved \*'
8925       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'
8926       archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
8927       $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'
8928
8929       #Both c and cxx compiler support -rpath directly
8930       hardcode_libdir_flag_spec='-rpath $libdir'
8931     fi
8932     hardcode_libdir_separator=:
8933     ;;
8934
8935   sco3.2v5*)
8936     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8937     hardcode_shlibpath_var=no
8938     runpath_var=LD_RUN_PATH
8939     hardcode_runpath_var=yes
8940     export_dynamic_flag_spec='${wl}-Bexport'
8941     ;;
8942
8943   solaris*)
8944     # gcc --version < 3.0 without binutils cannot create self contained
8945     # shared libraries reliably, requiring libgcc.a to resolve some of
8946     # the object symbols generated in some cases.  Libraries that use
8947     # assert need libgcc.a to resolve __eprintf, for example.  Linking
8948     # a copy of libgcc.a into every shared library to guarantee resolving
8949     # such symbols causes other problems:  According to Tim Van Holder
8950     # <tim.van.holder@pandora.be>, C++ libraries end up with a separate
8951     # (to the application) exception stack for one thing.
8952     no_undefined_flag=' -z defs'
8953     if test "$GCC" = yes; then
8954       case `$CC --version 2>/dev/null` in
8955       [12].*)
8956         cat <<EOF 1>&2
8957
8958 *** Warning: Releases of GCC earlier than version 3.0 cannot reliably
8959 *** create self contained shared libraries on Solaris systems, without
8960 *** introducing a dependency on libgcc.a.  Therefore, libtool is disabling
8961 *** -no-undefined support, which will at least allow you to build shared
8962 *** libraries.  However, you may find that when you link such libraries
8963 *** into an application without using GCC, you have to manually add
8964 *** \`gcc --print-libgcc-file-name\` to the link command.  We urge you to
8965 *** upgrade to a newer version of GCC.  Another option is to rebuild your
8966 *** current GCC to use the GNU linker from GNU binutils 2.9.1 or newer.
8967
8968 EOF
8969         no_undefined_flag=
8970         ;;
8971       esac
8972     fi
8973     # $CC -shared without GNU ld will not create a library from C++
8974     # object files and a static libstdc++, better avoid it by now
8975     archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8976     archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8977                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8978     hardcode_libdir_flag_spec='-R$libdir'
8979     hardcode_shlibpath_var=no
8980     case $host_os in
8981     solaris2.[0-5] | solaris2.[0-5].*) ;;
8982     *) # Supported since Solaris 2.6 (maybe 2.5.1?)
8983       whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
8984     esac
8985     link_all_deplibs=yes
8986     ;;
8987
8988   sunos4*)
8989     if test "x$host_vendor" = xsequent; then
8990       # Use $CC to link under sequent, because it throws in some extra .o
8991       # files that make .init and .fini sections work.
8992       archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
8993     else
8994       archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
8995     fi
8996     hardcode_libdir_flag_spec='-L$libdir'
8997     hardcode_direct=yes
8998     hardcode_minus_L=yes
8999     hardcode_shlibpath_var=no
9000     ;;
9001
9002   sysv4)
9003     case $host_vendor in
9004       sni)
9005         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9006         hardcode_direct=yes # is this really true???
9007         ;;
9008       siemens)
9009         ## LD is ld it makes a PLAMLIB
9010         ## CC just makes a GrossModule.
9011         archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
9012         reload_cmds='$CC -r -o $output$reload_objs'
9013         hardcode_direct=no
9014         ;;
9015       motorola)
9016         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9017         hardcode_direct=no #Motorola manual says yes, but my tests say they lie
9018         ;;
9019     esac
9020     runpath_var='LD_RUN_PATH'
9021     hardcode_shlibpath_var=no
9022     ;;
9023
9024   sysv4.3*)
9025     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9026     hardcode_shlibpath_var=no
9027     export_dynamic_flag_spec='-Bexport'
9028     ;;
9029
9030   sysv5*)
9031     no_undefined_flag=' -z text'
9032     # $CC -shared without GNU ld will not create a library from C++
9033     # object files and a static libstdc++, better avoid it by now
9034     archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
9035     archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
9036                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
9037     hardcode_libdir_flag_spec=
9038     hardcode_shlibpath_var=no
9039     runpath_var='LD_RUN_PATH'
9040     ;;
9041
9042   uts4*)
9043     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9044     hardcode_libdir_flag_spec='-L$libdir'
9045     hardcode_shlibpath_var=no
9046     ;;
9047
9048   dgux*)
9049     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9050     hardcode_libdir_flag_spec='-L$libdir'
9051     hardcode_shlibpath_var=no
9052     ;;
9053
9054   sysv4*MP*)
9055     if test -d /usr/nec; then
9056       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9057       hardcode_shlibpath_var=no
9058       runpath_var=LD_RUN_PATH
9059       hardcode_runpath_var=yes
9060       ld_shlibs=yes
9061     fi
9062     ;;
9063
9064   sysv4.2uw2*)
9065     archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
9066     hardcode_direct=yes
9067     hardcode_minus_L=no
9068     hardcode_shlibpath_var=no
9069     hardcode_runpath_var=yes
9070     runpath_var=LD_RUN_PATH
9071     ;;
9072
9073   sysv5uw7* | unixware7*)
9074     no_undefined_flag='${wl}-z ${wl}text'
9075     if test "$GCC" = yes; then
9076       archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9077     else
9078       archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9079     fi
9080     runpath_var='LD_RUN_PATH'
9081     hardcode_shlibpath_var=no
9082     ;;
9083
9084   *)
9085     ld_shlibs=no
9086     ;;
9087   esac
9088 fi
9089 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
9090 echo "${ECHO_T}$ld_shlibs" >&6
9091 test "$ld_shlibs" = no && can_build_shared=no
9092
9093 # Check hardcoding attributes.
9094 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
9095 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
9096 hardcode_action=
9097 if test -n "$hardcode_libdir_flag_spec" || \
9098    test -n "$runpath_var"; then
9099
9100   # We can hardcode non-existant directories.
9101   if test "$hardcode_direct" != no &&
9102      # If the only mechanism to avoid hardcoding is shlibpath_var, we
9103      # have to relink, otherwise we might link with an installed library
9104      # when we should be linking with a yet-to-be-installed one
9105      ## test "$hardcode_shlibpath_var" != no &&
9106      test "$hardcode_minus_L" != no; then
9107     # Linking always hardcodes the temporary library directory.
9108     hardcode_action=relink
9109   else
9110     # We can link without hardcoding, and we can hardcode nonexisting dirs.
9111     hardcode_action=immediate
9112   fi
9113 else
9114   # We cannot hardcode anything, or else we can only hardcode existing
9115   # directories.
9116   hardcode_action=unsupported
9117 fi
9118 echo "$as_me:$LINENO: result: $hardcode_action" >&5
9119 echo "${ECHO_T}$hardcode_action" >&6
9120
9121 striplib=
9122 old_striplib=
9123 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
9124 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
9125 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
9126   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
9127   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
9128   echo "$as_me:$LINENO: result: yes" >&5
9129 echo "${ECHO_T}yes" >&6
9130 else
9131   echo "$as_me:$LINENO: result: no" >&5
9132 echo "${ECHO_T}no" >&6
9133 fi
9134
9135 reload_cmds='$LD$reload_flag -o $output$reload_objs'
9136 test -z "$deplibs_check_method" && deplibs_check_method=unknown
9137
9138 # PORTME Fill in your ld.so characteristics
9139 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
9140 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
9141 library_names_spec=
9142 libname_spec='lib$name'
9143 soname_spec=
9144 postinstall_cmds=
9145 postuninstall_cmds=
9146 finish_cmds=
9147 finish_eval=
9148 shlibpath_var=
9149 shlibpath_overrides_runpath=unknown
9150 version_type=none
9151 dynamic_linker="$host_os ld.so"
9152 sys_lib_dlsearch_path_spec="/lib /usr/lib"
9153 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
9154
9155 case $host_os in
9156 aix3*)
9157   version_type=linux
9158   library_names_spec='${libname}${release}.so$versuffix $libname.a'
9159   shlibpath_var=LIBPATH
9160
9161   # AIX has no versioning support, so we append a major version to the name.
9162   soname_spec='${libname}${release}.so$major'
9163   ;;
9164
9165 aix4* | aix5*)
9166   version_type=linux
9167   need_lib_prefix=no
9168   need_version=no
9169   hardcode_into_libs=yes
9170   if test "$host_cpu" = ia64; then
9171     # AIX 5 supports IA64
9172     library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
9173     shlibpath_var=LD_LIBRARY_PATH
9174   else
9175     # With GCC up to 2.95.x, collect2 would create an import file
9176     # for dependence libraries.  The import file would start with
9177     # the line `#! .'.  This would cause the generated library to
9178     # depend on `.', always an invalid library.  This was fixed in
9179     # development snapshots of GCC prior to 3.0.
9180     case $host_os in
9181       aix4 | aix4.[01] | aix4.[01].*)
9182         if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9183              echo ' yes '
9184              echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
9185           :
9186         else
9187           can_build_shared=no
9188         fi
9189         ;;
9190     esac
9191     # AIX (on Power*) has no versioning support, so currently we can
9192     # not hardcode correct soname into executable. Probably we can
9193     # add versioning support to collect2, so additional links can
9194     # be useful in future.
9195     if test "$aix_use_runtimelinking" = yes; then
9196       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9197       # instead of lib<name>.a to let people know that these are not
9198       # typical AIX shared libraries.
9199       library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9200     else
9201       # We preserve .a as extension for shared libraries through AIX4.2
9202       # and later when we are not doing run time linking.
9203       library_names_spec='${libname}${release}.a $libname.a'
9204       soname_spec='${libname}${release}.so$major'
9205     fi
9206     shlibpath_var=LIBPATH
9207   fi
9208   hardcode_into_libs=yes
9209   ;;
9210
9211 amigaos*)
9212   library_names_spec='$libname.ixlibrary $libname.a'
9213   # Create ${libname}_ixlibrary.a entries in /sys/libs.
9214   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'
9215   ;;
9216
9217 beos*)
9218   library_names_spec='${libname}.so'
9219   dynamic_linker="$host_os ld.so"
9220   shlibpath_var=LIBRARY_PATH
9221   ;;
9222
9223 bsdi4*)
9224   version_type=linux
9225   need_version=no
9226   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9227   soname_spec='${libname}${release}.so$major'
9228   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9229   shlibpath_var=LD_LIBRARY_PATH
9230   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9231   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9232   export_dynamic_flag_spec=-rdynamic
9233   # the default ld.so.conf also contains /usr/contrib/lib and
9234   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9235   # libtool to hard-code these into programs
9236   ;;
9237
9238 cygwin* | mingw* | pw32*)
9239   version_type=windows
9240   need_version=no
9241   need_lib_prefix=no
9242   case $GCC,$host_os in
9243   yes,cygwin*)
9244     library_names_spec='$libname.dll.a'
9245     soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
9246     postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
9247       dldir=$destdir/`dirname \$dlpath`~
9248       test -d \$dldir || mkdir -p \$dldir~
9249       $install_prog .libs/$dlname \$dldir/$dlname'
9250     postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
9251       dlpath=$dir/\$dldll~
9252        $rm \$dlpath'
9253     ;;
9254   yes,mingw*)
9255     library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
9256     sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g" -e "s,=/,/,g"`
9257     ;;
9258   yes,pw32*)
9259     library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/./-/g'`${versuffix}.dll'
9260     ;;
9261   *)
9262     library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll $libname.lib'
9263     ;;
9264   esac
9265   dynamic_linker='Win32 ld.exe'
9266   # FIXME: first we should search . and the directory the executable is in
9267   shlibpath_var=PATH
9268   ;;
9269
9270 darwin* | rhapsody*)
9271   dynamic_linker="$host_os dyld"
9272   version_type=darwin
9273   need_lib_prefix=no
9274   need_version=no
9275   # FIXME: Relying on posixy $() will cause problems for
9276   #        cross-compilation, but unfortunately the echo tests do not
9277   #        yet detect zsh echo's removal of \ escapes.
9278   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)'
9279   soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
9280   shlibpath_overrides_runpath=yes
9281   shlibpath_var=DYLD_LIBRARY_PATH
9282   ;;
9283
9284 freebsd1*)
9285   dynamic_linker=no
9286   ;;
9287
9288 freebsd*)
9289   objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
9290   version_type=freebsd-$objformat
9291   case $version_type in
9292     freebsd-elf*)
9293       library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
9294       need_version=no
9295       need_lib_prefix=no
9296       ;;
9297     freebsd-*)
9298       library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
9299       need_version=yes
9300       ;;
9301   esac
9302   shlibpath_var=LD_LIBRARY_PATH
9303   case $host_os in
9304   freebsd2*)
9305     shlibpath_overrides_runpath=yes
9306     ;;
9307   *)
9308     shlibpath_overrides_runpath=no
9309     hardcode_into_libs=yes
9310     ;;
9311   esac
9312   ;;
9313
9314 gnu*)
9315   version_type=linux
9316   need_lib_prefix=no
9317   need_version=no
9318   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
9319   soname_spec='${libname}${release}.so$major'
9320   shlibpath_var=LD_LIBRARY_PATH
9321   hardcode_into_libs=yes
9322   ;;
9323
9324 hpux9* | hpux10* | hpux11*)
9325   # Give a soname corresponding to the major version so that dld.sl refuses to
9326   # link against other versions.
9327   dynamic_linker="$host_os dld.sl"
9328   version_type=sunos
9329   need_lib_prefix=no
9330   need_version=no
9331   shlibpath_var=SHLIB_PATH
9332   shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9333   library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
9334   soname_spec='${libname}${release}.sl$major'
9335   # HP-UX runs *really* slowly unless shared libraries are mode 555.
9336   postinstall_cmds='chmod 555 $lib'
9337   ;;
9338
9339 irix5* | irix6* | nonstopux*)
9340   case $host_os in
9341     nonstopux*) version_type=nonstopux ;;
9342     *)          version_type=irix ;;
9343   esac
9344   need_lib_prefix=no
9345   need_version=no
9346   soname_spec='${libname}${release}.so$major'
9347   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
9348   case $host_os in
9349   irix5* | nonstopux*)
9350     libsuff= shlibsuff=
9351     ;;
9352   *)
9353     case $LD in # libtool.m4 will add one of these switches to LD
9354     *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
9355     *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
9356     *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
9357     *) libsuff= shlibsuff= libmagic=never-match;;
9358     esac
9359     ;;
9360   esac
9361   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9362   shlibpath_overrides_runpath=no
9363   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9364   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9365   ;;
9366
9367 # No shared lib support for Linux oldld, aout, or coff.
9368 linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
9369   dynamic_linker=no
9370   ;;
9371
9372 # This must be Linux ELF.
9373 linux-gnu*)
9374   version_type=linux
9375   need_lib_prefix=no
9376   need_version=no
9377   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9378   soname_spec='${libname}${release}.so$major'
9379   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9380   shlibpath_var=LD_LIBRARY_PATH
9381   shlibpath_overrides_runpath=no
9382   # This implies no fast_install, which is unacceptable.
9383   # Some rework will be needed to allow for fast_install
9384   # before this can be enabled.
9385   hardcode_into_libs=yes
9386
9387   # We used to test for /lib/ld.so.1 and disable shared libraries on
9388   # powerpc, because MkLinux only supported shared libraries with the
9389   # GNU dynamic linker.  Since this was broken with cross compilers,
9390   # most powerpc-linux boxes support dynamic linking these days and
9391   # people can always --disable-shared, the test was removed, and we
9392   # assume the GNU/Linux dynamic linker is in use.
9393   dynamic_linker='GNU/Linux ld.so'
9394   ;;
9395
9396 netbsd*)
9397   version_type=sunos
9398   need_lib_prefix=no
9399   need_version=no
9400   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9401     library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
9402     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9403     dynamic_linker='NetBSD (a.out) ld.so'
9404   else
9405     library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
9406     soname_spec='${libname}${release}.so$major'
9407     dynamic_linker='NetBSD ld.elf_so'
9408   fi
9409   shlibpath_var=LD_LIBRARY_PATH
9410   shlibpath_overrides_runpath=yes
9411   hardcode_into_libs=yes
9412   ;;
9413
9414 newsos6)
9415   version_type=linux
9416   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9417   shlibpath_var=LD_LIBRARY_PATH
9418   shlibpath_overrides_runpath=yes
9419   ;;
9420
9421 openbsd*)
9422   version_type=sunos
9423   need_lib_prefix=no
9424   need_version=no
9425   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9426     case "$host_os" in
9427     openbsd2.[89] | openbsd2.[89].*)
9428       shlibpath_overrides_runpath=no
9429       ;;
9430     *)
9431       shlibpath_overrides_runpath=yes
9432       ;;
9433     esac
9434   else
9435     shlibpath_overrides_runpath=yes
9436   fi
9437   library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
9438   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9439   shlibpath_var=LD_LIBRARY_PATH
9440   ;;
9441
9442 os2*)
9443   libname_spec='$name'
9444   need_lib_prefix=no
9445   library_names_spec='$libname.dll $libname.a'
9446   dynamic_linker='OS/2 ld.exe'
9447   shlibpath_var=LIBPATH
9448   ;;
9449
9450 osf3* | osf4* | osf5*)
9451   version_type=osf
9452   need_version=no
9453   soname_spec='${libname}${release}.so$major'
9454   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9455   shlibpath_var=LD_LIBRARY_PATH
9456   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9457   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
9458   hardcode_into_libs=yes
9459   ;;
9460
9461 sco3.2v5*)
9462   version_type=osf
9463   soname_spec='${libname}${release}.so$major'
9464   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9465   shlibpath_var=LD_LIBRARY_PATH
9466   ;;
9467
9468 solaris*)
9469   version_type=linux
9470   need_lib_prefix=no
9471   need_version=no
9472   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9473   soname_spec='${libname}${release}.so$major'
9474   shlibpath_var=LD_LIBRARY_PATH
9475   shlibpath_overrides_runpath=yes
9476   hardcode_into_libs=yes
9477   # ldd complains unless libraries are executable
9478   postinstall_cmds='chmod +x $lib'
9479   ;;
9480
9481 sunos4*)
9482   version_type=sunos
9483   library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
9484   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
9485   shlibpath_var=LD_LIBRARY_PATH
9486   shlibpath_overrides_runpath=yes
9487   if test "$with_gnu_ld" = yes; then
9488     need_lib_prefix=no
9489   fi
9490   need_version=yes
9491   ;;
9492
9493 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9494   version_type=linux
9495   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9496   soname_spec='${libname}${release}.so$major'
9497   shlibpath_var=LD_LIBRARY_PATH
9498   case $host_vendor in
9499     sni)
9500       shlibpath_overrides_runpath=no
9501       need_lib_prefix=no
9502       export_dynamic_flag_spec='${wl}-Blargedynsym'
9503       runpath_var=LD_RUN_PATH
9504       ;;
9505     siemens)
9506       need_lib_prefix=no
9507       ;;
9508     motorola)
9509       need_lib_prefix=no
9510       need_version=no
9511       shlibpath_overrides_runpath=no
9512       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
9513       ;;
9514   esac
9515   ;;
9516
9517 uts4*)
9518   version_type=linux
9519   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9520   soname_spec='${libname}${release}.so$major'
9521   shlibpath_var=LD_LIBRARY_PATH
9522   ;;
9523
9524 dgux*)
9525   version_type=linux
9526   need_lib_prefix=no
9527   need_version=no
9528   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
9529   soname_spec='${libname}${release}.so$major'
9530   shlibpath_var=LD_LIBRARY_PATH
9531   ;;
9532
9533 sysv4*MP*)
9534   if test -d /usr/nec ;then
9535     version_type=linux
9536     library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
9537     soname_spec='$libname.so.$major'
9538     shlibpath_var=LD_LIBRARY_PATH
9539   fi
9540   ;;
9541
9542 *)
9543   dynamic_linker=no
9544   ;;
9545 esac
9546 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
9547 echo "${ECHO_T}$dynamic_linker" >&6
9548 test "$dynamic_linker" = no && can_build_shared=no
9549
9550 # Report the final consequences.
9551 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
9552 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
9553 echo "$as_me:$LINENO: result: $can_build_shared" >&5
9554 echo "${ECHO_T}$can_build_shared" >&6
9555
9556 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
9557 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
9558 test "$can_build_shared" = "no" && enable_shared=no
9559
9560 # On AIX, shared libraries and static libraries use the same namespace, and
9561 # are all built from PIC.
9562 case "$host_os" in
9563 aix3*)
9564   test "$enable_shared" = yes && enable_static=no
9565   if test -n "$RANLIB"; then
9566     archive_cmds="$archive_cmds~\$RANLIB \$lib"
9567     postinstall_cmds='$RANLIB $lib'
9568   fi
9569   ;;
9570
9571 aix4*)
9572   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
9573     test "$enable_shared" = yes && enable_static=no
9574   fi
9575   ;;
9576 esac
9577 echo "$as_me:$LINENO: result: $enable_shared" >&5
9578 echo "${ECHO_T}$enable_shared" >&6
9579
9580 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
9581 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
9582 # Make sure either enable_shared or enable_static is yes.
9583 test "$enable_shared" = yes || enable_static=yes
9584 echo "$as_me:$LINENO: result: $enable_static" >&5
9585 echo "${ECHO_T}$enable_static" >&6
9586
9587 if test "$hardcode_action" = relink; then
9588   # Fast installation is not supported
9589   enable_fast_install=no
9590 elif test "$shlibpath_overrides_runpath" = yes ||
9591      test "$enable_shared" = no; then
9592   # Fast installation is not necessary
9593   enable_fast_install=needless
9594 fi
9595
9596 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
9597 if test "$GCC" = yes; then
9598   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
9599 fi
9600
9601 if test "x$enable_dlopen" != xyes; then
9602   enable_dlopen=unknown
9603   enable_dlopen_self=unknown
9604   enable_dlopen_self_static=unknown
9605 else
9606   lt_cv_dlopen=no
9607   lt_cv_dlopen_libs=
9608
9609   case $host_os in
9610   beos*)
9611     lt_cv_dlopen="load_add_on"
9612     lt_cv_dlopen_libs=
9613     lt_cv_dlopen_self=yes
9614     ;;
9615
9616   cygwin* | mingw* | pw32*)
9617     lt_cv_dlopen="LoadLibrary"
9618     lt_cv_dlopen_libs=
9619    ;;
9620
9621   *)
9622     echo "$as_me:$LINENO: checking for shl_load" >&5
9623 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
9624 if test "${ac_cv_func_shl_load+set}" = set; then
9625   echo $ECHO_N "(cached) $ECHO_C" >&6
9626 else
9627   cat >conftest.$ac_ext <<_ACEOF
9628 #line $LINENO "configure"
9629 /* confdefs.h.  */
9630 _ACEOF
9631 cat confdefs.h >>conftest.$ac_ext
9632 cat >>conftest.$ac_ext <<_ACEOF
9633 /* end confdefs.h.  */
9634 /* System header to define __stub macros and hopefully few prototypes,
9635     which can conflict with char shl_load (); below.
9636     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9637     <limits.h> exists even on freestanding compilers.  */
9638 #ifdef __STDC__
9639 # include <limits.h>
9640 #else
9641 # include <assert.h>
9642 #endif
9643 /* Override any gcc2 internal prototype to avoid an error.  */
9644 #ifdef __cplusplus
9645 extern "C"
9646 {
9647 #endif
9648 /* We use char because int might match the return type of a gcc2
9649    builtin and then its argument prototype would still apply.  */
9650 char shl_load ();
9651 /* The GNU C library defines this for functions which it implements
9652     to always fail with ENOSYS.  Some functions are actually named
9653     something starting with __ and the normal name is an alias.  */
9654 #if defined (__stub_shl_load) || defined (__stub___shl_load)
9655 choke me
9656 #else
9657 char (*f) () = shl_load;
9658 #endif
9659 #ifdef __cplusplus
9660 }
9661 #endif
9662
9663 int
9664 main ()
9665 {
9666 return f != shl_load;
9667   ;
9668   return 0;
9669 }
9670 _ACEOF
9671 rm -f conftest.$ac_objext conftest$ac_exeext
9672 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9673   (eval $ac_link) 2>&5
9674   ac_status=$?
9675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9676   (exit $ac_status); } &&
9677          { ac_try='test -s conftest$ac_exeext'
9678   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9679   (eval $ac_try) 2>&5
9680   ac_status=$?
9681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9682   (exit $ac_status); }; }; then
9683   ac_cv_func_shl_load=yes
9684 else
9685   echo "$as_me: failed program was:" >&5
9686 sed 's/^/| /' conftest.$ac_ext >&5
9687
9688 ac_cv_func_shl_load=no
9689 fi
9690 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9691 fi
9692 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
9693 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
9694 if test $ac_cv_func_shl_load = yes; then
9695   lt_cv_dlopen="shl_load"
9696 else
9697   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9698 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9699 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9700   echo $ECHO_N "(cached) $ECHO_C" >&6
9701 else
9702   ac_check_lib_save_LIBS=$LIBS
9703 LIBS="-ldld  $LIBS"
9704 cat >conftest.$ac_ext <<_ACEOF
9705 #line $LINENO "configure"
9706 /* confdefs.h.  */
9707 _ACEOF
9708 cat confdefs.h >>conftest.$ac_ext
9709 cat >>conftest.$ac_ext <<_ACEOF
9710 /* end confdefs.h.  */
9711
9712 /* Override any gcc2 internal prototype to avoid an error.  */
9713 #ifdef __cplusplus
9714 extern "C"
9715 #endif
9716 /* We use char because int might match the return type of a gcc2
9717    builtin and then its argument prototype would still apply.  */
9718 char shl_load ();
9719 int
9720 main ()
9721 {
9722 shl_load ();
9723   ;
9724   return 0;
9725 }
9726 _ACEOF
9727 rm -f conftest.$ac_objext conftest$ac_exeext
9728 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9729   (eval $ac_link) 2>&5
9730   ac_status=$?
9731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9732   (exit $ac_status); } &&
9733          { ac_try='test -s conftest$ac_exeext'
9734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9735   (eval $ac_try) 2>&5
9736   ac_status=$?
9737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9738   (exit $ac_status); }; }; then
9739   ac_cv_lib_dld_shl_load=yes
9740 else
9741   echo "$as_me: failed program was:" >&5
9742 sed 's/^/| /' conftest.$ac_ext >&5
9743
9744 ac_cv_lib_dld_shl_load=no
9745 fi
9746 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9747 LIBS=$ac_check_lib_save_LIBS
9748 fi
9749 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9750 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9751 if test $ac_cv_lib_dld_shl_load = yes; then
9752   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
9753 else
9754   echo "$as_me:$LINENO: checking for dlopen" >&5
9755 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
9756 if test "${ac_cv_func_dlopen+set}" = set; then
9757   echo $ECHO_N "(cached) $ECHO_C" >&6
9758 else
9759   cat >conftest.$ac_ext <<_ACEOF
9760 #line $LINENO "configure"
9761 /* confdefs.h.  */
9762 _ACEOF
9763 cat confdefs.h >>conftest.$ac_ext
9764 cat >>conftest.$ac_ext <<_ACEOF
9765 /* end confdefs.h.  */
9766 /* System header to define __stub macros and hopefully few prototypes,
9767     which can conflict with char dlopen (); below.
9768     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9769     <limits.h> exists even on freestanding compilers.  */
9770 #ifdef __STDC__
9771 # include <limits.h>
9772 #else
9773 # include <assert.h>
9774 #endif
9775 /* Override any gcc2 internal prototype to avoid an error.  */
9776 #ifdef __cplusplus
9777 extern "C"
9778 {
9779 #endif
9780 /* We use char because int might match the return type of a gcc2
9781    builtin and then its argument prototype would still apply.  */
9782 char dlopen ();
9783 /* The GNU C library defines this for functions which it implements
9784     to always fail with ENOSYS.  Some functions are actually named
9785     something starting with __ and the normal name is an alias.  */
9786 #if defined (__stub_dlopen) || defined (__stub___dlopen)
9787 choke me
9788 #else
9789 char (*f) () = dlopen;
9790 #endif
9791 #ifdef __cplusplus
9792 }
9793 #endif
9794
9795 int
9796 main ()
9797 {
9798 return f != dlopen;
9799   ;
9800   return 0;
9801 }
9802 _ACEOF
9803 rm -f conftest.$ac_objext conftest$ac_exeext
9804 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9805   (eval $ac_link) 2>&5
9806   ac_status=$?
9807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9808   (exit $ac_status); } &&
9809          { ac_try='test -s conftest$ac_exeext'
9810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9811   (eval $ac_try) 2>&5
9812   ac_status=$?
9813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9814   (exit $ac_status); }; }; then
9815   ac_cv_func_dlopen=yes
9816 else
9817   echo "$as_me: failed program was:" >&5
9818 sed 's/^/| /' conftest.$ac_ext >&5
9819
9820 ac_cv_func_dlopen=no
9821 fi
9822 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9823 fi
9824 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
9825 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
9826 if test $ac_cv_func_dlopen = yes; then
9827   lt_cv_dlopen="dlopen"
9828 else
9829   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9830 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9831 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9832   echo $ECHO_N "(cached) $ECHO_C" >&6
9833 else
9834   ac_check_lib_save_LIBS=$LIBS
9835 LIBS="-ldl  $LIBS"
9836 cat >conftest.$ac_ext <<_ACEOF
9837 #line $LINENO "configure"
9838 /* confdefs.h.  */
9839 _ACEOF
9840 cat confdefs.h >>conftest.$ac_ext
9841 cat >>conftest.$ac_ext <<_ACEOF
9842 /* end confdefs.h.  */
9843
9844 /* Override any gcc2 internal prototype to avoid an error.  */
9845 #ifdef __cplusplus
9846 extern "C"
9847 #endif
9848 /* We use char because int might match the return type of a gcc2
9849    builtin and then its argument prototype would still apply.  */
9850 char dlopen ();
9851 int
9852 main ()
9853 {
9854 dlopen ();
9855   ;
9856   return 0;
9857 }
9858 _ACEOF
9859 rm -f conftest.$ac_objext conftest$ac_exeext
9860 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9861   (eval $ac_link) 2>&5
9862   ac_status=$?
9863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9864   (exit $ac_status); } &&
9865          { ac_try='test -s conftest$ac_exeext'
9866   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9867   (eval $ac_try) 2>&5
9868   ac_status=$?
9869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9870   (exit $ac_status); }; }; then
9871   ac_cv_lib_dl_dlopen=yes
9872 else
9873   echo "$as_me: failed program was:" >&5
9874 sed 's/^/| /' conftest.$ac_ext >&5
9875
9876 ac_cv_lib_dl_dlopen=no
9877 fi
9878 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9879 LIBS=$ac_check_lib_save_LIBS
9880 fi
9881 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9882 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9883 if test $ac_cv_lib_dl_dlopen = yes; then
9884   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9885 else
9886   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
9887 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
9888 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
9889   echo $ECHO_N "(cached) $ECHO_C" >&6
9890 else
9891   ac_check_lib_save_LIBS=$LIBS
9892 LIBS="-lsvld  $LIBS"
9893 cat >conftest.$ac_ext <<_ACEOF
9894 #line $LINENO "configure"
9895 /* confdefs.h.  */
9896 _ACEOF
9897 cat confdefs.h >>conftest.$ac_ext
9898 cat >>conftest.$ac_ext <<_ACEOF
9899 /* end confdefs.h.  */
9900
9901 /* Override any gcc2 internal prototype to avoid an error.  */
9902 #ifdef __cplusplus
9903 extern "C"
9904 #endif
9905 /* We use char because int might match the return type of a gcc2
9906    builtin and then its argument prototype would still apply.  */
9907 char dlopen ();
9908 int
9909 main ()
9910 {
9911 dlopen ();
9912   ;
9913   return 0;
9914 }
9915 _ACEOF
9916 rm -f conftest.$ac_objext conftest$ac_exeext
9917 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9918   (eval $ac_link) 2>&5
9919   ac_status=$?
9920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9921   (exit $ac_status); } &&
9922          { ac_try='test -s conftest$ac_exeext'
9923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9924   (eval $ac_try) 2>&5
9925   ac_status=$?
9926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9927   (exit $ac_status); }; }; then
9928   ac_cv_lib_svld_dlopen=yes
9929 else
9930   echo "$as_me: failed program was:" >&5
9931 sed 's/^/| /' conftest.$ac_ext >&5
9932
9933 ac_cv_lib_svld_dlopen=no
9934 fi
9935 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9936 LIBS=$ac_check_lib_save_LIBS
9937 fi
9938 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
9939 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
9940 if test $ac_cv_lib_svld_dlopen = yes; then
9941   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
9942 else
9943   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
9944 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
9945 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
9946   echo $ECHO_N "(cached) $ECHO_C" >&6
9947 else
9948   ac_check_lib_save_LIBS=$LIBS
9949 LIBS="-ldld  $LIBS"
9950 cat >conftest.$ac_ext <<_ACEOF
9951 #line $LINENO "configure"
9952 /* confdefs.h.  */
9953 _ACEOF
9954 cat confdefs.h >>conftest.$ac_ext
9955 cat >>conftest.$ac_ext <<_ACEOF
9956 /* end confdefs.h.  */
9957
9958 /* Override any gcc2 internal prototype to avoid an error.  */
9959 #ifdef __cplusplus
9960 extern "C"
9961 #endif
9962 /* We use char because int might match the return type of a gcc2
9963    builtin and then its argument prototype would still apply.  */
9964 char dld_link ();
9965 int
9966 main ()
9967 {
9968 dld_link ();
9969   ;
9970   return 0;
9971 }
9972 _ACEOF
9973 rm -f conftest.$ac_objext conftest$ac_exeext
9974 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9975   (eval $ac_link) 2>&5
9976   ac_status=$?
9977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9978   (exit $ac_status); } &&
9979          { ac_try='test -s conftest$ac_exeext'
9980   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9981   (eval $ac_try) 2>&5
9982   ac_status=$?
9983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9984   (exit $ac_status); }; }; then
9985   ac_cv_lib_dld_dld_link=yes
9986 else
9987   echo "$as_me: failed program was:" >&5
9988 sed 's/^/| /' conftest.$ac_ext >&5
9989
9990 ac_cv_lib_dld_dld_link=no
9991 fi
9992 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9993 LIBS=$ac_check_lib_save_LIBS
9994 fi
9995 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
9996 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
9997 if test $ac_cv_lib_dld_dld_link = yes; then
9998   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
9999 fi
10000
10001
10002 fi
10003
10004
10005 fi
10006
10007
10008 fi
10009
10010
10011 fi
10012
10013
10014 fi
10015
10016     ;;
10017   esac
10018
10019   if test "x$lt_cv_dlopen" != xno; then
10020     enable_dlopen=yes
10021   else
10022     enable_dlopen=no
10023   fi
10024
10025   case $lt_cv_dlopen in
10026   dlopen)
10027     save_CPPFLAGS="$CPPFLAGS"
10028         test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10029
10030     save_LDFLAGS="$LDFLAGS"
10031     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10032
10033     save_LIBS="$LIBS"
10034     LIBS="$lt_cv_dlopen_libs $LIBS"
10035
10036     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10037 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
10038 if test "${lt_cv_dlopen_self+set}" = set; then
10039   echo $ECHO_N "(cached) $ECHO_C" >&6
10040 else
10041           if test "$cross_compiling" = yes; then :
10042   lt_cv_dlopen_self=cross
10043 else
10044     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10045   lt_status=$lt_dlunknown
10046   cat > conftest.$ac_ext <<EOF
10047 #line 10047 "configure"
10048 #include "confdefs.h"
10049
10050 #if HAVE_DLFCN_H
10051 #include <dlfcn.h>
10052 #endif
10053
10054 #include <stdio.h>
10055
10056 #ifdef RTLD_GLOBAL
10057 #  define LT_DLGLOBAL           RTLD_GLOBAL
10058 #else
10059 #  ifdef DL_GLOBAL
10060 #    define LT_DLGLOBAL         DL_GLOBAL
10061 #  else
10062 #    define LT_DLGLOBAL         0
10063 #  endif
10064 #endif
10065
10066 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10067    find out it does not work in some platform. */
10068 #ifndef LT_DLLAZY_OR_NOW
10069 #  ifdef RTLD_LAZY
10070 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10071 #  else
10072 #    ifdef DL_LAZY
10073 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10074 #    else
10075 #      ifdef RTLD_NOW
10076 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10077 #      else
10078 #        ifdef DL_NOW
10079 #          define LT_DLLAZY_OR_NOW      DL_NOW
10080 #        else
10081 #          define LT_DLLAZY_OR_NOW      0
10082 #        endif
10083 #      endif
10084 #    endif
10085 #  endif
10086 #endif
10087
10088 #ifdef __cplusplus
10089 extern "C" void exit (int);
10090 #endif
10091
10092 void fnord() { int i=42;}
10093 int main ()
10094 {
10095   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10096   int status = $lt_dlunknown;
10097
10098   if (self)
10099     {
10100       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10101       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10102       /* dlclose (self); */
10103     }
10104
10105     exit (status);
10106 }
10107 EOF
10108   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10109   (eval $ac_link) 2>&5
10110   ac_status=$?
10111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10112   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10113     (./conftest; exit; ) 2>/dev/null
10114     lt_status=$?
10115     case x$lt_status in
10116       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10117       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10118       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
10119     esac
10120   else :
10121     # compilation failed
10122     lt_cv_dlopen_self=no
10123   fi
10124 fi
10125 rm -fr conftest*
10126
10127
10128 fi
10129 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10130 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
10131
10132     if test "x$lt_cv_dlopen_self" = xyes; then
10133       LDFLAGS="$LDFLAGS $link_static_flag"
10134       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10135 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
10136 if test "${lt_cv_dlopen_self_static+set}" = set; then
10137   echo $ECHO_N "(cached) $ECHO_C" >&6
10138 else
10139           if test "$cross_compiling" = yes; then :
10140   lt_cv_dlopen_self_static=cross
10141 else
10142     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10143   lt_status=$lt_dlunknown
10144   cat > conftest.$ac_ext <<EOF
10145 #line 10145 "configure"
10146 #include "confdefs.h"
10147
10148 #if HAVE_DLFCN_H
10149 #include <dlfcn.h>
10150 #endif
10151
10152 #include <stdio.h>
10153
10154 #ifdef RTLD_GLOBAL
10155 #  define LT_DLGLOBAL           RTLD_GLOBAL
10156 #else
10157 #  ifdef DL_GLOBAL
10158 #    define LT_DLGLOBAL         DL_GLOBAL
10159 #  else
10160 #    define LT_DLGLOBAL         0
10161 #  endif
10162 #endif
10163
10164 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10165    find out it does not work in some platform. */
10166 #ifndef LT_DLLAZY_OR_NOW
10167 #  ifdef RTLD_LAZY
10168 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10169 #  else
10170 #    ifdef DL_LAZY
10171 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10172 #    else
10173 #      ifdef RTLD_NOW
10174 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10175 #      else
10176 #        ifdef DL_NOW
10177 #          define LT_DLLAZY_OR_NOW      DL_NOW
10178 #        else
10179 #          define LT_DLLAZY_OR_NOW      0
10180 #        endif
10181 #      endif
10182 #    endif
10183 #  endif
10184 #endif
10185
10186 #ifdef __cplusplus
10187 extern "C" void exit (int);
10188 #endif
10189
10190 void fnord() { int i=42;}
10191 int main ()
10192 {
10193   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10194   int status = $lt_dlunknown;
10195
10196   if (self)
10197     {
10198       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10199       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10200       /* dlclose (self); */
10201     }
10202
10203     exit (status);
10204 }
10205 EOF
10206   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10207   (eval $ac_link) 2>&5
10208   ac_status=$?
10209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10210   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10211     (./conftest; exit; ) 2>/dev/null
10212     lt_status=$?
10213     case x$lt_status in
10214       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
10215       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
10216       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
10217     esac
10218   else :
10219     # compilation failed
10220     lt_cv_dlopen_self_static=no
10221   fi
10222 fi
10223 rm -fr conftest*
10224
10225
10226 fi
10227 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
10228 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
10229     fi
10230
10231     CPPFLAGS="$save_CPPFLAGS"
10232     LDFLAGS="$save_LDFLAGS"
10233     LIBS="$save_LIBS"
10234     ;;
10235   esac
10236
10237   case $lt_cv_dlopen_self in
10238   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
10239   *) enable_dlopen_self=unknown ;;
10240   esac
10241
10242   case $lt_cv_dlopen_self_static in
10243   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
10244   *) enable_dlopen_self_static=unknown ;;
10245   esac
10246 fi
10247
10248
10249 if test "$enable_shared" = yes && test "$GCC" = yes; then
10250   case $archive_cmds in
10251   *'~'*)
10252     # FIXME: we may have to deal with multi-command sequences.
10253     ;;
10254   '$CC '*)
10255     # Test whether the compiler implicitly links with -lc since on some
10256     # systems, -lgcc has to come before -lc. If gcc already passes -lc
10257     # to ld, don't add -lc before -lgcc.
10258     echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
10259 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
10260     if test "${lt_cv_archive_cmds_need_lc+set}" = set; then
10261   echo $ECHO_N "(cached) $ECHO_C" >&6
10262 else
10263   $rm conftest*
10264     echo 'static int dummy;' > conftest.$ac_ext
10265
10266     if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10267   (eval $ac_compile) 2>&5
10268   ac_status=$?
10269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10270   (exit $ac_status); }; then
10271       soname=conftest
10272       lib=conftest
10273       libobjs=conftest.$ac_objext
10274       deplibs=
10275       wl=$lt_cv_prog_cc_wl
10276       compiler_flags=-v
10277       linker_flags=-v
10278       verstring=
10279       output_objdir=.
10280       libname=conftest
10281       save_allow_undefined_flag=$allow_undefined_flag
10282       allow_undefined_flag=
10283       if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
10284   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
10285   ac_status=$?
10286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10287   (exit $ac_status); }
10288       then
10289         lt_cv_archive_cmds_need_lc=no
10290       else
10291         lt_cv_archive_cmds_need_lc=yes
10292       fi
10293       allow_undefined_flag=$save_allow_undefined_flag
10294     else
10295       cat conftest.err 1>&5
10296     fi
10297 fi
10298
10299     echo "$as_me:$LINENO: result: $lt_cv_archive_cmds_need_lc" >&5
10300 echo "${ECHO_T}$lt_cv_archive_cmds_need_lc" >&6
10301     ;;
10302   esac
10303 fi
10304 need_lc=${lt_cv_archive_cmds_need_lc-yes}
10305
10306 # The second clause should only fire when bootstrapping the
10307 # libtool distribution, otherwise you forgot to ship ltmain.sh
10308 # with your package, and you will get complaints that there are
10309 # no rules to generate ltmain.sh.
10310 if test -f "$ltmain"; then
10311   :
10312 else
10313   # If there is no Makefile yet, we rely on a make rule to execute
10314   # `config.status --recheck' to rerun these tests and create the
10315   # libtool script then.
10316   test -f Makefile && make "$ltmain"
10317 fi
10318
10319 if test -f "$ltmain"; then
10320   trap "$rm \"${ofile}T\"; exit 1" 1 2 15
10321   $rm -f "${ofile}T"
10322
10323   echo creating $ofile
10324
10325   # Now quote all the things that may contain metacharacters while being
10326   # careful not to overquote the AC_SUBSTed values.  We take copies of the
10327   # variables and quote the copies for generation of the libtool script.
10328   for var in echo old_CC old_CFLAGS SED \
10329     AR AR_FLAGS CC LD LN_S NM SHELL \
10330     reload_flag reload_cmds wl \
10331     pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
10332     thread_safe_flag_spec whole_archive_flag_spec libname_spec \
10333     library_names_spec soname_spec \
10334     RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
10335     old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
10336     postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
10337     old_striplib striplib file_magic_cmd export_symbols_cmds \
10338     deplibs_check_method allow_undefined_flag no_undefined_flag \
10339     finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
10340     global_symbol_to_c_name_address \
10341     hardcode_libdir_flag_spec hardcode_libdir_separator  \
10342     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
10343     compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
10344
10345     case $var in
10346     reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
10347     old_postinstall_cmds | old_postuninstall_cmds | \
10348     export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
10349     extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
10350     postinstall_cmds | postuninstall_cmds | \
10351     finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
10352       # Double-quote double-evaled strings.
10353       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
10354       ;;
10355     *)
10356       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
10357       ;;
10358     esac
10359   done
10360
10361   cat <<__EOF__ > "${ofile}T"
10362 #! $SHELL
10363
10364 # `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
10365 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
10366 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10367 #
10368 # Copyright (C) 1996-2000 Free Software Foundation, Inc.
10369 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
10370 #
10371 # This program is free software; you can redistribute it and/or modify
10372 # it under the terms of the GNU General Public License as published by
10373 # the Free Software Foundation; either version 2 of the License, or
10374 # (at your option) any later version.
10375 #
10376 # This program is distributed in the hope that it will be useful, but
10377 # WITHOUT ANY WARRANTY; without even the implied warranty of
10378 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10379 # General Public License for more details.
10380 #
10381 # You should have received a copy of the GNU General Public License
10382 # along with this program; if not, write to the Free Software
10383 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
10384 #
10385 # As a special exception to the GNU General Public License, if you
10386 # distribute this file as part of a program that contains a
10387 # configuration script generated by Autoconf, you may include it under
10388 # the same distribution terms that you use for the rest of that program.
10389
10390 # A sed that does not truncate output.
10391 SED=$lt_SED
10392
10393 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
10394 Xsed="${SED} -e s/^X//"
10395
10396 # The HP-UX ksh and POSIX shell print the target directory to stdout
10397 # if CDPATH is set.
10398 if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
10399
10400 # ### BEGIN LIBTOOL CONFIG
10401
10402 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10403
10404 # Shell to use when invoking shell scripts.
10405 SHELL=$lt_SHELL
10406
10407 # Whether or not to build shared libraries.
10408 build_libtool_libs=$enable_shared
10409
10410 # Whether or not to build static libraries.
10411 build_old_libs=$enable_static
10412
10413 # Whether or not to add -lc for building shared libraries.
10414 build_libtool_need_lc=$need_lc
10415
10416 # Whether or not to optimize for fast installation.
10417 fast_install=$enable_fast_install
10418
10419 # The host system.
10420 host_alias=$host_alias
10421 host=$host
10422
10423 # An echo program that does not interpret backslashes.
10424 echo=$lt_echo
10425
10426 # The archiver.
10427 AR=$lt_AR
10428 AR_FLAGS=$lt_AR_FLAGS
10429
10430 # The default C compiler.
10431 CC=$lt_CC
10432
10433 # Is the compiler the GNU C compiler?
10434 with_gcc=$GCC
10435
10436 # The linker used to build libraries.
10437 LD=$lt_LD
10438
10439 # Whether we need hard or soft links.
10440 LN_S=$lt_LN_S
10441
10442 # A BSD-compatible nm program.
10443 NM=$lt_NM
10444
10445 # A symbol stripping program
10446 STRIP=$STRIP
10447
10448 # Used to examine libraries when file_magic_cmd begins "file"
10449 MAGIC_CMD=$MAGIC_CMD
10450
10451 # Used on cygwin: DLL creation program.
10452 DLLTOOL="$DLLTOOL"
10453
10454 # Used on cygwin: object dumper.
10455 OBJDUMP="$OBJDUMP"
10456
10457 # Used on cygwin: assembler.
10458 AS="$AS"
10459
10460 # The name of the directory that contains temporary libtool files.
10461 objdir=$objdir
10462
10463 # How to create reloadable object files.
10464 reload_flag=$lt_reload_flag
10465 reload_cmds=$lt_reload_cmds
10466
10467 # How to pass a linker flag through the compiler.
10468 wl=$lt_wl
10469
10470 # Object file suffix (normally "o").
10471 objext="$ac_objext"
10472
10473 # Old archive suffix (normally "a").
10474 libext="$libext"
10475
10476 # Executable file suffix (normally "").
10477 exeext="$exeext"
10478
10479 # Additional compiler flags for building library objects.
10480 pic_flag=$lt_pic_flag
10481 pic_mode=$pic_mode
10482
10483 # Does compiler simultaneously support -c and -o options?
10484 compiler_c_o=$lt_compiler_c_o
10485
10486 # Can we write directly to a .lo ?
10487 compiler_o_lo=$lt_compiler_o_lo
10488
10489 # Must we lock files when doing compilation ?
10490 need_locks=$lt_need_locks
10491
10492 # Do we need the lib prefix for modules?
10493 need_lib_prefix=$need_lib_prefix
10494
10495 # Do we need a version for libraries?
10496 need_version=$need_version
10497
10498 # Whether dlopen is supported.
10499 dlopen_support=$enable_dlopen
10500
10501 # Whether dlopen of programs is supported.
10502 dlopen_self=$enable_dlopen_self
10503
10504 # Whether dlopen of statically linked programs is supported.
10505 dlopen_self_static=$enable_dlopen_self_static
10506
10507 # Compiler flag to prevent dynamic linking.
10508 link_static_flag=$lt_link_static_flag
10509
10510 # Compiler flag to turn off builtin functions.
10511 no_builtin_flag=$lt_no_builtin_flag
10512
10513 # Compiler flag to allow reflexive dlopens.
10514 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
10515
10516 # Compiler flag to generate shared objects directly from archives.
10517 whole_archive_flag_spec=$lt_whole_archive_flag_spec
10518
10519 # Compiler flag to generate thread-safe objects.
10520 thread_safe_flag_spec=$lt_thread_safe_flag_spec
10521
10522 # Library versioning type.
10523 version_type=$version_type
10524
10525 # Format of library name prefix.
10526 libname_spec=$lt_libname_spec
10527
10528 # List of archive names.  First name is the real one, the rest are links.
10529 # The last name is the one that the linker finds with -lNAME.
10530 library_names_spec=$lt_library_names_spec
10531
10532 # The coded name of the library, if different from the real name.
10533 soname_spec=$lt_soname_spec
10534
10535 # Commands used to build and install an old-style archive.
10536 RANLIB=$lt_RANLIB
10537 old_archive_cmds=$lt_old_archive_cmds
10538 old_postinstall_cmds=$lt_old_postinstall_cmds
10539 old_postuninstall_cmds=$lt_old_postuninstall_cmds
10540
10541 # Create an old-style archive from a shared archive.
10542 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
10543
10544 # Create a temporary old-style archive to link instead of a shared archive.
10545 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
10546
10547 # Commands used to build and install a shared archive.
10548 archive_cmds=$lt_archive_cmds
10549 archive_expsym_cmds=$lt_archive_expsym_cmds
10550 postinstall_cmds=$lt_postinstall_cmds
10551 postuninstall_cmds=$lt_postuninstall_cmds
10552
10553 # Commands to strip libraries.
10554 old_striplib=$lt_old_striplib
10555 striplib=$lt_striplib
10556
10557 # Method to check whether dependent libraries are shared objects.
10558 deplibs_check_method=$lt_deplibs_check_method
10559
10560 # Command to use when deplibs_check_method == file_magic.
10561 file_magic_cmd=$lt_file_magic_cmd
10562
10563 # Flag that allows shared libraries with undefined symbols to be built.
10564 allow_undefined_flag=$lt_allow_undefined_flag
10565
10566 # Flag that forces no undefined symbols.
10567 no_undefined_flag=$lt_no_undefined_flag
10568
10569 # Commands used to finish a libtool library installation in a directory.
10570 finish_cmds=$lt_finish_cmds
10571
10572 # Same as above, but a single script fragment to be evaled but not shown.
10573 finish_eval=$lt_finish_eval
10574
10575 # Take the output of nm and produce a listing of raw symbols and C names.
10576 global_symbol_pipe=$lt_global_symbol_pipe
10577
10578 # Transform the output of nm in a proper C declaration
10579 global_symbol_to_cdecl=$lt_global_symbol_to_cdecl
10580
10581 # Transform the output of nm in a C name address pair
10582 global_symbol_to_c_name_address=$lt_global_symbol_to_c_name_address
10583
10584 # This is the shared library runtime path variable.
10585 runpath_var=$runpath_var
10586
10587 # This is the shared library path variable.
10588 shlibpath_var=$shlibpath_var
10589
10590 # Is shlibpath searched before the hard-coded library search path?
10591 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
10592
10593 # How to hardcode a shared library path into an executable.
10594 hardcode_action=$hardcode_action
10595
10596 # Whether we should hardcode library paths into libraries.
10597 hardcode_into_libs=$hardcode_into_libs
10598
10599 # Flag to hardcode \$libdir into a binary during linking.
10600 # This must work even if \$libdir does not exist.
10601 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
10602
10603 # Whether we need a single -rpath flag with a separated argument.
10604 hardcode_libdir_separator=$lt_hardcode_libdir_separator
10605
10606 # Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
10607 # resulting binary.
10608 hardcode_direct=$hardcode_direct
10609
10610 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
10611 # resulting binary.
10612 hardcode_minus_L=$hardcode_minus_L
10613
10614 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
10615 # the resulting binary.
10616 hardcode_shlibpath_var=$hardcode_shlibpath_var
10617
10618 # Variables whose values should be saved in libtool wrapper scripts and
10619 # restored at relink time.
10620 variables_saved_for_relink="$variables_saved_for_relink"
10621
10622 # Whether libtool must link a program against all its dependency libraries.
10623 link_all_deplibs=$link_all_deplibs
10624
10625 # Compile-time system search path for libraries
10626 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
10627
10628 # Run-time system search path for libraries
10629 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
10630
10631 # Fix the shell variable \$srcfile for the compiler.
10632 fix_srcfile_path="$fix_srcfile_path"
10633
10634 # Set to yes if exported symbols are required.
10635 always_export_symbols=$always_export_symbols
10636
10637 # The commands to list exported symbols.
10638 export_symbols_cmds=$lt_export_symbols_cmds
10639
10640 # The commands to extract the exported symbol list from a shared archive.
10641 extract_expsyms_cmds=$lt_extract_expsyms_cmds
10642
10643 # Symbols that should not be listed in the preloaded symbols.
10644 exclude_expsyms=$lt_exclude_expsyms
10645
10646 # Symbols that must always be exported.
10647 include_expsyms=$lt_include_expsyms
10648
10649 # ### END LIBTOOL CONFIG
10650
10651 __EOF__
10652
10653   case $host_os in
10654   aix3*)
10655     cat <<\EOF >> "${ofile}T"
10656
10657 # AIX sometimes has problems with the GCC collect2 program.  For some
10658 # reason, if we set the COLLECT_NAMES environment variable, the problems
10659 # vanish in a puff of smoke.
10660 if test "X${COLLECT_NAMES+set}" != Xset; then
10661   COLLECT_NAMES=
10662   export COLLECT_NAMES
10663 fi
10664 EOF
10665     ;;
10666   esac
10667
10668   case $host_os in
10669   cygwin* | mingw* | pw32* | os2*)
10670     cat <<'EOF' >> "${ofile}T"
10671       # This is a source program that is used to create dlls on Windows
10672       # Don't remove nor modify the starting and closing comments
10673 # /* ltdll.c starts here */
10674 # #define WIN32_LEAN_AND_MEAN
10675 # #include <windows.h>
10676 # #undef WIN32_LEAN_AND_MEAN
10677 # #include <stdio.h>
10678 #
10679 # #ifndef __CYGWIN__
10680 # #  ifdef __CYGWIN32__
10681 # #    define __CYGWIN__ __CYGWIN32__
10682 # #  endif
10683 # #endif
10684 #
10685 # #ifdef __cplusplus
10686 # extern "C" {
10687 # #endif
10688 # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
10689 # #ifdef __cplusplus
10690 # }
10691 # #endif
10692 #
10693 # #ifdef __CYGWIN__
10694 # #include <cygwin/cygwin_dll.h>
10695 # DECLARE_CYGWIN_DLL( DllMain );
10696 # #endif
10697 # HINSTANCE __hDllInstance_base;
10698 #
10699 # BOOL APIENTRY
10700 # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
10701 # {
10702 #   __hDllInstance_base = hInst;
10703 #   return TRUE;
10704 # }
10705 # /* ltdll.c ends here */
10706         # This is a source program that is used to create import libraries
10707         # on Windows for dlls which lack them. Don't remove nor modify the
10708         # starting and closing comments
10709 # /* impgen.c starts here */
10710 # /*   Copyright (C) 1999-2000 Free Software Foundation, Inc.
10711 #
10712 #  This file is part of GNU libtool.
10713 #
10714 #  This program is free software; you can redistribute it and/or modify
10715 #  it under the terms of the GNU General Public License as published by
10716 #  the Free Software Foundation; either version 2 of the License, or
10717 #  (at your option) any later version.
10718 #
10719 #  This program is distributed in the hope that it will be useful,
10720 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
10721 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10722 #  GNU General Public License for more details.
10723 #
10724 #  You should have received a copy of the GNU General Public License
10725 #  along with this program; if not, write to the Free Software
10726 #  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
10727 #  */
10728 #
10729 # #include <stdio.h>            /* for printf() */
10730 # #include <unistd.h>           /* for open(), lseek(), read() */
10731 # #include <fcntl.h>            /* for O_RDONLY, O_BINARY */
10732 # #include <string.h>           /* for strdup() */
10733 #
10734 # /* O_BINARY isn't required (or even defined sometimes) under Unix */
10735 # #ifndef O_BINARY
10736 # #define O_BINARY 0
10737 # #endif
10738 #
10739 # static unsigned int
10740 # pe_get16 (fd, offset)
10741 #      int fd;
10742 #      int offset;
10743 # {
10744 #   unsigned char b[2];
10745 #   lseek (fd, offset, SEEK_SET);
10746 #   read (fd, b, 2);
10747 #   return b[0] + (b[1]<<8);
10748 # }
10749 #
10750 # static unsigned int
10751 # pe_get32 (fd, offset)
10752 #     int fd;
10753 #     int offset;
10754 # {
10755 #   unsigned char b[4];
10756 #   lseek (fd, offset, SEEK_SET);
10757 #   read (fd, b, 4);
10758 #   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
10759 # }
10760 #
10761 # static unsigned int
10762 # pe_as32 (ptr)
10763 #      void *ptr;
10764 # {
10765 #   unsigned char *b = ptr;
10766 #   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
10767 # }
10768 #
10769 # int
10770 # main (argc, argv)
10771 #     int argc;
10772 #     char *argv[];
10773 # {
10774 #     int dll;
10775 #     unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
10776 #     unsigned long export_rva, export_size, nsections, secptr, expptr;
10777 #     unsigned long name_rvas, nexp;
10778 #     unsigned char *expdata, *erva;
10779 #     char *filename, *dll_name;
10780 #
10781 #     filename = argv[1];
10782 #
10783 #     dll = open(filename, O_RDONLY|O_BINARY);
10784 #     if (dll < 1)
10785 #       return 1;
10786 #
10787 #     dll_name = filename;
10788 #
10789 #     for (i=0; filename[i]; i++)
10790 #       if (filename[i] == '/' || filename[i] == '\\'  || filename[i] == ':')
10791 #           dll_name = filename + i +1;
10792 #
10793 #     pe_header_offset = pe_get32 (dll, 0x3c);
10794 #     opthdr_ofs = pe_header_offset + 4 + 20;
10795 #     num_entries = pe_get32 (dll, opthdr_ofs + 92);
10796 #
10797 #     if (num_entries < 1) /* no exports */
10798 #       return 1;
10799 #
10800 #     export_rva = pe_get32 (dll, opthdr_ofs + 96);
10801 #     export_size = pe_get32 (dll, opthdr_ofs + 100);
10802 #     nsections = pe_get16 (dll, pe_header_offset + 4 +2);
10803 #     secptr = (pe_header_offset + 4 + 20 +
10804 #             pe_get16 (dll, pe_header_offset + 4 + 16));
10805 #
10806 #     expptr = 0;
10807 #     for (i = 0; i < nsections; i++)
10808 #     {
10809 #       char sname[8];
10810 #       unsigned long secptr1 = secptr + 40 * i;
10811 #       unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
10812 #       unsigned long vsize = pe_get32 (dll, secptr1 + 16);
10813 #       unsigned long fptr = pe_get32 (dll, secptr1 + 20);
10814 #       lseek(dll, secptr1, SEEK_SET);
10815 #       read(dll, sname, 8);
10816 #       if (vaddr <= export_rva && vaddr+vsize > export_rva)
10817 #       {
10818 #           expptr = fptr + (export_rva - vaddr);
10819 #           if (export_rva + export_size > vaddr + vsize)
10820 #               export_size = vsize - (export_rva - vaddr);
10821 #           break;
10822 #       }
10823 #     }
10824 #
10825 #     expdata = (unsigned char*)malloc(export_size);
10826 #     lseek (dll, expptr, SEEK_SET);
10827 #     read (dll, expdata, export_size);
10828 #     erva = expdata - export_rva;
10829 #
10830 #     nexp = pe_as32 (expdata+24);
10831 #     name_rvas = pe_as32 (expdata+32);
10832 #
10833 #     printf ("EXPORTS\n");
10834 #     for (i = 0; i<nexp; i++)
10835 #     {
10836 #       unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
10837 #       printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
10838 #     }
10839 #
10840 #     return 0;
10841 # }
10842 # /* impgen.c ends here */
10843
10844 EOF
10845     ;;
10846   esac
10847
10848   # We use sed instead of cat because bash on DJGPP gets confused if
10849   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
10850   # text mode, it properly converts lines to CR/LF.  This bash problem
10851   # is reportedly fixed, but why not run on old versions too?
10852   sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
10853
10854   mv -f "${ofile}T" "$ofile" || \
10855     (rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
10856   chmod +x "$ofile"
10857 fi
10858
10859
10860
10861
10862
10863 # This can be used to rebuild libtool when needed
10864 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
10865
10866 # Always use our own libtool.
10867 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10868
10869 # Prevent multiple expansion
10870
10871
10872
10873 # test for ln hardlink support
10874 echo "$as_me:$LINENO: checking whether ln works" >&5
10875 echo $ECHO_N "checking whether ln works... $ECHO_C" >&6
10876 if test "${ol_cv_prog_LN_H+set}" = set; then
10877   echo $ECHO_N "(cached) $ECHO_C" >&6
10878 else
10879   rm -f conftest.src conftest.dst
10880 echo "conftest" > conftest.src
10881 if ln conftest.src conftest.dst 2>/dev/null
10882 then
10883   ol_cv_prog_LN_H="ln"
10884 else
10885   ol_cv_prog_LN_H="cp"
10886 fi
10887 rm -f conftest.src conftest.dst
10888
10889 fi
10890 LN_H="$ol_cv_prog_LN_H"
10891 if test "$ol_cv_prog_LN_H" = "ln"; then
10892         echo "$as_me:$LINENO: result: yes" >&5
10893 echo "${ECHO_T}yes" >&6
10894 else
10895         echo "$as_me:$LINENO: result: no" >&5
10896 echo "${ECHO_T}no" >&6
10897 fi
10898
10899 echo "$as_me:$LINENO: checking whether ln -s works" >&5
10900 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
10901 LN_S=$as_ln_s
10902 if test "$LN_S" = "ln -s"; then
10903   echo "$as_me:$LINENO: result: yes" >&5
10904 echo "${ECHO_T}yes" >&6
10905 else
10906   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
10907 echo "${ECHO_T}no, using $LN_S" >&6
10908 fi
10909
10910
10911 ol_link_perl=no
10912 if test $ol_enable_perl != no ; then
10913         # Extract the first word of "perl", so it can be a program name with args.
10914 set dummy perl; ac_word=$2
10915 echo "$as_me:$LINENO: checking for $ac_word" >&5
10916 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10917 if test "${ac_cv_path_PERLBIN+set}" = set; then
10918   echo $ECHO_N "(cached) $ECHO_C" >&6
10919 else
10920   case $PERLBIN in
10921   [\\/]* | ?:[\\/]*)
10922   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
10923   ;;
10924   *)
10925   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10926 for as_dir in $PATH
10927 do
10928   IFS=$as_save_IFS
10929   test -z "$as_dir" && as_dir=.
10930   for ac_exec_ext in '' $ac_executable_extensions; do
10931   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10932     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
10933     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10934     break 2
10935   fi
10936 done
10937 done
10938
10939   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
10940   ;;
10941 esac
10942 fi
10943 PERLBIN=$ac_cv_path_PERLBIN
10944
10945 if test -n "$PERLBIN"; then
10946   echo "$as_me:$LINENO: result: $PERLBIN" >&5
10947 echo "${ECHO_T}$PERLBIN" >&6
10948 else
10949   echo "$as_me:$LINENO: result: no" >&5
10950 echo "${ECHO_T}no" >&6
10951 fi
10952
10953
10954         if test "no$PERLBIN" = "no" ; then
10955                 if test $ol_enable_perl = yes ; then
10956                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
10957 echo "$as_me: error: could not locate perl" >&2;}
10958    { (exit 1); exit 1; }; }
10959                 fi
10960
10961         else
10962                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
10963                 if test x"$ol_with_perl_module" = "xstatic" ; then
10964                         SLAPD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
10965                 else
10966                         MOD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
10967                 fi
10968                                 ol_link_perl=yes
10969         fi
10970 fi
10971
10972 ac_ext=c
10973 ac_cpp='$CPP $CPPFLAGS'
10974 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10975 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10976 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10977 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
10978 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
10979 # On Suns, sometimes $CPP names a directory.
10980 if test -n "$CPP" && test -d "$CPP"; then
10981   CPP=
10982 fi
10983 if test -z "$CPP"; then
10984   if test "${ac_cv_prog_CPP+set}" = set; then
10985   echo $ECHO_N "(cached) $ECHO_C" >&6
10986 else
10987       # Double quotes because CPP needs to be expanded
10988     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
10989     do
10990       ac_preproc_ok=false
10991 for ac_c_preproc_warn_flag in '' yes
10992 do
10993   # Use a header file that comes with gcc, so configuring glibc
10994   # with a fresh cross-compiler works.
10995   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10996   # <limits.h> exists even on freestanding compilers.
10997   # On the NeXT, cc -E runs the code through the compiler's parser,
10998   # not just through cpp. "Syntax error" is here to catch this case.
10999   cat >conftest.$ac_ext <<_ACEOF
11000 #line $LINENO "configure"
11001 /* confdefs.h.  */
11002 _ACEOF
11003 cat confdefs.h >>conftest.$ac_ext
11004 cat >>conftest.$ac_ext <<_ACEOF
11005 /* end confdefs.h.  */
11006 #ifdef __STDC__
11007 # include <limits.h>
11008 #else
11009 # include <assert.h>
11010 #endif
11011                      Syntax error
11012 _ACEOF
11013 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11014   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11015   ac_status=$?
11016   grep -v '^ *+' conftest.er1 >conftest.err
11017   rm -f conftest.er1
11018   cat conftest.err >&5
11019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11020   (exit $ac_status); } >/dev/null; then
11021   if test -s conftest.err; then
11022     ac_cpp_err=$ac_c_preproc_warn_flag
11023   else
11024     ac_cpp_err=
11025   fi
11026 else
11027   ac_cpp_err=yes
11028 fi
11029 if test -z "$ac_cpp_err"; then
11030   :
11031 else
11032   echo "$as_me: failed program was:" >&5
11033 sed 's/^/| /' conftest.$ac_ext >&5
11034
11035   # Broken: fails on valid input.
11036 continue
11037 fi
11038 rm -f conftest.err conftest.$ac_ext
11039
11040   # OK, works on sane cases.  Now check whether non-existent headers
11041   # can be detected and how.
11042   cat >conftest.$ac_ext <<_ACEOF
11043 #line $LINENO "configure"
11044 /* confdefs.h.  */
11045 _ACEOF
11046 cat confdefs.h >>conftest.$ac_ext
11047 cat >>conftest.$ac_ext <<_ACEOF
11048 /* end confdefs.h.  */
11049 #include <ac_nonexistent.h>
11050 _ACEOF
11051 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11052   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11053   ac_status=$?
11054   grep -v '^ *+' conftest.er1 >conftest.err
11055   rm -f conftest.er1
11056   cat conftest.err >&5
11057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11058   (exit $ac_status); } >/dev/null; then
11059   if test -s conftest.err; then
11060     ac_cpp_err=$ac_c_preproc_warn_flag
11061   else
11062     ac_cpp_err=
11063   fi
11064 else
11065   ac_cpp_err=yes
11066 fi
11067 if test -z "$ac_cpp_err"; then
11068   # Broken: success on invalid input.
11069 continue
11070 else
11071   echo "$as_me: failed program was:" >&5
11072 sed 's/^/| /' conftest.$ac_ext >&5
11073
11074   # Passes both tests.
11075 ac_preproc_ok=:
11076 break
11077 fi
11078 rm -f conftest.err conftest.$ac_ext
11079
11080 done
11081 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11082 rm -f conftest.err conftest.$ac_ext
11083 if $ac_preproc_ok; then
11084   break
11085 fi
11086
11087     done
11088     ac_cv_prog_CPP=$CPP
11089
11090 fi
11091   CPP=$ac_cv_prog_CPP
11092 else
11093   ac_cv_prog_CPP=$CPP
11094 fi
11095 echo "$as_me:$LINENO: result: $CPP" >&5
11096 echo "${ECHO_T}$CPP" >&6
11097 ac_preproc_ok=false
11098 for ac_c_preproc_warn_flag in '' yes
11099 do
11100   # Use a header file that comes with gcc, so configuring glibc
11101   # with a fresh cross-compiler works.
11102   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11103   # <limits.h> exists even on freestanding compilers.
11104   # On the NeXT, cc -E runs the code through the compiler's parser,
11105   # not just through cpp. "Syntax error" is here to catch this case.
11106   cat >conftest.$ac_ext <<_ACEOF
11107 #line $LINENO "configure"
11108 /* confdefs.h.  */
11109 _ACEOF
11110 cat confdefs.h >>conftest.$ac_ext
11111 cat >>conftest.$ac_ext <<_ACEOF
11112 /* end confdefs.h.  */
11113 #ifdef __STDC__
11114 # include <limits.h>
11115 #else
11116 # include <assert.h>
11117 #endif
11118                      Syntax error
11119 _ACEOF
11120 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11121   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11122   ac_status=$?
11123   grep -v '^ *+' conftest.er1 >conftest.err
11124   rm -f conftest.er1
11125   cat conftest.err >&5
11126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11127   (exit $ac_status); } >/dev/null; then
11128   if test -s conftest.err; then
11129     ac_cpp_err=$ac_c_preproc_warn_flag
11130   else
11131     ac_cpp_err=
11132   fi
11133 else
11134   ac_cpp_err=yes
11135 fi
11136 if test -z "$ac_cpp_err"; then
11137   :
11138 else
11139   echo "$as_me: failed program was:" >&5
11140 sed 's/^/| /' conftest.$ac_ext >&5
11141
11142   # Broken: fails on valid input.
11143 continue
11144 fi
11145 rm -f conftest.err conftest.$ac_ext
11146
11147   # OK, works on sane cases.  Now check whether non-existent headers
11148   # can be detected and how.
11149   cat >conftest.$ac_ext <<_ACEOF
11150 #line $LINENO "configure"
11151 /* confdefs.h.  */
11152 _ACEOF
11153 cat confdefs.h >>conftest.$ac_ext
11154 cat >>conftest.$ac_ext <<_ACEOF
11155 /* end confdefs.h.  */
11156 #include <ac_nonexistent.h>
11157 _ACEOF
11158 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11159   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11160   ac_status=$?
11161   grep -v '^ *+' conftest.er1 >conftest.err
11162   rm -f conftest.er1
11163   cat conftest.err >&5
11164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11165   (exit $ac_status); } >/dev/null; then
11166   if test -s conftest.err; then
11167     ac_cpp_err=$ac_c_preproc_warn_flag
11168   else
11169     ac_cpp_err=
11170   fi
11171 else
11172   ac_cpp_err=yes
11173 fi
11174 if test -z "$ac_cpp_err"; then
11175   # Broken: success on invalid input.
11176 continue
11177 else
11178   echo "$as_me: failed program was:" >&5
11179 sed 's/^/| /' conftest.$ac_ext >&5
11180
11181   # Passes both tests.
11182 ac_preproc_ok=:
11183 break
11184 fi
11185 rm -f conftest.err conftest.$ac_ext
11186
11187 done
11188 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11189 rm -f conftest.err conftest.$ac_ext
11190 if $ac_preproc_ok; then
11191   :
11192 else
11193   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
11194 See \`config.log' for more details." >&5
11195 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
11196 See \`config.log' for more details." >&2;}
11197    { (exit 1); exit 1; }; }
11198 fi
11199
11200 ac_ext=c
11201 ac_cpp='$CPP $CPPFLAGS'
11202 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11203 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11204 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11205
11206
11207 if test $cross_compiling = yes -a $ol_enable_x_compile = yes; then
11208         { echo "$as_me:$LINENO: WARNING: cross compiling....  some functionality will be removed." >&5
11209 echo "$as_me: WARNING: cross compiling....  some functionality will be removed." >&2;}
11210
11211 elif test $cross_compiling = no -a $ol_enable_x_compile = yes; then
11212         { echo "$as_me:$LINENO: WARNING: programs compiled here do run here..." >&5
11213 echo "$as_me: WARNING: programs compiled here do run here..." >&2;}
11214         { { echo "$as_me:$LINENO: error:   if not cross compiling, use --disable-x-compile." >&5
11215 echo "$as_me: error:   if not cross compiling, use --disable-x-compile." >&2;}
11216    { (exit 1); exit 1; }; }
11217
11218 elif test $cross_compiling = yes -a $ol_enable_x_compile = no; then
11219         { echo "$as_me:$LINENO: WARNING: programs compiled here do not run here..." >&5
11220 echo "$as_me: WARNING: programs compiled here do not run here..." >&2;}
11221         { { echo "$as_me:$LINENO: error:   if cross compiling,  add --enable-x-compile." >&5
11222 echo "$as_me: error:   if cross compiling,  add --enable-x-compile." >&2;}
11223    { (exit 1); exit 1; }; }
11224 fi
11225
11226
11227
11228 case $host_os in
11229   *cygwin* ) CYGWIN=yes;;
11230          * ) CYGWIN=no;;
11231 esac
11232
11233
11234 case $host_os in
11235   *mingw32* ) MINGW32=yes;;
11236           * ) MINGW32=no;;
11237 esac
11238
11239
11240
11241
11242
11243 cat >>confdefs.h <<_ACEOF
11244 #define EXEEXT "${EXEEXT}"
11245 _ACEOF
11246
11247
11248 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
11249 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
11250 if test "${ac_cv_lib_be_be_app+set}" = set; then
11251   echo $ECHO_N "(cached) $ECHO_C" >&6
11252 else
11253   ac_check_lib_save_LIBS=$LIBS
11254 LIBS="-lbe -lroot -lnet $LIBS"
11255 cat >conftest.$ac_ext <<_ACEOF
11256 #line $LINENO "configure"
11257 /* confdefs.h.  */
11258 _ACEOF
11259 cat confdefs.h >>conftest.$ac_ext
11260 cat >>conftest.$ac_ext <<_ACEOF
11261 /* end confdefs.h.  */
11262
11263 /* Override any gcc2 internal prototype to avoid an error.  */
11264 #ifdef __cplusplus
11265 extern "C"
11266 #endif
11267 /* We use char because int might match the return type of a gcc2
11268    builtin and then its argument prototype would still apply.  */
11269 char be_app ();
11270 int
11271 main ()
11272 {
11273 be_app ();
11274   ;
11275   return 0;
11276 }
11277 _ACEOF
11278 rm -f conftest.$ac_objext conftest$ac_exeext
11279 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11280   (eval $ac_link) 2>&5
11281   ac_status=$?
11282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11283   (exit $ac_status); } &&
11284          { ac_try='test -s conftest$ac_exeext'
11285   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11286   (eval $ac_try) 2>&5
11287   ac_status=$?
11288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11289   (exit $ac_status); }; }; then
11290   ac_cv_lib_be_be_app=yes
11291 else
11292   echo "$as_me: failed program was:" >&5
11293 sed 's/^/| /' conftest.$ac_ext >&5
11294
11295 ac_cv_lib_be_be_app=no
11296 fi
11297 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11298 LIBS=$ac_check_lib_save_LIBS
11299 fi
11300 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
11301 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
11302 if test $ac_cv_lib_be_be_app = yes; then
11303   LIBS="$LIBS -lbe -lroot -lnet"
11304 else
11305   :
11306 fi
11307
11308
11309
11310
11311
11312 echo "$as_me:$LINENO: checking for ${CC-cc} option to accept ANSI C" >&5
11313 echo $ECHO_N "checking for ${CC-cc} option to accept ANSI C... $ECHO_C" >&6
11314 if test "${am_cv_prog_cc_stdc+set}" = set; then
11315   echo $ECHO_N "(cached) $ECHO_C" >&6
11316 else
11317   am_cv_prog_cc_stdc=no
11318 ac_save_CC="$CC"
11319 # Don't try gcc -ansi; that turns off useful extensions and
11320 # breaks some systems' header files.
11321 # AIX                   -qlanglvl=ansi
11322 # Ultrix and OSF/1      -std1
11323 # HP-UX 10.20 and later -Ae
11324 # HP-UX older versions  -Aa -D_HPUX_SOURCE
11325 # SVR4                  -Xc -D__EXTENSIONS__
11326 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
11327 do
11328   CC="$ac_save_CC $ac_arg"
11329   cat >conftest.$ac_ext <<_ACEOF
11330 #line $LINENO "configure"
11331 /* confdefs.h.  */
11332 _ACEOF
11333 cat confdefs.h >>conftest.$ac_ext
11334 cat >>conftest.$ac_ext <<_ACEOF
11335 /* end confdefs.h.  */
11336 #include <stdarg.h>
11337 #include <stdio.h>
11338 #include <sys/types.h>
11339 #include <sys/stat.h>
11340 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
11341 struct buf { int x; };
11342 FILE * (*rcsopen) (struct buf *, struct stat *, int);
11343 static char *e (p, i)
11344      char **p;
11345      int i;
11346 {
11347   return p[i];
11348 }
11349 static char *f (char * (*g) (char **, int), char **p, ...)
11350 {
11351   char *s;
11352   va_list v;
11353   va_start (v,p);
11354   s = g (p, va_arg (v,int));
11355   va_end (v);
11356   return s;
11357 }
11358 int test (int i, double x);
11359 struct s1 {int (*f) (int a);};
11360 struct s2 {int (*f) (double a);};
11361 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
11362 int argc;
11363 char **argv;
11364
11365 int
11366 main ()
11367 {
11368
11369 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
11370
11371   ;
11372   return 0;
11373 }
11374 _ACEOF
11375 rm -f conftest.$ac_objext
11376 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11377   (eval $ac_compile) 2>&5
11378   ac_status=$?
11379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11380   (exit $ac_status); } &&
11381          { ac_try='test -s conftest.$ac_objext'
11382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11383   (eval $ac_try) 2>&5
11384   ac_status=$?
11385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11386   (exit $ac_status); }; }; then
11387   am_cv_prog_cc_stdc="$ac_arg"; break
11388 else
11389   echo "$as_me: failed program was:" >&5
11390 sed 's/^/| /' conftest.$ac_ext >&5
11391
11392 fi
11393 rm -f conftest.$ac_objext conftest.$ac_ext
11394 done
11395 CC="$ac_save_CC"
11396
11397 fi
11398
11399 if test -z "$am_cv_prog_cc_stdc"; then
11400   echo "$as_me:$LINENO: result: none needed" >&5
11401 echo "${ECHO_T}none needed" >&6
11402 else
11403   echo "$as_me:$LINENO: result: $am_cv_prog_cc_stdc" >&5
11404 echo "${ECHO_T}$am_cv_prog_cc_stdc" >&6
11405 fi
11406 case "x$am_cv_prog_cc_stdc" in
11407   x|xno) ;;
11408   *) CC="$CC $am_cv_prog_cc_stdc" ;;
11409 esac
11410
11411 if test "X${am_cv_prog_cc_stdc}" = "Xno" ; then
11412         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
11413 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
11414    { (exit 1); exit 1; }; }
11415 fi
11416
11417 # test for make depend flag
11418 OL_MKDEP=
11419 OL_MKDEP_FLAGS=
11420 if test -z "${MKDEP}"; then
11421         OL_MKDEP="${CC-cc}"
11422         if test -z "${MKDEP_FLAGS}"; then
11423                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
11424 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
11425 if test "${ol_cv_mkdep+set}" = set; then
11426   echo $ECHO_N "(cached) $ECHO_C" >&6
11427 else
11428
11429                         ol_cv_mkdep=no
11430                         for flag in "-M" "-xM"; do
11431                                 cat > conftest.c <<EOF
11432  noCode;
11433 EOF
11434                                 if { ac_try='$OL_MKDEP $flag conftest.c'
11435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11436   (eval $ac_try) 2>&5
11437   ac_status=$?
11438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11439   (exit $ac_status); }; } \
11440                                         | egrep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
11441                                 then
11442                                         if test ! -f conftest."${ac_object}" ; then
11443                                                 ol_cv_mkdep=$flag
11444                                                 OL_MKDEP_FLAGS="$flag"
11445                                                 break
11446                                         fi
11447                                 fi
11448                         done
11449                         rm -f conftest*
11450
11451 fi
11452 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
11453 echo "${ECHO_T}$ol_cv_mkdep" >&6
11454         else
11455                 cc_cv_mkdep=yes
11456                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
11457         fi
11458 else
11459         cc_cv_mkdep=yes
11460         OL_MKDEP="${MKDEP}"
11461         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
11462 fi
11463
11464
11465
11466 if test "${ol_cv_mkdep}" = no ; then
11467         # this will soon become an error
11468         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
11469 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
11470 fi
11471
11472 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
11473 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
11474 if test "${ac_cv_lib_s_afopen+set}" = set; then
11475   echo $ECHO_N "(cached) $ECHO_C" >&6
11476 else
11477   ac_check_lib_save_LIBS=$LIBS
11478 LIBS="-ls  $LIBS"
11479 cat >conftest.$ac_ext <<_ACEOF
11480 #line $LINENO "configure"
11481 /* confdefs.h.  */
11482 _ACEOF
11483 cat confdefs.h >>conftest.$ac_ext
11484 cat >>conftest.$ac_ext <<_ACEOF
11485 /* end confdefs.h.  */
11486
11487 /* Override any gcc2 internal prototype to avoid an error.  */
11488 #ifdef __cplusplus
11489 extern "C"
11490 #endif
11491 /* We use char because int might match the return type of a gcc2
11492    builtin and then its argument prototype would still apply.  */
11493 char afopen ();
11494 int
11495 main ()
11496 {
11497 afopen ();
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   ac_cv_lib_s_afopen=yes
11515 else
11516   echo "$as_me: failed program was:" >&5
11517 sed 's/^/| /' conftest.$ac_ext >&5
11518
11519 ac_cv_lib_s_afopen=no
11520 fi
11521 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11522 LIBS=$ac_check_lib_save_LIBS
11523 fi
11524 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
11525 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
11526 if test $ac_cv_lib_s_afopen = yes; then
11527
11528         AUTH_LIBS=-ls
11529
11530 cat >>confdefs.h <<\_ACEOF
11531 #define HAVE_AIX_SECURITY 1
11532 _ACEOF
11533
11534
11535 fi
11536
11537
11538 case "$target" in
11539 *-ibm-openedition)
11540         ac_cv_func_getopt=no
11541
11542 cat >>confdefs.h <<\_ACEOF
11543 #define BOTH_STRINGS_H 1
11544 _ACEOF
11545
11546         ;;
11547 esac
11548
11549 ol_link_modules=no
11550 if test $ol_enable_modules != no ; then
11551
11552 for ac_header in ltdl.h
11553 do
11554 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11555 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11556   echo "$as_me:$LINENO: checking for $ac_header" >&5
11557 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11558 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11559   echo $ECHO_N "(cached) $ECHO_C" >&6
11560 fi
11561 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11562 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11563 else
11564   # Is the header compilable?
11565 echo "$as_me:$LINENO: checking $ac_header usability" >&5
11566 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11567 cat >conftest.$ac_ext <<_ACEOF
11568 #line $LINENO "configure"
11569 /* confdefs.h.  */
11570 _ACEOF
11571 cat confdefs.h >>conftest.$ac_ext
11572 cat >>conftest.$ac_ext <<_ACEOF
11573 /* end confdefs.h.  */
11574 $ac_includes_default
11575 #include <$ac_header>
11576 _ACEOF
11577 rm -f conftest.$ac_objext
11578 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11579   (eval $ac_compile) 2>&5
11580   ac_status=$?
11581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11582   (exit $ac_status); } &&
11583          { ac_try='test -s conftest.$ac_objext'
11584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11585   (eval $ac_try) 2>&5
11586   ac_status=$?
11587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11588   (exit $ac_status); }; }; then
11589   ac_header_compiler=yes
11590 else
11591   echo "$as_me: failed program was:" >&5
11592 sed 's/^/| /' conftest.$ac_ext >&5
11593
11594 ac_header_compiler=no
11595 fi
11596 rm -f conftest.$ac_objext conftest.$ac_ext
11597 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11598 echo "${ECHO_T}$ac_header_compiler" >&6
11599
11600 # Is the header present?
11601 echo "$as_me:$LINENO: checking $ac_header presence" >&5
11602 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11603 cat >conftest.$ac_ext <<_ACEOF
11604 #line $LINENO "configure"
11605 /* confdefs.h.  */
11606 _ACEOF
11607 cat confdefs.h >>conftest.$ac_ext
11608 cat >>conftest.$ac_ext <<_ACEOF
11609 /* end confdefs.h.  */
11610 #include <$ac_header>
11611 _ACEOF
11612 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11613   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11614   ac_status=$?
11615   grep -v '^ *+' conftest.er1 >conftest.err
11616   rm -f conftest.er1
11617   cat conftest.err >&5
11618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11619   (exit $ac_status); } >/dev/null; then
11620   if test -s conftest.err; then
11621     ac_cpp_err=$ac_c_preproc_warn_flag
11622   else
11623     ac_cpp_err=
11624   fi
11625 else
11626   ac_cpp_err=yes
11627 fi
11628 if test -z "$ac_cpp_err"; then
11629   ac_header_preproc=yes
11630 else
11631   echo "$as_me: failed program was:" >&5
11632 sed 's/^/| /' conftest.$ac_ext >&5
11633
11634   ac_header_preproc=no
11635 fi
11636 rm -f conftest.err conftest.$ac_ext
11637 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11638 echo "${ECHO_T}$ac_header_preproc" >&6
11639
11640 # So?  What about this header?
11641 case $ac_header_compiler:$ac_header_preproc in
11642   yes:no )
11643     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11644 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11645     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11646 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11647     (
11648       cat <<\_ASBOX
11649 ## ------------------------------------ ##
11650 ## Report this to bug-autoconf@gnu.org. ##
11651 ## ------------------------------------ ##
11652 _ASBOX
11653     ) |
11654       sed "s/^/$as_me: WARNING:     /" >&2
11655     ;;
11656   no:yes )
11657     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11658 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11659     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11660 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11661     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11662 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11663     (
11664       cat <<\_ASBOX
11665 ## ------------------------------------ ##
11666 ## Report this to bug-autoconf@gnu.org. ##
11667 ## ------------------------------------ ##
11668 _ASBOX
11669     ) |
11670       sed "s/^/$as_me: WARNING:     /" >&2
11671     ;;
11672 esac
11673 echo "$as_me:$LINENO: checking for $ac_header" >&5
11674 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11675 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11676   echo $ECHO_N "(cached) $ECHO_C" >&6
11677 else
11678   eval "$as_ac_Header=$ac_header_preproc"
11679 fi
11680 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11681 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11682
11683 fi
11684 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11685   cat >>confdefs.h <<_ACEOF
11686 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11687 _ACEOF
11688
11689 fi
11690
11691 done
11692
11693
11694         if test $ac_cv_header_ltdl_h = no ; then
11695                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
11696 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
11697    { (exit 1); exit 1; }; }
11698         fi
11699
11700         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
11701 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
11702 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
11703   echo $ECHO_N "(cached) $ECHO_C" >&6
11704 else
11705   ac_check_lib_save_LIBS=$LIBS
11706 LIBS="-lltdl  $LIBS"
11707 cat >conftest.$ac_ext <<_ACEOF
11708 #line $LINENO "configure"
11709 /* confdefs.h.  */
11710 _ACEOF
11711 cat confdefs.h >>conftest.$ac_ext
11712 cat >>conftest.$ac_ext <<_ACEOF
11713 /* end confdefs.h.  */
11714
11715 /* Override any gcc2 internal prototype to avoid an error.  */
11716 #ifdef __cplusplus
11717 extern "C"
11718 #endif
11719 /* We use char because int might match the return type of a gcc2
11720    builtin and then its argument prototype would still apply.  */
11721 char lt_dlinit ();
11722 int
11723 main ()
11724 {
11725 lt_dlinit ();
11726   ;
11727   return 0;
11728 }
11729 _ACEOF
11730 rm -f conftest.$ac_objext conftest$ac_exeext
11731 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11732   (eval $ac_link) 2>&5
11733   ac_status=$?
11734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11735   (exit $ac_status); } &&
11736          { ac_try='test -s conftest$ac_exeext'
11737   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11738   (eval $ac_try) 2>&5
11739   ac_status=$?
11740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11741   (exit $ac_status); }; }; then
11742   ac_cv_lib_ltdl_lt_dlinit=yes
11743 else
11744   echo "$as_me: failed program was:" >&5
11745 sed 's/^/| /' conftest.$ac_ext >&5
11746
11747 ac_cv_lib_ltdl_lt_dlinit=no
11748 fi
11749 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11750 LIBS=$ac_check_lib_save_LIBS
11751 fi
11752 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
11753 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
11754 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
11755
11756                 MODULES_LIBS=-lltdl
11757
11758 cat >>confdefs.h <<\_ACEOF
11759 #define HAVE_LIBLTDL 1
11760 _ACEOF
11761
11762
11763 fi
11764
11765
11766         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
11767                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
11768 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
11769    { (exit 1); exit 1; }; }
11770         fi
11771         ol_link_modules=yes
11772 else
11773         ol_with_bdb_module=static
11774         ol_with_dnssrv_module=static
11775         ol_with_ldap_module=static
11776         ol_with_ldbm_module=static
11777         ol_with_meta_module=static
11778         ol_with_monitor_module=static
11779         ol_with_null_module=static
11780         ol_with_passwd_module=static
11781         ol_with_perl_module=static
11782         ol_with_shell_module=static
11783         ol_with_tcl_module=static
11784         ol_with_sql_module=static
11785 fi
11786
11787 # test for EBCDIC
11788 echo "$as_me:$LINENO: checking for EBCDIC" >&5
11789 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
11790 if test "${ol_cv_cpp_ebcdic+set}" = set; then
11791   echo $ECHO_N "(cached) $ECHO_C" >&6
11792 else
11793
11794         cat >conftest.$ac_ext <<_ACEOF
11795 #line $LINENO "configure"
11796 /* confdefs.h.  */
11797 _ACEOF
11798 cat confdefs.h >>conftest.$ac_ext
11799 cat >>conftest.$ac_ext <<_ACEOF
11800 /* end confdefs.h.  */
11801
11802 #if !('M' == 0xd4)
11803 #include <__ASCII__/generate_error.h>
11804 #endif
11805
11806 _ACEOF
11807 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11808   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11809   ac_status=$?
11810   grep -v '^ *+' conftest.er1 >conftest.err
11811   rm -f conftest.er1
11812   cat conftest.err >&5
11813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11814   (exit $ac_status); } >/dev/null; then
11815   if test -s conftest.err; then
11816     ac_cpp_err=$ac_c_preproc_warn_flag
11817   else
11818     ac_cpp_err=
11819   fi
11820 else
11821   ac_cpp_err=yes
11822 fi
11823 if test -z "$ac_cpp_err"; then
11824   ol_cv_cpp_ebcdic=yes
11825 else
11826   echo "$as_me: failed program was:" >&5
11827 sed 's/^/| /' conftest.$ac_ext >&5
11828
11829   ol_cv_cpp_ebcdic=no
11830 fi
11831 rm -f conftest.err conftest.$ac_ext
11832 fi
11833 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
11834 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
11835 if test $ol_cv_cpp_ebcdic = yes ; then
11836
11837 cat >>confdefs.h <<\_ACEOF
11838 #define HAVE_EBCDIC 1
11839 _ACEOF
11840
11841 fi
11842
11843 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
11844 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
11845 if test "${ol_cv_header_stdc+set}" = set; then
11846   echo $ECHO_N "(cached) $ECHO_C" >&6
11847 else
11848   cat >conftest.$ac_ext <<_ACEOF
11849 #line $LINENO "configure"
11850 /* confdefs.h.  */
11851 _ACEOF
11852 cat confdefs.h >>conftest.$ac_ext
11853 cat >>conftest.$ac_ext <<_ACEOF
11854 /* end confdefs.h.  */
11855 #include <stdlib.h>
11856 #include <stdarg.h>
11857 #include <string.h>
11858 #include <float.h>
11859 _ACEOF
11860 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11861   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11862   ac_status=$?
11863   grep -v '^ *+' conftest.er1 >conftest.err
11864   rm -f conftest.er1
11865   cat conftest.err >&5
11866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11867   (exit $ac_status); } >/dev/null; then
11868   if test -s conftest.err; then
11869     ac_cpp_err=$ac_c_preproc_warn_flag
11870   else
11871     ac_cpp_err=
11872   fi
11873 else
11874   ac_cpp_err=yes
11875 fi
11876 if test -z "$ac_cpp_err"; then
11877   ol_cv_header_stdc=yes
11878 else
11879   echo "$as_me: failed program was:" >&5
11880 sed 's/^/| /' conftest.$ac_ext >&5
11881
11882   ol_cv_header_stdc=no
11883 fi
11884 rm -f conftest.err conftest.$ac_ext
11885
11886 if test $ol_cv_header_stdc = yes; then
11887   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
11888 cat >conftest.$ac_ext <<_ACEOF
11889 #line $LINENO "configure"
11890 /* confdefs.h.  */
11891 _ACEOF
11892 cat confdefs.h >>conftest.$ac_ext
11893 cat >>conftest.$ac_ext <<_ACEOF
11894 /* end confdefs.h.  */
11895 #include <string.h>
11896
11897 _ACEOF
11898 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11899   $EGREP "memchr" >/dev/null 2>&1; then
11900   :
11901 else
11902   ol_cv_header_stdc=no
11903 fi
11904 rm -f conftest*
11905
11906 fi
11907
11908 if test $ol_cv_header_stdc = yes; then
11909   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
11910 cat >conftest.$ac_ext <<_ACEOF
11911 #line $LINENO "configure"
11912 /* confdefs.h.  */
11913 _ACEOF
11914 cat confdefs.h >>conftest.$ac_ext
11915 cat >>conftest.$ac_ext <<_ACEOF
11916 /* end confdefs.h.  */
11917 #include <stdlib.h>
11918
11919 _ACEOF
11920 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11921   $EGREP "free" >/dev/null 2>&1; then
11922   :
11923 else
11924   ol_cv_header_stdc=no
11925 fi
11926 rm -f conftest*
11927
11928 fi
11929
11930 if test $ol_cv_header_stdc = yes; then
11931   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
11932 if test "$cross_compiling" = yes; then
11933   :
11934 else
11935   cat >conftest.$ac_ext <<_ACEOF
11936 #line $LINENO "configure"
11937 /* confdefs.h.  */
11938 _ACEOF
11939 cat confdefs.h >>conftest.$ac_ext
11940 cat >>conftest.$ac_ext <<_ACEOF
11941 /* end confdefs.h.  */
11942 #include <ctype.h>
11943 #ifndef HAVE_EBCDIC
11944 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
11945 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
11946 #else
11947 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
11948                 || ('j' <= (c) && (c) <= 'r') \
11949                 || ('s' <= (c) && (c) <= 'z'))
11950 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
11951 #endif
11952 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
11953 int main () { int i; for (i = 0; i < 256; i++)
11954 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
11955 exit (0); }
11956
11957 _ACEOF
11958 rm -f conftest$ac_exeext
11959 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11960   (eval $ac_link) 2>&5
11961   ac_status=$?
11962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11963   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11965   (eval $ac_try) 2>&5
11966   ac_status=$?
11967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11968   (exit $ac_status); }; }; then
11969   :
11970 else
11971   echo "$as_me: program exited with status $ac_status" >&5
11972 echo "$as_me: failed program was:" >&5
11973 sed 's/^/| /' conftest.$ac_ext >&5
11974
11975 ( exit $ac_status )
11976 ol_cv_header_stdc=no
11977 fi
11978 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11979 fi
11980 fi
11981 fi
11982 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
11983 echo "${ECHO_T}$ol_cv_header_stdc" >&6
11984 if test $ol_cv_header_stdc = yes; then
11985   cat >>confdefs.h <<\_ACEOF
11986 #define STDC_HEADERS 1
11987 _ACEOF
11988
11989 fi
11990 ac_cv_header_stdc=disable
11991
11992
11993 if test $ol_cv_header_stdc != yes; then
11994         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
11995 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
11996 fi
11997
11998
11999
12000
12001
12002
12003 ac_header_dirent=no
12004 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
12005   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
12006 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
12007 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
12008 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12009   echo $ECHO_N "(cached) $ECHO_C" >&6
12010 else
12011   cat >conftest.$ac_ext <<_ACEOF
12012 #line $LINENO "configure"
12013 /* confdefs.h.  */
12014 _ACEOF
12015 cat confdefs.h >>conftest.$ac_ext
12016 cat >>conftest.$ac_ext <<_ACEOF
12017 /* end confdefs.h.  */
12018 #include <sys/types.h>
12019 #include <$ac_hdr>
12020
12021 int
12022 main ()
12023 {
12024 if ((DIR *) 0)
12025 return 0;
12026   ;
12027   return 0;
12028 }
12029 _ACEOF
12030 rm -f conftest.$ac_objext
12031 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12032   (eval $ac_compile) 2>&5
12033   ac_status=$?
12034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12035   (exit $ac_status); } &&
12036          { ac_try='test -s conftest.$ac_objext'
12037   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12038   (eval $ac_try) 2>&5
12039   ac_status=$?
12040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12041   (exit $ac_status); }; }; then
12042   eval "$as_ac_Header=yes"
12043 else
12044   echo "$as_me: failed program was:" >&5
12045 sed 's/^/| /' conftest.$ac_ext >&5
12046
12047 eval "$as_ac_Header=no"
12048 fi
12049 rm -f conftest.$ac_objext conftest.$ac_ext
12050 fi
12051 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12052 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12053 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12054   cat >>confdefs.h <<_ACEOF
12055 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
12056 _ACEOF
12057
12058 ac_header_dirent=$ac_hdr; break
12059 fi
12060
12061 done
12062 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
12063 if test $ac_header_dirent = dirent.h; then
12064   echo "$as_me:$LINENO: checking for library containing opendir" >&5
12065 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
12066 if test "${ac_cv_search_opendir+set}" = set; then
12067   echo $ECHO_N "(cached) $ECHO_C" >&6
12068 else
12069   ac_func_search_save_LIBS=$LIBS
12070 ac_cv_search_opendir=no
12071 cat >conftest.$ac_ext <<_ACEOF
12072 #line $LINENO "configure"
12073 /* confdefs.h.  */
12074 _ACEOF
12075 cat confdefs.h >>conftest.$ac_ext
12076 cat >>conftest.$ac_ext <<_ACEOF
12077 /* end confdefs.h.  */
12078
12079 /* Override any gcc2 internal prototype to avoid an error.  */
12080 #ifdef __cplusplus
12081 extern "C"
12082 #endif
12083 /* We use char because int might match the return type of a gcc2
12084    builtin and then its argument prototype would still apply.  */
12085 char opendir ();
12086 int
12087 main ()
12088 {
12089 opendir ();
12090   ;
12091   return 0;
12092 }
12093 _ACEOF
12094 rm -f conftest.$ac_objext conftest$ac_exeext
12095 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12096   (eval $ac_link) 2>&5
12097   ac_status=$?
12098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12099   (exit $ac_status); } &&
12100          { ac_try='test -s conftest$ac_exeext'
12101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12102   (eval $ac_try) 2>&5
12103   ac_status=$?
12104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12105   (exit $ac_status); }; }; then
12106   ac_cv_search_opendir="none required"
12107 else
12108   echo "$as_me: failed program was:" >&5
12109 sed 's/^/| /' conftest.$ac_ext >&5
12110
12111 fi
12112 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12113 if test "$ac_cv_search_opendir" = no; then
12114   for ac_lib in dir; do
12115     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12116     cat >conftest.$ac_ext <<_ACEOF
12117 #line $LINENO "configure"
12118 /* confdefs.h.  */
12119 _ACEOF
12120 cat confdefs.h >>conftest.$ac_ext
12121 cat >>conftest.$ac_ext <<_ACEOF
12122 /* end confdefs.h.  */
12123
12124 /* Override any gcc2 internal prototype to avoid an error.  */
12125 #ifdef __cplusplus
12126 extern "C"
12127 #endif
12128 /* We use char because int might match the return type of a gcc2
12129    builtin and then its argument prototype would still apply.  */
12130 char opendir ();
12131 int
12132 main ()
12133 {
12134 opendir ();
12135   ;
12136   return 0;
12137 }
12138 _ACEOF
12139 rm -f conftest.$ac_objext conftest$ac_exeext
12140 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12141   (eval $ac_link) 2>&5
12142   ac_status=$?
12143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12144   (exit $ac_status); } &&
12145          { ac_try='test -s conftest$ac_exeext'
12146   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12147   (eval $ac_try) 2>&5
12148   ac_status=$?
12149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12150   (exit $ac_status); }; }; then
12151   ac_cv_search_opendir="-l$ac_lib"
12152 break
12153 else
12154   echo "$as_me: failed program was:" >&5
12155 sed 's/^/| /' conftest.$ac_ext >&5
12156
12157 fi
12158 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12159   done
12160 fi
12161 LIBS=$ac_func_search_save_LIBS
12162 fi
12163 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
12164 echo "${ECHO_T}$ac_cv_search_opendir" >&6
12165 if test "$ac_cv_search_opendir" != no; then
12166   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
12167
12168 fi
12169
12170 else
12171   echo "$as_me:$LINENO: checking for library containing opendir" >&5
12172 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
12173 if test "${ac_cv_search_opendir+set}" = set; then
12174   echo $ECHO_N "(cached) $ECHO_C" >&6
12175 else
12176   ac_func_search_save_LIBS=$LIBS
12177 ac_cv_search_opendir=no
12178 cat >conftest.$ac_ext <<_ACEOF
12179 #line $LINENO "configure"
12180 /* confdefs.h.  */
12181 _ACEOF
12182 cat confdefs.h >>conftest.$ac_ext
12183 cat >>conftest.$ac_ext <<_ACEOF
12184 /* end confdefs.h.  */
12185
12186 /* Override any gcc2 internal prototype to avoid an error.  */
12187 #ifdef __cplusplus
12188 extern "C"
12189 #endif
12190 /* We use char because int might match the return type of a gcc2
12191    builtin and then its argument prototype would still apply.  */
12192 char opendir ();
12193 int
12194 main ()
12195 {
12196 opendir ();
12197   ;
12198   return 0;
12199 }
12200 _ACEOF
12201 rm -f conftest.$ac_objext conftest$ac_exeext
12202 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12203   (eval $ac_link) 2>&5
12204   ac_status=$?
12205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12206   (exit $ac_status); } &&
12207          { ac_try='test -s conftest$ac_exeext'
12208   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12209   (eval $ac_try) 2>&5
12210   ac_status=$?
12211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12212   (exit $ac_status); }; }; then
12213   ac_cv_search_opendir="none required"
12214 else
12215   echo "$as_me: failed program was:" >&5
12216 sed 's/^/| /' conftest.$ac_ext >&5
12217
12218 fi
12219 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12220 if test "$ac_cv_search_opendir" = no; then
12221   for ac_lib in x; do
12222     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12223     cat >conftest.$ac_ext <<_ACEOF
12224 #line $LINENO "configure"
12225 /* confdefs.h.  */
12226 _ACEOF
12227 cat confdefs.h >>conftest.$ac_ext
12228 cat >>conftest.$ac_ext <<_ACEOF
12229 /* end confdefs.h.  */
12230
12231 /* Override any gcc2 internal prototype to avoid an error.  */
12232 #ifdef __cplusplus
12233 extern "C"
12234 #endif
12235 /* We use char because int might match the return type of a gcc2
12236    builtin and then its argument prototype would still apply.  */
12237 char opendir ();
12238 int
12239 main ()
12240 {
12241 opendir ();
12242   ;
12243   return 0;
12244 }
12245 _ACEOF
12246 rm -f conftest.$ac_objext conftest$ac_exeext
12247 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12248   (eval $ac_link) 2>&5
12249   ac_status=$?
12250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12251   (exit $ac_status); } &&
12252          { ac_try='test -s conftest$ac_exeext'
12253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12254   (eval $ac_try) 2>&5
12255   ac_status=$?
12256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12257   (exit $ac_status); }; }; then
12258   ac_cv_search_opendir="-l$ac_lib"
12259 break
12260 else
12261   echo "$as_me: failed program was:" >&5
12262 sed 's/^/| /' conftest.$ac_ext >&5
12263
12264 fi
12265 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12266   done
12267 fi
12268 LIBS=$ac_func_search_save_LIBS
12269 fi
12270 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
12271 echo "${ECHO_T}$ac_cv_search_opendir" >&6
12272 if test "$ac_cv_search_opendir" != no; then
12273   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
12274
12275 fi
12276
12277 fi
12278
12279 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
12280 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
12281 if test "${ac_cv_header_sys_wait_h+set}" = set; then
12282   echo $ECHO_N "(cached) $ECHO_C" >&6
12283 else
12284   cat >conftest.$ac_ext <<_ACEOF
12285 #line $LINENO "configure"
12286 /* confdefs.h.  */
12287 _ACEOF
12288 cat confdefs.h >>conftest.$ac_ext
12289 cat >>conftest.$ac_ext <<_ACEOF
12290 /* end confdefs.h.  */
12291 #include <sys/types.h>
12292 #include <sys/wait.h>
12293 #ifndef WEXITSTATUS
12294 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
12295 #endif
12296 #ifndef WIFEXITED
12297 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
12298 #endif
12299
12300 int
12301 main ()
12302 {
12303   int s;
12304   wait (&s);
12305   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
12306   ;
12307   return 0;
12308 }
12309 _ACEOF
12310 rm -f conftest.$ac_objext
12311 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12312   (eval $ac_compile) 2>&5
12313   ac_status=$?
12314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12315   (exit $ac_status); } &&
12316          { ac_try='test -s conftest.$ac_objext'
12317   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12318   (eval $ac_try) 2>&5
12319   ac_status=$?
12320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12321   (exit $ac_status); }; }; then
12322   ac_cv_header_sys_wait_h=yes
12323 else
12324   echo "$as_me: failed program was:" >&5
12325 sed 's/^/| /' conftest.$ac_ext >&5
12326
12327 ac_cv_header_sys_wait_h=no
12328 fi
12329 rm -f conftest.$ac_objext conftest.$ac_ext
12330 fi
12331 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
12332 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
12333 if test $ac_cv_header_sys_wait_h = yes; then
12334
12335 cat >>confdefs.h <<\_ACEOF
12336 #define HAVE_SYS_WAIT_H 1
12337 _ACEOF
12338
12339 fi
12340
12341 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
12342 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
12343 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
12344   echo $ECHO_N "(cached) $ECHO_C" >&6
12345 else
12346   cat >conftest.$ac_ext <<_ACEOF
12347 #line $LINENO "configure"
12348 /* confdefs.h.  */
12349 _ACEOF
12350 cat confdefs.h >>conftest.$ac_ext
12351 cat >>conftest.$ac_ext <<_ACEOF
12352 /* end confdefs.h.  */
12353 #include <sys/types.h>
12354 #include <termios.h>
12355 #ifdef TIOCGWINSZ
12356   yes
12357 #endif
12358
12359 _ACEOF
12360 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12361   $EGREP "yes" >/dev/null 2>&1; then
12362   ac_cv_sys_tiocgwinsz_in_termios_h=yes
12363 else
12364   ac_cv_sys_tiocgwinsz_in_termios_h=no
12365 fi
12366 rm -f conftest*
12367
12368 fi
12369 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
12370 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
12371
12372 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
12373   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
12374 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
12375 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
12376   echo $ECHO_N "(cached) $ECHO_C" >&6
12377 else
12378   cat >conftest.$ac_ext <<_ACEOF
12379 #line $LINENO "configure"
12380 /* confdefs.h.  */
12381 _ACEOF
12382 cat confdefs.h >>conftest.$ac_ext
12383 cat >>conftest.$ac_ext <<_ACEOF
12384 /* end confdefs.h.  */
12385 #include <sys/types.h>
12386 #include <sys/ioctl.h>
12387 #ifdef TIOCGWINSZ
12388   yes
12389 #endif
12390
12391 _ACEOF
12392 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12393   $EGREP "yes" >/dev/null 2>&1; then
12394   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
12395 else
12396   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
12397 fi
12398 rm -f conftest*
12399
12400 fi
12401 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
12402 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
12403
12404   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
12405
12406 cat >>confdefs.h <<\_ACEOF
12407 #define GWINSZ_IN_SYS_IOCTL 1
12408 _ACEOF
12409
12410   fi
12411 fi
12412
12413 if test $am_cv_sys_posix_termios = yes ; then
12414
12415 cat >>confdefs.h <<\_ACEOF
12416 #define HAVE_POSIX_TERMIOS 1
12417 _ACEOF
12418
12419 fi
12420
12421
12422
12423
12424
12425
12426
12427
12428
12429
12430
12431
12432
12433
12434
12435
12436
12437
12438
12439
12440
12441
12442
12443
12444
12445
12446
12447
12448
12449
12450
12451
12452
12453
12454
12455
12456
12457
12458
12459
12460
12461
12462
12463
12464
12465
12466 for ac_header in \
12467         arpa/inet.h             \
12468         arpa/nameser.h  \
12469         assert.h                \
12470         conio.h                 \
12471         crypt.h                 \
12472         direct.h                \
12473         errno.h                 \
12474         fcntl.h                 \
12475         filio.h                 \
12476         getopt.h                \
12477         grp.h                   \
12478         io.h                    \
12479         libutil.h               \
12480         limits.h                \
12481         locale.h                \
12482         netinet/tcp.h   \
12483         malloc.h                \
12484         memory.h                \
12485         psap.h                  \
12486         pwd.h                   \
12487         process.h               \
12488         sgtty.h                 \
12489         shadow.h                \
12490         stddef.h                \
12491         string.h                \
12492         strings.h               \
12493         sysexits.h              \
12494         sys/file.h              \
12495         sys/filio.h             \
12496         sys/errno.h             \
12497         sys/ioctl.h             \
12498         sys/param.h             \
12499         sys/resource.h  \
12500         sys/select.h    \
12501         sys/socket.h    \
12502         sys/stat.h              \
12503         sys/syslog.h    \
12504         sys/time.h              \
12505         sys/types.h             \
12506         sys/uio.h               \
12507         syslog.h                \
12508         termios.h               \
12509         unistd.h                \
12510         winsock.h               \
12511         winsock2.h              \
12512
12513 do
12514 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12515 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12516   echo "$as_me:$LINENO: checking for $ac_header" >&5
12517 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12518 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12519   echo $ECHO_N "(cached) $ECHO_C" >&6
12520 fi
12521 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12522 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12523 else
12524   # Is the header compilable?
12525 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12526 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12527 cat >conftest.$ac_ext <<_ACEOF
12528 #line $LINENO "configure"
12529 /* confdefs.h.  */
12530 _ACEOF
12531 cat confdefs.h >>conftest.$ac_ext
12532 cat >>conftest.$ac_ext <<_ACEOF
12533 /* end confdefs.h.  */
12534 $ac_includes_default
12535 #include <$ac_header>
12536 _ACEOF
12537 rm -f conftest.$ac_objext
12538 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12539   (eval $ac_compile) 2>&5
12540   ac_status=$?
12541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12542   (exit $ac_status); } &&
12543          { ac_try='test -s conftest.$ac_objext'
12544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12545   (eval $ac_try) 2>&5
12546   ac_status=$?
12547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12548   (exit $ac_status); }; }; then
12549   ac_header_compiler=yes
12550 else
12551   echo "$as_me: failed program was:" >&5
12552 sed 's/^/| /' conftest.$ac_ext >&5
12553
12554 ac_header_compiler=no
12555 fi
12556 rm -f conftest.$ac_objext conftest.$ac_ext
12557 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12558 echo "${ECHO_T}$ac_header_compiler" >&6
12559
12560 # Is the header present?
12561 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12562 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12563 cat >conftest.$ac_ext <<_ACEOF
12564 #line $LINENO "configure"
12565 /* confdefs.h.  */
12566 _ACEOF
12567 cat confdefs.h >>conftest.$ac_ext
12568 cat >>conftest.$ac_ext <<_ACEOF
12569 /* end confdefs.h.  */
12570 #include <$ac_header>
12571 _ACEOF
12572 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12573   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12574   ac_status=$?
12575   grep -v '^ *+' conftest.er1 >conftest.err
12576   rm -f conftest.er1
12577   cat conftest.err >&5
12578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12579   (exit $ac_status); } >/dev/null; then
12580   if test -s conftest.err; then
12581     ac_cpp_err=$ac_c_preproc_warn_flag
12582   else
12583     ac_cpp_err=
12584   fi
12585 else
12586   ac_cpp_err=yes
12587 fi
12588 if test -z "$ac_cpp_err"; then
12589   ac_header_preproc=yes
12590 else
12591   echo "$as_me: failed program was:" >&5
12592 sed 's/^/| /' conftest.$ac_ext >&5
12593
12594   ac_header_preproc=no
12595 fi
12596 rm -f conftest.err conftest.$ac_ext
12597 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12598 echo "${ECHO_T}$ac_header_preproc" >&6
12599
12600 # So?  What about this header?
12601 case $ac_header_compiler:$ac_header_preproc in
12602   yes:no )
12603     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12604 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12605     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12606 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12607     (
12608       cat <<\_ASBOX
12609 ## ------------------------------------ ##
12610 ## Report this to bug-autoconf@gnu.org. ##
12611 ## ------------------------------------ ##
12612 _ASBOX
12613     ) |
12614       sed "s/^/$as_me: WARNING:     /" >&2
12615     ;;
12616   no:yes )
12617     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12618 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12619     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12620 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
12621     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12622 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12623     (
12624       cat <<\_ASBOX
12625 ## ------------------------------------ ##
12626 ## Report this to bug-autoconf@gnu.org. ##
12627 ## ------------------------------------ ##
12628 _ASBOX
12629     ) |
12630       sed "s/^/$as_me: WARNING:     /" >&2
12631     ;;
12632 esac
12633 echo "$as_me:$LINENO: checking for $ac_header" >&5
12634 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12635 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12636   echo $ECHO_N "(cached) $ECHO_C" >&6
12637 else
12638   eval "$as_ac_Header=$ac_header_preproc"
12639 fi
12640 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12641 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12642
12643 fi
12644 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12645   cat >>confdefs.h <<_ACEOF
12646 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12647 _ACEOF
12648
12649 fi
12650
12651 done
12652
12653
12654
12655 for ac_header in sys/ucred.h
12656 do
12657 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12658 echo "$as_me:$LINENO: checking for $ac_header" >&5
12659 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12660 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12661   echo $ECHO_N "(cached) $ECHO_C" >&6
12662 else
12663   cat >conftest.$ac_ext <<_ACEOF
12664 #line $LINENO "configure"
12665 /* confdefs.h.  */
12666 _ACEOF
12667 cat confdefs.h >>conftest.$ac_ext
12668 cat >>conftest.$ac_ext <<_ACEOF
12669 /* end confdefs.h.  */
12670 #include <sys/types.h>
12671
12672 #include <$ac_header>
12673 _ACEOF
12674 rm -f conftest.$ac_objext
12675 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12676   (eval $ac_compile) 2>&5
12677   ac_status=$?
12678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12679   (exit $ac_status); } &&
12680          { ac_try='test -s conftest.$ac_objext'
12681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12682   (eval $ac_try) 2>&5
12683   ac_status=$?
12684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12685   (exit $ac_status); }; }; then
12686   eval "$as_ac_Header=yes"
12687 else
12688   echo "$as_me: failed program was:" >&5
12689 sed 's/^/| /' conftest.$ac_ext >&5
12690
12691 eval "$as_ac_Header=no"
12692 fi
12693 rm -f conftest.$ac_objext conftest.$ac_ext
12694 fi
12695 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12696 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12697 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12698   cat >>confdefs.h <<_ACEOF
12699 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12700 _ACEOF
12701
12702 fi
12703
12704 done
12705
12706
12707 for ac_header in resolv.h
12708 do
12709 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12710 echo "$as_me:$LINENO: checking for $ac_header" >&5
12711 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12712 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12713   echo $ECHO_N "(cached) $ECHO_C" >&6
12714 else
12715   cat >conftest.$ac_ext <<_ACEOF
12716 #line $LINENO "configure"
12717 /* confdefs.h.  */
12718 _ACEOF
12719 cat confdefs.h >>conftest.$ac_ext
12720 cat >>conftest.$ac_ext <<_ACEOF
12721 /* end confdefs.h.  */
12722
12723 #include <sys/types.h>
12724 #include <netinet/in.h>
12725 #include <arpa/nameser.h>
12726
12727
12728 #include <$ac_header>
12729 _ACEOF
12730 rm -f conftest.$ac_objext
12731 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12732   (eval $ac_compile) 2>&5
12733   ac_status=$?
12734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12735   (exit $ac_status); } &&
12736          { ac_try='test -s conftest.$ac_objext'
12737   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12738   (eval $ac_try) 2>&5
12739   ac_status=$?
12740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12741   (exit $ac_status); }; }; then
12742   eval "$as_ac_Header=yes"
12743 else
12744   echo "$as_me: failed program was:" >&5
12745 sed 's/^/| /' conftest.$ac_ext >&5
12746
12747 eval "$as_ac_Header=no"
12748 fi
12749 rm -f conftest.$ac_objext conftest.$ac_ext
12750 fi
12751 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12752 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12753 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12754   cat >>confdefs.h <<_ACEOF
12755 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12756 _ACEOF
12757
12758 fi
12759
12760 done
12761
12762
12763
12764 echo "$as_me:$LINENO: checking for dlopen" >&5
12765 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
12766 if test "${ac_cv_func_dlopen+set}" = set; then
12767   echo $ECHO_N "(cached) $ECHO_C" >&6
12768 else
12769   cat >conftest.$ac_ext <<_ACEOF
12770 #line $LINENO "configure"
12771 /* confdefs.h.  */
12772 _ACEOF
12773 cat confdefs.h >>conftest.$ac_ext
12774 cat >>conftest.$ac_ext <<_ACEOF
12775 /* end confdefs.h.  */
12776 /* System header to define __stub macros and hopefully few prototypes,
12777     which can conflict with char dlopen (); below.
12778     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12779     <limits.h> exists even on freestanding compilers.  */
12780 #ifdef __STDC__
12781 # include <limits.h>
12782 #else
12783 # include <assert.h>
12784 #endif
12785 /* Override any gcc2 internal prototype to avoid an error.  */
12786 #ifdef __cplusplus
12787 extern "C"
12788 {
12789 #endif
12790 /* We use char because int might match the return type of a gcc2
12791    builtin and then its argument prototype would still apply.  */
12792 char dlopen ();
12793 /* The GNU C library defines this for functions which it implements
12794     to always fail with ENOSYS.  Some functions are actually named
12795     something starting with __ and the normal name is an alias.  */
12796 #if defined (__stub_dlopen) || defined (__stub___dlopen)
12797 choke me
12798 #else
12799 char (*f) () = dlopen;
12800 #endif
12801 #ifdef __cplusplus
12802 }
12803 #endif
12804
12805 int
12806 main ()
12807 {
12808 return f != dlopen;
12809   ;
12810   return 0;
12811 }
12812 _ACEOF
12813 rm -f conftest.$ac_objext conftest$ac_exeext
12814 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12815   (eval $ac_link) 2>&5
12816   ac_status=$?
12817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12818   (exit $ac_status); } &&
12819          { ac_try='test -s conftest$ac_exeext'
12820   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12821   (eval $ac_try) 2>&5
12822   ac_status=$?
12823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12824   (exit $ac_status); }; }; then
12825   ac_cv_func_dlopen=yes
12826 else
12827   echo "$as_me: failed program was:" >&5
12828 sed 's/^/| /' conftest.$ac_ext >&5
12829
12830 ac_cv_func_dlopen=no
12831 fi
12832 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12833 fi
12834 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
12835 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
12836 if test $ac_cv_func_dlopen = yes; then
12837   :
12838 else
12839
12840 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
12841 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
12842 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
12843   echo $ECHO_N "(cached) $ECHO_C" >&6
12844 else
12845   ac_check_lib_save_LIBS=$LIBS
12846 LIBS="-ldl  $LIBS"
12847 cat >conftest.$ac_ext <<_ACEOF
12848 #line $LINENO "configure"
12849 /* confdefs.h.  */
12850 _ACEOF
12851 cat confdefs.h >>conftest.$ac_ext
12852 cat >>conftest.$ac_ext <<_ACEOF
12853 /* end confdefs.h.  */
12854
12855 /* Override any gcc2 internal prototype to avoid an error.  */
12856 #ifdef __cplusplus
12857 extern "C"
12858 #endif
12859 /* We use char because int might match the return type of a gcc2
12860    builtin and then its argument prototype would still apply.  */
12861 char dlopen ();
12862 int
12863 main ()
12864 {
12865 dlopen ();
12866   ;
12867   return 0;
12868 }
12869 _ACEOF
12870 rm -f conftest.$ac_objext conftest$ac_exeext
12871 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12872   (eval $ac_link) 2>&5
12873   ac_status=$?
12874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12875   (exit $ac_status); } &&
12876          { ac_try='test -s conftest$ac_exeext'
12877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12878   (eval $ac_try) 2>&5
12879   ac_status=$?
12880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12881   (exit $ac_status); }; }; then
12882   ac_cv_lib_dl_dlopen=yes
12883 else
12884   echo "$as_me: failed program was:" >&5
12885 sed 's/^/| /' conftest.$ac_ext >&5
12886
12887 ac_cv_lib_dl_dlopen=no
12888 fi
12889 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12890 LIBS=$ac_check_lib_save_LIBS
12891 fi
12892 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
12893 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
12894 if test $ac_cv_lib_dl_dlopen = yes; then
12895   cat >>confdefs.h <<_ACEOF
12896 #define HAVE_LIBDL 1
12897 _ACEOF
12898
12899   LIBS="-ldl $LIBS"
12900
12901 fi
12902
12903 fi
12904
12905
12906
12907 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
12908 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
12909 if test "${ac_cv_lib_V3_sigset+set}" = set; then
12910   echo $ECHO_N "(cached) $ECHO_C" >&6
12911 else
12912   ac_check_lib_save_LIBS=$LIBS
12913 LIBS="-lV3  $LIBS"
12914 cat >conftest.$ac_ext <<_ACEOF
12915 #line $LINENO "configure"
12916 /* confdefs.h.  */
12917 _ACEOF
12918 cat confdefs.h >>conftest.$ac_ext
12919 cat >>conftest.$ac_ext <<_ACEOF
12920 /* end confdefs.h.  */
12921
12922 /* Override any gcc2 internal prototype to avoid an error.  */
12923 #ifdef __cplusplus
12924 extern "C"
12925 #endif
12926 /* We use char because int might match the return type of a gcc2
12927    builtin and then its argument prototype would still apply.  */
12928 char sigset ();
12929 int
12930 main ()
12931 {
12932 sigset ();
12933   ;
12934   return 0;
12935 }
12936 _ACEOF
12937 rm -f conftest.$ac_objext conftest$ac_exeext
12938 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12939   (eval $ac_link) 2>&5
12940   ac_status=$?
12941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12942   (exit $ac_status); } &&
12943          { ac_try='test -s conftest$ac_exeext'
12944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12945   (eval $ac_try) 2>&5
12946   ac_status=$?
12947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12948   (exit $ac_status); }; }; then
12949   ac_cv_lib_V3_sigset=yes
12950 else
12951   echo "$as_me: failed program was:" >&5
12952 sed 's/^/| /' conftest.$ac_ext >&5
12953
12954 ac_cv_lib_V3_sigset=no
12955 fi
12956 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12957 LIBS=$ac_check_lib_save_LIBS
12958 fi
12959 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
12960 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
12961 if test $ac_cv_lib_V3_sigset = yes; then
12962   cat >>confdefs.h <<_ACEOF
12963 #define HAVE_LIBV3 1
12964 _ACEOF
12965
12966   LIBS="-lV3 $LIBS"
12967
12968 fi
12969
12970
12971 echo "$as_me:$LINENO: checking for winsock" >&5
12972 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
12973 save_LIBS="$LIBS"
12974 for curlib in ws2_32 wsock32; do
12975         LIBS="$LIBS -l$curlib"
12976         cat >conftest.$ac_ext <<_ACEOF
12977 #line $LINENO "configure"
12978 /* confdefs.h.  */
12979 _ACEOF
12980 cat confdefs.h >>conftest.$ac_ext
12981 cat >>conftest.$ac_ext <<_ACEOF
12982 /* end confdefs.h.  */
12983
12984                         char socket@12();
12985                         char select@20();
12986                         char closesocket@4();
12987                         char gethostname@8();
12988
12989 int
12990 main ()
12991 {
12992
12993                         socket@12();
12994                         select@20();
12995                         closesocket@4();
12996                         gethostname@8();
12997
12998   ;
12999   return 0;
13000 }
13001 _ACEOF
13002 rm -f conftest.$ac_objext conftest$ac_exeext
13003 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13004   (eval $ac_link) 2>&5
13005   ac_status=$?
13006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13007   (exit $ac_status); } &&
13008          { ac_try='test -s conftest$ac_exeext'
13009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13010   (eval $ac_try) 2>&5
13011   ac_status=$?
13012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13013   (exit $ac_status); }; }; then
13014   have_winsock=yes
13015 else
13016   echo "$as_me: failed program was:" >&5
13017 sed 's/^/| /' conftest.$ac_ext >&5
13018
13019 have_winsock=no
13020 fi
13021 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13022
13023         if test $have_winsock = yes; then
13024
13025 cat >>confdefs.h <<\_ACEOF
13026 #define HAVE_WINSOCK 1
13027 _ACEOF
13028
13029                 ac_cv_func_socket=yes
13030                 ac_cv_func_select=yes
13031                 ac_cv_func_closesocket=yes
13032                 ac_cv_func_gethostname=yes
13033                 if test $curlib = ws2_32; then
13034                         have_winsock=winsock2
13035
13036 cat >>confdefs.h <<\_ACEOF
13037 #define HAVE_WINSOCK2 1
13038 _ACEOF
13039
13040                 fi
13041                 break
13042         fi
13043         LIBS="$save_LIBS"
13044 done
13045 echo "$as_me:$LINENO: result: $have_winsock" >&5
13046 echo "${ECHO_T}$have_winsock" >&6
13047
13048
13049 echo "$as_me:$LINENO: checking for socket" >&5
13050 echo $ECHO_N "checking for socket... $ECHO_C" >&6
13051 if test "${ac_cv_func_socket+set}" = set; then
13052   echo $ECHO_N "(cached) $ECHO_C" >&6
13053 else
13054   cat >conftest.$ac_ext <<_ACEOF
13055 #line $LINENO "configure"
13056 /* confdefs.h.  */
13057 _ACEOF
13058 cat confdefs.h >>conftest.$ac_ext
13059 cat >>conftest.$ac_ext <<_ACEOF
13060 /* end confdefs.h.  */
13061 /* System header to define __stub macros and hopefully few prototypes,
13062     which can conflict with char socket (); below.
13063     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13064     <limits.h> exists even on freestanding compilers.  */
13065 #ifdef __STDC__
13066 # include <limits.h>
13067 #else
13068 # include <assert.h>
13069 #endif
13070 /* Override any gcc2 internal prototype to avoid an error.  */
13071 #ifdef __cplusplus
13072 extern "C"
13073 {
13074 #endif
13075 /* We use char because int might match the return type of a gcc2
13076    builtin and then its argument prototype would still apply.  */
13077 char socket ();
13078 /* The GNU C library defines this for functions which it implements
13079     to always fail with ENOSYS.  Some functions are actually named
13080     something starting with __ and the normal name is an alias.  */
13081 #if defined (__stub_socket) || defined (__stub___socket)
13082 choke me
13083 #else
13084 char (*f) () = socket;
13085 #endif
13086 #ifdef __cplusplus
13087 }
13088 #endif
13089
13090 int
13091 main ()
13092 {
13093 return f != socket;
13094   ;
13095   return 0;
13096 }
13097 _ACEOF
13098 rm -f conftest.$ac_objext conftest$ac_exeext
13099 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13100   (eval $ac_link) 2>&5
13101   ac_status=$?
13102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13103   (exit $ac_status); } &&
13104          { ac_try='test -s conftest$ac_exeext'
13105   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13106   (eval $ac_try) 2>&5
13107   ac_status=$?
13108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13109   (exit $ac_status); }; }; then
13110   ac_cv_func_socket=yes
13111 else
13112   echo "$as_me: failed program was:" >&5
13113 sed 's/^/| /' conftest.$ac_ext >&5
13114
13115 ac_cv_func_socket=no
13116 fi
13117 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13118 fi
13119 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
13120 echo "${ECHO_T}$ac_cv_func_socket" >&6
13121 if test $ac_cv_func_socket = yes; then
13122   :
13123 else
13124
13125
13126 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
13127 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
13128 if test "${ac_cv_lib_socket_main+set}" = set; then
13129   echo $ECHO_N "(cached) $ECHO_C" >&6
13130 else
13131   ac_check_lib_save_LIBS=$LIBS
13132 LIBS="-lsocket  $LIBS"
13133 cat >conftest.$ac_ext <<_ACEOF
13134 #line $LINENO "configure"
13135 /* confdefs.h.  */
13136 _ACEOF
13137 cat confdefs.h >>conftest.$ac_ext
13138 cat >>conftest.$ac_ext <<_ACEOF
13139 /* end confdefs.h.  */
13140
13141
13142 int
13143 main ()
13144 {
13145 main ();
13146   ;
13147   return 0;
13148 }
13149 _ACEOF
13150 rm -f conftest.$ac_objext conftest$ac_exeext
13151 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13152   (eval $ac_link) 2>&5
13153   ac_status=$?
13154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13155   (exit $ac_status); } &&
13156          { ac_try='test -s conftest$ac_exeext'
13157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13158   (eval $ac_try) 2>&5
13159   ac_status=$?
13160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13161   (exit $ac_status); }; }; then
13162   ac_cv_lib_socket_main=yes
13163 else
13164   echo "$as_me: failed program was:" >&5
13165 sed 's/^/| /' conftest.$ac_ext >&5
13166
13167 ac_cv_lib_socket_main=no
13168 fi
13169 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13170 LIBS=$ac_check_lib_save_LIBS
13171 fi
13172 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
13173 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
13174 if test $ac_cv_lib_socket_main = yes; then
13175   cat >>confdefs.h <<_ACEOF
13176 #define HAVE_LIBSOCKET 1
13177 _ACEOF
13178
13179   LIBS="-lsocket $LIBS"
13180
13181 fi
13182
13183
13184 echo "$as_me:$LINENO: checking for main in -lnet" >&5
13185 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
13186 if test "${ac_cv_lib_net_main+set}" = set; then
13187   echo $ECHO_N "(cached) $ECHO_C" >&6
13188 else
13189   ac_check_lib_save_LIBS=$LIBS
13190 LIBS="-lnet  $LIBS"
13191 cat >conftest.$ac_ext <<_ACEOF
13192 #line $LINENO "configure"
13193 /* confdefs.h.  */
13194 _ACEOF
13195 cat confdefs.h >>conftest.$ac_ext
13196 cat >>conftest.$ac_ext <<_ACEOF
13197 /* end confdefs.h.  */
13198
13199
13200 int
13201 main ()
13202 {
13203 main ();
13204   ;
13205   return 0;
13206 }
13207 _ACEOF
13208 rm -f conftest.$ac_objext conftest$ac_exeext
13209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13210   (eval $ac_link) 2>&5
13211   ac_status=$?
13212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13213   (exit $ac_status); } &&
13214          { ac_try='test -s conftest$ac_exeext'
13215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13216   (eval $ac_try) 2>&5
13217   ac_status=$?
13218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13219   (exit $ac_status); }; }; then
13220   ac_cv_lib_net_main=yes
13221 else
13222   echo "$as_me: failed program was:" >&5
13223 sed 's/^/| /' conftest.$ac_ext >&5
13224
13225 ac_cv_lib_net_main=no
13226 fi
13227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13228 LIBS=$ac_check_lib_save_LIBS
13229 fi
13230 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
13231 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
13232 if test $ac_cv_lib_net_main = yes; then
13233   cat >>confdefs.h <<_ACEOF
13234 #define HAVE_LIBNET 1
13235 _ACEOF
13236
13237   LIBS="-lnet $LIBS"
13238
13239 fi
13240
13241
13242 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
13243 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
13244 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
13245   echo $ECHO_N "(cached) $ECHO_C" >&6
13246 else
13247   ac_check_lib_save_LIBS=$LIBS
13248 LIBS="-lnsl_s  $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
13258 int
13259 main ()
13260 {
13261 main ();
13262   ;
13263   return 0;
13264 }
13265 _ACEOF
13266 rm -f conftest.$ac_objext conftest$ac_exeext
13267 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13268   (eval $ac_link) 2>&5
13269   ac_status=$?
13270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13271   (exit $ac_status); } &&
13272          { ac_try='test -s conftest$ac_exeext'
13273   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13274   (eval $ac_try) 2>&5
13275   ac_status=$?
13276   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13277   (exit $ac_status); }; }; then
13278   ac_cv_lib_nsl_s_main=yes
13279 else
13280   echo "$as_me: failed program was:" >&5
13281 sed 's/^/| /' conftest.$ac_ext >&5
13282
13283 ac_cv_lib_nsl_s_main=no
13284 fi
13285 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13286 LIBS=$ac_check_lib_save_LIBS
13287 fi
13288 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
13289 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
13290 if test $ac_cv_lib_nsl_s_main = yes; then
13291   cat >>confdefs.h <<_ACEOF
13292 #define HAVE_LIBNSL_S 1
13293 _ACEOF
13294
13295   LIBS="-lnsl_s $LIBS"
13296
13297 fi
13298
13299
13300 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
13301 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
13302 if test "${ac_cv_lib_nsl_main+set}" = set; then
13303   echo $ECHO_N "(cached) $ECHO_C" >&6
13304 else
13305   ac_check_lib_save_LIBS=$LIBS
13306 LIBS="-lnsl  $LIBS"
13307 cat >conftest.$ac_ext <<_ACEOF
13308 #line $LINENO "configure"
13309 /* confdefs.h.  */
13310 _ACEOF
13311 cat confdefs.h >>conftest.$ac_ext
13312 cat >>conftest.$ac_ext <<_ACEOF
13313 /* end confdefs.h.  */
13314
13315
13316 int
13317 main ()
13318 {
13319 main ();
13320   ;
13321   return 0;
13322 }
13323 _ACEOF
13324 rm -f conftest.$ac_objext conftest$ac_exeext
13325 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13326   (eval $ac_link) 2>&5
13327   ac_status=$?
13328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13329   (exit $ac_status); } &&
13330          { ac_try='test -s conftest$ac_exeext'
13331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13332   (eval $ac_try) 2>&5
13333   ac_status=$?
13334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13335   (exit $ac_status); }; }; then
13336   ac_cv_lib_nsl_main=yes
13337 else
13338   echo "$as_me: failed program was:" >&5
13339 sed 's/^/| /' conftest.$ac_ext >&5
13340
13341 ac_cv_lib_nsl_main=no
13342 fi
13343 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13344 LIBS=$ac_check_lib_save_LIBS
13345 fi
13346 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
13347 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
13348 if test $ac_cv_lib_nsl_main = yes; then
13349   cat >>confdefs.h <<_ACEOF
13350 #define HAVE_LIBNSL 1
13351 _ACEOF
13352
13353   LIBS="-lnsl $LIBS"
13354
13355 fi
13356
13357
13358 echo "$as_me:$LINENO: checking for socket in -linet" >&5
13359 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
13360 if test "${ac_cv_lib_inet_socket+set}" = set; then
13361   echo $ECHO_N "(cached) $ECHO_C" >&6
13362 else
13363   ac_check_lib_save_LIBS=$LIBS
13364 LIBS="-linet  $LIBS"
13365 cat >conftest.$ac_ext <<_ACEOF
13366 #line $LINENO "configure"
13367 /* confdefs.h.  */
13368 _ACEOF
13369 cat confdefs.h >>conftest.$ac_ext
13370 cat >>conftest.$ac_ext <<_ACEOF
13371 /* end confdefs.h.  */
13372
13373 /* Override any gcc2 internal prototype to avoid an error.  */
13374 #ifdef __cplusplus
13375 extern "C"
13376 #endif
13377 /* We use char because int might match the return type of a gcc2
13378    builtin and then its argument prototype would still apply.  */
13379 char socket ();
13380 int
13381 main ()
13382 {
13383 socket ();
13384   ;
13385   return 0;
13386 }
13387 _ACEOF
13388 rm -f conftest.$ac_objext conftest$ac_exeext
13389 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13390   (eval $ac_link) 2>&5
13391   ac_status=$?
13392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13393   (exit $ac_status); } &&
13394          { ac_try='test -s conftest$ac_exeext'
13395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13396   (eval $ac_try) 2>&5
13397   ac_status=$?
13398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13399   (exit $ac_status); }; }; then
13400   ac_cv_lib_inet_socket=yes
13401 else
13402   echo "$as_me: failed program was:" >&5
13403 sed 's/^/| /' conftest.$ac_ext >&5
13404
13405 ac_cv_lib_inet_socket=no
13406 fi
13407 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13408 LIBS=$ac_check_lib_save_LIBS
13409 fi
13410 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
13411 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
13412 if test $ac_cv_lib_inet_socket = yes; then
13413   cat >>confdefs.h <<_ACEOF
13414 #define HAVE_LIBINET 1
13415 _ACEOF
13416
13417   LIBS="-linet $LIBS"
13418
13419 fi
13420
13421
13422 echo "$as_me:$LINENO: checking for main in -lgen" >&5
13423 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
13424 if test "${ac_cv_lib_gen_main+set}" = set; then
13425   echo $ECHO_N "(cached) $ECHO_C" >&6
13426 else
13427   ac_check_lib_save_LIBS=$LIBS
13428 LIBS="-lgen  $LIBS"
13429 cat >conftest.$ac_ext <<_ACEOF
13430 #line $LINENO "configure"
13431 /* confdefs.h.  */
13432 _ACEOF
13433 cat confdefs.h >>conftest.$ac_ext
13434 cat >>conftest.$ac_ext <<_ACEOF
13435 /* end confdefs.h.  */
13436
13437
13438 int
13439 main ()
13440 {
13441 main ();
13442   ;
13443   return 0;
13444 }
13445 _ACEOF
13446 rm -f conftest.$ac_objext conftest$ac_exeext
13447 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13448   (eval $ac_link) 2>&5
13449   ac_status=$?
13450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13451   (exit $ac_status); } &&
13452          { ac_try='test -s conftest$ac_exeext'
13453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13454   (eval $ac_try) 2>&5
13455   ac_status=$?
13456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13457   (exit $ac_status); }; }; then
13458   ac_cv_lib_gen_main=yes
13459 else
13460   echo "$as_me: failed program was:" >&5
13461 sed 's/^/| /' conftest.$ac_ext >&5
13462
13463 ac_cv_lib_gen_main=no
13464 fi
13465 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13466 LIBS=$ac_check_lib_save_LIBS
13467 fi
13468 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
13469 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
13470 if test $ac_cv_lib_gen_main = yes; then
13471   cat >>confdefs.h <<_ACEOF
13472 #define HAVE_LIBGEN 1
13473 _ACEOF
13474
13475   LIBS="-lgen $LIBS"
13476
13477 fi
13478
13479
13480 fi
13481
13482
13483 echo "$as_me:$LINENO: checking for select" >&5
13484 echo $ECHO_N "checking for select... $ECHO_C" >&6
13485 if test "${ac_cv_func_select+set}" = set; then
13486   echo $ECHO_N "(cached) $ECHO_C" >&6
13487 else
13488   cat >conftest.$ac_ext <<_ACEOF
13489 #line $LINENO "configure"
13490 /* confdefs.h.  */
13491 _ACEOF
13492 cat confdefs.h >>conftest.$ac_ext
13493 cat >>conftest.$ac_ext <<_ACEOF
13494 /* end confdefs.h.  */
13495 /* System header to define __stub macros and hopefully few prototypes,
13496     which can conflict with char select (); below.
13497     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13498     <limits.h> exists even on freestanding compilers.  */
13499 #ifdef __STDC__
13500 # include <limits.h>
13501 #else
13502 # include <assert.h>
13503 #endif
13504 /* Override any gcc2 internal prototype to avoid an error.  */
13505 #ifdef __cplusplus
13506 extern "C"
13507 {
13508 #endif
13509 /* We use char because int might match the return type of a gcc2
13510    builtin and then its argument prototype would still apply.  */
13511 char select ();
13512 /* The GNU C library defines this for functions which it implements
13513     to always fail with ENOSYS.  Some functions are actually named
13514     something starting with __ and the normal name is an alias.  */
13515 #if defined (__stub_select) || defined (__stub___select)
13516 choke me
13517 #else
13518 char (*f) () = select;
13519 #endif
13520 #ifdef __cplusplus
13521 }
13522 #endif
13523
13524 int
13525 main ()
13526 {
13527 return f != select;
13528   ;
13529   return 0;
13530 }
13531 _ACEOF
13532 rm -f conftest.$ac_objext conftest$ac_exeext
13533 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13534   (eval $ac_link) 2>&5
13535   ac_status=$?
13536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13537   (exit $ac_status); } &&
13538          { ac_try='test -s conftest$ac_exeext'
13539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13540   (eval $ac_try) 2>&5
13541   ac_status=$?
13542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13543   (exit $ac_status); }; }; then
13544   ac_cv_func_select=yes
13545 else
13546   echo "$as_me: failed program was:" >&5
13547 sed 's/^/| /' conftest.$ac_ext >&5
13548
13549 ac_cv_func_select=no
13550 fi
13551 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13552 fi
13553 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
13554 echo "${ECHO_T}$ac_cv_func_select" >&6
13555 if test $ac_cv_func_select = yes; then
13556   :
13557 else
13558   { { echo "$as_me:$LINENO: error: select() required." >&5
13559 echo "$as_me: error: select() required." >&2;}
13560    { (exit 1); exit 1; }; }
13561 fi
13562
13563
13564 if test "${ac_cv_header_winsock_h}" != yes; then
13565
13566
13567 for ac_header in sys/select.h sys/socket.h
13568 do
13569 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13570 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13571   echo "$as_me:$LINENO: checking for $ac_header" >&5
13572 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13573 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13574   echo $ECHO_N "(cached) $ECHO_C" >&6
13575 fi
13576 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13577 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13578 else
13579   # Is the header compilable?
13580 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13581 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13582 cat >conftest.$ac_ext <<_ACEOF
13583 #line $LINENO "configure"
13584 /* confdefs.h.  */
13585 _ACEOF
13586 cat confdefs.h >>conftest.$ac_ext
13587 cat >>conftest.$ac_ext <<_ACEOF
13588 /* end confdefs.h.  */
13589 $ac_includes_default
13590 #include <$ac_header>
13591 _ACEOF
13592 rm -f conftest.$ac_objext
13593 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13594   (eval $ac_compile) 2>&5
13595   ac_status=$?
13596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13597   (exit $ac_status); } &&
13598          { ac_try='test -s conftest.$ac_objext'
13599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13600   (eval $ac_try) 2>&5
13601   ac_status=$?
13602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13603   (exit $ac_status); }; }; then
13604   ac_header_compiler=yes
13605 else
13606   echo "$as_me: failed program was:" >&5
13607 sed 's/^/| /' conftest.$ac_ext >&5
13608
13609 ac_header_compiler=no
13610 fi
13611 rm -f conftest.$ac_objext conftest.$ac_ext
13612 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13613 echo "${ECHO_T}$ac_header_compiler" >&6
13614
13615 # Is the header present?
13616 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13617 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13618 cat >conftest.$ac_ext <<_ACEOF
13619 #line $LINENO "configure"
13620 /* confdefs.h.  */
13621 _ACEOF
13622 cat confdefs.h >>conftest.$ac_ext
13623 cat >>conftest.$ac_ext <<_ACEOF
13624 /* end confdefs.h.  */
13625 #include <$ac_header>
13626 _ACEOF
13627 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13628   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13629   ac_status=$?
13630   grep -v '^ *+' conftest.er1 >conftest.err
13631   rm -f conftest.er1
13632   cat conftest.err >&5
13633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13634   (exit $ac_status); } >/dev/null; then
13635   if test -s conftest.err; then
13636     ac_cpp_err=$ac_c_preproc_warn_flag
13637   else
13638     ac_cpp_err=
13639   fi
13640 else
13641   ac_cpp_err=yes
13642 fi
13643 if test -z "$ac_cpp_err"; then
13644   ac_header_preproc=yes
13645 else
13646   echo "$as_me: failed program was:" >&5
13647 sed 's/^/| /' conftest.$ac_ext >&5
13648
13649   ac_header_preproc=no
13650 fi
13651 rm -f conftest.err conftest.$ac_ext
13652 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13653 echo "${ECHO_T}$ac_header_preproc" >&6
13654
13655 # So?  What about this header?
13656 case $ac_header_compiler:$ac_header_preproc in
13657   yes:no )
13658     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13659 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13660     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13661 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13662     (
13663       cat <<\_ASBOX
13664 ## ------------------------------------ ##
13665 ## Report this to bug-autoconf@gnu.org. ##
13666 ## ------------------------------------ ##
13667 _ASBOX
13668     ) |
13669       sed "s/^/$as_me: WARNING:     /" >&2
13670     ;;
13671   no:yes )
13672     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13673 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13674     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13675 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13676     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13677 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13678     (
13679       cat <<\_ASBOX
13680 ## ------------------------------------ ##
13681 ## Report this to bug-autoconf@gnu.org. ##
13682 ## ------------------------------------ ##
13683 _ASBOX
13684     ) |
13685       sed "s/^/$as_me: WARNING:     /" >&2
13686     ;;
13687 esac
13688 echo "$as_me:$LINENO: checking for $ac_header" >&5
13689 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13690 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13691   echo $ECHO_N "(cached) $ECHO_C" >&6
13692 else
13693   eval "$as_ac_Header=$ac_header_preproc"
13694 fi
13695 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13696 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13697
13698 fi
13699 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13700   cat >>confdefs.h <<_ACEOF
13701 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13702 _ACEOF
13703
13704 fi
13705
13706 done
13707
13708 echo "$as_me:$LINENO: checking types of arguments for select" >&5
13709 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
13710 if test "${ac_cv_func_select_args+set}" = set; then
13711   echo $ECHO_N "(cached) $ECHO_C" >&6
13712 else
13713   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
13714  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
13715   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
13716    cat >conftest.$ac_ext <<_ACEOF
13717 #line $LINENO "configure"
13718 /* confdefs.h.  */
13719 _ACEOF
13720 cat confdefs.h >>conftest.$ac_ext
13721 cat >>conftest.$ac_ext <<_ACEOF
13722 /* end confdefs.h.  */
13723 $ac_includes_default
13724 #if HAVE_SYS_SELECT_H
13725 # include <sys/select.h>
13726 #endif
13727 #if HAVE_SYS_SOCKET_H
13728 # include <sys/socket.h>
13729 #endif
13730
13731 int
13732 main ()
13733 {
13734 extern int select ($ac_arg1,
13735                                             $ac_arg234, $ac_arg234, $ac_arg234,
13736                                             $ac_arg5);
13737   ;
13738   return 0;
13739 }
13740 _ACEOF
13741 rm -f conftest.$ac_objext
13742 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13743   (eval $ac_compile) 2>&5
13744   ac_status=$?
13745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13746   (exit $ac_status); } &&
13747          { ac_try='test -s conftest.$ac_objext'
13748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13749   (eval $ac_try) 2>&5
13750   ac_status=$?
13751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13752   (exit $ac_status); }; }; then
13753   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
13754 else
13755   echo "$as_me: failed program was:" >&5
13756 sed 's/^/| /' conftest.$ac_ext >&5
13757
13758 fi
13759 rm -f conftest.$ac_objext conftest.$ac_ext
13760   done
13761  done
13762 done
13763 # Provide a safe default value.
13764 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
13765
13766 fi
13767 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
13768 echo "${ECHO_T}$ac_cv_func_select_args" >&6
13769 ac_save_IFS=$IFS; IFS=','
13770 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
13771 IFS=$ac_save_IFS
13772 shift
13773
13774 cat >>confdefs.h <<_ACEOF
13775 #define SELECT_TYPE_ARG1 $1
13776 _ACEOF
13777
13778
13779 cat >>confdefs.h <<_ACEOF
13780 #define SELECT_TYPE_ARG234 ($2)
13781 _ACEOF
13782
13783
13784 cat >>confdefs.h <<_ACEOF
13785 #define SELECT_TYPE_ARG5 ($3)
13786 _ACEOF
13787
13788 rm -f conftest*
13789
13790 fi
13791
13792
13793
13794 for ac_header in regex.h
13795 do
13796 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13797 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13798   echo "$as_me:$LINENO: checking for $ac_header" >&5
13799 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13800 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13801   echo $ECHO_N "(cached) $ECHO_C" >&6
13802 fi
13803 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13804 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13805 else
13806   # Is the header compilable?
13807 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13808 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13809 cat >conftest.$ac_ext <<_ACEOF
13810 #line $LINENO "configure"
13811 /* confdefs.h.  */
13812 _ACEOF
13813 cat confdefs.h >>conftest.$ac_ext
13814 cat >>conftest.$ac_ext <<_ACEOF
13815 /* end confdefs.h.  */
13816 $ac_includes_default
13817 #include <$ac_header>
13818 _ACEOF
13819 rm -f conftest.$ac_objext
13820 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13821   (eval $ac_compile) 2>&5
13822   ac_status=$?
13823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13824   (exit $ac_status); } &&
13825          { ac_try='test -s conftest.$ac_objext'
13826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13827   (eval $ac_try) 2>&5
13828   ac_status=$?
13829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13830   (exit $ac_status); }; }; then
13831   ac_header_compiler=yes
13832 else
13833   echo "$as_me: failed program was:" >&5
13834 sed 's/^/| /' conftest.$ac_ext >&5
13835
13836 ac_header_compiler=no
13837 fi
13838 rm -f conftest.$ac_objext conftest.$ac_ext
13839 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13840 echo "${ECHO_T}$ac_header_compiler" >&6
13841
13842 # Is the header present?
13843 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13844 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13845 cat >conftest.$ac_ext <<_ACEOF
13846 #line $LINENO "configure"
13847 /* confdefs.h.  */
13848 _ACEOF
13849 cat confdefs.h >>conftest.$ac_ext
13850 cat >>conftest.$ac_ext <<_ACEOF
13851 /* end confdefs.h.  */
13852 #include <$ac_header>
13853 _ACEOF
13854 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13855   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13856   ac_status=$?
13857   grep -v '^ *+' conftest.er1 >conftest.err
13858   rm -f conftest.er1
13859   cat conftest.err >&5
13860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13861   (exit $ac_status); } >/dev/null; then
13862   if test -s conftest.err; then
13863     ac_cpp_err=$ac_c_preproc_warn_flag
13864   else
13865     ac_cpp_err=
13866   fi
13867 else
13868   ac_cpp_err=yes
13869 fi
13870 if test -z "$ac_cpp_err"; then
13871   ac_header_preproc=yes
13872 else
13873   echo "$as_me: failed program was:" >&5
13874 sed 's/^/| /' conftest.$ac_ext >&5
13875
13876   ac_header_preproc=no
13877 fi
13878 rm -f conftest.err conftest.$ac_ext
13879 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13880 echo "${ECHO_T}$ac_header_preproc" >&6
13881
13882 # So?  What about this header?
13883 case $ac_header_compiler:$ac_header_preproc in
13884   yes:no )
13885     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13886 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13887     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13888 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13889     (
13890       cat <<\_ASBOX
13891 ## ------------------------------------ ##
13892 ## Report this to bug-autoconf@gnu.org. ##
13893 ## ------------------------------------ ##
13894 _ASBOX
13895     ) |
13896       sed "s/^/$as_me: WARNING:     /" >&2
13897     ;;
13898   no:yes )
13899     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13900 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13901     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13902 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13903     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13904 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13905     (
13906       cat <<\_ASBOX
13907 ## ------------------------------------ ##
13908 ## Report this to bug-autoconf@gnu.org. ##
13909 ## ------------------------------------ ##
13910 _ASBOX
13911     ) |
13912       sed "s/^/$as_me: WARNING:     /" >&2
13913     ;;
13914 esac
13915 echo "$as_me:$LINENO: checking for $ac_header" >&5
13916 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13917 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13918   echo $ECHO_N "(cached) $ECHO_C" >&6
13919 else
13920   eval "$as_ac_Header=$ac_header_preproc"
13921 fi
13922 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13923 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13924
13925 fi
13926 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13927   cat >>confdefs.h <<_ACEOF
13928 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13929 _ACEOF
13930
13931 fi
13932
13933 done
13934
13935 if test "$ac_cv_header_regex_h" != yes ; then
13936         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
13937 echo "$as_me: error: POSIX regex.h required." >&2;}
13938    { (exit 1); exit 1; }; }
13939 fi
13940 echo "$as_me:$LINENO: checking for library containing regfree" >&5
13941 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
13942 if test "${ac_cv_search_regfree+set}" = set; then
13943   echo $ECHO_N "(cached) $ECHO_C" >&6
13944 else
13945   ac_func_search_save_LIBS=$LIBS
13946 ac_cv_search_regfree=no
13947 cat >conftest.$ac_ext <<_ACEOF
13948 #line $LINENO "configure"
13949 /* confdefs.h.  */
13950 _ACEOF
13951 cat confdefs.h >>conftest.$ac_ext
13952 cat >>conftest.$ac_ext <<_ACEOF
13953 /* end confdefs.h.  */
13954
13955 /* Override any gcc2 internal prototype to avoid an error.  */
13956 #ifdef __cplusplus
13957 extern "C"
13958 #endif
13959 /* We use char because int might match the return type of a gcc2
13960    builtin and then its argument prototype would still apply.  */
13961 char regfree ();
13962 int
13963 main ()
13964 {
13965 regfree ();
13966   ;
13967   return 0;
13968 }
13969 _ACEOF
13970 rm -f conftest.$ac_objext conftest$ac_exeext
13971 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13972   (eval $ac_link) 2>&5
13973   ac_status=$?
13974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13975   (exit $ac_status); } &&
13976          { ac_try='test -s conftest$ac_exeext'
13977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13978   (eval $ac_try) 2>&5
13979   ac_status=$?
13980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13981   (exit $ac_status); }; }; then
13982   ac_cv_search_regfree="none required"
13983 else
13984   echo "$as_me: failed program was:" >&5
13985 sed 's/^/| /' conftest.$ac_ext >&5
13986
13987 fi
13988 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13989 if test "$ac_cv_search_regfree" = no; then
13990   for ac_lib in regex gnuregex; do
13991     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13992     cat >conftest.$ac_ext <<_ACEOF
13993 #line $LINENO "configure"
13994 /* confdefs.h.  */
13995 _ACEOF
13996 cat confdefs.h >>conftest.$ac_ext
13997 cat >>conftest.$ac_ext <<_ACEOF
13998 /* end confdefs.h.  */
13999
14000 /* Override any gcc2 internal prototype to avoid an error.  */
14001 #ifdef __cplusplus
14002 extern "C"
14003 #endif
14004 /* We use char because int might match the return type of a gcc2
14005    builtin and then its argument prototype would still apply.  */
14006 char regfree ();
14007 int
14008 main ()
14009 {
14010 regfree ();
14011   ;
14012   return 0;
14013 }
14014 _ACEOF
14015 rm -f conftest.$ac_objext conftest$ac_exeext
14016 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14017   (eval $ac_link) 2>&5
14018   ac_status=$?
14019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14020   (exit $ac_status); } &&
14021          { ac_try='test -s conftest$ac_exeext'
14022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14023   (eval $ac_try) 2>&5
14024   ac_status=$?
14025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14026   (exit $ac_status); }; }; then
14027   ac_cv_search_regfree="-l$ac_lib"
14028 break
14029 else
14030   echo "$as_me: failed program was:" >&5
14031 sed 's/^/| /' conftest.$ac_ext >&5
14032
14033 fi
14034 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14035   done
14036 fi
14037 LIBS=$ac_func_search_save_LIBS
14038 fi
14039 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
14040 echo "${ECHO_T}$ac_cv_search_regfree" >&6
14041 if test "$ac_cv_search_regfree" != no; then
14042   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
14043   :
14044 else
14045   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
14046 echo "$as_me: error: POSIX regex required." >&2;}
14047    { (exit 1); exit 1; }; }
14048 fi
14049
14050
14051
14052 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
14053 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
14054 if test "${ol_cv_c_posix_regex+set}" = set; then
14055   echo $ECHO_N "(cached) $ECHO_C" >&6
14056 else
14057
14058         if test "$cross_compiling" = yes; then
14059   ol_cv_c_posix_regex=cross
14060 else
14061   cat >conftest.$ac_ext <<_ACEOF
14062 #line $LINENO "configure"
14063 /* confdefs.h.  */
14064 _ACEOF
14065 cat confdefs.h >>conftest.$ac_ext
14066 cat >>conftest.$ac_ext <<_ACEOF
14067 /* end confdefs.h.  */
14068
14069 #include <sys/types.h>
14070 #include <regex.h>
14071 static char *pattern, *string;
14072 main()
14073 {
14074         int rc;
14075         regex_t re;
14076
14077         pattern = "^A";
14078
14079         if(regcomp(&re, pattern, 0)) {
14080                 return -1;
14081         }
14082
14083         string = "ALL MATCH";
14084
14085         rc = regexec(&re, string, 0, (void*)0, 0);
14086
14087         regfree(&re);
14088
14089         return rc;
14090 }
14091 _ACEOF
14092 rm -f conftest$ac_exeext
14093 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14094   (eval $ac_link) 2>&5
14095   ac_status=$?
14096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14097   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14099   (eval $ac_try) 2>&5
14100   ac_status=$?
14101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14102   (exit $ac_status); }; }; then
14103   ol_cv_c_posix_regex=yes
14104 else
14105   echo "$as_me: program exited with status $ac_status" >&5
14106 echo "$as_me: failed program was:" >&5
14107 sed 's/^/| /' conftest.$ac_ext >&5
14108
14109 ( exit $ac_status )
14110 ol_cv_c_posix_regex=no
14111 fi
14112 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14113 fi
14114 fi
14115 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
14116 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
14117
14118 if test "$ol_cv_c_posix_regex" = no ; then
14119         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
14120 echo "$as_me: error: broken POSIX regex!" >&2;}
14121    { (exit 1); exit 1; }; }
14122 fi
14123
14124
14125 have_uuid=no
14126
14127 for ac_header in sys/uuid.h
14128 do
14129 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14130 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14131   echo "$as_me:$LINENO: checking for $ac_header" >&5
14132 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14133 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14134   echo $ECHO_N "(cached) $ECHO_C" >&6
14135 fi
14136 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14137 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14138 else
14139   # Is the header compilable?
14140 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14141 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14142 cat >conftest.$ac_ext <<_ACEOF
14143 #line $LINENO "configure"
14144 /* confdefs.h.  */
14145 _ACEOF
14146 cat confdefs.h >>conftest.$ac_ext
14147 cat >>conftest.$ac_ext <<_ACEOF
14148 /* end confdefs.h.  */
14149 $ac_includes_default
14150 #include <$ac_header>
14151 _ACEOF
14152 rm -f conftest.$ac_objext
14153 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14154   (eval $ac_compile) 2>&5
14155   ac_status=$?
14156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14157   (exit $ac_status); } &&
14158          { ac_try='test -s conftest.$ac_objext'
14159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14160   (eval $ac_try) 2>&5
14161   ac_status=$?
14162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14163   (exit $ac_status); }; }; then
14164   ac_header_compiler=yes
14165 else
14166   echo "$as_me: failed program was:" >&5
14167 sed 's/^/| /' conftest.$ac_ext >&5
14168
14169 ac_header_compiler=no
14170 fi
14171 rm -f conftest.$ac_objext conftest.$ac_ext
14172 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14173 echo "${ECHO_T}$ac_header_compiler" >&6
14174
14175 # Is the header present?
14176 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14177 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14178 cat >conftest.$ac_ext <<_ACEOF
14179 #line $LINENO "configure"
14180 /* confdefs.h.  */
14181 _ACEOF
14182 cat confdefs.h >>conftest.$ac_ext
14183 cat >>conftest.$ac_ext <<_ACEOF
14184 /* end confdefs.h.  */
14185 #include <$ac_header>
14186 _ACEOF
14187 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14188   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14189   ac_status=$?
14190   grep -v '^ *+' conftest.er1 >conftest.err
14191   rm -f conftest.er1
14192   cat conftest.err >&5
14193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14194   (exit $ac_status); } >/dev/null; then
14195   if test -s conftest.err; then
14196     ac_cpp_err=$ac_c_preproc_warn_flag
14197   else
14198     ac_cpp_err=
14199   fi
14200 else
14201   ac_cpp_err=yes
14202 fi
14203 if test -z "$ac_cpp_err"; then
14204   ac_header_preproc=yes
14205 else
14206   echo "$as_me: failed program was:" >&5
14207 sed 's/^/| /' conftest.$ac_ext >&5
14208
14209   ac_header_preproc=no
14210 fi
14211 rm -f conftest.err conftest.$ac_ext
14212 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14213 echo "${ECHO_T}$ac_header_preproc" >&6
14214
14215 # So?  What about this header?
14216 case $ac_header_compiler:$ac_header_preproc in
14217   yes:no )
14218     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14219 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14220     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14221 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14222     (
14223       cat <<\_ASBOX
14224 ## ------------------------------------ ##
14225 ## Report this to bug-autoconf@gnu.org. ##
14226 ## ------------------------------------ ##
14227 _ASBOX
14228     ) |
14229       sed "s/^/$as_me: WARNING:     /" >&2
14230     ;;
14231   no:yes )
14232     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14233 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14234     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14235 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14236     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14237 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14238     (
14239       cat <<\_ASBOX
14240 ## ------------------------------------ ##
14241 ## Report this to bug-autoconf@gnu.org. ##
14242 ## ------------------------------------ ##
14243 _ASBOX
14244     ) |
14245       sed "s/^/$as_me: WARNING:     /" >&2
14246     ;;
14247 esac
14248 echo "$as_me:$LINENO: checking for $ac_header" >&5
14249 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14250 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14251   echo $ECHO_N "(cached) $ECHO_C" >&6
14252 else
14253   eval "$as_ac_Header=$ac_header_preproc"
14254 fi
14255 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14256 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14257
14258 fi
14259 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14260   cat >>confdefs.h <<_ACEOF
14261 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14262 _ACEOF
14263
14264 fi
14265
14266 done
14267
14268 if test $ac_cv_header_sys_uuid_h = yes ; then
14269         save_LIBS="$LIBS"
14270         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
14271 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
14272 if test "${ac_cv_search_uuid_to_str+set}" = set; then
14273   echo $ECHO_N "(cached) $ECHO_C" >&6
14274 else
14275   ac_func_search_save_LIBS=$LIBS
14276 ac_cv_search_uuid_to_str=no
14277 cat >conftest.$ac_ext <<_ACEOF
14278 #line $LINENO "configure"
14279 /* confdefs.h.  */
14280 _ACEOF
14281 cat confdefs.h >>conftest.$ac_ext
14282 cat >>conftest.$ac_ext <<_ACEOF
14283 /* end confdefs.h.  */
14284
14285 /* Override any gcc2 internal prototype to avoid an error.  */
14286 #ifdef __cplusplus
14287 extern "C"
14288 #endif
14289 /* We use char because int might match the return type of a gcc2
14290    builtin and then its argument prototype would still apply.  */
14291 char uuid_to_str ();
14292 int
14293 main ()
14294 {
14295 uuid_to_str ();
14296   ;
14297   return 0;
14298 }
14299 _ACEOF
14300 rm -f conftest.$ac_objext conftest$ac_exeext
14301 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14302   (eval $ac_link) 2>&5
14303   ac_status=$?
14304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14305   (exit $ac_status); } &&
14306          { ac_try='test -s conftest$ac_exeext'
14307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14308   (eval $ac_try) 2>&5
14309   ac_status=$?
14310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14311   (exit $ac_status); }; }; then
14312   ac_cv_search_uuid_to_str="none required"
14313 else
14314   echo "$as_me: failed program was:" >&5
14315 sed 's/^/| /' conftest.$ac_ext >&5
14316
14317 fi
14318 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14319 if test "$ac_cv_search_uuid_to_str" = no; then
14320   for ac_lib in uuid; do
14321     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14322     cat >conftest.$ac_ext <<_ACEOF
14323 #line $LINENO "configure"
14324 /* confdefs.h.  */
14325 _ACEOF
14326 cat confdefs.h >>conftest.$ac_ext
14327 cat >>conftest.$ac_ext <<_ACEOF
14328 /* end confdefs.h.  */
14329
14330 /* Override any gcc2 internal prototype to avoid an error.  */
14331 #ifdef __cplusplus
14332 extern "C"
14333 #endif
14334 /* We use char because int might match the return type of a gcc2
14335    builtin and then its argument prototype would still apply.  */
14336 char uuid_to_str ();
14337 int
14338 main ()
14339 {
14340 uuid_to_str ();
14341   ;
14342   return 0;
14343 }
14344 _ACEOF
14345 rm -f conftest.$ac_objext conftest$ac_exeext
14346 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14347   (eval $ac_link) 2>&5
14348   ac_status=$?
14349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14350   (exit $ac_status); } &&
14351          { ac_try='test -s conftest$ac_exeext'
14352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14353   (eval $ac_try) 2>&5
14354   ac_status=$?
14355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14356   (exit $ac_status); }; }; then
14357   ac_cv_search_uuid_to_str="-l$ac_lib"
14358 break
14359 else
14360   echo "$as_me: failed program was:" >&5
14361 sed 's/^/| /' conftest.$ac_ext >&5
14362
14363 fi
14364 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14365   done
14366 fi
14367 LIBS=$ac_func_search_save_LIBS
14368 fi
14369 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
14370 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
14371 if test "$ac_cv_search_uuid_to_str" != no; then
14372   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
14373   have_uuid=yes
14374 else
14375   :
14376 fi
14377
14378         LIBS="$save_LIBS"
14379
14380         if test have_uuid = yes ; then
14381
14382 cat >>confdefs.h <<\_ACEOF
14383 #define HAVE_UUID_TO_STR 1
14384 _ACEOF
14385
14386
14387                 test "$ac_cv_search_uuid_to_str" = "none required" || \
14388                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
14389         fi
14390 fi
14391
14392 if test $have_uuid = no ; then
14393         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
14394 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
14395         save_LIBS="$LIBS"
14396         LIBS="$LIBS -lrpcrt4"
14397         cat >conftest.$ac_ext <<_ACEOF
14398 #line $LINENO "configure"
14399 /* confdefs.h.  */
14400 _ACEOF
14401 cat confdefs.h >>conftest.$ac_ext
14402 cat >>conftest.$ac_ext <<_ACEOF
14403 /* end confdefs.h.  */
14404
14405                 char UuidCreate@4();
14406                 char UuidToStringA@8();
14407
14408 int
14409 main ()
14410 {
14411
14412                 UuidCreate@4();
14413                 UuidToStringA@8();
14414
14415   ;
14416   return 0;
14417 }
14418 _ACEOF
14419 rm -f conftest.$ac_objext conftest$ac_exeext
14420 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14421   (eval $ac_link) 2>&5
14422   ac_status=$?
14423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14424   (exit $ac_status); } &&
14425          { ac_try='test -s conftest$ac_exeext'
14426   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14427   (eval $ac_try) 2>&5
14428   ac_status=$?
14429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14430   (exit $ac_status); }; }; then
14431   need_rpcrt=yes
14432 else
14433   echo "$as_me: failed program was:" >&5
14434 sed 's/^/| /' conftest.$ac_ext >&5
14435
14436 need_rpcrt=no
14437 fi
14438 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14439         if test $need_rpcrt = yes; then
14440                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
14441         fi
14442         LIBS="$save_LIBS"
14443         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
14444 echo "${ECHO_T}$need_rpcrt" >&6
14445 fi
14446
14447 ol_link_dnssrv=no
14448 echo "$as_me:$LINENO: checking for res_query" >&5
14449 echo $ECHO_N "checking for res_query... $ECHO_C" >&6
14450 if test "${ac_cv_func_res_query+set}" = set; then
14451   echo $ECHO_N "(cached) $ECHO_C" >&6
14452 else
14453   cat >conftest.$ac_ext <<_ACEOF
14454 #line $LINENO "configure"
14455 /* confdefs.h.  */
14456 _ACEOF
14457 cat confdefs.h >>conftest.$ac_ext
14458 cat >>conftest.$ac_ext <<_ACEOF
14459 /* end confdefs.h.  */
14460 /* System header to define __stub macros and hopefully few prototypes,
14461     which can conflict with char res_query (); below.
14462     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14463     <limits.h> exists even on freestanding compilers.  */
14464 #ifdef __STDC__
14465 # include <limits.h>
14466 #else
14467 # include <assert.h>
14468 #endif
14469 /* Override any gcc2 internal prototype to avoid an error.  */
14470 #ifdef __cplusplus
14471 extern "C"
14472 {
14473 #endif
14474 /* We use char because int might match the return type of a gcc2
14475    builtin and then its argument prototype would still apply.  */
14476 char res_query ();
14477 /* The GNU C library defines this for functions which it implements
14478     to always fail with ENOSYS.  Some functions are actually named
14479     something starting with __ and the normal name is an alias.  */
14480 #if defined (__stub_res_query) || defined (__stub___res_query)
14481 choke me
14482 #else
14483 char (*f) () = res_query;
14484 #endif
14485 #ifdef __cplusplus
14486 }
14487 #endif
14488
14489 int
14490 main ()
14491 {
14492 return f != res_query;
14493   ;
14494   return 0;
14495 }
14496 _ACEOF
14497 rm -f conftest.$ac_objext conftest$ac_exeext
14498 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14499   (eval $ac_link) 2>&5
14500   ac_status=$?
14501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14502   (exit $ac_status); } &&
14503          { ac_try='test -s conftest$ac_exeext'
14504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14505   (eval $ac_try) 2>&5
14506   ac_status=$?
14507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14508   (exit $ac_status); }; }; then
14509   ac_cv_func_res_query=yes
14510 else
14511   echo "$as_me: failed program was:" >&5
14512 sed 's/^/| /' conftest.$ac_ext >&5
14513
14514 ac_cv_func_res_query=no
14515 fi
14516 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14517 fi
14518 echo "$as_me:$LINENO: result: $ac_cv_func_res_query" >&5
14519 echo "${ECHO_T}$ac_cv_func_res_query" >&6
14520 if test $ac_cv_func_res_query = yes; then
14521   :
14522 fi
14523
14524 if test $ac_cv_func_res_query = no ; then
14525         echo "$as_me:$LINENO: checking for __res_query" >&5
14526 echo $ECHO_N "checking for __res_query... $ECHO_C" >&6
14527 if test "${ac_cv_func___res_query+set}" = set; then
14528   echo $ECHO_N "(cached) $ECHO_C" >&6
14529 else
14530   cat >conftest.$ac_ext <<_ACEOF
14531 #line $LINENO "configure"
14532 /* confdefs.h.  */
14533 _ACEOF
14534 cat confdefs.h >>conftest.$ac_ext
14535 cat >>conftest.$ac_ext <<_ACEOF
14536 /* end confdefs.h.  */
14537 /* System header to define __stub macros and hopefully few prototypes,
14538     which can conflict with char __res_query (); below.
14539     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14540     <limits.h> exists even on freestanding compilers.  */
14541 #ifdef __STDC__
14542 # include <limits.h>
14543 #else
14544 # include <assert.h>
14545 #endif
14546 /* Override any gcc2 internal prototype to avoid an error.  */
14547 #ifdef __cplusplus
14548 extern "C"
14549 {
14550 #endif
14551 /* We use char because int might match the return type of a gcc2
14552    builtin and then its argument prototype would still apply.  */
14553 char __res_query ();
14554 /* The GNU C library defines this for functions which it implements
14555     to always fail with ENOSYS.  Some functions are actually named
14556     something starting with __ and the normal name is an alias.  */
14557 #if defined (__stub___res_query) || defined (__stub_____res_query)
14558 choke me
14559 #else
14560 char (*f) () = __res_query;
14561 #endif
14562 #ifdef __cplusplus
14563 }
14564 #endif
14565
14566 int
14567 main ()
14568 {
14569 return f != __res_query;
14570   ;
14571   return 0;
14572 }
14573 _ACEOF
14574 rm -f conftest.$ac_objext conftest$ac_exeext
14575 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14576   (eval $ac_link) 2>&5
14577   ac_status=$?
14578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14579   (exit $ac_status); } &&
14580          { ac_try='test -s conftest$ac_exeext'
14581   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14582   (eval $ac_try) 2>&5
14583   ac_status=$?
14584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14585   (exit $ac_status); }; }; then
14586   ac_cv_func___res_query=yes
14587 else
14588   echo "$as_me: failed program was:" >&5
14589 sed 's/^/| /' conftest.$ac_ext >&5
14590
14591 ac_cv_func___res_query=no
14592 fi
14593 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14594 fi
14595 echo "$as_me:$LINENO: result: $ac_cv_func___res_query" >&5
14596 echo "${ECHO_T}$ac_cv_func___res_query" >&6
14597 if test $ac_cv_func___res_query = yes; then
14598   :
14599 fi
14600
14601         ac_cv_func_res_query=$ac_cv_func___res_query
14602 fi
14603
14604 if test $ac_cv_func_res_query = no ; then
14605
14606 echo "$as_me:$LINENO: checking for res_query in -lbind" >&5
14607 echo $ECHO_N "checking for res_query in -lbind... $ECHO_C" >&6
14608 if test "${ac_cv_lib_bind_res_query+set}" = set; then
14609   echo $ECHO_N "(cached) $ECHO_C" >&6
14610 else
14611   ac_check_lib_save_LIBS=$LIBS
14612 LIBS="-lbind  $LIBS"
14613 cat >conftest.$ac_ext <<_ACEOF
14614 #line $LINENO "configure"
14615 /* confdefs.h.  */
14616 _ACEOF
14617 cat confdefs.h >>conftest.$ac_ext
14618 cat >>conftest.$ac_ext <<_ACEOF
14619 /* end confdefs.h.  */
14620
14621 /* Override any gcc2 internal prototype to avoid an error.  */
14622 #ifdef __cplusplus
14623 extern "C"
14624 #endif
14625 /* We use char because int might match the return type of a gcc2
14626    builtin and then its argument prototype would still apply.  */
14627 char res_query ();
14628 int
14629 main ()
14630 {
14631 res_query ();
14632   ;
14633   return 0;
14634 }
14635 _ACEOF
14636 rm -f conftest.$ac_objext conftest$ac_exeext
14637 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14638   (eval $ac_link) 2>&5
14639   ac_status=$?
14640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14641   (exit $ac_status); } &&
14642          { ac_try='test -s conftest$ac_exeext'
14643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14644   (eval $ac_try) 2>&5
14645   ac_status=$?
14646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14647   (exit $ac_status); }; }; then
14648   ac_cv_lib_bind_res_query=yes
14649 else
14650   echo "$as_me: failed program was:" >&5
14651 sed 's/^/| /' conftest.$ac_ext >&5
14652
14653 ac_cv_lib_bind_res_query=no
14654 fi
14655 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14656 LIBS=$ac_check_lib_save_LIBS
14657 fi
14658 echo "$as_me:$LINENO: result: $ac_cv_lib_bind_res_query" >&5
14659 echo "${ECHO_T}$ac_cv_lib_bind_res_query" >&6
14660 if test $ac_cv_lib_bind_res_query = yes; then
14661   cat >>confdefs.h <<_ACEOF
14662 #define HAVE_LIBBIND 1
14663 _ACEOF
14664
14665   LIBS="-lbind $LIBS"
14666
14667 fi
14668
14669         ac_cv_func_res_query=$ac_cv_lib_bind_res_query
14670 fi
14671
14672 if test $ac_cv_func_res_query = no ; then
14673
14674 echo "$as_me:$LINENO: checking for __res_query in -lbind" >&5
14675 echo $ECHO_N "checking for __res_query in -lbind... $ECHO_C" >&6
14676 if test "${ac_cv_lib_bind___res_query+set}" = set; then
14677   echo $ECHO_N "(cached) $ECHO_C" >&6
14678 else
14679   ac_check_lib_save_LIBS=$LIBS
14680 LIBS="-lbind  $LIBS"
14681 cat >conftest.$ac_ext <<_ACEOF
14682 #line $LINENO "configure"
14683 /* confdefs.h.  */
14684 _ACEOF
14685 cat confdefs.h >>conftest.$ac_ext
14686 cat >>conftest.$ac_ext <<_ACEOF
14687 /* end confdefs.h.  */
14688
14689 /* Override any gcc2 internal prototype to avoid an error.  */
14690 #ifdef __cplusplus
14691 extern "C"
14692 #endif
14693 /* We use char because int might match the return type of a gcc2
14694    builtin and then its argument prototype would still apply.  */
14695 char __res_query ();
14696 int
14697 main ()
14698 {
14699 __res_query ();
14700   ;
14701   return 0;
14702 }
14703 _ACEOF
14704 rm -f conftest.$ac_objext conftest$ac_exeext
14705 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14706   (eval $ac_link) 2>&5
14707   ac_status=$?
14708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14709   (exit $ac_status); } &&
14710          { ac_try='test -s conftest$ac_exeext'
14711   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14712   (eval $ac_try) 2>&5
14713   ac_status=$?
14714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14715   (exit $ac_status); }; }; then
14716   ac_cv_lib_bind___res_query=yes
14717 else
14718   echo "$as_me: failed program was:" >&5
14719 sed 's/^/| /' conftest.$ac_ext >&5
14720
14721 ac_cv_lib_bind___res_query=no
14722 fi
14723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14724 LIBS=$ac_check_lib_save_LIBS
14725 fi
14726 echo "$as_me:$LINENO: result: $ac_cv_lib_bind___res_query" >&5
14727 echo "${ECHO_T}$ac_cv_lib_bind___res_query" >&6
14728 if test $ac_cv_lib_bind___res_query = yes; then
14729   cat >>confdefs.h <<_ACEOF
14730 #define HAVE_LIBBIND 1
14731 _ACEOF
14732
14733   LIBS="-lbind $LIBS"
14734
14735 fi
14736
14737         ac_cv_func_res_query=$ac_cv_lib_bind___res_query
14738 fi
14739
14740 if test $ac_cv_func_res_query = no ; then
14741
14742 echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
14743 echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6
14744 if test "${ac_cv_lib_resolv_res_query+set}" = set; then
14745   echo $ECHO_N "(cached) $ECHO_C" >&6
14746 else
14747   ac_check_lib_save_LIBS=$LIBS
14748 LIBS="-lresolv  $LIBS"
14749 cat >conftest.$ac_ext <<_ACEOF
14750 #line $LINENO "configure"
14751 /* confdefs.h.  */
14752 _ACEOF
14753 cat confdefs.h >>conftest.$ac_ext
14754 cat >>conftest.$ac_ext <<_ACEOF
14755 /* end confdefs.h.  */
14756
14757 /* Override any gcc2 internal prototype to avoid an error.  */
14758 #ifdef __cplusplus
14759 extern "C"
14760 #endif
14761 /* We use char because int might match the return type of a gcc2
14762    builtin and then its argument prototype would still apply.  */
14763 char res_query ();
14764 int
14765 main ()
14766 {
14767 res_query ();
14768   ;
14769   return 0;
14770 }
14771 _ACEOF
14772 rm -f conftest.$ac_objext conftest$ac_exeext
14773 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14774   (eval $ac_link) 2>&5
14775   ac_status=$?
14776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14777   (exit $ac_status); } &&
14778          { ac_try='test -s conftest$ac_exeext'
14779   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14780   (eval $ac_try) 2>&5
14781   ac_status=$?
14782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14783   (exit $ac_status); }; }; then
14784   ac_cv_lib_resolv_res_query=yes
14785 else
14786   echo "$as_me: failed program was:" >&5
14787 sed 's/^/| /' conftest.$ac_ext >&5
14788
14789 ac_cv_lib_resolv_res_query=no
14790 fi
14791 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14792 LIBS=$ac_check_lib_save_LIBS
14793 fi
14794 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_query" >&5
14795 echo "${ECHO_T}$ac_cv_lib_resolv_res_query" >&6
14796 if test $ac_cv_lib_resolv_res_query = yes; then
14797   cat >>confdefs.h <<_ACEOF
14798 #define HAVE_LIBRESOLV 1
14799 _ACEOF
14800
14801   LIBS="-lresolv $LIBS"
14802
14803 fi
14804
14805         ac_cv_func_res_query=$ac_cv_lib_resolv_res_query
14806 fi
14807
14808 if test $ac_cv_func_res_query = no ; then
14809
14810 echo "$as_me:$LINENO: checking for __res_query in -lresolv" >&5
14811 echo $ECHO_N "checking for __res_query in -lresolv... $ECHO_C" >&6
14812 if test "${ac_cv_lib_resolv___res_query+set}" = set; then
14813   echo $ECHO_N "(cached) $ECHO_C" >&6
14814 else
14815   ac_check_lib_save_LIBS=$LIBS
14816 LIBS="-lresolv  $LIBS"
14817 cat >conftest.$ac_ext <<_ACEOF
14818 #line $LINENO "configure"
14819 /* confdefs.h.  */
14820 _ACEOF
14821 cat confdefs.h >>conftest.$ac_ext
14822 cat >>conftest.$ac_ext <<_ACEOF
14823 /* end confdefs.h.  */
14824
14825 /* Override any gcc2 internal prototype to avoid an error.  */
14826 #ifdef __cplusplus
14827 extern "C"
14828 #endif
14829 /* We use char because int might match the return type of a gcc2
14830    builtin and then its argument prototype would still apply.  */
14831 char __res_query ();
14832 int
14833 main ()
14834 {
14835 __res_query ();
14836   ;
14837   return 0;
14838 }
14839 _ACEOF
14840 rm -f conftest.$ac_objext conftest$ac_exeext
14841 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14842   (eval $ac_link) 2>&5
14843   ac_status=$?
14844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14845   (exit $ac_status); } &&
14846          { ac_try='test -s conftest$ac_exeext'
14847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14848   (eval $ac_try) 2>&5
14849   ac_status=$?
14850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14851   (exit $ac_status); }; }; then
14852   ac_cv_lib_resolv___res_query=yes
14853 else
14854   echo "$as_me: failed program was:" >&5
14855 sed 's/^/| /' conftest.$ac_ext >&5
14856
14857 ac_cv_lib_resolv___res_query=no
14858 fi
14859 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14860 LIBS=$ac_check_lib_save_LIBS
14861 fi
14862 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_query" >&5
14863 echo "${ECHO_T}$ac_cv_lib_resolv___res_query" >&6
14864 if test $ac_cv_lib_resolv___res_query = yes; then
14865   cat >>confdefs.h <<_ACEOF
14866 #define HAVE_LIBRESOLV 1
14867 _ACEOF
14868
14869   LIBS="-lresolv $LIBS"
14870
14871 fi
14872
14873         ac_cv_func_res_query=$ac_cv_lib_resolv___res_query
14874 fi
14875
14876 if test "$ac_cv_func_res_query" = yes ; then
14877
14878 cat >>confdefs.h <<\_ACEOF
14879 #define HAVE_RES_QUERY 1
14880 _ACEOF
14881
14882
14883         if test $ol_enable_dnssrv != no ; then
14884                 ol_link_dnssrv=yes
14885         fi
14886 fi
14887
14888 if test "$ol_enable_dnssrv" = yes -a "$ol_link_dnssrv" = no ; then
14889         { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
14890 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
14891    { (exit 1); exit 1; }; }
14892 fi
14893
14894
14895
14896
14897
14898 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
14899 do
14900 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14901 echo "$as_me:$LINENO: checking for $ac_func" >&5
14902 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14903 if eval "test \"\${$as_ac_var+set}\" = set"; then
14904   echo $ECHO_N "(cached) $ECHO_C" >&6
14905 else
14906   cat >conftest.$ac_ext <<_ACEOF
14907 #line $LINENO "configure"
14908 /* confdefs.h.  */
14909 _ACEOF
14910 cat confdefs.h >>conftest.$ac_ext
14911 cat >>conftest.$ac_ext <<_ACEOF
14912 /* end confdefs.h.  */
14913 /* System header to define __stub macros and hopefully few prototypes,
14914     which can conflict with char $ac_func (); below.
14915     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14916     <limits.h> exists even on freestanding compilers.  */
14917 #ifdef __STDC__
14918 # include <limits.h>
14919 #else
14920 # include <assert.h>
14921 #endif
14922 /* Override any gcc2 internal prototype to avoid an error.  */
14923 #ifdef __cplusplus
14924 extern "C"
14925 {
14926 #endif
14927 /* We use char because int might match the return type of a gcc2
14928    builtin and then its argument prototype would still apply.  */
14929 char $ac_func ();
14930 /* The GNU C library defines this for functions which it implements
14931     to always fail with ENOSYS.  Some functions are actually named
14932     something starting with __ and the normal name is an alias.  */
14933 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14934 choke me
14935 #else
14936 char (*f) () = $ac_func;
14937 #endif
14938 #ifdef __cplusplus
14939 }
14940 #endif
14941
14942 int
14943 main ()
14944 {
14945 return f != $ac_func;
14946   ;
14947   return 0;
14948 }
14949 _ACEOF
14950 rm -f conftest.$ac_objext conftest$ac_exeext
14951 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14952   (eval $ac_link) 2>&5
14953   ac_status=$?
14954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14955   (exit $ac_status); } &&
14956          { ac_try='test -s conftest$ac_exeext'
14957   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14958   (eval $ac_try) 2>&5
14959   ac_status=$?
14960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14961   (exit $ac_status); }; }; then
14962   eval "$as_ac_var=yes"
14963 else
14964   echo "$as_me: failed program was:" >&5
14965 sed 's/^/| /' conftest.$ac_ext >&5
14966
14967 eval "$as_ac_var=no"
14968 fi
14969 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14970 fi
14971 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14972 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14973 if test `eval echo '${'$as_ac_var'}'` = yes; then
14974   cat >>confdefs.h <<_ACEOF
14975 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14976 _ACEOF
14977
14978 fi
14979 done
14980
14981
14982 ol_link_ipv6=no
14983 if test $ac_cv_func_getaddrinfo = no -o $ac_cv_func_inet_ntop = no ; then
14984         if test $ol_enable_ipv6 = yes ; then
14985                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
14986 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
14987    { (exit 1); exit 1; }; }
14988         fi
14989 elif test $ol_enable_ipv6 != no ; then
14990         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
14991 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
14992 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
14993   echo $ECHO_N "(cached) $ECHO_C" >&6
14994 else
14995
14996                 cat >conftest.$ac_ext <<_ACEOF
14997 #line $LINENO "configure"
14998 /* confdefs.h.  */
14999 _ACEOF
15000 cat confdefs.h >>conftest.$ac_ext
15001 cat >>conftest.$ac_ext <<_ACEOF
15002 /* end confdefs.h.  */
15003
15004 #                       include <netinet/in.h>
15005 #                       ifdef INET6_ADDRSTRLEN
15006                                 __has_inet6_addrstrlen__;
15007 #                       endif
15008
15009 _ACEOF
15010 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15011   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
15012   ol_cv_inet6_addrstrlen=yes
15013 else
15014   ol_cv_inet6_addrstrlen=no
15015 fi
15016 rm -f conftest*
15017
15018 fi
15019 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
15020 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
15021
15022
15023         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
15024 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
15025 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
15026   echo $ECHO_N "(cached) $ECHO_C" >&6
15027 else
15028
15029                 cat >conftest.$ac_ext <<_ACEOF
15030 #line $LINENO "configure"
15031 /* confdefs.h.  */
15032 _ACEOF
15033 cat confdefs.h >>conftest.$ac_ext
15034 cat >>conftest.$ac_ext <<_ACEOF
15035 /* end confdefs.h.  */
15036
15037 #include <sys/types.h>
15038 #include <sys/socket.h>
15039
15040 int
15041 main ()
15042 {
15043
15044                         struct sockaddr_storage ss;
15045
15046   ;
15047   return 0;
15048 }
15049 _ACEOF
15050 rm -f conftest.$ac_objext
15051 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15052   (eval $ac_compile) 2>&5
15053   ac_status=$?
15054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15055   (exit $ac_status); } &&
15056          { ac_try='test -s conftest.$ac_objext'
15057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15058   (eval $ac_try) 2>&5
15059   ac_status=$?
15060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15061   (exit $ac_status); }; }; then
15062   ol_cv_struct_sockaddr_storage=yes
15063 else
15064   echo "$as_me: failed program was:" >&5
15065 sed 's/^/| /' conftest.$ac_ext >&5
15066
15067 ol_cv_struct_sockaddr_storage=no
15068 fi
15069 rm -f conftest.$ac_objext conftest.$ac_ext
15070 fi
15071 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
15072 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
15073
15074         if test $ol_cv_inet6_addrstrlen = yes \
15075                 -a $ol_cv_struct_sockaddr_storage = yes ; then
15076                 ol_link_ipv6=yes
15077         elif test $ol_enable_ipv6 = yes \
15078                         -a $ol_cv_inet6_addrstrlen = no ; then
15079                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
15080 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
15081    { (exit 1); exit 1; }; }
15082         elif test $ol_enable_ipv6 = yes \
15083                         -a $ol_cv_struct_sockaddr_storage = no ; then
15084                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
15085 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
15086    { (exit 1); exit 1; }; }
15087         fi
15088 fi
15089
15090 if test $ol_enable_local != no ; then
15091
15092 for ac_header in sys/un.h
15093 do
15094 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15095 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15096   echo "$as_me:$LINENO: checking for $ac_header" >&5
15097 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15098 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15099   echo $ECHO_N "(cached) $ECHO_C" >&6
15100 fi
15101 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15102 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15103 else
15104   # Is the header compilable?
15105 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15106 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15107 cat >conftest.$ac_ext <<_ACEOF
15108 #line $LINENO "configure"
15109 /* confdefs.h.  */
15110 _ACEOF
15111 cat confdefs.h >>conftest.$ac_ext
15112 cat >>conftest.$ac_ext <<_ACEOF
15113 /* end confdefs.h.  */
15114 $ac_includes_default
15115 #include <$ac_header>
15116 _ACEOF
15117 rm -f conftest.$ac_objext
15118 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15119   (eval $ac_compile) 2>&5
15120   ac_status=$?
15121   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15122   (exit $ac_status); } &&
15123          { ac_try='test -s conftest.$ac_objext'
15124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15125   (eval $ac_try) 2>&5
15126   ac_status=$?
15127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15128   (exit $ac_status); }; }; then
15129   ac_header_compiler=yes
15130 else
15131   echo "$as_me: failed program was:" >&5
15132 sed 's/^/| /' conftest.$ac_ext >&5
15133
15134 ac_header_compiler=no
15135 fi
15136 rm -f conftest.$ac_objext conftest.$ac_ext
15137 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15138 echo "${ECHO_T}$ac_header_compiler" >&6
15139
15140 # Is the header present?
15141 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15142 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15143 cat >conftest.$ac_ext <<_ACEOF
15144 #line $LINENO "configure"
15145 /* confdefs.h.  */
15146 _ACEOF
15147 cat confdefs.h >>conftest.$ac_ext
15148 cat >>conftest.$ac_ext <<_ACEOF
15149 /* end confdefs.h.  */
15150 #include <$ac_header>
15151 _ACEOF
15152 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15153   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15154   ac_status=$?
15155   grep -v '^ *+' conftest.er1 >conftest.err
15156   rm -f conftest.er1
15157   cat conftest.err >&5
15158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15159   (exit $ac_status); } >/dev/null; then
15160   if test -s conftest.err; then
15161     ac_cpp_err=$ac_c_preproc_warn_flag
15162   else
15163     ac_cpp_err=
15164   fi
15165 else
15166   ac_cpp_err=yes
15167 fi
15168 if test -z "$ac_cpp_err"; then
15169   ac_header_preproc=yes
15170 else
15171   echo "$as_me: failed program was:" >&5
15172 sed 's/^/| /' conftest.$ac_ext >&5
15173
15174   ac_header_preproc=no
15175 fi
15176 rm -f conftest.err conftest.$ac_ext
15177 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15178 echo "${ECHO_T}$ac_header_preproc" >&6
15179
15180 # So?  What about this header?
15181 case $ac_header_compiler:$ac_header_preproc in
15182   yes:no )
15183     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15184 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15185     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15186 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15187     (
15188       cat <<\_ASBOX
15189 ## ------------------------------------ ##
15190 ## Report this to bug-autoconf@gnu.org. ##
15191 ## ------------------------------------ ##
15192 _ASBOX
15193     ) |
15194       sed "s/^/$as_me: WARNING:     /" >&2
15195     ;;
15196   no:yes )
15197     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15198 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15199     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15200 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15201     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15202 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15203     (
15204       cat <<\_ASBOX
15205 ## ------------------------------------ ##
15206 ## Report this to bug-autoconf@gnu.org. ##
15207 ## ------------------------------------ ##
15208 _ASBOX
15209     ) |
15210       sed "s/^/$as_me: WARNING:     /" >&2
15211     ;;
15212 esac
15213 echo "$as_me:$LINENO: checking for $ac_header" >&5
15214 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15215 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15216   echo $ECHO_N "(cached) $ECHO_C" >&6
15217 else
15218   eval "$as_ac_Header=$ac_header_preproc"
15219 fi
15220 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15221 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15222
15223 fi
15224 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15225   cat >>confdefs.h <<_ACEOF
15226 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15227 _ACEOF
15228
15229 fi
15230
15231 done
15232
15233
15234         if test $ol_enable_local = auto ; then
15235                 ol_enable_local=$ac_cv_header_sys_un_h
15236         elif test $ac_cv_header_sys_un_h = no ; then
15237                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
15238 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
15239    { (exit 1); exit 1; }; }
15240         fi
15241 fi
15242
15243 ol_link_kbind=no
15244 ol_link_kpasswd=no
15245 ol_link_krb5=no
15246 ol_link_krb4=no
15247
15248 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
15249         -o $ol_with_kerberos = k5 -o $ol_with_kerberos = k5only \
15250         -o $ol_with_kerberos = k425 ; then
15251
15252
15253 for ac_header in krb5.h
15254 do
15255 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15256 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15257   echo "$as_me:$LINENO: checking for $ac_header" >&5
15258 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15259 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15260   echo $ECHO_N "(cached) $ECHO_C" >&6
15261 fi
15262 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15263 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15264 else
15265   # Is the header compilable?
15266 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15267 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15268 cat >conftest.$ac_ext <<_ACEOF
15269 #line $LINENO "configure"
15270 /* confdefs.h.  */
15271 _ACEOF
15272 cat confdefs.h >>conftest.$ac_ext
15273 cat >>conftest.$ac_ext <<_ACEOF
15274 /* end confdefs.h.  */
15275 $ac_includes_default
15276 #include <$ac_header>
15277 _ACEOF
15278 rm -f conftest.$ac_objext
15279 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15280   (eval $ac_compile) 2>&5
15281   ac_status=$?
15282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15283   (exit $ac_status); } &&
15284          { ac_try='test -s conftest.$ac_objext'
15285   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15286   (eval $ac_try) 2>&5
15287   ac_status=$?
15288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15289   (exit $ac_status); }; }; then
15290   ac_header_compiler=yes
15291 else
15292   echo "$as_me: failed program was:" >&5
15293 sed 's/^/| /' conftest.$ac_ext >&5
15294
15295 ac_header_compiler=no
15296 fi
15297 rm -f conftest.$ac_objext conftest.$ac_ext
15298 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15299 echo "${ECHO_T}$ac_header_compiler" >&6
15300
15301 # Is the header present?
15302 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15303 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15304 cat >conftest.$ac_ext <<_ACEOF
15305 #line $LINENO "configure"
15306 /* confdefs.h.  */
15307 _ACEOF
15308 cat confdefs.h >>conftest.$ac_ext
15309 cat >>conftest.$ac_ext <<_ACEOF
15310 /* end confdefs.h.  */
15311 #include <$ac_header>
15312 _ACEOF
15313 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15314   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15315   ac_status=$?
15316   grep -v '^ *+' conftest.er1 >conftest.err
15317   rm -f conftest.er1
15318   cat conftest.err >&5
15319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15320   (exit $ac_status); } >/dev/null; then
15321   if test -s conftest.err; then
15322     ac_cpp_err=$ac_c_preproc_warn_flag
15323   else
15324     ac_cpp_err=
15325   fi
15326 else
15327   ac_cpp_err=yes
15328 fi
15329 if test -z "$ac_cpp_err"; then
15330   ac_header_preproc=yes
15331 else
15332   echo "$as_me: failed program was:" >&5
15333 sed 's/^/| /' conftest.$ac_ext >&5
15334
15335   ac_header_preproc=no
15336 fi
15337 rm -f conftest.err conftest.$ac_ext
15338 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15339 echo "${ECHO_T}$ac_header_preproc" >&6
15340
15341 # So?  What about this header?
15342 case $ac_header_compiler:$ac_header_preproc in
15343   yes:no )
15344     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15345 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15346     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15347 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15348     (
15349       cat <<\_ASBOX
15350 ## ------------------------------------ ##
15351 ## Report this to bug-autoconf@gnu.org. ##
15352 ## ------------------------------------ ##
15353 _ASBOX
15354     ) |
15355       sed "s/^/$as_me: WARNING:     /" >&2
15356     ;;
15357   no:yes )
15358     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15359 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15360     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15361 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15362     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15363 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15364     (
15365       cat <<\_ASBOX
15366 ## ------------------------------------ ##
15367 ## Report this to bug-autoconf@gnu.org. ##
15368 ## ------------------------------------ ##
15369 _ASBOX
15370     ) |
15371       sed "s/^/$as_me: WARNING:     /" >&2
15372     ;;
15373 esac
15374 echo "$as_me:$LINENO: checking for $ac_header" >&5
15375 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15376 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15377   echo $ECHO_N "(cached) $ECHO_C" >&6
15378 else
15379   eval "$as_ac_Header=$ac_header_preproc"
15380 fi
15381 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15382 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15383
15384 fi
15385 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15386   cat >>confdefs.h <<_ACEOF
15387 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15388 _ACEOF
15389
15390 fi
15391
15392 done
15393
15394
15395         if test $ac_cv_header_krb5_h = yes ; then
15396
15397 for ac_header in heim_err.h
15398 do
15399 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15400 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15401   echo "$as_me:$LINENO: checking for $ac_header" >&5
15402 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15403 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15404   echo $ECHO_N "(cached) $ECHO_C" >&6
15405 fi
15406 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15407 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15408 else
15409   # Is the header compilable?
15410 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15411 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15412 cat >conftest.$ac_ext <<_ACEOF
15413 #line $LINENO "configure"
15414 /* confdefs.h.  */
15415 _ACEOF
15416 cat confdefs.h >>conftest.$ac_ext
15417 cat >>conftest.$ac_ext <<_ACEOF
15418 /* end confdefs.h.  */
15419 $ac_includes_default
15420 #include <$ac_header>
15421 _ACEOF
15422 rm -f conftest.$ac_objext
15423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15424   (eval $ac_compile) 2>&5
15425   ac_status=$?
15426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15427   (exit $ac_status); } &&
15428          { ac_try='test -s conftest.$ac_objext'
15429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15430   (eval $ac_try) 2>&5
15431   ac_status=$?
15432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15433   (exit $ac_status); }; }; then
15434   ac_header_compiler=yes
15435 else
15436   echo "$as_me: failed program was:" >&5
15437 sed 's/^/| /' conftest.$ac_ext >&5
15438
15439 ac_header_compiler=no
15440 fi
15441 rm -f conftest.$ac_objext conftest.$ac_ext
15442 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15443 echo "${ECHO_T}$ac_header_compiler" >&6
15444
15445 # Is the header present?
15446 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15447 echo $ECHO_N "checking $ac_header presence... $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 #include <$ac_header>
15456 _ACEOF
15457 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15458   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15459   ac_status=$?
15460   grep -v '^ *+' conftest.er1 >conftest.err
15461   rm -f conftest.er1
15462   cat conftest.err >&5
15463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15464   (exit $ac_status); } >/dev/null; then
15465   if test -s conftest.err; then
15466     ac_cpp_err=$ac_c_preproc_warn_flag
15467   else
15468     ac_cpp_err=
15469   fi
15470 else
15471   ac_cpp_err=yes
15472 fi
15473 if test -z "$ac_cpp_err"; then
15474   ac_header_preproc=yes
15475 else
15476   echo "$as_me: failed program was:" >&5
15477 sed 's/^/| /' conftest.$ac_ext >&5
15478
15479   ac_header_preproc=no
15480 fi
15481 rm -f conftest.err conftest.$ac_ext
15482 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15483 echo "${ECHO_T}$ac_header_preproc" >&6
15484
15485 # So?  What about this header?
15486 case $ac_header_compiler:$ac_header_preproc in
15487   yes:no )
15488     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15489 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15490     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15491 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15492     (
15493       cat <<\_ASBOX
15494 ## ------------------------------------ ##
15495 ## Report this to bug-autoconf@gnu.org. ##
15496 ## ------------------------------------ ##
15497 _ASBOX
15498     ) |
15499       sed "s/^/$as_me: WARNING:     /" >&2
15500     ;;
15501   no:yes )
15502     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15503 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15504     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15505 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15506     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15507 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15508     (
15509       cat <<\_ASBOX
15510 ## ------------------------------------ ##
15511 ## Report this to bug-autoconf@gnu.org. ##
15512 ## ------------------------------------ ##
15513 _ASBOX
15514     ) |
15515       sed "s/^/$as_me: WARNING:     /" >&2
15516     ;;
15517 esac
15518 echo "$as_me:$LINENO: checking for $ac_header" >&5
15519 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15520 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15521   echo $ECHO_N "(cached) $ECHO_C" >&6
15522 else
15523   eval "$as_ac_Header=$ac_header_preproc"
15524 fi
15525 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15526 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15527
15528 fi
15529 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15530   cat >>confdefs.h <<_ACEOF
15531 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15532 _ACEOF
15533
15534 fi
15535
15536 done
15537
15538                 if test $ac_cv_header_heim_err_h = yes ; then
15539                         krb5_impl=heimdal
15540                 else
15541                         krb5_impl=mit
15542                 fi
15543
15544                 if test $krb5_impl = mit; then
15545                         echo "$as_me:$LINENO: checking for main in -lk5crypto" >&5
15546 echo $ECHO_N "checking for main in -lk5crypto... $ECHO_C" >&6
15547 if test "${ac_cv_lib_k5crypto_main+set}" = set; then
15548   echo $ECHO_N "(cached) $ECHO_C" >&6
15549 else
15550   ac_check_lib_save_LIBS=$LIBS
15551 LIBS="-lk5crypto  $LIBS"
15552 cat >conftest.$ac_ext <<_ACEOF
15553 #line $LINENO "configure"
15554 /* confdefs.h.  */
15555 _ACEOF
15556 cat confdefs.h >>conftest.$ac_ext
15557 cat >>conftest.$ac_ext <<_ACEOF
15558 /* end confdefs.h.  */
15559
15560
15561 int
15562 main ()
15563 {
15564 main ();
15565   ;
15566   return 0;
15567 }
15568 _ACEOF
15569 rm -f conftest.$ac_objext conftest$ac_exeext
15570 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15571   (eval $ac_link) 2>&5
15572   ac_status=$?
15573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15574   (exit $ac_status); } &&
15575          { ac_try='test -s conftest$ac_exeext'
15576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15577   (eval $ac_try) 2>&5
15578   ac_status=$?
15579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15580   (exit $ac_status); }; }; then
15581   ac_cv_lib_k5crypto_main=yes
15582 else
15583   echo "$as_me: failed program was:" >&5
15584 sed 's/^/| /' conftest.$ac_ext >&5
15585
15586 ac_cv_lib_k5crypto_main=no
15587 fi
15588 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15589 LIBS=$ac_check_lib_save_LIBS
15590 fi
15591 echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_main" >&5
15592 echo "${ECHO_T}$ac_cv_lib_k5crypto_main" >&6
15593 if test $ac_cv_lib_k5crypto_main = yes; then
15594   krb5crypto=k5crypto
15595 else
15596   krb5crypto=crypto
15597 fi
15598
15599
15600                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
15601 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
15602 if test "${ac_cv_lib_krb5_main+set}" = set; then
15603   echo $ECHO_N "(cached) $ECHO_C" >&6
15604 else
15605   ac_check_lib_save_LIBS=$LIBS
15606 LIBS="-lkrb5 -l$krb5crypto -lcom_err $LIBS"
15607 cat >conftest.$ac_ext <<_ACEOF
15608 #line $LINENO "configure"
15609 /* confdefs.h.  */
15610 _ACEOF
15611 cat confdefs.h >>conftest.$ac_ext
15612 cat >>conftest.$ac_ext <<_ACEOF
15613 /* end confdefs.h.  */
15614
15615
15616 int
15617 main ()
15618 {
15619 main ();
15620   ;
15621   return 0;
15622 }
15623 _ACEOF
15624 rm -f conftest.$ac_objext conftest$ac_exeext
15625 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15626   (eval $ac_link) 2>&5
15627   ac_status=$?
15628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15629   (exit $ac_status); } &&
15630          { ac_try='test -s conftest$ac_exeext'
15631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15632   (eval $ac_try) 2>&5
15633   ac_status=$?
15634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15635   (exit $ac_status); }; }; then
15636   ac_cv_lib_krb5_main=yes
15637 else
15638   echo "$as_me: failed program was:" >&5
15639 sed 's/^/| /' conftest.$ac_ext >&5
15640
15641 ac_cv_lib_krb5_main=no
15642 fi
15643 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15644 LIBS=$ac_check_lib_save_LIBS
15645 fi
15646 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
15647 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
15648 if test $ac_cv_lib_krb5_main = yes; then
15649   have_krb5=yes
15650                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lcom_err"
15651 else
15652   have_krb5=no
15653 fi
15654
15655
15656                 elif test $krb5_impl = heimdal; then
15657                         echo "$as_me:$LINENO: checking for main in -ldes" >&5
15658 echo $ECHO_N "checking for main in -ldes... $ECHO_C" >&6
15659 if test "${ac_cv_lib_des_main+set}" = set; then
15660   echo $ECHO_N "(cached) $ECHO_C" >&6
15661 else
15662   ac_check_lib_save_LIBS=$LIBS
15663 LIBS="-ldes  $LIBS"
15664 cat >conftest.$ac_ext <<_ACEOF
15665 #line $LINENO "configure"
15666 /* confdefs.h.  */
15667 _ACEOF
15668 cat confdefs.h >>conftest.$ac_ext
15669 cat >>conftest.$ac_ext <<_ACEOF
15670 /* end confdefs.h.  */
15671
15672
15673 int
15674 main ()
15675 {
15676 main ();
15677   ;
15678   return 0;
15679 }
15680 _ACEOF
15681 rm -f conftest.$ac_objext conftest$ac_exeext
15682 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15683   (eval $ac_link) 2>&5
15684   ac_status=$?
15685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15686   (exit $ac_status); } &&
15687          { ac_try='test -s conftest$ac_exeext'
15688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15689   (eval $ac_try) 2>&5
15690   ac_status=$?
15691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15692   (exit $ac_status); }; }; then
15693   ac_cv_lib_des_main=yes
15694 else
15695   echo "$as_me: failed program was:" >&5
15696 sed 's/^/| /' conftest.$ac_ext >&5
15697
15698 ac_cv_lib_des_main=no
15699 fi
15700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15701 LIBS=$ac_check_lib_save_LIBS
15702 fi
15703 echo "$as_me:$LINENO: result: $ac_cv_lib_des_main" >&5
15704 echo "${ECHO_T}$ac_cv_lib_des_main" >&6
15705 if test $ac_cv_lib_des_main = yes; then
15706   krb5crypto=des
15707 else
15708   krb5crypto=crypto
15709 fi
15710
15711
15712                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
15713 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
15714 if test "${ac_cv_lib_krb5_main+set}" = set; then
15715   echo $ECHO_N "(cached) $ECHO_C" >&6
15716 else
15717   ac_check_lib_save_LIBS=$LIBS
15718 LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
15719 cat >conftest.$ac_ext <<_ACEOF
15720 #line $LINENO "configure"
15721 /* confdefs.h.  */
15722 _ACEOF
15723 cat confdefs.h >>conftest.$ac_ext
15724 cat >>conftest.$ac_ext <<_ACEOF
15725 /* end confdefs.h.  */
15726
15727
15728 int
15729 main ()
15730 {
15731 main ();
15732   ;
15733   return 0;
15734 }
15735 _ACEOF
15736 rm -f conftest.$ac_objext conftest$ac_exeext
15737 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15738   (eval $ac_link) 2>&5
15739   ac_status=$?
15740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15741   (exit $ac_status); } &&
15742          { ac_try='test -s conftest$ac_exeext'
15743   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15744   (eval $ac_try) 2>&5
15745   ac_status=$?
15746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15747   (exit $ac_status); }; }; then
15748   ac_cv_lib_krb5_main=yes
15749 else
15750   echo "$as_me: failed program was:" >&5
15751 sed 's/^/| /' conftest.$ac_ext >&5
15752
15753 ac_cv_lib_krb5_main=no
15754 fi
15755 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15756 LIBS=$ac_check_lib_save_LIBS
15757 fi
15758 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
15759 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
15760 if test $ac_cv_lib_krb5_main = yes; then
15761   have_krb5=yes
15762                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err"
15763 else
15764   have_krb5=no
15765 fi
15766
15767
15768
15769 cat >>confdefs.h <<\_ACEOF
15770 #define HAVE_HEIMDAL_KERBEROS 1
15771 _ACEOF
15772
15773
15774                 else
15775                         have_krb5=no
15776                         { echo "$as_me:$LINENO: WARNING: Unrecognized Kerberos5 Implementation" >&5
15777 echo "$as_me: WARNING: Unrecognized Kerberos5 Implementation" >&2;}
15778                 fi
15779
15780                 if test $have_krb5 = yes ; then
15781                         ol_link_krb5=yes
15782
15783
15784 cat >>confdefs.h <<\_ACEOF
15785 #define HAVE_KRB5 1
15786 _ACEOF
15787
15788
15789                         if test $ol_enable_kpasswd != no ; then
15790                                 ol_link_kpasswd=yes;
15791                         fi
15792
15793                         if test $ol_with_kerberos = k5only ; then
15794                                 ol_with_kerberos=found
15795                         fi
15796
15797                 elif test $ol_with_kerberos != auto ; then
15798                         { { echo "$as_me:$LINENO: error: Required Kerberos 5 support not available" >&5
15799 echo "$as_me: error: Required Kerberos 5 support not available" >&2;}
15800    { (exit 1); exit 1; }; }
15801                 fi
15802
15803         fi
15804 fi
15805
15806 if test $ol_link_krb5 = yes -a \( $ol_with_kerberos = yes -o \
15807         $ol_with_kerberos = auto -o $ol_with_kerberos = k425 \) ; then
15808
15809
15810
15811 for ac_header in kerberosIV/krb.h kerberosIV/des.h
15812 do
15813 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15814 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15815   echo "$as_me:$LINENO: checking for $ac_header" >&5
15816 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15817 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15818   echo $ECHO_N "(cached) $ECHO_C" >&6
15819 fi
15820 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15821 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15822 else
15823   # Is the header compilable?
15824 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15825 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15826 cat >conftest.$ac_ext <<_ACEOF
15827 #line $LINENO "configure"
15828 /* confdefs.h.  */
15829 _ACEOF
15830 cat confdefs.h >>conftest.$ac_ext
15831 cat >>conftest.$ac_ext <<_ACEOF
15832 /* end confdefs.h.  */
15833 $ac_includes_default
15834 #include <$ac_header>
15835 _ACEOF
15836 rm -f conftest.$ac_objext
15837 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15838   (eval $ac_compile) 2>&5
15839   ac_status=$?
15840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15841   (exit $ac_status); } &&
15842          { ac_try='test -s conftest.$ac_objext'
15843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15844   (eval $ac_try) 2>&5
15845   ac_status=$?
15846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15847   (exit $ac_status); }; }; then
15848   ac_header_compiler=yes
15849 else
15850   echo "$as_me: failed program was:" >&5
15851 sed 's/^/| /' conftest.$ac_ext >&5
15852
15853 ac_header_compiler=no
15854 fi
15855 rm -f conftest.$ac_objext conftest.$ac_ext
15856 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15857 echo "${ECHO_T}$ac_header_compiler" >&6
15858
15859 # Is the header present?
15860 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15861 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15862 cat >conftest.$ac_ext <<_ACEOF
15863 #line $LINENO "configure"
15864 /* confdefs.h.  */
15865 _ACEOF
15866 cat confdefs.h >>conftest.$ac_ext
15867 cat >>conftest.$ac_ext <<_ACEOF
15868 /* end confdefs.h.  */
15869 #include <$ac_header>
15870 _ACEOF
15871 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15872   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15873   ac_status=$?
15874   grep -v '^ *+' conftest.er1 >conftest.err
15875   rm -f conftest.er1
15876   cat conftest.err >&5
15877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15878   (exit $ac_status); } >/dev/null; then
15879   if test -s conftest.err; then
15880     ac_cpp_err=$ac_c_preproc_warn_flag
15881   else
15882     ac_cpp_err=
15883   fi
15884 else
15885   ac_cpp_err=yes
15886 fi
15887 if test -z "$ac_cpp_err"; then
15888   ac_header_preproc=yes
15889 else
15890   echo "$as_me: failed program was:" >&5
15891 sed 's/^/| /' conftest.$ac_ext >&5
15892
15893   ac_header_preproc=no
15894 fi
15895 rm -f conftest.err conftest.$ac_ext
15896 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15897 echo "${ECHO_T}$ac_header_preproc" >&6
15898
15899 # So?  What about this header?
15900 case $ac_header_compiler:$ac_header_preproc in
15901   yes:no )
15902     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15903 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15904     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15905 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15906     (
15907       cat <<\_ASBOX
15908 ## ------------------------------------ ##
15909 ## Report this to bug-autoconf@gnu.org. ##
15910 ## ------------------------------------ ##
15911 _ASBOX
15912     ) |
15913       sed "s/^/$as_me: WARNING:     /" >&2
15914     ;;
15915   no:yes )
15916     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15917 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15918     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15919 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15920     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15921 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15922     (
15923       cat <<\_ASBOX
15924 ## ------------------------------------ ##
15925 ## Report this to bug-autoconf@gnu.org. ##
15926 ## ------------------------------------ ##
15927 _ASBOX
15928     ) |
15929       sed "s/^/$as_me: WARNING:     /" >&2
15930     ;;
15931 esac
15932 echo "$as_me:$LINENO: checking for $ac_header" >&5
15933 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15934 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15935   echo $ECHO_N "(cached) $ECHO_C" >&6
15936 else
15937   eval "$as_ac_Header=$ac_header_preproc"
15938 fi
15939 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15940 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15941
15942 fi
15943 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15944   cat >>confdefs.h <<_ACEOF
15945 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15946 _ACEOF
15947
15948 fi
15949
15950 done
15951
15952
15953         if test $ac_cv_header_kerberosIV_krb_h = yes ; then
15954                 if test $krb5_impl = mit; then
15955                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
15956 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
15957 if test "${ac_cv_lib_krb4_main+set}" = set; then
15958   echo $ECHO_N "(cached) $ECHO_C" >&6
15959 else
15960   ac_check_lib_save_LIBS=$LIBS
15961 LIBS="-lkrb4 -ldes425 -lkrb5 -l$krb5crypto -lcom_err $LIBS"
15962 cat >conftest.$ac_ext <<_ACEOF
15963 #line $LINENO "configure"
15964 /* confdefs.h.  */
15965 _ACEOF
15966 cat confdefs.h >>conftest.$ac_ext
15967 cat >>conftest.$ac_ext <<_ACEOF
15968 /* end confdefs.h.  */
15969
15970
15971 int
15972 main ()
15973 {
15974 main ();
15975   ;
15976   return 0;
15977 }
15978 _ACEOF
15979 rm -f conftest.$ac_objext conftest$ac_exeext
15980 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15981   (eval $ac_link) 2>&5
15982   ac_status=$?
15983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15984   (exit $ac_status); } &&
15985          { ac_try='test -s conftest$ac_exeext'
15986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15987   (eval $ac_try) 2>&5
15988   ac_status=$?
15989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15990   (exit $ac_status); }; }; then
15991   ac_cv_lib_krb4_main=yes
15992 else
15993   echo "$as_me: failed program was:" >&5
15994 sed 's/^/| /' conftest.$ac_ext >&5
15995
15996 ac_cv_lib_krb4_main=no
15997 fi
15998 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15999 LIBS=$ac_check_lib_save_LIBS
16000 fi
16001 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
16002 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
16003 if test $ac_cv_lib_krb4_main = yes; then
16004   have_k425=yes
16005                                 KRB4_LIBS="-lkrb4 -ldes425"
16006 else
16007   have_k425=no
16008 fi
16009
16010
16011                 elif test $krb5_impl = heimdal; then
16012                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
16013 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
16014 if test "${ac_cv_lib_krb4_main+set}" = set; then
16015   echo $ECHO_N "(cached) $ECHO_C" >&6
16016 else
16017   ac_check_lib_save_LIBS=$LIBS
16018 LIBS="-lkrb4 -lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
16019 cat >conftest.$ac_ext <<_ACEOF
16020 #line $LINENO "configure"
16021 /* confdefs.h.  */
16022 _ACEOF
16023 cat confdefs.h >>conftest.$ac_ext
16024 cat >>conftest.$ac_ext <<_ACEOF
16025 /* end confdefs.h.  */
16026
16027
16028 int
16029 main ()
16030 {
16031 main ();
16032   ;
16033   return 0;
16034 }
16035 _ACEOF
16036 rm -f conftest.$ac_objext conftest$ac_exeext
16037 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16038   (eval $ac_link) 2>&5
16039   ac_status=$?
16040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16041   (exit $ac_status); } &&
16042          { ac_try='test -s conftest$ac_exeext'
16043   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16044   (eval $ac_try) 2>&5
16045   ac_status=$?
16046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16047   (exit $ac_status); }; }; then
16048   ac_cv_lib_krb4_main=yes
16049 else
16050   echo "$as_me: failed program was:" >&5
16051 sed 's/^/| /' conftest.$ac_ext >&5
16052
16053 ac_cv_lib_krb4_main=no
16054 fi
16055 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16056 LIBS=$ac_check_lib_save_LIBS
16057 fi
16058 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
16059 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
16060 if test $ac_cv_lib_krb4_main = yes; then
16061   have_k425=yes
16062                                 KRB4_LIBS="-lkrb4"
16063 else
16064   have_k425=no
16065 fi
16066
16067
16068                 else
16069                         have_425=no
16070                         { echo "$as_me:$LINENO: WARNING: Unrecongized Kerberos V Implementation" >&5
16071 echo "$as_me: WARNING: Unrecongized Kerberos V Implementation" >&2;}
16072                 fi
16073
16074                 if test $have_k425 = yes ; then
16075                         ol_with_kerberos=found
16076                         ol_link_krb4=yes
16077
16078
16079 cat >>confdefs.h <<\_ACEOF
16080 #define HAVE_KRB425 1
16081 _ACEOF
16082
16083
16084 cat >>confdefs.h <<\_ACEOF
16085 #define HAVE_KRB4 1
16086 _ACEOF
16087
16088
16089                         echo "$as_me:$LINENO: checking for des_debug in Kerberos libraries" >&5
16090 echo $ECHO_N "checking for des_debug in Kerberos libraries... $ECHO_C" >&6
16091 if test "${ol_cv_var_des_debug+set}" = set; then
16092   echo $ECHO_N "(cached) $ECHO_C" >&6
16093 else
16094
16095                                                                 save_LIBS="$LIBS"
16096                                 LIBS="$KRB4_LIBS $KRB5_LIBS $LIBS"
16097                                 cat >conftest.$ac_ext <<_ACEOF
16098 #line $LINENO "configure"
16099 /* confdefs.h.  */
16100 _ACEOF
16101 cat confdefs.h >>conftest.$ac_ext
16102 cat >>conftest.$ac_ext <<_ACEOF
16103 /* end confdefs.h.  */
16104
16105 #include <kerberosIV/krb.h>
16106 #include <kerberosIV/des.h>
16107 extern int des_debug;
16108
16109 int
16110 main ()
16111 {
16112
16113 des_debug = 1;
16114
16115   ;
16116   return 0;
16117 }
16118 _ACEOF
16119 rm -f conftest.$ac_objext conftest$ac_exeext
16120 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16121   (eval $ac_link) 2>&5
16122   ac_status=$?
16123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16124   (exit $ac_status); } &&
16125          { ac_try='test -s conftest$ac_exeext'
16126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16127   (eval $ac_try) 2>&5
16128   ac_status=$?
16129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16130   (exit $ac_status); }; }; then
16131   ol_cv_var_des_debug=yes
16132 else
16133   echo "$as_me: failed program was:" >&5
16134 sed 's/^/| /' conftest.$ac_ext >&5
16135
16136 ol_cv_var_des_debug=no
16137 fi
16138 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16139                                                                 LIBS="$save_LIBS"
16140
16141 fi
16142 echo "$as_me:$LINENO: result: $ol_cv_var_des_debug" >&5
16143 echo "${ECHO_T}$ol_cv_var_des_debug" >&6
16144
16145                         if test $ol_cv_var_des_debug = yes ; then
16146
16147 cat >>confdefs.h <<\_ACEOF
16148 #define HAVE_DES_DEBUG 1
16149 _ACEOF
16150
16151                         fi
16152
16153                         LIBS="$save_LIBS"
16154                 fi
16155         fi
16156 fi
16157
16158 if test $ol_link_krb5 = yes ; then
16159         ol_with_kerberos=found
16160 fi
16161
16162 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
16163         -o $ol_with_kerberos = k4 -o $ol_with_kerberos = kth ; then
16164
16165
16166
16167
16168 for ac_header in krb.h des.h krb-archaeology.h
16169 do
16170 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16171 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16172   echo "$as_me:$LINENO: checking for $ac_header" >&5
16173 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16174 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16175   echo $ECHO_N "(cached) $ECHO_C" >&6
16176 fi
16177 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16178 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16179 else
16180   # Is the header compilable?
16181 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16182 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16183 cat >conftest.$ac_ext <<_ACEOF
16184 #line $LINENO "configure"
16185 /* confdefs.h.  */
16186 _ACEOF
16187 cat confdefs.h >>conftest.$ac_ext
16188 cat >>conftest.$ac_ext <<_ACEOF
16189 /* end confdefs.h.  */
16190 $ac_includes_default
16191 #include <$ac_header>
16192 _ACEOF
16193 rm -f conftest.$ac_objext
16194 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16195   (eval $ac_compile) 2>&5
16196   ac_status=$?
16197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16198   (exit $ac_status); } &&
16199          { ac_try='test -s conftest.$ac_objext'
16200   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16201   (eval $ac_try) 2>&5
16202   ac_status=$?
16203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16204   (exit $ac_status); }; }; then
16205   ac_header_compiler=yes
16206 else
16207   echo "$as_me: failed program was:" >&5
16208 sed 's/^/| /' conftest.$ac_ext >&5
16209
16210 ac_header_compiler=no
16211 fi
16212 rm -f conftest.$ac_objext conftest.$ac_ext
16213 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16214 echo "${ECHO_T}$ac_header_compiler" >&6
16215
16216 # Is the header present?
16217 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16218 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16219 cat >conftest.$ac_ext <<_ACEOF
16220 #line $LINENO "configure"
16221 /* confdefs.h.  */
16222 _ACEOF
16223 cat confdefs.h >>conftest.$ac_ext
16224 cat >>conftest.$ac_ext <<_ACEOF
16225 /* end confdefs.h.  */
16226 #include <$ac_header>
16227 _ACEOF
16228 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16229   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16230   ac_status=$?
16231   grep -v '^ *+' conftest.er1 >conftest.err
16232   rm -f conftest.er1
16233   cat conftest.err >&5
16234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16235   (exit $ac_status); } >/dev/null; then
16236   if test -s conftest.err; then
16237     ac_cpp_err=$ac_c_preproc_warn_flag
16238   else
16239     ac_cpp_err=
16240   fi
16241 else
16242   ac_cpp_err=yes
16243 fi
16244 if test -z "$ac_cpp_err"; then
16245   ac_header_preproc=yes
16246 else
16247   echo "$as_me: failed program was:" >&5
16248 sed 's/^/| /' conftest.$ac_ext >&5
16249
16250   ac_header_preproc=no
16251 fi
16252 rm -f conftest.err conftest.$ac_ext
16253 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16254 echo "${ECHO_T}$ac_header_preproc" >&6
16255
16256 # So?  What about this header?
16257 case $ac_header_compiler:$ac_header_preproc in
16258   yes:no )
16259     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16260 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16261     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16262 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16263     (
16264       cat <<\_ASBOX
16265 ## ------------------------------------ ##
16266 ## Report this to bug-autoconf@gnu.org. ##
16267 ## ------------------------------------ ##
16268 _ASBOX
16269     ) |
16270       sed "s/^/$as_me: WARNING:     /" >&2
16271     ;;
16272   no:yes )
16273     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16274 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16275     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16276 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16277     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16278 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16279     (
16280       cat <<\_ASBOX
16281 ## ------------------------------------ ##
16282 ## Report this to bug-autoconf@gnu.org. ##
16283 ## ------------------------------------ ##
16284 _ASBOX
16285     ) |
16286       sed "s/^/$as_me: WARNING:     /" >&2
16287     ;;
16288 esac
16289 echo "$as_me:$LINENO: checking for $ac_header" >&5
16290 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16291 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16292   echo $ECHO_N "(cached) $ECHO_C" >&6
16293 else
16294   eval "$as_ac_Header=$ac_header_preproc"
16295 fi
16296 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16297 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16298
16299 fi
16300 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16301   cat >>confdefs.h <<_ACEOF
16302 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16303 _ACEOF
16304
16305 fi
16306
16307 done
16308
16309
16310         if test $ac_cv_header_krb_h = yes ; then
16311                 echo "$as_me:$LINENO: checking for main in -lkrb" >&5
16312 echo $ECHO_N "checking for main in -lkrb... $ECHO_C" >&6
16313 if test "${ac_cv_lib_krb_main+set}" = set; then
16314   echo $ECHO_N "(cached) $ECHO_C" >&6
16315 else
16316   ac_check_lib_save_LIBS=$LIBS
16317 LIBS="-lkrb -ldes $LIBS"
16318 cat >conftest.$ac_ext <<_ACEOF
16319 #line $LINENO "configure"
16320 /* confdefs.h.  */
16321 _ACEOF
16322 cat confdefs.h >>conftest.$ac_ext
16323 cat >>conftest.$ac_ext <<_ACEOF
16324 /* end confdefs.h.  */
16325
16326
16327 int
16328 main ()
16329 {
16330 main ();
16331   ;
16332   return 0;
16333 }
16334 _ACEOF
16335 rm -f conftest.$ac_objext conftest$ac_exeext
16336 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16337   (eval $ac_link) 2>&5
16338   ac_status=$?
16339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16340   (exit $ac_status); } &&
16341          { ac_try='test -s conftest$ac_exeext'
16342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16343   (eval $ac_try) 2>&5
16344   ac_status=$?
16345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16346   (exit $ac_status); }; }; then
16347   ac_cv_lib_krb_main=yes
16348 else
16349   echo "$as_me: failed program was:" >&5
16350 sed 's/^/| /' conftest.$ac_ext >&5
16351
16352 ac_cv_lib_krb_main=no
16353 fi
16354 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16355 LIBS=$ac_check_lib_save_LIBS
16356 fi
16357 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_main" >&5
16358 echo "${ECHO_T}$ac_cv_lib_krb_main" >&6
16359 if test $ac_cv_lib_krb_main = yes; then
16360   have_k4=yes
16361 else
16362   have_k4=no
16363 fi
16364
16365
16366                 if test $have_k4 = yes ; then
16367                         ol_with_kerberos=found
16368                         ol_link_krb4=yes
16369
16370
16371 cat >>confdefs.h <<\_ACEOF
16372 #define HAVE_KRB4 1
16373 _ACEOF
16374
16375
16376                         KRB4_LIBS="-lkrb -ldes"
16377
16378                         if test $ac_cv_header_krb_archaeology_h = yes ; then
16379
16380 cat >>confdefs.h <<\_ACEOF
16381 #define HAVE_KTH_KERBEROS 1
16382 _ACEOF
16383
16384                         fi
16385                 fi
16386         fi
16387 fi
16388
16389 if test $ol_link_krb4 = yes -a $ol_enable_kpasswd != no ; then
16390         ol_link_kpasswd=yes
16391 fi
16392
16393 if test $ol_link_krb4 = yes -a $ol_enable_kbind != no ; then
16394         ol_link_kbind=yes
16395
16396 elif test $ol_enable_kbind = yes ; then
16397         { { echo "$as_me:$LINENO: error: Kerberos IV detection failed" >&5
16398 echo "$as_me: error: Kerberos IV detection failed" >&2;}
16399    { (exit 1); exit 1; }; }
16400 fi
16401
16402 if test $ol_link_krb4 = yes -o $ol_link_krb5 = yes ; then
16403
16404 cat >>confdefs.h <<\_ACEOF
16405 #define HAVE_KERBEROS 1
16406 _ACEOF
16407
16408
16409 elif test $ol_with_kerberos != auto -a $ol_with_kerberos != no ; then
16410         { { echo "$as_me:$LINENO: error: Kerberos detection failed" >&5
16411 echo "$as_me: error: Kerberos detection failed" >&2;}
16412    { (exit 1); exit 1; }; }
16413 fi
16414
16415 ol_link_tls=no
16416 if test $ol_with_tls != no ; then
16417
16418
16419 for ac_header in openssl/ssl.h ssl.h
16420 do
16421 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16422 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16423   echo "$as_me:$LINENO: checking for $ac_header" >&5
16424 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16425 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16426   echo $ECHO_N "(cached) $ECHO_C" >&6
16427 fi
16428 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16429 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16430 else
16431   # Is the header compilable?
16432 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16433 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16434 cat >conftest.$ac_ext <<_ACEOF
16435 #line $LINENO "configure"
16436 /* confdefs.h.  */
16437 _ACEOF
16438 cat confdefs.h >>conftest.$ac_ext
16439 cat >>conftest.$ac_ext <<_ACEOF
16440 /* end confdefs.h.  */
16441 $ac_includes_default
16442 #include <$ac_header>
16443 _ACEOF
16444 rm -f conftest.$ac_objext
16445 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16446   (eval $ac_compile) 2>&5
16447   ac_status=$?
16448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16449   (exit $ac_status); } &&
16450          { ac_try='test -s conftest.$ac_objext'
16451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16452   (eval $ac_try) 2>&5
16453   ac_status=$?
16454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16455   (exit $ac_status); }; }; then
16456   ac_header_compiler=yes
16457 else
16458   echo "$as_me: failed program was:" >&5
16459 sed 's/^/| /' conftest.$ac_ext >&5
16460
16461 ac_header_compiler=no
16462 fi
16463 rm -f conftest.$ac_objext conftest.$ac_ext
16464 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16465 echo "${ECHO_T}$ac_header_compiler" >&6
16466
16467 # Is the header present?
16468 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16469 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16470 cat >conftest.$ac_ext <<_ACEOF
16471 #line $LINENO "configure"
16472 /* confdefs.h.  */
16473 _ACEOF
16474 cat confdefs.h >>conftest.$ac_ext
16475 cat >>conftest.$ac_ext <<_ACEOF
16476 /* end confdefs.h.  */
16477 #include <$ac_header>
16478 _ACEOF
16479 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16480   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16481   ac_status=$?
16482   grep -v '^ *+' conftest.er1 >conftest.err
16483   rm -f conftest.er1
16484   cat conftest.err >&5
16485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16486   (exit $ac_status); } >/dev/null; then
16487   if test -s conftest.err; then
16488     ac_cpp_err=$ac_c_preproc_warn_flag
16489   else
16490     ac_cpp_err=
16491   fi
16492 else
16493   ac_cpp_err=yes
16494 fi
16495 if test -z "$ac_cpp_err"; then
16496   ac_header_preproc=yes
16497 else
16498   echo "$as_me: failed program was:" >&5
16499 sed 's/^/| /' conftest.$ac_ext >&5
16500
16501   ac_header_preproc=no
16502 fi
16503 rm -f conftest.err conftest.$ac_ext
16504 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16505 echo "${ECHO_T}$ac_header_preproc" >&6
16506
16507 # So?  What about this header?
16508 case $ac_header_compiler:$ac_header_preproc in
16509   yes:no )
16510     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16511 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16512     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16513 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16514     (
16515       cat <<\_ASBOX
16516 ## ------------------------------------ ##
16517 ## Report this to bug-autoconf@gnu.org. ##
16518 ## ------------------------------------ ##
16519 _ASBOX
16520     ) |
16521       sed "s/^/$as_me: WARNING:     /" >&2
16522     ;;
16523   no:yes )
16524     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16525 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16526     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16527 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16528     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16529 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16530     (
16531       cat <<\_ASBOX
16532 ## ------------------------------------ ##
16533 ## Report this to bug-autoconf@gnu.org. ##
16534 ## ------------------------------------ ##
16535 _ASBOX
16536     ) |
16537       sed "s/^/$as_me: WARNING:     /" >&2
16538     ;;
16539 esac
16540 echo "$as_me:$LINENO: checking for $ac_header" >&5
16541 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16542 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16543   echo $ECHO_N "(cached) $ECHO_C" >&6
16544 else
16545   eval "$as_ac_Header=$ac_header_preproc"
16546 fi
16547 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16548 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16549
16550 fi
16551 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16552   cat >>confdefs.h <<_ACEOF
16553 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16554 _ACEOF
16555
16556 fi
16557
16558 done
16559
16560
16561         if test $ac_cv_header_openssl_ssl_h = yes \
16562                 -o $ac_cv_header_ssl_h = yes ; then
16563                 echo "$as_me:$LINENO: checking for SSLeay_add_ssl_algorithms in -lssl" >&5
16564 echo $ECHO_N "checking for SSLeay_add_ssl_algorithms in -lssl... $ECHO_C" >&6
16565 if test "${ac_cv_lib_ssl_SSLeay_add_ssl_algorithms+set}" = set; then
16566   echo $ECHO_N "(cached) $ECHO_C" >&6
16567 else
16568   ac_check_lib_save_LIBS=$LIBS
16569 LIBS="-lssl -lcrypto $LIBS"
16570 cat >conftest.$ac_ext <<_ACEOF
16571 #line $LINENO "configure"
16572 /* confdefs.h.  */
16573 _ACEOF
16574 cat confdefs.h >>conftest.$ac_ext
16575 cat >>conftest.$ac_ext <<_ACEOF
16576 /* end confdefs.h.  */
16577
16578 /* Override any gcc2 internal prototype to avoid an error.  */
16579 #ifdef __cplusplus
16580 extern "C"
16581 #endif
16582 /* We use char because int might match the return type of a gcc2
16583    builtin and then its argument prototype would still apply.  */
16584 char SSLeay_add_ssl_algorithms ();
16585 int
16586 main ()
16587 {
16588 SSLeay_add_ssl_algorithms ();
16589   ;
16590   return 0;
16591 }
16592 _ACEOF
16593 rm -f conftest.$ac_objext conftest$ac_exeext
16594 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16595   (eval $ac_link) 2>&5
16596   ac_status=$?
16597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16598   (exit $ac_status); } &&
16599          { ac_try='test -s conftest$ac_exeext'
16600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16601   (eval $ac_try) 2>&5
16602   ac_status=$?
16603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16604   (exit $ac_status); }; }; then
16605   ac_cv_lib_ssl_SSLeay_add_ssl_algorithms=yes
16606 else
16607   echo "$as_me: failed program was:" >&5
16608 sed 's/^/| /' conftest.$ac_ext >&5
16609
16610 ac_cv_lib_ssl_SSLeay_add_ssl_algorithms=no
16611 fi
16612 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16613 LIBS=$ac_check_lib_save_LIBS
16614 fi
16615 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSLeay_add_ssl_algorithms" >&5
16616 echo "${ECHO_T}$ac_cv_lib_ssl_SSLeay_add_ssl_algorithms" >&6
16617 if test $ac_cv_lib_ssl_SSLeay_add_ssl_algorithms = yes; then
16618   have_ssleay=yes
16619                         need_rsaref=no
16620 else
16621   have_ssleay=no
16622 fi
16623
16624
16625                 if test $have_ssleay = no ; then
16626                         echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
16627 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
16628 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
16629   echo $ECHO_N "(cached) $ECHO_C" >&6
16630 else
16631   ac_check_lib_save_LIBS=$LIBS
16632 LIBS="-lssl -lcrypto $LIBS"
16633 cat >conftest.$ac_ext <<_ACEOF
16634 #line $LINENO "configure"
16635 /* confdefs.h.  */
16636 _ACEOF
16637 cat confdefs.h >>conftest.$ac_ext
16638 cat >>conftest.$ac_ext <<_ACEOF
16639 /* end confdefs.h.  */
16640
16641 /* Override any gcc2 internal prototype to avoid an error.  */
16642 #ifdef __cplusplus
16643 extern "C"
16644 #endif
16645 /* We use char because int might match the return type of a gcc2
16646    builtin and then its argument prototype would still apply.  */
16647 char SSL_library_init ();
16648 int
16649 main ()
16650 {
16651 SSL_library_init ();
16652   ;
16653   return 0;
16654 }
16655 _ACEOF
16656 rm -f conftest.$ac_objext conftest$ac_exeext
16657 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16658   (eval $ac_link) 2>&5
16659   ac_status=$?
16660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16661   (exit $ac_status); } &&
16662          { ac_try='test -s conftest$ac_exeext'
16663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16664   (eval $ac_try) 2>&5
16665   ac_status=$?
16666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16667   (exit $ac_status); }; }; then
16668   ac_cv_lib_ssl_SSL_library_init=yes
16669 else
16670   echo "$as_me: failed program was:" >&5
16671 sed 's/^/| /' conftest.$ac_ext >&5
16672
16673 ac_cv_lib_ssl_SSL_library_init=no
16674 fi
16675 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16676 LIBS=$ac_check_lib_save_LIBS
16677 fi
16678 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
16679 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
16680 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
16681   have_ssleay=yes
16682                                 need_rsaref=no
16683 else
16684   have_ssleay=no
16685 fi
16686
16687                 fi
16688
16689                 if test $have_ssleay = no ; then
16690                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
16691 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
16692 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
16693   echo $ECHO_N "(cached) $ECHO_C" >&6
16694 else
16695   ac_check_lib_save_LIBS=$LIBS
16696 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
16697 cat >conftest.$ac_ext <<_ACEOF
16698 #line $LINENO "configure"
16699 /* confdefs.h.  */
16700 _ACEOF
16701 cat confdefs.h >>conftest.$ac_ext
16702 cat >>conftest.$ac_ext <<_ACEOF
16703 /* end confdefs.h.  */
16704
16705 /* Override any gcc2 internal prototype to avoid an error.  */
16706 #ifdef __cplusplus
16707 extern "C"
16708 #endif
16709 /* We use char because int might match the return type of a gcc2
16710    builtin and then its argument prototype would still apply.  */
16711 char ssl3_accept ();
16712 int
16713 main ()
16714 {
16715 ssl3_accept ();
16716   ;
16717   return 0;
16718 }
16719 _ACEOF
16720 rm -f conftest.$ac_objext conftest$ac_exeext
16721 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16722   (eval $ac_link) 2>&5
16723   ac_status=$?
16724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16725   (exit $ac_status); } &&
16726          { ac_try='test -s conftest$ac_exeext'
16727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16728   (eval $ac_try) 2>&5
16729   ac_status=$?
16730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16731   (exit $ac_status); }; }; then
16732   ac_cv_lib_ssl_ssl3_accept=yes
16733 else
16734   echo "$as_me: failed program was:" >&5
16735 sed 's/^/| /' conftest.$ac_ext >&5
16736
16737 ac_cv_lib_ssl_ssl3_accept=no
16738 fi
16739 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16740 LIBS=$ac_check_lib_save_LIBS
16741 fi
16742 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
16743 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
16744 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
16745   have_ssleay=yes
16746                                 need_rsaref=yes
16747 else
16748   have_ssleay=no
16749 fi
16750
16751                 fi
16752
16753                 if test $have_ssleay = yes ; then
16754                         ol_with_tls=found
16755                         ol_link_tls=yes
16756
16757
16758 cat >>confdefs.h <<\_ACEOF
16759 #define HAVE_SSLEAY 1
16760 _ACEOF
16761
16762
16763                         if test $need_rsaref = yes; then
16764
16765 cat >>confdefs.h <<\_ACEOF
16766 #define HAVE_RSAREF 1
16767 _ACEOF
16768
16769
16770                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
16771                         else
16772                                 TLS_LIBS="-lssl -lcrypto"
16773                         fi
16774                 fi
16775         fi
16776
16777 else
16778         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
16779 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
16780 fi
16781
16782 if test $ol_link_tls = yes ; then
16783
16784 cat >>confdefs.h <<\_ACEOF
16785 #define HAVE_TLS 1
16786 _ACEOF
16787
16788
16789 elif test $ol_with_tls = auto ; then
16790         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
16791 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
16792         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
16793 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
16794
16795 elif test $ol_with_tls != no ; then
16796         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
16797 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
16798    { (exit 1); exit 1; }; }
16799 fi
16800
16801 if test $ol_enable_lmpasswd != no; then
16802         if test $ol_link_tls != yes ; then
16803                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
16804 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
16805    { (exit 1); exit 1; }; }
16806         fi
16807
16808
16809 cat >>confdefs.h <<\_ACEOF
16810 #define SLAPD_LMHASH 1
16811 _ACEOF
16812
16813 fi
16814
16815 ol_link_threads=no
16816
16817 if test $ol_with_threads = auto -o $ol_with_threads = yes \
16818         -o $ol_with_threads = nt ; then
16819
16820
16821         echo "$as_me:$LINENO: checking for _beginthread" >&5
16822 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
16823 if test "${ac_cv_func__beginthread+set}" = set; then
16824   echo $ECHO_N "(cached) $ECHO_C" >&6
16825 else
16826   cat >conftest.$ac_ext <<_ACEOF
16827 #line $LINENO "configure"
16828 /* confdefs.h.  */
16829 _ACEOF
16830 cat confdefs.h >>conftest.$ac_ext
16831 cat >>conftest.$ac_ext <<_ACEOF
16832 /* end confdefs.h.  */
16833 /* System header to define __stub macros and hopefully few prototypes,
16834     which can conflict with char _beginthread (); below.
16835     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16836     <limits.h> exists even on freestanding compilers.  */
16837 #ifdef __STDC__
16838 # include <limits.h>
16839 #else
16840 # include <assert.h>
16841 #endif
16842 /* Override any gcc2 internal prototype to avoid an error.  */
16843 #ifdef __cplusplus
16844 extern "C"
16845 {
16846 #endif
16847 /* We use char because int might match the return type of a gcc2
16848    builtin and then its argument prototype would still apply.  */
16849 char _beginthread ();
16850 /* The GNU C library defines this for functions which it implements
16851     to always fail with ENOSYS.  Some functions are actually named
16852     something starting with __ and the normal name is an alias.  */
16853 #if defined (__stub__beginthread) || defined (__stub____beginthread)
16854 choke me
16855 #else
16856 char (*f) () = _beginthread;
16857 #endif
16858 #ifdef __cplusplus
16859 }
16860 #endif
16861
16862 int
16863 main ()
16864 {
16865 return f != _beginthread;
16866   ;
16867   return 0;
16868 }
16869 _ACEOF
16870 rm -f conftest.$ac_objext conftest$ac_exeext
16871 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16872   (eval $ac_link) 2>&5
16873   ac_status=$?
16874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16875   (exit $ac_status); } &&
16876          { ac_try='test -s conftest$ac_exeext'
16877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16878   (eval $ac_try) 2>&5
16879   ac_status=$?
16880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16881   (exit $ac_status); }; }; then
16882   ac_cv_func__beginthread=yes
16883 else
16884   echo "$as_me: failed program was:" >&5
16885 sed 's/^/| /' conftest.$ac_ext >&5
16886
16887 ac_cv_func__beginthread=no
16888 fi
16889 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16890 fi
16891 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
16892 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
16893
16894
16895         if test $ac_cv_func__beginthread = yes ; then
16896
16897 cat >>confdefs.h <<\_ACEOF
16898 #define HAVE_NT_THREADS 1
16899 _ACEOF
16900
16901                 ol_cv_nt_threads=yes
16902         fi
16903
16904
16905         if test "$ol_cv_nt_threads" = yes ; then
16906                 ol_link_threads=nt
16907                 ol_with_threads=found
16908                 ol_with_yielding_select=yes
16909
16910
16911 cat >>confdefs.h <<\_ACEOF
16912 #define HAVE_NT_SERVICE_MANAGER 1
16913 _ACEOF
16914
16915
16916 cat >>confdefs.h <<\_ACEOF
16917 #define HAVE_NT_EVENT_LOG 1
16918 _ACEOF
16919
16920         fi
16921
16922         if test $ol_with_threads = nt ; then
16923                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
16924 echo "$as_me: error: could not locate NT Threads" >&2;}
16925    { (exit 1); exit 1; }; }
16926         fi
16927 fi
16928
16929 if test $ol_with_threads = auto -o $ol_with_threads = yes \
16930         -o $ol_with_threads = posix ; then
16931
16932
16933 for ac_header in pthread.h
16934 do
16935 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16936 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16937   echo "$as_me:$LINENO: checking for $ac_header" >&5
16938 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16939 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16940   echo $ECHO_N "(cached) $ECHO_C" >&6
16941 fi
16942 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16943 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16944 else
16945   # Is the header compilable?
16946 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16947 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16948 cat >conftest.$ac_ext <<_ACEOF
16949 #line $LINENO "configure"
16950 /* confdefs.h.  */
16951 _ACEOF
16952 cat confdefs.h >>conftest.$ac_ext
16953 cat >>conftest.$ac_ext <<_ACEOF
16954 /* end confdefs.h.  */
16955 $ac_includes_default
16956 #include <$ac_header>
16957 _ACEOF
16958 rm -f conftest.$ac_objext
16959 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16960   (eval $ac_compile) 2>&5
16961   ac_status=$?
16962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16963   (exit $ac_status); } &&
16964          { ac_try='test -s conftest.$ac_objext'
16965   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16966   (eval $ac_try) 2>&5
16967   ac_status=$?
16968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16969   (exit $ac_status); }; }; then
16970   ac_header_compiler=yes
16971 else
16972   echo "$as_me: failed program was:" >&5
16973 sed 's/^/| /' conftest.$ac_ext >&5
16974
16975 ac_header_compiler=no
16976 fi
16977 rm -f conftest.$ac_objext conftest.$ac_ext
16978 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16979 echo "${ECHO_T}$ac_header_compiler" >&6
16980
16981 # Is the header present?
16982 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16983 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16984 cat >conftest.$ac_ext <<_ACEOF
16985 #line $LINENO "configure"
16986 /* confdefs.h.  */
16987 _ACEOF
16988 cat confdefs.h >>conftest.$ac_ext
16989 cat >>conftest.$ac_ext <<_ACEOF
16990 /* end confdefs.h.  */
16991 #include <$ac_header>
16992 _ACEOF
16993 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16994   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16995   ac_status=$?
16996   grep -v '^ *+' conftest.er1 >conftest.err
16997   rm -f conftest.er1
16998   cat conftest.err >&5
16999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17000   (exit $ac_status); } >/dev/null; then
17001   if test -s conftest.err; then
17002     ac_cpp_err=$ac_c_preproc_warn_flag
17003   else
17004     ac_cpp_err=
17005   fi
17006 else
17007   ac_cpp_err=yes
17008 fi
17009 if test -z "$ac_cpp_err"; then
17010   ac_header_preproc=yes
17011 else
17012   echo "$as_me: failed program was:" >&5
17013 sed 's/^/| /' conftest.$ac_ext >&5
17014
17015   ac_header_preproc=no
17016 fi
17017 rm -f conftest.err conftest.$ac_ext
17018 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17019 echo "${ECHO_T}$ac_header_preproc" >&6
17020
17021 # So?  What about this header?
17022 case $ac_header_compiler:$ac_header_preproc in
17023   yes:no )
17024     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17025 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17026     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17027 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17028     (
17029       cat <<\_ASBOX
17030 ## ------------------------------------ ##
17031 ## Report this to bug-autoconf@gnu.org. ##
17032 ## ------------------------------------ ##
17033 _ASBOX
17034     ) |
17035       sed "s/^/$as_me: WARNING:     /" >&2
17036     ;;
17037   no:yes )
17038     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17039 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17040     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17041 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17042     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17043 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17044     (
17045       cat <<\_ASBOX
17046 ## ------------------------------------ ##
17047 ## Report this to bug-autoconf@gnu.org. ##
17048 ## ------------------------------------ ##
17049 _ASBOX
17050     ) |
17051       sed "s/^/$as_me: WARNING:     /" >&2
17052     ;;
17053 esac
17054 echo "$as_me:$LINENO: checking for $ac_header" >&5
17055 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17056 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17057   echo $ECHO_N "(cached) $ECHO_C" >&6
17058 else
17059   eval "$as_ac_Header=$ac_header_preproc"
17060 fi
17061 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17062 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17063
17064 fi
17065 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17066   cat >>confdefs.h <<_ACEOF
17067 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17068 _ACEOF
17069
17070 fi
17071
17072 done
17073
17074
17075         if test $ac_cv_header_pthread_h = yes ; then
17076                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
17077 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
17078 if test "${ol_cv_pthread_version+set}" = set; then
17079   echo $ECHO_N "(cached) $ECHO_C" >&6
17080 else
17081
17082         cat >conftest.$ac_ext <<_ACEOF
17083 #line $LINENO "configure"
17084 /* confdefs.h.  */
17085 _ACEOF
17086 cat confdefs.h >>conftest.$ac_ext
17087 cat >>conftest.$ac_ext <<_ACEOF
17088 /* end confdefs.h.  */
17089
17090 #               include <pthread.h>
17091
17092 int
17093 main ()
17094 {
17095
17096                 int i = PTHREAD_CREATE_JOINABLE;
17097
17098   ;
17099   return 0;
17100 }
17101 _ACEOF
17102 rm -f conftest.$ac_objext
17103 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17104   (eval $ac_compile) 2>&5
17105   ac_status=$?
17106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17107   (exit $ac_status); } &&
17108          { ac_try='test -s conftest.$ac_objext'
17109   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17110   (eval $ac_try) 2>&5
17111   ac_status=$?
17112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17113   (exit $ac_status); }; }; then
17114
17115         cat >conftest.$ac_ext <<_ACEOF
17116 #line $LINENO "configure"
17117 /* confdefs.h.  */
17118 _ACEOF
17119 cat confdefs.h >>conftest.$ac_ext
17120 cat >>conftest.$ac_ext <<_ACEOF
17121 /* end confdefs.h.  */
17122 #include <pthread.h>
17123
17124 _ACEOF
17125 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17126   $EGREP "pthread_detach" >/dev/null 2>&1; then
17127   ol_cv_pthread_version=10
17128 else
17129   ol_cv_pthread_version=8
17130 fi
17131 rm -f conftest*
17132
17133 else
17134   echo "$as_me: failed program was:" >&5
17135 sed 's/^/| /' conftest.$ac_ext >&5
17136
17137
17138         cat >conftest.$ac_ext <<_ACEOF
17139 #line $LINENO "configure"
17140 /* confdefs.h.  */
17141 _ACEOF
17142 cat confdefs.h >>conftest.$ac_ext
17143 cat >>conftest.$ac_ext <<_ACEOF
17144 /* end confdefs.h.  */
17145
17146 #               include <pthread.h>
17147 #               ifdef PTHREAD_CREATE_UNDETACHED
17148                 draft7
17149 #               endif
17150
17151 _ACEOF
17152 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17153   $EGREP "draft7" >/dev/null 2>&1; then
17154   ol_cv_pthread_version=7
17155 else
17156
17157         cat >conftest.$ac_ext <<_ACEOF
17158 #line $LINENO "configure"
17159 /* confdefs.h.  */
17160 _ACEOF
17161 cat confdefs.h >>conftest.$ac_ext
17162 cat >>conftest.$ac_ext <<_ACEOF
17163 /* end confdefs.h.  */
17164 #include <pthread.h>
17165
17166 _ACEOF
17167 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17168   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
17169   ol_cv_pthread_version=6
17170 else
17171
17172         cat >conftest.$ac_ext <<_ACEOF
17173 #line $LINENO "configure"
17174 /* confdefs.h.  */
17175 _ACEOF
17176 cat confdefs.h >>conftest.$ac_ext
17177 cat >>conftest.$ac_ext <<_ACEOF
17178 /* end confdefs.h.  */
17179
17180 #               include <pthread.h>
17181 #ifdef          PTHREAD_MUTEX_INITIALIZER
17182                 draft5
17183 #endif
17184
17185 _ACEOF
17186 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17187   $EGREP "draft5" >/dev/null 2>&1; then
17188   ol_cv_pthread_version=5
17189 else
17190   ol_cv_pthread_version=4
17191 fi
17192 rm -f conftest*
17193
17194 fi
17195 rm -f conftest*
17196
17197 fi
17198 rm -f conftest*
17199
17200 fi
17201 rm -f conftest.$ac_objext conftest.$ac_ext
17202
17203 fi
17204 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
17205 echo "${ECHO_T}$ol_cv_pthread_version" >&6
17206
17207
17208                 if test $ol_cv_pthread_version != 0 ; then
17209
17210 cat >>confdefs.h <<_ACEOF
17211 #define HAVE_PTHREADS $ol_cv_pthread_version
17212 _ACEOF
17213
17214                 else
17215                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
17216 echo "$as_me: error: unknown pthread version" >&2;}
17217    { (exit 1); exit 1; }; }
17218                 fi
17219
17220                 # consider threads found
17221                 ol_with_threads=found
17222
17223
17224         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
17225 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
17226 if test "${ol_cv_header_linux_threads+set}" = set; then
17227   echo $ECHO_N "(cached) $ECHO_C" >&6
17228 else
17229   cat >conftest.$ac_ext <<_ACEOF
17230 #line $LINENO "configure"
17231 /* confdefs.h.  */
17232 _ACEOF
17233 cat confdefs.h >>conftest.$ac_ext
17234 cat >>conftest.$ac_ext <<_ACEOF
17235 /* end confdefs.h.  */
17236 #include <pthread.h>
17237 _ACEOF
17238 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17239   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
17240   ol_cv_header_linux_threads=yes
17241 else
17242   ol_cv_header_linux_threads=no
17243 fi
17244 rm -f conftest*
17245
17246
17247 fi
17248 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
17249 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
17250         if test $ol_cv_header_linux_threads = yes; then
17251
17252 cat >>confdefs.h <<\_ACEOF
17253 #define HAVE_LINUX_THREADS 1
17254 _ACEOF
17255
17256         fi
17257
17258
17259         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
17260 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
17261 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
17262   echo $ECHO_N "(cached) $ECHO_C" >&6
17263 else
17264   cat >conftest.$ac_ext <<_ACEOF
17265 #line $LINENO "configure"
17266 /* confdefs.h.  */
17267 _ACEOF
17268 cat confdefs.h >>conftest.$ac_ext
17269 cat >>conftest.$ac_ext <<_ACEOF
17270 /* end confdefs.h.  */
17271 #include <pthread.h>
17272 #ifdef _POSIX_THREAD_IS_GNU_PTH
17273         __gnu_pth__;
17274 #endif
17275
17276 _ACEOF
17277 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17278   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
17279   ol_cv_header_gnu_pth_pthread_h=yes
17280 else
17281   ol_cv_header_gnu_pth_pthread_h=no
17282 fi
17283 rm -f conftest*
17284
17285
17286 fi
17287 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
17288 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
17289
17290
17291                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
17292
17293 for ac_header in sched.h
17294 do
17295 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17296 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17297   echo "$as_me:$LINENO: checking for $ac_header" >&5
17298 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17299 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17300   echo $ECHO_N "(cached) $ECHO_C" >&6
17301 fi
17302 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17303 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17304 else
17305   # Is the header compilable?
17306 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17307 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17308 cat >conftest.$ac_ext <<_ACEOF
17309 #line $LINENO "configure"
17310 /* confdefs.h.  */
17311 _ACEOF
17312 cat confdefs.h >>conftest.$ac_ext
17313 cat >>conftest.$ac_ext <<_ACEOF
17314 /* end confdefs.h.  */
17315 $ac_includes_default
17316 #include <$ac_header>
17317 _ACEOF
17318 rm -f conftest.$ac_objext
17319 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17320   (eval $ac_compile) 2>&5
17321   ac_status=$?
17322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17323   (exit $ac_status); } &&
17324          { ac_try='test -s conftest.$ac_objext'
17325   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17326   (eval $ac_try) 2>&5
17327   ac_status=$?
17328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17329   (exit $ac_status); }; }; then
17330   ac_header_compiler=yes
17331 else
17332   echo "$as_me: failed program was:" >&5
17333 sed 's/^/| /' conftest.$ac_ext >&5
17334
17335 ac_header_compiler=no
17336 fi
17337 rm -f conftest.$ac_objext conftest.$ac_ext
17338 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17339 echo "${ECHO_T}$ac_header_compiler" >&6
17340
17341 # Is the header present?
17342 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17343 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17344 cat >conftest.$ac_ext <<_ACEOF
17345 #line $LINENO "configure"
17346 /* confdefs.h.  */
17347 _ACEOF
17348 cat confdefs.h >>conftest.$ac_ext
17349 cat >>conftest.$ac_ext <<_ACEOF
17350 /* end confdefs.h.  */
17351 #include <$ac_header>
17352 _ACEOF
17353 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17354   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17355   ac_status=$?
17356   grep -v '^ *+' conftest.er1 >conftest.err
17357   rm -f conftest.er1
17358   cat conftest.err >&5
17359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17360   (exit $ac_status); } >/dev/null; then
17361   if test -s conftest.err; then
17362     ac_cpp_err=$ac_c_preproc_warn_flag
17363   else
17364     ac_cpp_err=
17365   fi
17366 else
17367   ac_cpp_err=yes
17368 fi
17369 if test -z "$ac_cpp_err"; then
17370   ac_header_preproc=yes
17371 else
17372   echo "$as_me: failed program was:" >&5
17373 sed 's/^/| /' conftest.$ac_ext >&5
17374
17375   ac_header_preproc=no
17376 fi
17377 rm -f conftest.err conftest.$ac_ext
17378 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17379 echo "${ECHO_T}$ac_header_preproc" >&6
17380
17381 # So?  What about this header?
17382 case $ac_header_compiler:$ac_header_preproc in
17383   yes:no )
17384     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17385 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17386     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17387 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17388     (
17389       cat <<\_ASBOX
17390 ## ------------------------------------ ##
17391 ## Report this to bug-autoconf@gnu.org. ##
17392 ## ------------------------------------ ##
17393 _ASBOX
17394     ) |
17395       sed "s/^/$as_me: WARNING:     /" >&2
17396     ;;
17397   no:yes )
17398     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17399 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17400     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17401 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17402     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17403 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17404     (
17405       cat <<\_ASBOX
17406 ## ------------------------------------ ##
17407 ## Report this to bug-autoconf@gnu.org. ##
17408 ## ------------------------------------ ##
17409 _ASBOX
17410     ) |
17411       sed "s/^/$as_me: WARNING:     /" >&2
17412     ;;
17413 esac
17414 echo "$as_me:$LINENO: checking for $ac_header" >&5
17415 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17416 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17417   echo $ECHO_N "(cached) $ECHO_C" >&6
17418 else
17419   eval "$as_ac_Header=$ac_header_preproc"
17420 fi
17421 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17422 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17423
17424 fi
17425 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17426   cat >>confdefs.h <<_ACEOF
17427 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17428 _ACEOF
17429
17430 fi
17431
17432 done
17433
17434                 fi
17435
17436
17437                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
17438 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
17439 if test "${ol_cv_pthread_create+set}" = set; then
17440   echo $ECHO_N "(cached) $ECHO_C" >&6
17441 else
17442
17443                 if test "$cross_compiling" = yes; then
17444   cat >conftest.$ac_ext <<_ACEOF
17445 #line $LINENO "configure"
17446 /* confdefs.h.  */
17447 _ACEOF
17448 cat confdefs.h >>conftest.$ac_ext
17449 cat >>conftest.$ac_ext <<_ACEOF
17450 /* end confdefs.h.  */
17451 /* pthread test headers */
17452 #include <pthread.h>
17453 #if HAVE_PTHREADS < 7
17454 #include <errno.h>
17455 #endif
17456 #ifndef NULL
17457 #define NULL (void*)0
17458 #endif
17459
17460 static void *task(p)
17461         void *p;
17462 {
17463         return (void *) (p == NULL);
17464 }
17465
17466 int
17467 main ()
17468 {
17469
17470         /* pthread test function */
17471 #ifndef PTHREAD_CREATE_DETACHED
17472 #define PTHREAD_CREATE_DETACHED 1
17473 #endif
17474         pthread_t t;
17475         int status;
17476         int detach = PTHREAD_CREATE_DETACHED;
17477
17478 #if HAVE_PTHREADS > 4
17479         /* Final pthreads */
17480         pthread_attr_t attr;
17481
17482         status = pthread_attr_init(&attr);
17483         if( status ) return status;
17484
17485 #if HAVE_PTHREADS < 7
17486         status = pthread_attr_setdetachstate(&attr, &detach);
17487         if( status < 0 ) status = errno;
17488 #else
17489         status = pthread_attr_setdetachstate(&attr, detach);
17490 #endif
17491         if( status ) return status;
17492         status = pthread_create( &t, &attr, task, NULL );
17493 #if HAVE_PTHREADS < 7
17494         if( status < 0 ) status = errno;
17495 #endif
17496         if( status ) return status;
17497 #else
17498         /* Draft 4 pthreads */
17499         status = pthread_create( &t, pthread_attr_default, task, NULL );
17500         if( status ) return errno;
17501
17502         /* give thread a chance to complete */
17503         /* it should remain joinable and hence detachable */
17504         sleep( 1 );
17505
17506         status = pthread_detach( &t );
17507         if( status ) return errno;
17508 #endif
17509
17510 #ifdef HAVE_LINUX_THREADS
17511         pthread_kill_other_threads_np();
17512 #endif
17513
17514         return 0;
17515
17516   ;
17517   return 0;
17518 }
17519 _ACEOF
17520 rm -f conftest.$ac_objext conftest$ac_exeext
17521 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17522   (eval $ac_link) 2>&5
17523   ac_status=$?
17524   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17525   (exit $ac_status); } &&
17526          { ac_try='test -s conftest$ac_exeext'
17527   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17528   (eval $ac_try) 2>&5
17529   ac_status=$?
17530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17531   (exit $ac_status); }; }; then
17532   ol_cv_pthread_create=yes
17533 else
17534   echo "$as_me: failed program was:" >&5
17535 sed 's/^/| /' conftest.$ac_ext >&5
17536
17537 ol_cv_pthread_create=no
17538 fi
17539 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17540 else
17541   cat >conftest.$ac_ext <<_ACEOF
17542 #line $LINENO "configure"
17543 /* confdefs.h.  */
17544 _ACEOF
17545 cat confdefs.h >>conftest.$ac_ext
17546 cat >>conftest.$ac_ext <<_ACEOF
17547 /* end confdefs.h.  */
17548 /* pthread test headers */
17549 #include <pthread.h>
17550 #if HAVE_PTHREADS < 7
17551 #include <errno.h>
17552 #endif
17553 #ifndef NULL
17554 #define NULL (void*)0
17555 #endif
17556
17557 static void *task(p)
17558         void *p;
17559 {
17560         return (void *) (p == NULL);
17561 }
17562
17563
17564 int main(argc, argv)
17565         int argc;
17566         char **argv;
17567 {
17568
17569         /* pthread test function */
17570 #ifndef PTHREAD_CREATE_DETACHED
17571 #define PTHREAD_CREATE_DETACHED 1
17572 #endif
17573         pthread_t t;
17574         int status;
17575         int detach = PTHREAD_CREATE_DETACHED;
17576
17577 #if HAVE_PTHREADS > 4
17578         /* Final pthreads */
17579         pthread_attr_t attr;
17580
17581         status = pthread_attr_init(&attr);
17582         if( status ) return status;
17583
17584 #if HAVE_PTHREADS < 7
17585         status = pthread_attr_setdetachstate(&attr, &detach);
17586         if( status < 0 ) status = errno;
17587 #else
17588         status = pthread_attr_setdetachstate(&attr, detach);
17589 #endif
17590         if( status ) return status;
17591         status = pthread_create( &t, &attr, task, NULL );
17592 #if HAVE_PTHREADS < 7
17593         if( status < 0 ) status = errno;
17594 #endif
17595         if( status ) return status;
17596 #else
17597         /* Draft 4 pthreads */
17598         status = pthread_create( &t, pthread_attr_default, task, NULL );
17599         if( status ) return errno;
17600
17601         /* give thread a chance to complete */
17602         /* it should remain joinable and hence detachable */
17603         sleep( 1 );
17604
17605         status = pthread_detach( &t );
17606         if( status ) return errno;
17607 #endif
17608
17609 #ifdef HAVE_LINUX_THREADS
17610         pthread_kill_other_threads_np();
17611 #endif
17612
17613         return 0;
17614
17615 }
17616
17617 _ACEOF
17618 rm -f conftest$ac_exeext
17619 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17620   (eval $ac_link) 2>&5
17621   ac_status=$?
17622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17623   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17625   (eval $ac_try) 2>&5
17626   ac_status=$?
17627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17628   (exit $ac_status); }; }; then
17629   ol_cv_pthread_create=yes
17630 else
17631   echo "$as_me: program exited with status $ac_status" >&5
17632 echo "$as_me: failed program was:" >&5
17633 sed 's/^/| /' conftest.$ac_ext >&5
17634
17635 ( exit $ac_status )
17636 ol_cv_pthread_create=no
17637 fi
17638 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17639 fi
17640 fi
17641 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
17642 echo "${ECHO_T}$ol_cv_pthread_create" >&6
17643
17644                 if test $ol_cv_pthread_create != no ; then
17645                         ol_link_threads=posix
17646                         ol_link_pthreads=""
17647                 fi
17648
17649                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
17650 if test "$ol_link_threads" = no ; then
17651         # try -kthread
17652         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
17653 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
17654 if test "${ol_cv_pthread_kthread+set}" = set; then
17655   echo $ECHO_N "(cached) $ECHO_C" >&6
17656 else
17657
17658                 # save the flags
17659                 ol_LIBS="$LIBS"
17660                 LIBS="-kthread $LIBS"
17661
17662                 if test "$cross_compiling" = yes; then
17663   cat >conftest.$ac_ext <<_ACEOF
17664 #line $LINENO "configure"
17665 /* confdefs.h.  */
17666 _ACEOF
17667 cat confdefs.h >>conftest.$ac_ext
17668 cat >>conftest.$ac_ext <<_ACEOF
17669 /* end confdefs.h.  */
17670 /* pthread test headers */
17671 #include <pthread.h>
17672 #if HAVE_PTHREADS < 7
17673 #include <errno.h>
17674 #endif
17675 #ifndef NULL
17676 #define NULL (void*)0
17677 #endif
17678
17679 static void *task(p)
17680         void *p;
17681 {
17682         return (void *) (p == NULL);
17683 }
17684
17685 int
17686 main ()
17687 {
17688
17689         /* pthread test function */
17690 #ifndef PTHREAD_CREATE_DETACHED
17691 #define PTHREAD_CREATE_DETACHED 1
17692 #endif
17693         pthread_t t;
17694         int status;
17695         int detach = PTHREAD_CREATE_DETACHED;
17696
17697 #if HAVE_PTHREADS > 4
17698         /* Final pthreads */
17699         pthread_attr_t attr;
17700
17701         status = pthread_attr_init(&attr);
17702         if( status ) return status;
17703
17704 #if HAVE_PTHREADS < 7
17705         status = pthread_attr_setdetachstate(&attr, &detach);
17706         if( status < 0 ) status = errno;
17707 #else
17708         status = pthread_attr_setdetachstate(&attr, detach);
17709 #endif
17710         if( status ) return status;
17711         status = pthread_create( &t, &attr, task, NULL );
17712 #if HAVE_PTHREADS < 7
17713         if( status < 0 ) status = errno;
17714 #endif
17715         if( status ) return status;
17716 #else
17717         /* Draft 4 pthreads */
17718         status = pthread_create( &t, pthread_attr_default, task, NULL );
17719         if( status ) return errno;
17720
17721         /* give thread a chance to complete */
17722         /* it should remain joinable and hence detachable */
17723         sleep( 1 );
17724
17725         status = pthread_detach( &t );
17726         if( status ) return errno;
17727 #endif
17728
17729 #ifdef HAVE_LINUX_THREADS
17730         pthread_kill_other_threads_np();
17731 #endif
17732
17733         return 0;
17734
17735   ;
17736   return 0;
17737 }
17738 _ACEOF
17739 rm -f conftest.$ac_objext conftest$ac_exeext
17740 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17741   (eval $ac_link) 2>&5
17742   ac_status=$?
17743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17744   (exit $ac_status); } &&
17745          { ac_try='test -s conftest$ac_exeext'
17746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17747   (eval $ac_try) 2>&5
17748   ac_status=$?
17749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17750   (exit $ac_status); }; }; then
17751   ol_cv_pthread_kthread=yes
17752 else
17753   echo "$as_me: failed program was:" >&5
17754 sed 's/^/| /' conftest.$ac_ext >&5
17755
17756 ol_cv_pthread_kthread=no
17757 fi
17758 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17759 else
17760   cat >conftest.$ac_ext <<_ACEOF
17761 #line $LINENO "configure"
17762 /* confdefs.h.  */
17763 _ACEOF
17764 cat confdefs.h >>conftest.$ac_ext
17765 cat >>conftest.$ac_ext <<_ACEOF
17766 /* end confdefs.h.  */
17767 /* pthread test headers */
17768 #include <pthread.h>
17769 #if HAVE_PTHREADS < 7
17770 #include <errno.h>
17771 #endif
17772 #ifndef NULL
17773 #define NULL (void*)0
17774 #endif
17775
17776 static void *task(p)
17777         void *p;
17778 {
17779         return (void *) (p == NULL);
17780 }
17781
17782
17783 int main(argc, argv)
17784         int argc;
17785         char **argv;
17786 {
17787
17788         /* pthread test function */
17789 #ifndef PTHREAD_CREATE_DETACHED
17790 #define PTHREAD_CREATE_DETACHED 1
17791 #endif
17792         pthread_t t;
17793         int status;
17794         int detach = PTHREAD_CREATE_DETACHED;
17795
17796 #if HAVE_PTHREADS > 4
17797         /* Final pthreads */
17798         pthread_attr_t attr;
17799
17800         status = pthread_attr_init(&attr);
17801         if( status ) return status;
17802
17803 #if HAVE_PTHREADS < 7
17804         status = pthread_attr_setdetachstate(&attr, &detach);
17805         if( status < 0 ) status = errno;
17806 #else
17807         status = pthread_attr_setdetachstate(&attr, detach);
17808 #endif
17809         if( status ) return status;
17810         status = pthread_create( &t, &attr, task, NULL );
17811 #if HAVE_PTHREADS < 7
17812         if( status < 0 ) status = errno;
17813 #endif
17814         if( status ) return status;
17815 #else
17816         /* Draft 4 pthreads */
17817         status = pthread_create( &t, pthread_attr_default, task, NULL );
17818         if( status ) return errno;
17819
17820         /* give thread a chance to complete */
17821         /* it should remain joinable and hence detachable */
17822         sleep( 1 );
17823
17824         status = pthread_detach( &t );
17825         if( status ) return errno;
17826 #endif
17827
17828 #ifdef HAVE_LINUX_THREADS
17829         pthread_kill_other_threads_np();
17830 #endif
17831
17832         return 0;
17833
17834 }
17835
17836 _ACEOF
17837 rm -f conftest$ac_exeext
17838 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17839   (eval $ac_link) 2>&5
17840   ac_status=$?
17841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17842   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17844   (eval $ac_try) 2>&5
17845   ac_status=$?
17846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17847   (exit $ac_status); }; }; then
17848   ol_cv_pthread_kthread=yes
17849 else
17850   echo "$as_me: program exited with status $ac_status" >&5
17851 echo "$as_me: failed program was:" >&5
17852 sed 's/^/| /' conftest.$ac_ext >&5
17853
17854 ( exit $ac_status )
17855 ol_cv_pthread_kthread=no
17856 fi
17857 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17858 fi
17859
17860                 # restore the LIBS
17861                 LIBS="$ol_LIBS"
17862
17863 fi
17864 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
17865 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
17866
17867         if test $ol_cv_pthread_kthread = yes ; then
17868                 ol_link_pthreads="-kthread"
17869                 ol_link_threads=posix
17870         fi
17871 fi
17872
17873                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
17874 if test "$ol_link_threads" = no ; then
17875         # try -pthread
17876         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
17877 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
17878 if test "${ol_cv_pthread_pthread+set}" = set; then
17879   echo $ECHO_N "(cached) $ECHO_C" >&6
17880 else
17881
17882                 # save the flags
17883                 ol_LIBS="$LIBS"
17884                 LIBS="-pthread $LIBS"
17885
17886                 if test "$cross_compiling" = yes; then
17887   cat >conftest.$ac_ext <<_ACEOF
17888 #line $LINENO "configure"
17889 /* confdefs.h.  */
17890 _ACEOF
17891 cat confdefs.h >>conftest.$ac_ext
17892 cat >>conftest.$ac_ext <<_ACEOF
17893 /* end confdefs.h.  */
17894 /* pthread test headers */
17895 #include <pthread.h>
17896 #if HAVE_PTHREADS < 7
17897 #include <errno.h>
17898 #endif
17899 #ifndef NULL
17900 #define NULL (void*)0
17901 #endif
17902
17903 static void *task(p)
17904         void *p;
17905 {
17906         return (void *) (p == NULL);
17907 }
17908
17909 int
17910 main ()
17911 {
17912
17913         /* pthread test function */
17914 #ifndef PTHREAD_CREATE_DETACHED
17915 #define PTHREAD_CREATE_DETACHED 1
17916 #endif
17917         pthread_t t;
17918         int status;
17919         int detach = PTHREAD_CREATE_DETACHED;
17920
17921 #if HAVE_PTHREADS > 4
17922         /* Final pthreads */
17923         pthread_attr_t attr;
17924
17925         status = pthread_attr_init(&attr);
17926         if( status ) return status;
17927
17928 #if HAVE_PTHREADS < 7
17929         status = pthread_attr_setdetachstate(&attr, &detach);
17930         if( status < 0 ) status = errno;
17931 #else
17932         status = pthread_attr_setdetachstate(&attr, detach);
17933 #endif
17934         if( status ) return status;
17935         status = pthread_create( &t, &attr, task, NULL );
17936 #if HAVE_PTHREADS < 7
17937         if( status < 0 ) status = errno;
17938 #endif
17939         if( status ) return status;
17940 #else
17941         /* Draft 4 pthreads */
17942         status = pthread_create( &t, pthread_attr_default, task, NULL );
17943         if( status ) return errno;
17944
17945         /* give thread a chance to complete */
17946         /* it should remain joinable and hence detachable */
17947         sleep( 1 );
17948
17949         status = pthread_detach( &t );
17950         if( status ) return errno;
17951 #endif
17952
17953 #ifdef HAVE_LINUX_THREADS
17954         pthread_kill_other_threads_np();
17955 #endif
17956
17957         return 0;
17958
17959   ;
17960   return 0;
17961 }
17962 _ACEOF
17963 rm -f conftest.$ac_objext conftest$ac_exeext
17964 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17965   (eval $ac_link) 2>&5
17966   ac_status=$?
17967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17968   (exit $ac_status); } &&
17969          { ac_try='test -s conftest$ac_exeext'
17970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17971   (eval $ac_try) 2>&5
17972   ac_status=$?
17973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17974   (exit $ac_status); }; }; then
17975   ol_cv_pthread_pthread=yes
17976 else
17977   echo "$as_me: failed program was:" >&5
17978 sed 's/^/| /' conftest.$ac_ext >&5
17979
17980 ol_cv_pthread_pthread=no
17981 fi
17982 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17983 else
17984   cat >conftest.$ac_ext <<_ACEOF
17985 #line $LINENO "configure"
17986 /* confdefs.h.  */
17987 _ACEOF
17988 cat confdefs.h >>conftest.$ac_ext
17989 cat >>conftest.$ac_ext <<_ACEOF
17990 /* end confdefs.h.  */
17991 /* pthread test headers */
17992 #include <pthread.h>
17993 #if HAVE_PTHREADS < 7
17994 #include <errno.h>
17995 #endif
17996 #ifndef NULL
17997 #define NULL (void*)0
17998 #endif
17999
18000 static void *task(p)
18001         void *p;
18002 {
18003         return (void *) (p == NULL);
18004 }
18005
18006
18007 int main(argc, argv)
18008         int argc;
18009         char **argv;
18010 {
18011
18012         /* pthread test function */
18013 #ifndef PTHREAD_CREATE_DETACHED
18014 #define PTHREAD_CREATE_DETACHED 1
18015 #endif
18016         pthread_t t;
18017         int status;
18018         int detach = PTHREAD_CREATE_DETACHED;
18019
18020 #if HAVE_PTHREADS > 4
18021         /* Final pthreads */
18022         pthread_attr_t attr;
18023
18024         status = pthread_attr_init(&attr);
18025         if( status ) return status;
18026
18027 #if HAVE_PTHREADS < 7
18028         status = pthread_attr_setdetachstate(&attr, &detach);
18029         if( status < 0 ) status = errno;
18030 #else
18031         status = pthread_attr_setdetachstate(&attr, detach);
18032 #endif
18033         if( status ) return status;
18034         status = pthread_create( &t, &attr, task, NULL );
18035 #if HAVE_PTHREADS < 7
18036         if( status < 0 ) status = errno;
18037 #endif
18038         if( status ) return status;
18039 #else
18040         /* Draft 4 pthreads */
18041         status = pthread_create( &t, pthread_attr_default, task, NULL );
18042         if( status ) return errno;
18043
18044         /* give thread a chance to complete */
18045         /* it should remain joinable and hence detachable */
18046         sleep( 1 );
18047
18048         status = pthread_detach( &t );
18049         if( status ) return errno;
18050 #endif
18051
18052 #ifdef HAVE_LINUX_THREADS
18053         pthread_kill_other_threads_np();
18054 #endif
18055
18056         return 0;
18057
18058 }
18059
18060 _ACEOF
18061 rm -f conftest$ac_exeext
18062 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18063   (eval $ac_link) 2>&5
18064   ac_status=$?
18065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18066   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18068   (eval $ac_try) 2>&5
18069   ac_status=$?
18070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18071   (exit $ac_status); }; }; then
18072   ol_cv_pthread_pthread=yes
18073 else
18074   echo "$as_me: program exited with status $ac_status" >&5
18075 echo "$as_me: failed program was:" >&5
18076 sed 's/^/| /' conftest.$ac_ext >&5
18077
18078 ( exit $ac_status )
18079 ol_cv_pthread_pthread=no
18080 fi
18081 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18082 fi
18083
18084                 # restore the LIBS
18085                 LIBS="$ol_LIBS"
18086
18087 fi
18088 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
18089 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
18090
18091         if test $ol_cv_pthread_pthread = yes ; then
18092                 ol_link_pthreads="-pthread"
18093                 ol_link_threads=posix
18094         fi
18095 fi
18096
18097                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
18098 if test "$ol_link_threads" = no ; then
18099         # try -pthreads
18100         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
18101 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
18102 if test "${ol_cv_pthread_pthreads+set}" = set; then
18103   echo $ECHO_N "(cached) $ECHO_C" >&6
18104 else
18105
18106                 # save the flags
18107                 ol_LIBS="$LIBS"
18108                 LIBS="-pthreads $LIBS"
18109
18110                 if test "$cross_compiling" = yes; then
18111   cat >conftest.$ac_ext <<_ACEOF
18112 #line $LINENO "configure"
18113 /* confdefs.h.  */
18114 _ACEOF
18115 cat confdefs.h >>conftest.$ac_ext
18116 cat >>conftest.$ac_ext <<_ACEOF
18117 /* end confdefs.h.  */
18118 /* pthread test headers */
18119 #include <pthread.h>
18120 #if HAVE_PTHREADS < 7
18121 #include <errno.h>
18122 #endif
18123 #ifndef NULL
18124 #define NULL (void*)0
18125 #endif
18126
18127 static void *task(p)
18128         void *p;
18129 {
18130         return (void *) (p == NULL);
18131 }
18132
18133 int
18134 main ()
18135 {
18136
18137         /* pthread test function */
18138 #ifndef PTHREAD_CREATE_DETACHED
18139 #define PTHREAD_CREATE_DETACHED 1
18140 #endif
18141         pthread_t t;
18142         int status;
18143         int detach = PTHREAD_CREATE_DETACHED;
18144
18145 #if HAVE_PTHREADS > 4
18146         /* Final pthreads */
18147         pthread_attr_t attr;
18148
18149         status = pthread_attr_init(&attr);
18150         if( status ) return status;
18151
18152 #if HAVE_PTHREADS < 7
18153         status = pthread_attr_setdetachstate(&attr, &detach);
18154         if( status < 0 ) status = errno;
18155 #else
18156         status = pthread_attr_setdetachstate(&attr, detach);
18157 #endif
18158         if( status ) return status;
18159         status = pthread_create( &t, &attr, task, NULL );
18160 #if HAVE_PTHREADS < 7
18161         if( status < 0 ) status = errno;
18162 #endif
18163         if( status ) return status;
18164 #else
18165         /* Draft 4 pthreads */
18166         status = pthread_create( &t, pthread_attr_default, task, NULL );
18167         if( status ) return errno;
18168
18169         /* give thread a chance to complete */
18170         /* it should remain joinable and hence detachable */
18171         sleep( 1 );
18172
18173         status = pthread_detach( &t );
18174         if( status ) return errno;
18175 #endif
18176
18177 #ifdef HAVE_LINUX_THREADS
18178         pthread_kill_other_threads_np();
18179 #endif
18180
18181         return 0;
18182
18183   ;
18184   return 0;
18185 }
18186 _ACEOF
18187 rm -f conftest.$ac_objext conftest$ac_exeext
18188 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18189   (eval $ac_link) 2>&5
18190   ac_status=$?
18191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18192   (exit $ac_status); } &&
18193          { ac_try='test -s conftest$ac_exeext'
18194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18195   (eval $ac_try) 2>&5
18196   ac_status=$?
18197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18198   (exit $ac_status); }; }; then
18199   ol_cv_pthread_pthreads=yes
18200 else
18201   echo "$as_me: failed program was:" >&5
18202 sed 's/^/| /' conftest.$ac_ext >&5
18203
18204 ol_cv_pthread_pthreads=no
18205 fi
18206 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18207 else
18208   cat >conftest.$ac_ext <<_ACEOF
18209 #line $LINENO "configure"
18210 /* confdefs.h.  */
18211 _ACEOF
18212 cat confdefs.h >>conftest.$ac_ext
18213 cat >>conftest.$ac_ext <<_ACEOF
18214 /* end confdefs.h.  */
18215 /* pthread test headers */
18216 #include <pthread.h>
18217 #if HAVE_PTHREADS < 7
18218 #include <errno.h>
18219 #endif
18220 #ifndef NULL
18221 #define NULL (void*)0
18222 #endif
18223
18224 static void *task(p)
18225         void *p;
18226 {
18227         return (void *) (p == NULL);
18228 }
18229
18230
18231 int main(argc, argv)
18232         int argc;
18233         char **argv;
18234 {
18235
18236         /* pthread test function */
18237 #ifndef PTHREAD_CREATE_DETACHED
18238 #define PTHREAD_CREATE_DETACHED 1
18239 #endif
18240         pthread_t t;
18241         int status;
18242         int detach = PTHREAD_CREATE_DETACHED;
18243
18244 #if HAVE_PTHREADS > 4
18245         /* Final pthreads */
18246         pthread_attr_t attr;
18247
18248         status = pthread_attr_init(&attr);
18249         if( status ) return status;
18250
18251 #if HAVE_PTHREADS < 7
18252         status = pthread_attr_setdetachstate(&attr, &detach);
18253         if( status < 0 ) status = errno;
18254 #else
18255         status = pthread_attr_setdetachstate(&attr, detach);
18256 #endif
18257         if( status ) return status;
18258         status = pthread_create( &t, &attr, task, NULL );
18259 #if HAVE_PTHREADS < 7
18260         if( status < 0 ) status = errno;
18261 #endif
18262         if( status ) return status;
18263 #else
18264         /* Draft 4 pthreads */
18265         status = pthread_create( &t, pthread_attr_default, task, NULL );
18266         if( status ) return errno;
18267
18268         /* give thread a chance to complete */
18269         /* it should remain joinable and hence detachable */
18270         sleep( 1 );
18271
18272         status = pthread_detach( &t );
18273         if( status ) return errno;
18274 #endif
18275
18276 #ifdef HAVE_LINUX_THREADS
18277         pthread_kill_other_threads_np();
18278 #endif
18279
18280         return 0;
18281
18282 }
18283
18284 _ACEOF
18285 rm -f conftest$ac_exeext
18286 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18287   (eval $ac_link) 2>&5
18288   ac_status=$?
18289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18290   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18291   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18292   (eval $ac_try) 2>&5
18293   ac_status=$?
18294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18295   (exit $ac_status); }; }; then
18296   ol_cv_pthread_pthreads=yes
18297 else
18298   echo "$as_me: program exited with status $ac_status" >&5
18299 echo "$as_me: failed program was:" >&5
18300 sed 's/^/| /' conftest.$ac_ext >&5
18301
18302 ( exit $ac_status )
18303 ol_cv_pthread_pthreads=no
18304 fi
18305 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18306 fi
18307
18308                 # restore the LIBS
18309                 LIBS="$ol_LIBS"
18310
18311 fi
18312 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
18313 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
18314
18315         if test $ol_cv_pthread_pthreads = yes ; then
18316                 ol_link_pthreads="-pthreads"
18317                 ol_link_threads=posix
18318         fi
18319 fi
18320
18321                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
18322 if test "$ol_link_threads" = no ; then
18323         # try -mthreads
18324         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
18325 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
18326 if test "${ol_cv_pthread_mthreads+set}" = set; then
18327   echo $ECHO_N "(cached) $ECHO_C" >&6
18328 else
18329
18330                 # save the flags
18331                 ol_LIBS="$LIBS"
18332                 LIBS="-mthreads $LIBS"
18333
18334                 if test "$cross_compiling" = yes; then
18335   cat >conftest.$ac_ext <<_ACEOF
18336 #line $LINENO "configure"
18337 /* confdefs.h.  */
18338 _ACEOF
18339 cat confdefs.h >>conftest.$ac_ext
18340 cat >>conftest.$ac_ext <<_ACEOF
18341 /* end confdefs.h.  */
18342 /* pthread test headers */
18343 #include <pthread.h>
18344 #if HAVE_PTHREADS < 7
18345 #include <errno.h>
18346 #endif
18347 #ifndef NULL
18348 #define NULL (void*)0
18349 #endif
18350
18351 static void *task(p)
18352         void *p;
18353 {
18354         return (void *) (p == NULL);
18355 }
18356
18357 int
18358 main ()
18359 {
18360
18361         /* pthread test function */
18362 #ifndef PTHREAD_CREATE_DETACHED
18363 #define PTHREAD_CREATE_DETACHED 1
18364 #endif
18365         pthread_t t;
18366         int status;
18367         int detach = PTHREAD_CREATE_DETACHED;
18368
18369 #if HAVE_PTHREADS > 4
18370         /* Final pthreads */
18371         pthread_attr_t attr;
18372
18373         status = pthread_attr_init(&attr);
18374         if( status ) return status;
18375
18376 #if HAVE_PTHREADS < 7
18377         status = pthread_attr_setdetachstate(&attr, &detach);
18378         if( status < 0 ) status = errno;
18379 #else
18380         status = pthread_attr_setdetachstate(&attr, detach);
18381 #endif
18382         if( status ) return status;
18383         status = pthread_create( &t, &attr, task, NULL );
18384 #if HAVE_PTHREADS < 7
18385         if( status < 0 ) status = errno;
18386 #endif
18387         if( status ) return status;
18388 #else
18389         /* Draft 4 pthreads */
18390         status = pthread_create( &t, pthread_attr_default, task, NULL );
18391         if( status ) return errno;
18392
18393         /* give thread a chance to complete */
18394         /* it should remain joinable and hence detachable */
18395         sleep( 1 );
18396
18397         status = pthread_detach( &t );
18398         if( status ) return errno;
18399 #endif
18400
18401 #ifdef HAVE_LINUX_THREADS
18402         pthread_kill_other_threads_np();
18403 #endif
18404
18405         return 0;
18406
18407   ;
18408   return 0;
18409 }
18410 _ACEOF
18411 rm -f conftest.$ac_objext conftest$ac_exeext
18412 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18413   (eval $ac_link) 2>&5
18414   ac_status=$?
18415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18416   (exit $ac_status); } &&
18417          { ac_try='test -s conftest$ac_exeext'
18418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18419   (eval $ac_try) 2>&5
18420   ac_status=$?
18421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18422   (exit $ac_status); }; }; then
18423   ol_cv_pthread_mthreads=yes
18424 else
18425   echo "$as_me: failed program was:" >&5
18426 sed 's/^/| /' conftest.$ac_ext >&5
18427
18428 ol_cv_pthread_mthreads=no
18429 fi
18430 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18431 else
18432   cat >conftest.$ac_ext <<_ACEOF
18433 #line $LINENO "configure"
18434 /* confdefs.h.  */
18435 _ACEOF
18436 cat confdefs.h >>conftest.$ac_ext
18437 cat >>conftest.$ac_ext <<_ACEOF
18438 /* end confdefs.h.  */
18439 /* pthread test headers */
18440 #include <pthread.h>
18441 #if HAVE_PTHREADS < 7
18442 #include <errno.h>
18443 #endif
18444 #ifndef NULL
18445 #define NULL (void*)0
18446 #endif
18447
18448 static void *task(p)
18449         void *p;
18450 {
18451         return (void *) (p == NULL);
18452 }
18453
18454
18455 int main(argc, argv)
18456         int argc;
18457         char **argv;
18458 {
18459
18460         /* pthread test function */
18461 #ifndef PTHREAD_CREATE_DETACHED
18462 #define PTHREAD_CREATE_DETACHED 1
18463 #endif
18464         pthread_t t;
18465         int status;
18466         int detach = PTHREAD_CREATE_DETACHED;
18467
18468 #if HAVE_PTHREADS > 4
18469         /* Final pthreads */
18470         pthread_attr_t attr;
18471
18472         status = pthread_attr_init(&attr);
18473         if( status ) return status;
18474
18475 #if HAVE_PTHREADS < 7
18476         status = pthread_attr_setdetachstate(&attr, &detach);
18477         if( status < 0 ) status = errno;
18478 #else
18479         status = pthread_attr_setdetachstate(&attr, detach);
18480 #endif
18481         if( status ) return status;
18482         status = pthread_create( &t, &attr, task, NULL );
18483 #if HAVE_PTHREADS < 7
18484         if( status < 0 ) status = errno;
18485 #endif
18486         if( status ) return status;
18487 #else
18488         /* Draft 4 pthreads */
18489         status = pthread_create( &t, pthread_attr_default, task, NULL );
18490         if( status ) return errno;
18491
18492         /* give thread a chance to complete */
18493         /* it should remain joinable and hence detachable */
18494         sleep( 1 );
18495
18496         status = pthread_detach( &t );
18497         if( status ) return errno;
18498 #endif
18499
18500 #ifdef HAVE_LINUX_THREADS
18501         pthread_kill_other_threads_np();
18502 #endif
18503
18504         return 0;
18505
18506 }
18507
18508 _ACEOF
18509 rm -f conftest$ac_exeext
18510 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18511   (eval $ac_link) 2>&5
18512   ac_status=$?
18513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18514   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18516   (eval $ac_try) 2>&5
18517   ac_status=$?
18518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18519   (exit $ac_status); }; }; then
18520   ol_cv_pthread_mthreads=yes
18521 else
18522   echo "$as_me: program exited with status $ac_status" >&5
18523 echo "$as_me: failed program was:" >&5
18524 sed 's/^/| /' conftest.$ac_ext >&5
18525
18526 ( exit $ac_status )
18527 ol_cv_pthread_mthreads=no
18528 fi
18529 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18530 fi
18531
18532                 # restore the LIBS
18533                 LIBS="$ol_LIBS"
18534
18535 fi
18536 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
18537 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
18538
18539         if test $ol_cv_pthread_mthreads = yes ; then
18540                 ol_link_pthreads="-mthreads"
18541                 ol_link_threads=posix
18542         fi
18543 fi
18544
18545                 # Pthread try link: -thread (ol_cv_pthread_thread)
18546 if test "$ol_link_threads" = no ; then
18547         # try -thread
18548         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
18549 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
18550 if test "${ol_cv_pthread_thread+set}" = set; then
18551   echo $ECHO_N "(cached) $ECHO_C" >&6
18552 else
18553
18554                 # save the flags
18555                 ol_LIBS="$LIBS"
18556                 LIBS="-thread $LIBS"
18557
18558                 if test "$cross_compiling" = yes; then
18559   cat >conftest.$ac_ext <<_ACEOF
18560 #line $LINENO "configure"
18561 /* confdefs.h.  */
18562 _ACEOF
18563 cat confdefs.h >>conftest.$ac_ext
18564 cat >>conftest.$ac_ext <<_ACEOF
18565 /* end confdefs.h.  */
18566 /* pthread test headers */
18567 #include <pthread.h>
18568 #if HAVE_PTHREADS < 7
18569 #include <errno.h>
18570 #endif
18571 #ifndef NULL
18572 #define NULL (void*)0
18573 #endif
18574
18575 static void *task(p)
18576         void *p;
18577 {
18578         return (void *) (p == NULL);
18579 }
18580
18581 int
18582 main ()
18583 {
18584
18585         /* pthread test function */
18586 #ifndef PTHREAD_CREATE_DETACHED
18587 #define PTHREAD_CREATE_DETACHED 1
18588 #endif
18589         pthread_t t;
18590         int status;
18591         int detach = PTHREAD_CREATE_DETACHED;
18592
18593 #if HAVE_PTHREADS > 4
18594         /* Final pthreads */
18595         pthread_attr_t attr;
18596
18597         status = pthread_attr_init(&attr);
18598         if( status ) return status;
18599
18600 #if HAVE_PTHREADS < 7
18601         status = pthread_attr_setdetachstate(&attr, &detach);
18602         if( status < 0 ) status = errno;
18603 #else
18604         status = pthread_attr_setdetachstate(&attr, detach);
18605 #endif
18606         if( status ) return status;
18607         status = pthread_create( &t, &attr, task, NULL );
18608 #if HAVE_PTHREADS < 7
18609         if( status < 0 ) status = errno;
18610 #endif
18611         if( status ) return status;
18612 #else
18613         /* Draft 4 pthreads */
18614         status = pthread_create( &t, pthread_attr_default, task, NULL );
18615         if( status ) return errno;
18616
18617         /* give thread a chance to complete */
18618         /* it should remain joinable and hence detachable */
18619         sleep( 1 );
18620
18621         status = pthread_detach( &t );
18622         if( status ) return errno;
18623 #endif
18624
18625 #ifdef HAVE_LINUX_THREADS
18626         pthread_kill_other_threads_np();
18627 #endif
18628
18629         return 0;
18630
18631   ;
18632   return 0;
18633 }
18634 _ACEOF
18635 rm -f conftest.$ac_objext conftest$ac_exeext
18636 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18637   (eval $ac_link) 2>&5
18638   ac_status=$?
18639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18640   (exit $ac_status); } &&
18641          { ac_try='test -s conftest$ac_exeext'
18642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18643   (eval $ac_try) 2>&5
18644   ac_status=$?
18645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18646   (exit $ac_status); }; }; then
18647   ol_cv_pthread_thread=yes
18648 else
18649   echo "$as_me: failed program was:" >&5
18650 sed 's/^/| /' conftest.$ac_ext >&5
18651
18652 ol_cv_pthread_thread=no
18653 fi
18654 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18655 else
18656   cat >conftest.$ac_ext <<_ACEOF
18657 #line $LINENO "configure"
18658 /* confdefs.h.  */
18659 _ACEOF
18660 cat confdefs.h >>conftest.$ac_ext
18661 cat >>conftest.$ac_ext <<_ACEOF
18662 /* end confdefs.h.  */
18663 /* pthread test headers */
18664 #include <pthread.h>
18665 #if HAVE_PTHREADS < 7
18666 #include <errno.h>
18667 #endif
18668 #ifndef NULL
18669 #define NULL (void*)0
18670 #endif
18671
18672 static void *task(p)
18673         void *p;
18674 {
18675         return (void *) (p == NULL);
18676 }
18677
18678
18679 int main(argc, argv)
18680         int argc;
18681         char **argv;
18682 {
18683
18684         /* pthread test function */
18685 #ifndef PTHREAD_CREATE_DETACHED
18686 #define PTHREAD_CREATE_DETACHED 1
18687 #endif
18688         pthread_t t;
18689         int status;
18690         int detach = PTHREAD_CREATE_DETACHED;
18691
18692 #if HAVE_PTHREADS > 4
18693         /* Final pthreads */
18694         pthread_attr_t attr;
18695
18696         status = pthread_attr_init(&attr);
18697         if( status ) return status;
18698
18699 #if HAVE_PTHREADS < 7
18700         status = pthread_attr_setdetachstate(&attr, &detach);
18701         if( status < 0 ) status = errno;
18702 #else
18703         status = pthread_attr_setdetachstate(&attr, detach);
18704 #endif
18705         if( status ) return status;
18706         status = pthread_create( &t, &attr, task, NULL );
18707 #if HAVE_PTHREADS < 7
18708         if( status < 0 ) status = errno;
18709 #endif
18710         if( status ) return status;
18711 #else
18712         /* Draft 4 pthreads */
18713         status = pthread_create( &t, pthread_attr_default, task, NULL );
18714         if( status ) return errno;
18715
18716         /* give thread a chance to complete */
18717         /* it should remain joinable and hence detachable */
18718         sleep( 1 );
18719
18720         status = pthread_detach( &t );
18721         if( status ) return errno;
18722 #endif
18723
18724 #ifdef HAVE_LINUX_THREADS
18725         pthread_kill_other_threads_np();
18726 #endif
18727
18728         return 0;
18729
18730 }
18731
18732 _ACEOF
18733 rm -f conftest$ac_exeext
18734 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18735   (eval $ac_link) 2>&5
18736   ac_status=$?
18737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18738   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18740   (eval $ac_try) 2>&5
18741   ac_status=$?
18742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18743   (exit $ac_status); }; }; then
18744   ol_cv_pthread_thread=yes
18745 else
18746   echo "$as_me: program exited with status $ac_status" >&5
18747 echo "$as_me: failed program was:" >&5
18748 sed 's/^/| /' conftest.$ac_ext >&5
18749
18750 ( exit $ac_status )
18751 ol_cv_pthread_thread=no
18752 fi
18753 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18754 fi
18755
18756                 # restore the LIBS
18757                 LIBS="$ol_LIBS"
18758
18759 fi
18760 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
18761 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
18762
18763         if test $ol_cv_pthread_thread = yes ; then
18764                 ol_link_pthreads="-thread"
18765                 ol_link_threads=posix
18766         fi
18767 fi
18768
18769
18770                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
18771 if test "$ol_link_threads" = no ; then
18772         # try -lpthread -lmach -lexc -lc_r
18773         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
18774 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
18775 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
18776   echo $ECHO_N "(cached) $ECHO_C" >&6
18777 else
18778
18779                 # save the flags
18780                 ol_LIBS="$LIBS"
18781                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
18782
18783                 if test "$cross_compiling" = yes; then
18784   cat >conftest.$ac_ext <<_ACEOF
18785 #line $LINENO "configure"
18786 /* confdefs.h.  */
18787 _ACEOF
18788 cat confdefs.h >>conftest.$ac_ext
18789 cat >>conftest.$ac_ext <<_ACEOF
18790 /* end confdefs.h.  */
18791 /* pthread test headers */
18792 #include <pthread.h>
18793 #if HAVE_PTHREADS < 7
18794 #include <errno.h>
18795 #endif
18796 #ifndef NULL
18797 #define NULL (void*)0
18798 #endif
18799
18800 static void *task(p)
18801         void *p;
18802 {
18803         return (void *) (p == NULL);
18804 }
18805
18806 int
18807 main ()
18808 {
18809
18810         /* pthread test function */
18811 #ifndef PTHREAD_CREATE_DETACHED
18812 #define PTHREAD_CREATE_DETACHED 1
18813 #endif
18814         pthread_t t;
18815         int status;
18816         int detach = PTHREAD_CREATE_DETACHED;
18817
18818 #if HAVE_PTHREADS > 4
18819         /* Final pthreads */
18820         pthread_attr_t attr;
18821
18822         status = pthread_attr_init(&attr);
18823         if( status ) return status;
18824
18825 #if HAVE_PTHREADS < 7
18826         status = pthread_attr_setdetachstate(&attr, &detach);
18827         if( status < 0 ) status = errno;
18828 #else
18829         status = pthread_attr_setdetachstate(&attr, detach);
18830 #endif
18831         if( status ) return status;
18832         status = pthread_create( &t, &attr, task, NULL );
18833 #if HAVE_PTHREADS < 7
18834         if( status < 0 ) status = errno;
18835 #endif
18836         if( status ) return status;
18837 #else
18838         /* Draft 4 pthreads */
18839         status = pthread_create( &t, pthread_attr_default, task, NULL );
18840         if( status ) return errno;
18841
18842         /* give thread a chance to complete */
18843         /* it should remain joinable and hence detachable */
18844         sleep( 1 );
18845
18846         status = pthread_detach( &t );
18847         if( status ) return errno;
18848 #endif
18849
18850 #ifdef HAVE_LINUX_THREADS
18851         pthread_kill_other_threads_np();
18852 #endif
18853
18854         return 0;
18855
18856   ;
18857   return 0;
18858 }
18859 _ACEOF
18860 rm -f conftest.$ac_objext conftest$ac_exeext
18861 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18862   (eval $ac_link) 2>&5
18863   ac_status=$?
18864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18865   (exit $ac_status); } &&
18866          { ac_try='test -s conftest$ac_exeext'
18867   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18868   (eval $ac_try) 2>&5
18869   ac_status=$?
18870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18871   (exit $ac_status); }; }; then
18872   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
18873 else
18874   echo "$as_me: failed program was:" >&5
18875 sed 's/^/| /' conftest.$ac_ext >&5
18876
18877 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
18878 fi
18879 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18880 else
18881   cat >conftest.$ac_ext <<_ACEOF
18882 #line $LINENO "configure"
18883 /* confdefs.h.  */
18884 _ACEOF
18885 cat confdefs.h >>conftest.$ac_ext
18886 cat >>conftest.$ac_ext <<_ACEOF
18887 /* end confdefs.h.  */
18888 /* pthread test headers */
18889 #include <pthread.h>
18890 #if HAVE_PTHREADS < 7
18891 #include <errno.h>
18892 #endif
18893 #ifndef NULL
18894 #define NULL (void*)0
18895 #endif
18896
18897 static void *task(p)
18898         void *p;
18899 {
18900         return (void *) (p == NULL);
18901 }
18902
18903
18904 int main(argc, argv)
18905         int argc;
18906         char **argv;
18907 {
18908
18909         /* pthread test function */
18910 #ifndef PTHREAD_CREATE_DETACHED
18911 #define PTHREAD_CREATE_DETACHED 1
18912 #endif
18913         pthread_t t;
18914         int status;
18915         int detach = PTHREAD_CREATE_DETACHED;
18916
18917 #if HAVE_PTHREADS > 4
18918         /* Final pthreads */
18919         pthread_attr_t attr;
18920
18921         status = pthread_attr_init(&attr);
18922         if( status ) return status;
18923
18924 #if HAVE_PTHREADS < 7
18925         status = pthread_attr_setdetachstate(&attr, &detach);
18926         if( status < 0 ) status = errno;
18927 #else
18928         status = pthread_attr_setdetachstate(&attr, detach);
18929 #endif
18930         if( status ) return status;
18931         status = pthread_create( &t, &attr, task, NULL );
18932 #if HAVE_PTHREADS < 7
18933         if( status < 0 ) status = errno;
18934 #endif
18935         if( status ) return status;
18936 #else
18937         /* Draft 4 pthreads */
18938         status = pthread_create( &t, pthread_attr_default, task, NULL );
18939         if( status ) return errno;
18940
18941         /* give thread a chance to complete */
18942         /* it should remain joinable and hence detachable */
18943         sleep( 1 );
18944
18945         status = pthread_detach( &t );
18946         if( status ) return errno;
18947 #endif
18948
18949 #ifdef HAVE_LINUX_THREADS
18950         pthread_kill_other_threads_np();
18951 #endif
18952
18953         return 0;
18954
18955 }
18956
18957 _ACEOF
18958 rm -f conftest$ac_exeext
18959 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18960   (eval $ac_link) 2>&5
18961   ac_status=$?
18962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18963   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18965   (eval $ac_try) 2>&5
18966   ac_status=$?
18967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18968   (exit $ac_status); }; }; then
18969   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
18970 else
18971   echo "$as_me: program exited with status $ac_status" >&5
18972 echo "$as_me: failed program was:" >&5
18973 sed 's/^/| /' conftest.$ac_ext >&5
18974
18975 ( exit $ac_status )
18976 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
18977 fi
18978 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18979 fi
18980
18981                 # restore the LIBS
18982                 LIBS="$ol_LIBS"
18983
18984 fi
18985 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
18986 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
18987
18988         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
18989                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
18990                 ol_link_threads=posix
18991         fi
18992 fi
18993
18994                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
18995 if test "$ol_link_threads" = no ; then
18996         # try -lpthread -lmach -lexc
18997         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
18998 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
18999 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
19000   echo $ECHO_N "(cached) $ECHO_C" >&6
19001 else
19002
19003                 # save the flags
19004                 ol_LIBS="$LIBS"
19005                 LIBS="-lpthread -lmach -lexc $LIBS"
19006
19007                 if test "$cross_compiling" = yes; then
19008   cat >conftest.$ac_ext <<_ACEOF
19009 #line $LINENO "configure"
19010 /* confdefs.h.  */
19011 _ACEOF
19012 cat confdefs.h >>conftest.$ac_ext
19013 cat >>conftest.$ac_ext <<_ACEOF
19014 /* end confdefs.h.  */
19015 /* pthread test headers */
19016 #include <pthread.h>
19017 #if HAVE_PTHREADS < 7
19018 #include <errno.h>
19019 #endif
19020 #ifndef NULL
19021 #define NULL (void*)0
19022 #endif
19023
19024 static void *task(p)
19025         void *p;
19026 {
19027         return (void *) (p == NULL);
19028 }
19029
19030 int
19031 main ()
19032 {
19033
19034         /* pthread test function */
19035 #ifndef PTHREAD_CREATE_DETACHED
19036 #define PTHREAD_CREATE_DETACHED 1
19037 #endif
19038         pthread_t t;
19039         int status;
19040         int detach = PTHREAD_CREATE_DETACHED;
19041
19042 #if HAVE_PTHREADS > 4
19043         /* Final pthreads */
19044         pthread_attr_t attr;
19045
19046         status = pthread_attr_init(&attr);
19047         if( status ) return status;
19048
19049 #if HAVE_PTHREADS < 7
19050         status = pthread_attr_setdetachstate(&attr, &detach);
19051         if( status < 0 ) status = errno;
19052 #else
19053         status = pthread_attr_setdetachstate(&attr, detach);
19054 #endif
19055         if( status ) return status;
19056         status = pthread_create( &t, &attr, task, NULL );
19057 #if HAVE_PTHREADS < 7
19058         if( status < 0 ) status = errno;
19059 #endif
19060         if( status ) return status;
19061 #else
19062         /* Draft 4 pthreads */
19063         status = pthread_create( &t, pthread_attr_default, task, NULL );
19064         if( status ) return errno;
19065
19066         /* give thread a chance to complete */
19067         /* it should remain joinable and hence detachable */
19068         sleep( 1 );
19069
19070         status = pthread_detach( &t );
19071         if( status ) return errno;
19072 #endif
19073
19074 #ifdef HAVE_LINUX_THREADS
19075         pthread_kill_other_threads_np();
19076 #endif
19077
19078         return 0;
19079
19080   ;
19081   return 0;
19082 }
19083 _ACEOF
19084 rm -f conftest.$ac_objext conftest$ac_exeext
19085 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19086   (eval $ac_link) 2>&5
19087   ac_status=$?
19088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19089   (exit $ac_status); } &&
19090          { ac_try='test -s conftest$ac_exeext'
19091   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19092   (eval $ac_try) 2>&5
19093   ac_status=$?
19094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19095   (exit $ac_status); }; }; then
19096   ol_cv_pthread_lpthread_lmach_lexc=yes
19097 else
19098   echo "$as_me: failed program was:" >&5
19099 sed 's/^/| /' conftest.$ac_ext >&5
19100
19101 ol_cv_pthread_lpthread_lmach_lexc=no
19102 fi
19103 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19104 else
19105   cat >conftest.$ac_ext <<_ACEOF
19106 #line $LINENO "configure"
19107 /* confdefs.h.  */
19108 _ACEOF
19109 cat confdefs.h >>conftest.$ac_ext
19110 cat >>conftest.$ac_ext <<_ACEOF
19111 /* end confdefs.h.  */
19112 /* pthread test headers */
19113 #include <pthread.h>
19114 #if HAVE_PTHREADS < 7
19115 #include <errno.h>
19116 #endif
19117 #ifndef NULL
19118 #define NULL (void*)0
19119 #endif
19120
19121 static void *task(p)
19122         void *p;
19123 {
19124         return (void *) (p == NULL);
19125 }
19126
19127
19128 int main(argc, argv)
19129         int argc;
19130         char **argv;
19131 {
19132
19133         /* pthread test function */
19134 #ifndef PTHREAD_CREATE_DETACHED
19135 #define PTHREAD_CREATE_DETACHED 1
19136 #endif
19137         pthread_t t;
19138         int status;
19139         int detach = PTHREAD_CREATE_DETACHED;
19140
19141 #if HAVE_PTHREADS > 4
19142         /* Final pthreads */
19143         pthread_attr_t attr;
19144
19145         status = pthread_attr_init(&attr);
19146         if( status ) return status;
19147
19148 #if HAVE_PTHREADS < 7
19149         status = pthread_attr_setdetachstate(&attr, &detach);
19150         if( status < 0 ) status = errno;
19151 #else
19152         status = pthread_attr_setdetachstate(&attr, detach);
19153 #endif
19154         if( status ) return status;
19155         status = pthread_create( &t, &attr, task, NULL );
19156 #if HAVE_PTHREADS < 7
19157         if( status < 0 ) status = errno;
19158 #endif
19159         if( status ) return status;
19160 #else
19161         /* Draft 4 pthreads */
19162         status = pthread_create( &t, pthread_attr_default, task, NULL );
19163         if( status ) return errno;
19164
19165         /* give thread a chance to complete */
19166         /* it should remain joinable and hence detachable */
19167         sleep( 1 );
19168
19169         status = pthread_detach( &t );
19170         if( status ) return errno;
19171 #endif
19172
19173 #ifdef HAVE_LINUX_THREADS
19174         pthread_kill_other_threads_np();
19175 #endif
19176
19177         return 0;
19178
19179 }
19180
19181 _ACEOF
19182 rm -f conftest$ac_exeext
19183 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19184   (eval $ac_link) 2>&5
19185   ac_status=$?
19186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19187   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19189   (eval $ac_try) 2>&5
19190   ac_status=$?
19191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19192   (exit $ac_status); }; }; then
19193   ol_cv_pthread_lpthread_lmach_lexc=yes
19194 else
19195   echo "$as_me: program exited with status $ac_status" >&5
19196 echo "$as_me: failed program was:" >&5
19197 sed 's/^/| /' conftest.$ac_ext >&5
19198
19199 ( exit $ac_status )
19200 ol_cv_pthread_lpthread_lmach_lexc=no
19201 fi
19202 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19203 fi
19204
19205                 # restore the LIBS
19206                 LIBS="$ol_LIBS"
19207
19208 fi
19209 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
19210 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
19211
19212         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
19213                 ol_link_pthreads="-lpthread -lmach -lexc"
19214                 ol_link_threads=posix
19215         fi
19216 fi
19217
19218
19219                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
19220 if test "$ol_link_threads" = no ; then
19221         # try -lpthread -Wl,-woff,85
19222         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
19223 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
19224 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
19225   echo $ECHO_N "(cached) $ECHO_C" >&6
19226 else
19227
19228                 # save the flags
19229                 ol_LIBS="$LIBS"
19230                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
19231
19232                 if test "$cross_compiling" = yes; then
19233   cat >conftest.$ac_ext <<_ACEOF
19234 #line $LINENO "configure"
19235 /* confdefs.h.  */
19236 _ACEOF
19237 cat confdefs.h >>conftest.$ac_ext
19238 cat >>conftest.$ac_ext <<_ACEOF
19239 /* end confdefs.h.  */
19240 /* pthread test headers */
19241 #include <pthread.h>
19242 #if HAVE_PTHREADS < 7
19243 #include <errno.h>
19244 #endif
19245 #ifndef NULL
19246 #define NULL (void*)0
19247 #endif
19248
19249 static void *task(p)
19250         void *p;
19251 {
19252         return (void *) (p == NULL);
19253 }
19254
19255 int
19256 main ()
19257 {
19258
19259         /* pthread test function */
19260 #ifndef PTHREAD_CREATE_DETACHED
19261 #define PTHREAD_CREATE_DETACHED 1
19262 #endif
19263         pthread_t t;
19264         int status;
19265         int detach = PTHREAD_CREATE_DETACHED;
19266
19267 #if HAVE_PTHREADS > 4
19268         /* Final pthreads */
19269         pthread_attr_t attr;
19270
19271         status = pthread_attr_init(&attr);
19272         if( status ) return status;
19273
19274 #if HAVE_PTHREADS < 7
19275         status = pthread_attr_setdetachstate(&attr, &detach);
19276         if( status < 0 ) status = errno;
19277 #else
19278         status = pthread_attr_setdetachstate(&attr, detach);
19279 #endif
19280         if( status ) return status;
19281         status = pthread_create( &t, &attr, task, NULL );
19282 #if HAVE_PTHREADS < 7
19283         if( status < 0 ) status = errno;
19284 #endif
19285         if( status ) return status;
19286 #else
19287         /* Draft 4 pthreads */
19288         status = pthread_create( &t, pthread_attr_default, task, NULL );
19289         if( status ) return errno;
19290
19291         /* give thread a chance to complete */
19292         /* it should remain joinable and hence detachable */
19293         sleep( 1 );
19294
19295         status = pthread_detach( &t );
19296         if( status ) return errno;
19297 #endif
19298
19299 #ifdef HAVE_LINUX_THREADS
19300         pthread_kill_other_threads_np();
19301 #endif
19302
19303         return 0;
19304
19305   ;
19306   return 0;
19307 }
19308 _ACEOF
19309 rm -f conftest.$ac_objext conftest$ac_exeext
19310 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19311   (eval $ac_link) 2>&5
19312   ac_status=$?
19313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19314   (exit $ac_status); } &&
19315          { ac_try='test -s conftest$ac_exeext'
19316   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19317   (eval $ac_try) 2>&5
19318   ac_status=$?
19319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19320   (exit $ac_status); }; }; then
19321   ol_cv_pthread_lib_lpthread_woff=yes
19322 else
19323   echo "$as_me: failed program was:" >&5
19324 sed 's/^/| /' conftest.$ac_ext >&5
19325
19326 ol_cv_pthread_lib_lpthread_woff=no
19327 fi
19328 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19329 else
19330   cat >conftest.$ac_ext <<_ACEOF
19331 #line $LINENO "configure"
19332 /* confdefs.h.  */
19333 _ACEOF
19334 cat confdefs.h >>conftest.$ac_ext
19335 cat >>conftest.$ac_ext <<_ACEOF
19336 /* end confdefs.h.  */
19337 /* pthread test headers */
19338 #include <pthread.h>
19339 #if HAVE_PTHREADS < 7
19340 #include <errno.h>
19341 #endif
19342 #ifndef NULL
19343 #define NULL (void*)0
19344 #endif
19345
19346 static void *task(p)
19347         void *p;
19348 {
19349         return (void *) (p == NULL);
19350 }
19351
19352
19353 int main(argc, argv)
19354         int argc;
19355         char **argv;
19356 {
19357
19358         /* pthread test function */
19359 #ifndef PTHREAD_CREATE_DETACHED
19360 #define PTHREAD_CREATE_DETACHED 1
19361 #endif
19362         pthread_t t;
19363         int status;
19364         int detach = PTHREAD_CREATE_DETACHED;
19365
19366 #if HAVE_PTHREADS > 4
19367         /* Final pthreads */
19368         pthread_attr_t attr;
19369
19370         status = pthread_attr_init(&attr);
19371         if( status ) return status;
19372
19373 #if HAVE_PTHREADS < 7
19374         status = pthread_attr_setdetachstate(&attr, &detach);
19375         if( status < 0 ) status = errno;
19376 #else
19377         status = pthread_attr_setdetachstate(&attr, detach);
19378 #endif
19379         if( status ) return status;
19380         status = pthread_create( &t, &attr, task, NULL );
19381 #if HAVE_PTHREADS < 7
19382         if( status < 0 ) status = errno;
19383 #endif
19384         if( status ) return status;
19385 #else
19386         /* Draft 4 pthreads */
19387         status = pthread_create( &t, pthread_attr_default, task, NULL );
19388         if( status ) return errno;
19389
19390         /* give thread a chance to complete */
19391         /* it should remain joinable and hence detachable */
19392         sleep( 1 );
19393
19394         status = pthread_detach( &t );
19395         if( status ) return errno;
19396 #endif
19397
19398 #ifdef HAVE_LINUX_THREADS
19399         pthread_kill_other_threads_np();
19400 #endif
19401
19402         return 0;
19403
19404 }
19405
19406 _ACEOF
19407 rm -f conftest$ac_exeext
19408 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19409   (eval $ac_link) 2>&5
19410   ac_status=$?
19411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19412   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19414   (eval $ac_try) 2>&5
19415   ac_status=$?
19416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19417   (exit $ac_status); }; }; then
19418   ol_cv_pthread_lib_lpthread_woff=yes
19419 else
19420   echo "$as_me: program exited with status $ac_status" >&5
19421 echo "$as_me: failed program was:" >&5
19422 sed 's/^/| /' conftest.$ac_ext >&5
19423
19424 ( exit $ac_status )
19425 ol_cv_pthread_lib_lpthread_woff=no
19426 fi
19427 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19428 fi
19429
19430                 # restore the LIBS
19431                 LIBS="$ol_LIBS"
19432
19433 fi
19434 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
19435 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
19436
19437         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
19438                 ol_link_pthreads="-lpthread -Wl,-woff,85"
19439                 ol_link_threads=posix
19440         fi
19441 fi
19442
19443
19444                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
19445 if test "$ol_link_threads" = no ; then
19446         # try -lpthread
19447         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
19448 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
19449 if test "${ol_cv_pthread_lpthread+set}" = set; then
19450   echo $ECHO_N "(cached) $ECHO_C" >&6
19451 else
19452
19453                 # save the flags
19454                 ol_LIBS="$LIBS"
19455                 LIBS="-lpthread $LIBS"
19456
19457                 if test "$cross_compiling" = yes; then
19458   cat >conftest.$ac_ext <<_ACEOF
19459 #line $LINENO "configure"
19460 /* confdefs.h.  */
19461 _ACEOF
19462 cat confdefs.h >>conftest.$ac_ext
19463 cat >>conftest.$ac_ext <<_ACEOF
19464 /* end confdefs.h.  */
19465 /* pthread test headers */
19466 #include <pthread.h>
19467 #if HAVE_PTHREADS < 7
19468 #include <errno.h>
19469 #endif
19470 #ifndef NULL
19471 #define NULL (void*)0
19472 #endif
19473
19474 static void *task(p)
19475         void *p;
19476 {
19477         return (void *) (p == NULL);
19478 }
19479
19480 int
19481 main ()
19482 {
19483
19484         /* pthread test function */
19485 #ifndef PTHREAD_CREATE_DETACHED
19486 #define PTHREAD_CREATE_DETACHED 1
19487 #endif
19488         pthread_t t;
19489         int status;
19490         int detach = PTHREAD_CREATE_DETACHED;
19491
19492 #if HAVE_PTHREADS > 4
19493         /* Final pthreads */
19494         pthread_attr_t attr;
19495
19496         status = pthread_attr_init(&attr);
19497         if( status ) return status;
19498
19499 #if HAVE_PTHREADS < 7
19500         status = pthread_attr_setdetachstate(&attr, &detach);
19501         if( status < 0 ) status = errno;
19502 #else
19503         status = pthread_attr_setdetachstate(&attr, detach);
19504 #endif
19505         if( status ) return status;
19506         status = pthread_create( &t, &attr, task, NULL );
19507 #if HAVE_PTHREADS < 7
19508         if( status < 0 ) status = errno;
19509 #endif
19510         if( status ) return status;
19511 #else
19512         /* Draft 4 pthreads */
19513         status = pthread_create( &t, pthread_attr_default, task, NULL );
19514         if( status ) return errno;
19515
19516         /* give thread a chance to complete */
19517         /* it should remain joinable and hence detachable */
19518         sleep( 1 );
19519
19520         status = pthread_detach( &t );
19521         if( status ) return errno;
19522 #endif
19523
19524 #ifdef HAVE_LINUX_THREADS
19525         pthread_kill_other_threads_np();
19526 #endif
19527
19528         return 0;
19529
19530   ;
19531   return 0;
19532 }
19533 _ACEOF
19534 rm -f conftest.$ac_objext conftest$ac_exeext
19535 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19536   (eval $ac_link) 2>&5
19537   ac_status=$?
19538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19539   (exit $ac_status); } &&
19540          { ac_try='test -s conftest$ac_exeext'
19541   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19542   (eval $ac_try) 2>&5
19543   ac_status=$?
19544   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19545   (exit $ac_status); }; }; then
19546   ol_cv_pthread_lpthread=yes
19547 else
19548   echo "$as_me: failed program was:" >&5
19549 sed 's/^/| /' conftest.$ac_ext >&5
19550
19551 ol_cv_pthread_lpthread=no
19552 fi
19553 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19554 else
19555   cat >conftest.$ac_ext <<_ACEOF
19556 #line $LINENO "configure"
19557 /* confdefs.h.  */
19558 _ACEOF
19559 cat confdefs.h >>conftest.$ac_ext
19560 cat >>conftest.$ac_ext <<_ACEOF
19561 /* end confdefs.h.  */
19562 /* pthread test headers */
19563 #include <pthread.h>
19564 #if HAVE_PTHREADS < 7
19565 #include <errno.h>
19566 #endif
19567 #ifndef NULL
19568 #define NULL (void*)0
19569 #endif
19570
19571 static void *task(p)
19572         void *p;
19573 {
19574         return (void *) (p == NULL);
19575 }
19576
19577
19578 int main(argc, argv)
19579         int argc;
19580         char **argv;
19581 {
19582
19583         /* pthread test function */
19584 #ifndef PTHREAD_CREATE_DETACHED
19585 #define PTHREAD_CREATE_DETACHED 1
19586 #endif
19587         pthread_t t;
19588         int status;
19589         int detach = PTHREAD_CREATE_DETACHED;
19590
19591 #if HAVE_PTHREADS > 4
19592         /* Final pthreads */
19593         pthread_attr_t attr;
19594
19595         status = pthread_attr_init(&attr);
19596         if( status ) return status;
19597
19598 #if HAVE_PTHREADS < 7
19599         status = pthread_attr_setdetachstate(&attr, &detach);
19600         if( status < 0 ) status = errno;
19601 #else
19602         status = pthread_attr_setdetachstate(&attr, detach);
19603 #endif
19604         if( status ) return status;
19605         status = pthread_create( &t, &attr, task, NULL );
19606 #if HAVE_PTHREADS < 7
19607         if( status < 0 ) status = errno;
19608 #endif
19609         if( status ) return status;
19610 #else
19611         /* Draft 4 pthreads */
19612         status = pthread_create( &t, pthread_attr_default, task, NULL );
19613         if( status ) return errno;
19614
19615         /* give thread a chance to complete */
19616         /* it should remain joinable and hence detachable */
19617         sleep( 1 );
19618
19619         status = pthread_detach( &t );
19620         if( status ) return errno;
19621 #endif
19622
19623 #ifdef HAVE_LINUX_THREADS
19624         pthread_kill_other_threads_np();
19625 #endif
19626
19627         return 0;
19628
19629 }
19630
19631 _ACEOF
19632 rm -f conftest$ac_exeext
19633 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19634   (eval $ac_link) 2>&5
19635   ac_status=$?
19636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19637   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19639   (eval $ac_try) 2>&5
19640   ac_status=$?
19641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19642   (exit $ac_status); }; }; then
19643   ol_cv_pthread_lpthread=yes
19644 else
19645   echo "$as_me: program exited with status $ac_status" >&5
19646 echo "$as_me: failed program was:" >&5
19647 sed 's/^/| /' conftest.$ac_ext >&5
19648
19649 ( exit $ac_status )
19650 ol_cv_pthread_lpthread=no
19651 fi
19652 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19653 fi
19654
19655                 # restore the LIBS
19656                 LIBS="$ol_LIBS"
19657
19658 fi
19659 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
19660 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
19661
19662         if test $ol_cv_pthread_lpthread = yes ; then
19663                 ol_link_pthreads="-lpthread"
19664                 ol_link_threads=posix
19665         fi
19666 fi
19667
19668                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
19669 if test "$ol_link_threads" = no ; then
19670         # try -lc_r
19671         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
19672 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
19673 if test "${ol_cv_pthread_lc_r+set}" = set; then
19674   echo $ECHO_N "(cached) $ECHO_C" >&6
19675 else
19676
19677                 # save the flags
19678                 ol_LIBS="$LIBS"
19679                 LIBS="-lc_r $LIBS"
19680
19681                 if test "$cross_compiling" = yes; then
19682   cat >conftest.$ac_ext <<_ACEOF
19683 #line $LINENO "configure"
19684 /* confdefs.h.  */
19685 _ACEOF
19686 cat confdefs.h >>conftest.$ac_ext
19687 cat >>conftest.$ac_ext <<_ACEOF
19688 /* end confdefs.h.  */
19689 /* pthread test headers */
19690 #include <pthread.h>
19691 #if HAVE_PTHREADS < 7
19692 #include <errno.h>
19693 #endif
19694 #ifndef NULL
19695 #define NULL (void*)0
19696 #endif
19697
19698 static void *task(p)
19699         void *p;
19700 {
19701         return (void *) (p == NULL);
19702 }
19703
19704 int
19705 main ()
19706 {
19707
19708         /* pthread test function */
19709 #ifndef PTHREAD_CREATE_DETACHED
19710 #define PTHREAD_CREATE_DETACHED 1
19711 #endif
19712         pthread_t t;
19713         int status;
19714         int detach = PTHREAD_CREATE_DETACHED;
19715
19716 #if HAVE_PTHREADS > 4
19717         /* Final pthreads */
19718         pthread_attr_t attr;
19719
19720         status = pthread_attr_init(&attr);
19721         if( status ) return status;
19722
19723 #if HAVE_PTHREADS < 7
19724         status = pthread_attr_setdetachstate(&attr, &detach);
19725         if( status < 0 ) status = errno;
19726 #else
19727         status = pthread_attr_setdetachstate(&attr, detach);
19728 #endif
19729         if( status ) return status;
19730         status = pthread_create( &t, &attr, task, NULL );
19731 #if HAVE_PTHREADS < 7
19732         if( status < 0 ) status = errno;
19733 #endif
19734         if( status ) return status;
19735 #else
19736         /* Draft 4 pthreads */
19737         status = pthread_create( &t, pthread_attr_default, task, NULL );
19738         if( status ) return errno;
19739
19740         /* give thread a chance to complete */
19741         /* it should remain joinable and hence detachable */
19742         sleep( 1 );
19743
19744         status = pthread_detach( &t );
19745         if( status ) return errno;
19746 #endif
19747
19748 #ifdef HAVE_LINUX_THREADS
19749         pthread_kill_other_threads_np();
19750 #endif
19751
19752         return 0;
19753
19754   ;
19755   return 0;
19756 }
19757 _ACEOF
19758 rm -f conftest.$ac_objext conftest$ac_exeext
19759 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19760   (eval $ac_link) 2>&5
19761   ac_status=$?
19762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19763   (exit $ac_status); } &&
19764          { ac_try='test -s conftest$ac_exeext'
19765   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19766   (eval $ac_try) 2>&5
19767   ac_status=$?
19768   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19769   (exit $ac_status); }; }; then
19770   ol_cv_pthread_lc_r=yes
19771 else
19772   echo "$as_me: failed program was:" >&5
19773 sed 's/^/| /' conftest.$ac_ext >&5
19774
19775 ol_cv_pthread_lc_r=no
19776 fi
19777 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19778 else
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 /* pthread test headers */
19787 #include <pthread.h>
19788 #if HAVE_PTHREADS < 7
19789 #include <errno.h>
19790 #endif
19791 #ifndef NULL
19792 #define NULL (void*)0
19793 #endif
19794
19795 static void *task(p)
19796         void *p;
19797 {
19798         return (void *) (p == NULL);
19799 }
19800
19801
19802 int main(argc, argv)
19803         int argc;
19804         char **argv;
19805 {
19806
19807         /* pthread test function */
19808 #ifndef PTHREAD_CREATE_DETACHED
19809 #define PTHREAD_CREATE_DETACHED 1
19810 #endif
19811         pthread_t t;
19812         int status;
19813         int detach = PTHREAD_CREATE_DETACHED;
19814
19815 #if HAVE_PTHREADS > 4
19816         /* Final pthreads */
19817         pthread_attr_t attr;
19818
19819         status = pthread_attr_init(&attr);
19820         if( status ) return status;
19821
19822 #if HAVE_PTHREADS < 7
19823         status = pthread_attr_setdetachstate(&attr, &detach);
19824         if( status < 0 ) status = errno;
19825 #else
19826         status = pthread_attr_setdetachstate(&attr, detach);
19827 #endif
19828         if( status ) return status;
19829         status = pthread_create( &t, &attr, task, NULL );
19830 #if HAVE_PTHREADS < 7
19831         if( status < 0 ) status = errno;
19832 #endif
19833         if( status ) return status;
19834 #else
19835         /* Draft 4 pthreads */
19836         status = pthread_create( &t, pthread_attr_default, task, NULL );
19837         if( status ) return errno;
19838
19839         /* give thread a chance to complete */
19840         /* it should remain joinable and hence detachable */
19841         sleep( 1 );
19842
19843         status = pthread_detach( &t );
19844         if( status ) return errno;
19845 #endif
19846
19847 #ifdef HAVE_LINUX_THREADS
19848         pthread_kill_other_threads_np();
19849 #endif
19850
19851         return 0;
19852
19853 }
19854
19855 _ACEOF
19856 rm -f conftest$ac_exeext
19857 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19858   (eval $ac_link) 2>&5
19859   ac_status=$?
19860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19861   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19862   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19863   (eval $ac_try) 2>&5
19864   ac_status=$?
19865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19866   (exit $ac_status); }; }; then
19867   ol_cv_pthread_lc_r=yes
19868 else
19869   echo "$as_me: program exited with status $ac_status" >&5
19870 echo "$as_me: failed program was:" >&5
19871 sed 's/^/| /' conftest.$ac_ext >&5
19872
19873 ( exit $ac_status )
19874 ol_cv_pthread_lc_r=no
19875 fi
19876 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19877 fi
19878
19879                 # restore the LIBS
19880                 LIBS="$ol_LIBS"
19881
19882 fi
19883 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
19884 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
19885
19886         if test $ol_cv_pthread_lc_r = yes ; then
19887                 ol_link_pthreads="-lc_r"
19888                 ol_link_threads=posix
19889         fi
19890 fi
19891
19892
19893                 # Pthread try link: -threads (ol_cv_pthread_threads)
19894 if test "$ol_link_threads" = no ; then
19895         # try -threads
19896         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
19897 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
19898 if test "${ol_cv_pthread_threads+set}" = set; then
19899   echo $ECHO_N "(cached) $ECHO_C" >&6
19900 else
19901
19902                 # save the flags
19903                 ol_LIBS="$LIBS"
19904                 LIBS="-threads $LIBS"
19905
19906                 if test "$cross_compiling" = yes; then
19907   cat >conftest.$ac_ext <<_ACEOF
19908 #line $LINENO "configure"
19909 /* confdefs.h.  */
19910 _ACEOF
19911 cat confdefs.h >>conftest.$ac_ext
19912 cat >>conftest.$ac_ext <<_ACEOF
19913 /* end confdefs.h.  */
19914 /* pthread test headers */
19915 #include <pthread.h>
19916 #if HAVE_PTHREADS < 7
19917 #include <errno.h>
19918 #endif
19919 #ifndef NULL
19920 #define NULL (void*)0
19921 #endif
19922
19923 static void *task(p)
19924         void *p;
19925 {
19926         return (void *) (p == NULL);
19927 }
19928
19929 int
19930 main ()
19931 {
19932
19933         /* pthread test function */
19934 #ifndef PTHREAD_CREATE_DETACHED
19935 #define PTHREAD_CREATE_DETACHED 1
19936 #endif
19937         pthread_t t;
19938         int status;
19939         int detach = PTHREAD_CREATE_DETACHED;
19940
19941 #if HAVE_PTHREADS > 4
19942         /* Final pthreads */
19943         pthread_attr_t attr;
19944
19945         status = pthread_attr_init(&attr);
19946         if( status ) return status;
19947
19948 #if HAVE_PTHREADS < 7
19949         status = pthread_attr_setdetachstate(&attr, &detach);
19950         if( status < 0 ) status = errno;
19951 #else
19952         status = pthread_attr_setdetachstate(&attr, detach);
19953 #endif
19954         if( status ) return status;
19955         status = pthread_create( &t, &attr, task, NULL );
19956 #if HAVE_PTHREADS < 7
19957         if( status < 0 ) status = errno;
19958 #endif
19959         if( status ) return status;
19960 #else
19961         /* Draft 4 pthreads */
19962         status = pthread_create( &t, pthread_attr_default, task, NULL );
19963         if( status ) return errno;
19964
19965         /* give thread a chance to complete */
19966         /* it should remain joinable and hence detachable */
19967         sleep( 1 );
19968
19969         status = pthread_detach( &t );
19970         if( status ) return errno;
19971 #endif
19972
19973 #ifdef HAVE_LINUX_THREADS
19974         pthread_kill_other_threads_np();
19975 #endif
19976
19977         return 0;
19978
19979   ;
19980   return 0;
19981 }
19982 _ACEOF
19983 rm -f conftest.$ac_objext conftest$ac_exeext
19984 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19985   (eval $ac_link) 2>&5
19986   ac_status=$?
19987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19988   (exit $ac_status); } &&
19989          { ac_try='test -s conftest$ac_exeext'
19990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19991   (eval $ac_try) 2>&5
19992   ac_status=$?
19993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19994   (exit $ac_status); }; }; then
19995   ol_cv_pthread_threads=yes
19996 else
19997   echo "$as_me: failed program was:" >&5
19998 sed 's/^/| /' conftest.$ac_ext >&5
19999
20000 ol_cv_pthread_threads=no
20001 fi
20002 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20003 else
20004   cat >conftest.$ac_ext <<_ACEOF
20005 #line $LINENO "configure"
20006 /* confdefs.h.  */
20007 _ACEOF
20008 cat confdefs.h >>conftest.$ac_ext
20009 cat >>conftest.$ac_ext <<_ACEOF
20010 /* end confdefs.h.  */
20011 /* pthread test headers */
20012 #include <pthread.h>
20013 #if HAVE_PTHREADS < 7
20014 #include <errno.h>
20015 #endif
20016 #ifndef NULL
20017 #define NULL (void*)0
20018 #endif
20019
20020 static void *task(p)
20021         void *p;
20022 {
20023         return (void *) (p == NULL);
20024 }
20025
20026
20027 int main(argc, argv)
20028         int argc;
20029         char **argv;
20030 {
20031
20032         /* pthread test function */
20033 #ifndef PTHREAD_CREATE_DETACHED
20034 #define PTHREAD_CREATE_DETACHED 1
20035 #endif
20036         pthread_t t;
20037         int status;
20038         int detach = PTHREAD_CREATE_DETACHED;
20039
20040 #if HAVE_PTHREADS > 4
20041         /* Final pthreads */
20042         pthread_attr_t attr;
20043
20044         status = pthread_attr_init(&attr);
20045         if( status ) return status;
20046
20047 #if HAVE_PTHREADS < 7
20048         status = pthread_attr_setdetachstate(&attr, &detach);
20049         if( status < 0 ) status = errno;
20050 #else
20051         status = pthread_attr_setdetachstate(&attr, detach);
20052 #endif
20053         if( status ) return status;
20054         status = pthread_create( &t, &attr, task, NULL );
20055 #if HAVE_PTHREADS < 7
20056         if( status < 0 ) status = errno;
20057 #endif
20058         if( status ) return status;
20059 #else
20060         /* Draft 4 pthreads */
20061         status = pthread_create( &t, pthread_attr_default, task, NULL );
20062         if( status ) return errno;
20063
20064         /* give thread a chance to complete */
20065         /* it should remain joinable and hence detachable */
20066         sleep( 1 );
20067
20068         status = pthread_detach( &t );
20069         if( status ) return errno;
20070 #endif
20071
20072 #ifdef HAVE_LINUX_THREADS
20073         pthread_kill_other_threads_np();
20074 #endif
20075
20076         return 0;
20077
20078 }
20079
20080 _ACEOF
20081 rm -f conftest$ac_exeext
20082 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20083   (eval $ac_link) 2>&5
20084   ac_status=$?
20085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20086   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20088   (eval $ac_try) 2>&5
20089   ac_status=$?
20090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20091   (exit $ac_status); }; }; then
20092   ol_cv_pthread_threads=yes
20093 else
20094   echo "$as_me: program exited with status $ac_status" >&5
20095 echo "$as_me: failed program was:" >&5
20096 sed 's/^/| /' conftest.$ac_ext >&5
20097
20098 ( exit $ac_status )
20099 ol_cv_pthread_threads=no
20100 fi
20101 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20102 fi
20103
20104                 # restore the LIBS
20105                 LIBS="$ol_LIBS"
20106
20107 fi
20108 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
20109 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
20110
20111         if test $ol_cv_pthread_threads = yes ; then
20112                 ol_link_pthreads="-threads"
20113                 ol_link_threads=posix
20114         fi
20115 fi
20116
20117
20118                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
20119 if test "$ol_link_threads" = no ; then
20120         # try -lpthreads -lmach -lexc -lc_r
20121         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
20122 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
20123 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
20124   echo $ECHO_N "(cached) $ECHO_C" >&6
20125 else
20126
20127                 # save the flags
20128                 ol_LIBS="$LIBS"
20129                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
20130
20131                 if test "$cross_compiling" = yes; then
20132   cat >conftest.$ac_ext <<_ACEOF
20133 #line $LINENO "configure"
20134 /* confdefs.h.  */
20135 _ACEOF
20136 cat confdefs.h >>conftest.$ac_ext
20137 cat >>conftest.$ac_ext <<_ACEOF
20138 /* end confdefs.h.  */
20139 /* pthread test headers */
20140 #include <pthread.h>
20141 #if HAVE_PTHREADS < 7
20142 #include <errno.h>
20143 #endif
20144 #ifndef NULL
20145 #define NULL (void*)0
20146 #endif
20147
20148 static void *task(p)
20149         void *p;
20150 {
20151         return (void *) (p == NULL);
20152 }
20153
20154 int
20155 main ()
20156 {
20157
20158         /* pthread test function */
20159 #ifndef PTHREAD_CREATE_DETACHED
20160 #define PTHREAD_CREATE_DETACHED 1
20161 #endif
20162         pthread_t t;
20163         int status;
20164         int detach = PTHREAD_CREATE_DETACHED;
20165
20166 #if HAVE_PTHREADS > 4
20167         /* Final pthreads */
20168         pthread_attr_t attr;
20169
20170         status = pthread_attr_init(&attr);
20171         if( status ) return status;
20172
20173 #if HAVE_PTHREADS < 7
20174         status = pthread_attr_setdetachstate(&attr, &detach);
20175         if( status < 0 ) status = errno;
20176 #else
20177         status = pthread_attr_setdetachstate(&attr, detach);
20178 #endif
20179         if( status ) return status;
20180         status = pthread_create( &t, &attr, task, NULL );
20181 #if HAVE_PTHREADS < 7
20182         if( status < 0 ) status = errno;
20183 #endif
20184         if( status ) return status;
20185 #else
20186         /* Draft 4 pthreads */
20187         status = pthread_create( &t, pthread_attr_default, task, NULL );
20188         if( status ) return errno;
20189
20190         /* give thread a chance to complete */
20191         /* it should remain joinable and hence detachable */
20192         sleep( 1 );
20193
20194         status = pthread_detach( &t );
20195         if( status ) return errno;
20196 #endif
20197
20198 #ifdef HAVE_LINUX_THREADS
20199         pthread_kill_other_threads_np();
20200 #endif
20201
20202         return 0;
20203
20204   ;
20205   return 0;
20206 }
20207 _ACEOF
20208 rm -f conftest.$ac_objext conftest$ac_exeext
20209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20210   (eval $ac_link) 2>&5
20211   ac_status=$?
20212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20213   (exit $ac_status); } &&
20214          { ac_try='test -s conftest$ac_exeext'
20215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20216   (eval $ac_try) 2>&5
20217   ac_status=$?
20218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20219   (exit $ac_status); }; }; then
20220   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
20221 else
20222   echo "$as_me: failed program was:" >&5
20223 sed 's/^/| /' conftest.$ac_ext >&5
20224
20225 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
20226 fi
20227 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20228 else
20229   cat >conftest.$ac_ext <<_ACEOF
20230 #line $LINENO "configure"
20231 /* confdefs.h.  */
20232 _ACEOF
20233 cat confdefs.h >>conftest.$ac_ext
20234 cat >>conftest.$ac_ext <<_ACEOF
20235 /* end confdefs.h.  */
20236 /* pthread test headers */
20237 #include <pthread.h>
20238 #if HAVE_PTHREADS < 7
20239 #include <errno.h>
20240 #endif
20241 #ifndef NULL
20242 #define NULL (void*)0
20243 #endif
20244
20245 static void *task(p)
20246         void *p;
20247 {
20248         return (void *) (p == NULL);
20249 }
20250
20251
20252 int main(argc, argv)
20253         int argc;
20254         char **argv;
20255 {
20256
20257         /* pthread test function */
20258 #ifndef PTHREAD_CREATE_DETACHED
20259 #define PTHREAD_CREATE_DETACHED 1
20260 #endif
20261         pthread_t t;
20262         int status;
20263         int detach = PTHREAD_CREATE_DETACHED;
20264
20265 #if HAVE_PTHREADS > 4
20266         /* Final pthreads */
20267         pthread_attr_t attr;
20268
20269         status = pthread_attr_init(&attr);
20270         if( status ) return status;
20271
20272 #if HAVE_PTHREADS < 7
20273         status = pthread_attr_setdetachstate(&attr, &detach);
20274         if( status < 0 ) status = errno;
20275 #else
20276         status = pthread_attr_setdetachstate(&attr, detach);
20277 #endif
20278         if( status ) return status;
20279         status = pthread_create( &t, &attr, task, NULL );
20280 #if HAVE_PTHREADS < 7
20281         if( status < 0 ) status = errno;
20282 #endif
20283         if( status ) return status;
20284 #else
20285         /* Draft 4 pthreads */
20286         status = pthread_create( &t, pthread_attr_default, task, NULL );
20287         if( status ) return errno;
20288
20289         /* give thread a chance to complete */
20290         /* it should remain joinable and hence detachable */
20291         sleep( 1 );
20292
20293         status = pthread_detach( &t );
20294         if( status ) return errno;
20295 #endif
20296
20297 #ifdef HAVE_LINUX_THREADS
20298         pthread_kill_other_threads_np();
20299 #endif
20300
20301         return 0;
20302
20303 }
20304
20305 _ACEOF
20306 rm -f conftest$ac_exeext
20307 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20308   (eval $ac_link) 2>&5
20309   ac_status=$?
20310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20311   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20313   (eval $ac_try) 2>&5
20314   ac_status=$?
20315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20316   (exit $ac_status); }; }; then
20317   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
20318 else
20319   echo "$as_me: program exited with status $ac_status" >&5
20320 echo "$as_me: failed program was:" >&5
20321 sed 's/^/| /' conftest.$ac_ext >&5
20322
20323 ( exit $ac_status )
20324 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
20325 fi
20326 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20327 fi
20328
20329                 # restore the LIBS
20330                 LIBS="$ol_LIBS"
20331
20332 fi
20333 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
20334 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
20335
20336         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
20337                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
20338                 ol_link_threads=posix
20339         fi
20340 fi
20341
20342                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
20343 if test "$ol_link_threads" = no ; then
20344         # try -lpthreads -lmach -lexc
20345         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
20346 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
20347 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
20348   echo $ECHO_N "(cached) $ECHO_C" >&6
20349 else
20350
20351                 # save the flags
20352                 ol_LIBS="$LIBS"
20353                 LIBS="-lpthreads -lmach -lexc $LIBS"
20354
20355                 if test "$cross_compiling" = yes; then
20356   cat >conftest.$ac_ext <<_ACEOF
20357 #line $LINENO "configure"
20358 /* confdefs.h.  */
20359 _ACEOF
20360 cat confdefs.h >>conftest.$ac_ext
20361 cat >>conftest.$ac_ext <<_ACEOF
20362 /* end confdefs.h.  */
20363 /* pthread test headers */
20364 #include <pthread.h>
20365 #if HAVE_PTHREADS < 7
20366 #include <errno.h>
20367 #endif
20368 #ifndef NULL
20369 #define NULL (void*)0
20370 #endif
20371
20372 static void *task(p)
20373         void *p;
20374 {
20375         return (void *) (p == NULL);
20376 }
20377
20378 int
20379 main ()
20380 {
20381
20382         /* pthread test function */
20383 #ifndef PTHREAD_CREATE_DETACHED
20384 #define PTHREAD_CREATE_DETACHED 1
20385 #endif
20386         pthread_t t;
20387         int status;
20388         int detach = PTHREAD_CREATE_DETACHED;
20389
20390 #if HAVE_PTHREADS > 4
20391         /* Final pthreads */
20392         pthread_attr_t attr;
20393
20394         status = pthread_attr_init(&attr);
20395         if( status ) return status;
20396
20397 #if HAVE_PTHREADS < 7
20398         status = pthread_attr_setdetachstate(&attr, &detach);
20399         if( status < 0 ) status = errno;
20400 #else
20401         status = pthread_attr_setdetachstate(&attr, detach);
20402 #endif
20403         if( status ) return status;
20404         status = pthread_create( &t, &attr, task, NULL );
20405 #if HAVE_PTHREADS < 7
20406         if( status < 0 ) status = errno;
20407 #endif
20408         if( status ) return status;
20409 #else
20410         /* Draft 4 pthreads */
20411         status = pthread_create( &t, pthread_attr_default, task, NULL );
20412         if( status ) return errno;
20413
20414         /* give thread a chance to complete */
20415         /* it should remain joinable and hence detachable */
20416         sleep( 1 );
20417
20418         status = pthread_detach( &t );
20419         if( status ) return errno;
20420 #endif
20421
20422 #ifdef HAVE_LINUX_THREADS
20423         pthread_kill_other_threads_np();
20424 #endif
20425
20426         return 0;
20427
20428   ;
20429   return 0;
20430 }
20431 _ACEOF
20432 rm -f conftest.$ac_objext conftest$ac_exeext
20433 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20434   (eval $ac_link) 2>&5
20435   ac_status=$?
20436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20437   (exit $ac_status); } &&
20438          { ac_try='test -s conftest$ac_exeext'
20439   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20440   (eval $ac_try) 2>&5
20441   ac_status=$?
20442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20443   (exit $ac_status); }; }; then
20444   ol_cv_pthread_lpthreads_lmach_lexc=yes
20445 else
20446   echo "$as_me: failed program was:" >&5
20447 sed 's/^/| /' conftest.$ac_ext >&5
20448
20449 ol_cv_pthread_lpthreads_lmach_lexc=no
20450 fi
20451 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20452 else
20453   cat >conftest.$ac_ext <<_ACEOF
20454 #line $LINENO "configure"
20455 /* confdefs.h.  */
20456 _ACEOF
20457 cat confdefs.h >>conftest.$ac_ext
20458 cat >>conftest.$ac_ext <<_ACEOF
20459 /* end confdefs.h.  */
20460 /* pthread test headers */
20461 #include <pthread.h>
20462 #if HAVE_PTHREADS < 7
20463 #include <errno.h>
20464 #endif
20465 #ifndef NULL
20466 #define NULL (void*)0
20467 #endif
20468
20469 static void *task(p)
20470         void *p;
20471 {
20472         return (void *) (p == NULL);
20473 }
20474
20475
20476 int main(argc, argv)
20477         int argc;
20478         char **argv;
20479 {
20480
20481         /* pthread test function */
20482 #ifndef PTHREAD_CREATE_DETACHED
20483 #define PTHREAD_CREATE_DETACHED 1
20484 #endif
20485         pthread_t t;
20486         int status;
20487         int detach = PTHREAD_CREATE_DETACHED;
20488
20489 #if HAVE_PTHREADS > 4
20490         /* Final pthreads */
20491         pthread_attr_t attr;
20492
20493         status = pthread_attr_init(&attr);
20494         if( status ) return status;
20495
20496 #if HAVE_PTHREADS < 7
20497         status = pthread_attr_setdetachstate(&attr, &detach);
20498         if( status < 0 ) status = errno;
20499 #else
20500         status = pthread_attr_setdetachstate(&attr, detach);
20501 #endif
20502         if( status ) return status;
20503         status = pthread_create( &t, &attr, task, NULL );
20504 #if HAVE_PTHREADS < 7
20505         if( status < 0 ) status = errno;
20506 #endif
20507         if( status ) return status;
20508 #else
20509         /* Draft 4 pthreads */
20510         status = pthread_create( &t, pthread_attr_default, task, NULL );
20511         if( status ) return errno;
20512
20513         /* give thread a chance to complete */
20514         /* it should remain joinable and hence detachable */
20515         sleep( 1 );
20516
20517         status = pthread_detach( &t );
20518         if( status ) return errno;
20519 #endif
20520
20521 #ifdef HAVE_LINUX_THREADS
20522         pthread_kill_other_threads_np();
20523 #endif
20524
20525         return 0;
20526
20527 }
20528
20529 _ACEOF
20530 rm -f conftest$ac_exeext
20531 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20532   (eval $ac_link) 2>&5
20533   ac_status=$?
20534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20535   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20537   (eval $ac_try) 2>&5
20538   ac_status=$?
20539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20540   (exit $ac_status); }; }; then
20541   ol_cv_pthread_lpthreads_lmach_lexc=yes
20542 else
20543   echo "$as_me: program exited with status $ac_status" >&5
20544 echo "$as_me: failed program was:" >&5
20545 sed 's/^/| /' conftest.$ac_ext >&5
20546
20547 ( exit $ac_status )
20548 ol_cv_pthread_lpthreads_lmach_lexc=no
20549 fi
20550 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20551 fi
20552
20553                 # restore the LIBS
20554                 LIBS="$ol_LIBS"
20555
20556 fi
20557 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
20558 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
20559
20560         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
20561                 ol_link_pthreads="-lpthreads -lmach -lexc"
20562                 ol_link_threads=posix
20563         fi
20564 fi
20565
20566                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
20567 if test "$ol_link_threads" = no ; then
20568         # try -lpthreads -lexc
20569         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
20570 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
20571 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
20572   echo $ECHO_N "(cached) $ECHO_C" >&6
20573 else
20574
20575                 # save the flags
20576                 ol_LIBS="$LIBS"
20577                 LIBS="-lpthreads -lexc $LIBS"
20578
20579                 if test "$cross_compiling" = yes; then
20580   cat >conftest.$ac_ext <<_ACEOF
20581 #line $LINENO "configure"
20582 /* confdefs.h.  */
20583 _ACEOF
20584 cat confdefs.h >>conftest.$ac_ext
20585 cat >>conftest.$ac_ext <<_ACEOF
20586 /* end confdefs.h.  */
20587 /* pthread test headers */
20588 #include <pthread.h>
20589 #if HAVE_PTHREADS < 7
20590 #include <errno.h>
20591 #endif
20592 #ifndef NULL
20593 #define NULL (void*)0
20594 #endif
20595
20596 static void *task(p)
20597         void *p;
20598 {
20599         return (void *) (p == NULL);
20600 }
20601
20602 int
20603 main ()
20604 {
20605
20606         /* pthread test function */
20607 #ifndef PTHREAD_CREATE_DETACHED
20608 #define PTHREAD_CREATE_DETACHED 1
20609 #endif
20610         pthread_t t;
20611         int status;
20612         int detach = PTHREAD_CREATE_DETACHED;
20613
20614 #if HAVE_PTHREADS > 4
20615         /* Final pthreads */
20616         pthread_attr_t attr;
20617
20618         status = pthread_attr_init(&attr);
20619         if( status ) return status;
20620
20621 #if HAVE_PTHREADS < 7
20622         status = pthread_attr_setdetachstate(&attr, &detach);
20623         if( status < 0 ) status = errno;
20624 #else
20625         status = pthread_attr_setdetachstate(&attr, detach);
20626 #endif
20627         if( status ) return status;
20628         status = pthread_create( &t, &attr, task, NULL );
20629 #if HAVE_PTHREADS < 7
20630         if( status < 0 ) status = errno;
20631 #endif
20632         if( status ) return status;
20633 #else
20634         /* Draft 4 pthreads */
20635         status = pthread_create( &t, pthread_attr_default, task, NULL );
20636         if( status ) return errno;
20637
20638         /* give thread a chance to complete */
20639         /* it should remain joinable and hence detachable */
20640         sleep( 1 );
20641
20642         status = pthread_detach( &t );
20643         if( status ) return errno;
20644 #endif
20645
20646 #ifdef HAVE_LINUX_THREADS
20647         pthread_kill_other_threads_np();
20648 #endif
20649
20650         return 0;
20651
20652   ;
20653   return 0;
20654 }
20655 _ACEOF
20656 rm -f conftest.$ac_objext conftest$ac_exeext
20657 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20658   (eval $ac_link) 2>&5
20659   ac_status=$?
20660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20661   (exit $ac_status); } &&
20662          { ac_try='test -s conftest$ac_exeext'
20663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20664   (eval $ac_try) 2>&5
20665   ac_status=$?
20666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20667   (exit $ac_status); }; }; then
20668   ol_cv_pthread_lpthreads_lexc=yes
20669 else
20670   echo "$as_me: failed program was:" >&5
20671 sed 's/^/| /' conftest.$ac_ext >&5
20672
20673 ol_cv_pthread_lpthreads_lexc=no
20674 fi
20675 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20676 else
20677   cat >conftest.$ac_ext <<_ACEOF
20678 #line $LINENO "configure"
20679 /* confdefs.h.  */
20680 _ACEOF
20681 cat confdefs.h >>conftest.$ac_ext
20682 cat >>conftest.$ac_ext <<_ACEOF
20683 /* end confdefs.h.  */
20684 /* pthread test headers */
20685 #include <pthread.h>
20686 #if HAVE_PTHREADS < 7
20687 #include <errno.h>
20688 #endif
20689 #ifndef NULL
20690 #define NULL (void*)0
20691 #endif
20692
20693 static void *task(p)
20694         void *p;
20695 {
20696         return (void *) (p == NULL);
20697 }
20698
20699
20700 int main(argc, argv)
20701         int argc;
20702         char **argv;
20703 {
20704
20705         /* pthread test function */
20706 #ifndef PTHREAD_CREATE_DETACHED
20707 #define PTHREAD_CREATE_DETACHED 1
20708 #endif
20709         pthread_t t;
20710         int status;
20711         int detach = PTHREAD_CREATE_DETACHED;
20712
20713 #if HAVE_PTHREADS > 4
20714         /* Final pthreads */
20715         pthread_attr_t attr;
20716
20717         status = pthread_attr_init(&attr);
20718         if( status ) return status;
20719
20720 #if HAVE_PTHREADS < 7
20721         status = pthread_attr_setdetachstate(&attr, &detach);
20722         if( status < 0 ) status = errno;
20723 #else
20724         status = pthread_attr_setdetachstate(&attr, detach);
20725 #endif
20726         if( status ) return status;
20727         status = pthread_create( &t, &attr, task, NULL );
20728 #if HAVE_PTHREADS < 7
20729         if( status < 0 ) status = errno;
20730 #endif
20731         if( status ) return status;
20732 #else
20733         /* Draft 4 pthreads */
20734         status = pthread_create( &t, pthread_attr_default, task, NULL );
20735         if( status ) return errno;
20736
20737         /* give thread a chance to complete */
20738         /* it should remain joinable and hence detachable */
20739         sleep( 1 );
20740
20741         status = pthread_detach( &t );
20742         if( status ) return errno;
20743 #endif
20744
20745 #ifdef HAVE_LINUX_THREADS
20746         pthread_kill_other_threads_np();
20747 #endif
20748
20749         return 0;
20750
20751 }
20752
20753 _ACEOF
20754 rm -f conftest$ac_exeext
20755 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20756   (eval $ac_link) 2>&5
20757   ac_status=$?
20758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20759   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20760   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20761   (eval $ac_try) 2>&5
20762   ac_status=$?
20763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20764   (exit $ac_status); }; }; then
20765   ol_cv_pthread_lpthreads_lexc=yes
20766 else
20767   echo "$as_me: program exited with status $ac_status" >&5
20768 echo "$as_me: failed program was:" >&5
20769 sed 's/^/| /' conftest.$ac_ext >&5
20770
20771 ( exit $ac_status )
20772 ol_cv_pthread_lpthreads_lexc=no
20773 fi
20774 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20775 fi
20776
20777                 # restore the LIBS
20778                 LIBS="$ol_LIBS"
20779
20780 fi
20781 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
20782 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
20783
20784         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
20785                 ol_link_pthreads="-lpthreads -lexc"
20786                 ol_link_threads=posix
20787         fi
20788 fi
20789
20790
20791                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
20792 if test "$ol_link_threads" = no ; then
20793         # try -lpthreads
20794         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
20795 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
20796 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
20797   echo $ECHO_N "(cached) $ECHO_C" >&6
20798 else
20799
20800                 # save the flags
20801                 ol_LIBS="$LIBS"
20802                 LIBS="-lpthreads $LIBS"
20803
20804                 if test "$cross_compiling" = yes; then
20805   cat >conftest.$ac_ext <<_ACEOF
20806 #line $LINENO "configure"
20807 /* confdefs.h.  */
20808 _ACEOF
20809 cat confdefs.h >>conftest.$ac_ext
20810 cat >>conftest.$ac_ext <<_ACEOF
20811 /* end confdefs.h.  */
20812 /* pthread test headers */
20813 #include <pthread.h>
20814 #if HAVE_PTHREADS < 7
20815 #include <errno.h>
20816 #endif
20817 #ifndef NULL
20818 #define NULL (void*)0
20819 #endif
20820
20821 static void *task(p)
20822         void *p;
20823 {
20824         return (void *) (p == NULL);
20825 }
20826
20827 int
20828 main ()
20829 {
20830
20831         /* pthread test function */
20832 #ifndef PTHREAD_CREATE_DETACHED
20833 #define PTHREAD_CREATE_DETACHED 1
20834 #endif
20835         pthread_t t;
20836         int status;
20837         int detach = PTHREAD_CREATE_DETACHED;
20838
20839 #if HAVE_PTHREADS > 4
20840         /* Final pthreads */
20841         pthread_attr_t attr;
20842
20843         status = pthread_attr_init(&attr);
20844         if( status ) return status;
20845
20846 #if HAVE_PTHREADS < 7
20847         status = pthread_attr_setdetachstate(&attr, &detach);
20848         if( status < 0 ) status = errno;
20849 #else
20850         status = pthread_attr_setdetachstate(&attr, detach);
20851 #endif
20852         if( status ) return status;
20853         status = pthread_create( &t, &attr, task, NULL );
20854 #if HAVE_PTHREADS < 7
20855         if( status < 0 ) status = errno;
20856 #endif
20857         if( status ) return status;
20858 #else
20859         /* Draft 4 pthreads */
20860         status = pthread_create( &t, pthread_attr_default, task, NULL );
20861         if( status ) return errno;
20862
20863         /* give thread a chance to complete */
20864         /* it should remain joinable and hence detachable */
20865         sleep( 1 );
20866
20867         status = pthread_detach( &t );
20868         if( status ) return errno;
20869 #endif
20870
20871 #ifdef HAVE_LINUX_THREADS
20872         pthread_kill_other_threads_np();
20873 #endif
20874
20875         return 0;
20876
20877   ;
20878   return 0;
20879 }
20880 _ACEOF
20881 rm -f conftest.$ac_objext conftest$ac_exeext
20882 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20883   (eval $ac_link) 2>&5
20884   ac_status=$?
20885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20886   (exit $ac_status); } &&
20887          { ac_try='test -s conftest$ac_exeext'
20888   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20889   (eval $ac_try) 2>&5
20890   ac_status=$?
20891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20892   (exit $ac_status); }; }; then
20893   ol_cv_pthread_lib_lpthreads=yes
20894 else
20895   echo "$as_me: failed program was:" >&5
20896 sed 's/^/| /' conftest.$ac_ext >&5
20897
20898 ol_cv_pthread_lib_lpthreads=no
20899 fi
20900 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20901 else
20902   cat >conftest.$ac_ext <<_ACEOF
20903 #line $LINENO "configure"
20904 /* confdefs.h.  */
20905 _ACEOF
20906 cat confdefs.h >>conftest.$ac_ext
20907 cat >>conftest.$ac_ext <<_ACEOF
20908 /* end confdefs.h.  */
20909 /* pthread test headers */
20910 #include <pthread.h>
20911 #if HAVE_PTHREADS < 7
20912 #include <errno.h>
20913 #endif
20914 #ifndef NULL
20915 #define NULL (void*)0
20916 #endif
20917
20918 static void *task(p)
20919         void *p;
20920 {
20921         return (void *) (p == NULL);
20922 }
20923
20924
20925 int main(argc, argv)
20926         int argc;
20927         char **argv;
20928 {
20929
20930         /* pthread test function */
20931 #ifndef PTHREAD_CREATE_DETACHED
20932 #define PTHREAD_CREATE_DETACHED 1
20933 #endif
20934         pthread_t t;
20935         int status;
20936         int detach = PTHREAD_CREATE_DETACHED;
20937
20938 #if HAVE_PTHREADS > 4
20939         /* Final pthreads */
20940         pthread_attr_t attr;
20941
20942         status = pthread_attr_init(&attr);
20943         if( status ) return status;
20944
20945 #if HAVE_PTHREADS < 7
20946         status = pthread_attr_setdetachstate(&attr, &detach);
20947         if( status < 0 ) status = errno;
20948 #else
20949         status = pthread_attr_setdetachstate(&attr, detach);
20950 #endif
20951         if( status ) return status;
20952         status = pthread_create( &t, &attr, task, NULL );
20953 #if HAVE_PTHREADS < 7
20954         if( status < 0 ) status = errno;
20955 #endif
20956         if( status ) return status;
20957 #else
20958         /* Draft 4 pthreads */
20959         status = pthread_create( &t, pthread_attr_default, task, NULL );
20960         if( status ) return errno;
20961
20962         /* give thread a chance to complete */
20963         /* it should remain joinable and hence detachable */
20964         sleep( 1 );
20965
20966         status = pthread_detach( &t );
20967         if( status ) return errno;
20968 #endif
20969
20970 #ifdef HAVE_LINUX_THREADS
20971         pthread_kill_other_threads_np();
20972 #endif
20973
20974         return 0;
20975
20976 }
20977
20978 _ACEOF
20979 rm -f conftest$ac_exeext
20980 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20981   (eval $ac_link) 2>&5
20982   ac_status=$?
20983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20984   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20986   (eval $ac_try) 2>&5
20987   ac_status=$?
20988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20989   (exit $ac_status); }; }; then
20990   ol_cv_pthread_lib_lpthreads=yes
20991 else
20992   echo "$as_me: program exited with status $ac_status" >&5
20993 echo "$as_me: failed program was:" >&5
20994 sed 's/^/| /' conftest.$ac_ext >&5
20995
20996 ( exit $ac_status )
20997 ol_cv_pthread_lib_lpthreads=no
20998 fi
20999 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21000 fi
21001
21002                 # restore the LIBS
21003                 LIBS="$ol_LIBS"
21004
21005 fi
21006 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
21007 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
21008
21009         if test $ol_cv_pthread_lib_lpthreads = yes ; then
21010                 ol_link_pthreads="-lpthreads"
21011                 ol_link_threads=posix
21012         fi
21013 fi
21014
21015
21016                 if test $ol_link_threads != no ; then
21017                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
21018
21019                                                 save_CPPFLAGS="$CPPFLAGS"
21020                         save_LIBS="$LIBS"
21021                         LIBS="$LTHREAD_LIBS $LIBS"
21022
21023
21024
21025
21026 for ac_func in sched_yield pthread_yield thr_yield
21027 do
21028 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21029 echo "$as_me:$LINENO: checking for $ac_func" >&5
21030 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21031 if eval "test \"\${$as_ac_var+set}\" = set"; then
21032   echo $ECHO_N "(cached) $ECHO_C" >&6
21033 else
21034   cat >conftest.$ac_ext <<_ACEOF
21035 #line $LINENO "configure"
21036 /* confdefs.h.  */
21037 _ACEOF
21038 cat confdefs.h >>conftest.$ac_ext
21039 cat >>conftest.$ac_ext <<_ACEOF
21040 /* end confdefs.h.  */
21041 /* System header to define __stub macros and hopefully few prototypes,
21042     which can conflict with char $ac_func (); below.
21043     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21044     <limits.h> exists even on freestanding compilers.  */
21045 #ifdef __STDC__
21046 # include <limits.h>
21047 #else
21048 # include <assert.h>
21049 #endif
21050 /* Override any gcc2 internal prototype to avoid an error.  */
21051 #ifdef __cplusplus
21052 extern "C"
21053 {
21054 #endif
21055 /* We use char because int might match the return type of a gcc2
21056    builtin and then its argument prototype would still apply.  */
21057 char $ac_func ();
21058 /* The GNU C library defines this for functions which it implements
21059     to always fail with ENOSYS.  Some functions are actually named
21060     something starting with __ and the normal name is an alias.  */
21061 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21062 choke me
21063 #else
21064 char (*f) () = $ac_func;
21065 #endif
21066 #ifdef __cplusplus
21067 }
21068 #endif
21069
21070 int
21071 main ()
21072 {
21073 return f != $ac_func;
21074   ;
21075   return 0;
21076 }
21077 _ACEOF
21078 rm -f conftest.$ac_objext conftest$ac_exeext
21079 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21080   (eval $ac_link) 2>&5
21081   ac_status=$?
21082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21083   (exit $ac_status); } &&
21084          { ac_try='test -s conftest$ac_exeext'
21085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21086   (eval $ac_try) 2>&5
21087   ac_status=$?
21088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21089   (exit $ac_status); }; }; then
21090   eval "$as_ac_var=yes"
21091 else
21092   echo "$as_me: failed program was:" >&5
21093 sed 's/^/| /' conftest.$ac_ext >&5
21094
21095 eval "$as_ac_var=no"
21096 fi
21097 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21098 fi
21099 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21100 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21101 if test `eval echo '${'$as_ac_var'}'` = yes; then
21102   cat >>confdefs.h <<_ACEOF
21103 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21104 _ACEOF
21105
21106 fi
21107 done
21108
21109
21110                         if test $ac_cv_func_sched_yield = no -a \
21111                                 $ac_cv_func_pthread_yield = no -a \
21112                                 $ac_cv_func_thr_yield = no ; then
21113                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
21114 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
21115 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
21116   echo $ECHO_N "(cached) $ECHO_C" >&6
21117 else
21118   ac_check_lib_save_LIBS=$LIBS
21119 LIBS="-lrt  $LIBS"
21120 cat >conftest.$ac_ext <<_ACEOF
21121 #line $LINENO "configure"
21122 /* confdefs.h.  */
21123 _ACEOF
21124 cat confdefs.h >>conftest.$ac_ext
21125 cat >>conftest.$ac_ext <<_ACEOF
21126 /* end confdefs.h.  */
21127
21128 /* Override any gcc2 internal prototype to avoid an error.  */
21129 #ifdef __cplusplus
21130 extern "C"
21131 #endif
21132 /* We use char because int might match the return type of a gcc2
21133    builtin and then its argument prototype would still apply.  */
21134 char sched_yield ();
21135 int
21136 main ()
21137 {
21138 sched_yield ();
21139   ;
21140   return 0;
21141 }
21142 _ACEOF
21143 rm -f conftest.$ac_objext conftest$ac_exeext
21144 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21145   (eval $ac_link) 2>&5
21146   ac_status=$?
21147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21148   (exit $ac_status); } &&
21149          { ac_try='test -s conftest$ac_exeext'
21150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21151   (eval $ac_try) 2>&5
21152   ac_status=$?
21153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21154   (exit $ac_status); }; }; then
21155   ac_cv_lib_rt_sched_yield=yes
21156 else
21157   echo "$as_me: failed program was:" >&5
21158 sed 's/^/| /' conftest.$ac_ext >&5
21159
21160 ac_cv_lib_rt_sched_yield=no
21161 fi
21162 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21163 LIBS=$ac_check_lib_save_LIBS
21164 fi
21165 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
21166 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
21167 if test $ac_cv_lib_rt_sched_yield = yes; then
21168   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
21169
21170 cat >>confdefs.h <<\_ACEOF
21171 #define HAVE_SCHED_YIELD 1
21172 _ACEOF
21173
21174                                         ac_cv_func_sched_yield=yes
21175 else
21176   ac_cv_func_sched_yield=no
21177 fi
21178
21179                         fi
21180                         if test $ac_cv_func_sched_yield = no -a \
21181                                 $ac_cv_func_pthread_yield = no -a \
21182                                 "$ac_cv_func_thr_yield" = no ; then
21183                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
21184 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
21185                         fi
21186
21187
21188
21189 for ac_func in pthread_kill pthread_rwlock_destroy
21190 do
21191 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21192 echo "$as_me:$LINENO: checking for $ac_func" >&5
21193 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21194 if eval "test \"\${$as_ac_var+set}\" = set"; then
21195   echo $ECHO_N "(cached) $ECHO_C" >&6
21196 else
21197   cat >conftest.$ac_ext <<_ACEOF
21198 #line $LINENO "configure"
21199 /* confdefs.h.  */
21200 _ACEOF
21201 cat confdefs.h >>conftest.$ac_ext
21202 cat >>conftest.$ac_ext <<_ACEOF
21203 /* end confdefs.h.  */
21204 /* System header to define __stub macros and hopefully few prototypes,
21205     which can conflict with char $ac_func (); below.
21206     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21207     <limits.h> exists even on freestanding compilers.  */
21208 #ifdef __STDC__
21209 # include <limits.h>
21210 #else
21211 # include <assert.h>
21212 #endif
21213 /* Override any gcc2 internal prototype to avoid an error.  */
21214 #ifdef __cplusplus
21215 extern "C"
21216 {
21217 #endif
21218 /* We use char because int might match the return type of a gcc2
21219    builtin and then its argument prototype would still apply.  */
21220 char $ac_func ();
21221 /* The GNU C library defines this for functions which it implements
21222     to always fail with ENOSYS.  Some functions are actually named
21223     something starting with __ and the normal name is an alias.  */
21224 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21225 choke me
21226 #else
21227 char (*f) () = $ac_func;
21228 #endif
21229 #ifdef __cplusplus
21230 }
21231 #endif
21232
21233 int
21234 main ()
21235 {
21236 return f != $ac_func;
21237   ;
21238   return 0;
21239 }
21240 _ACEOF
21241 rm -f conftest.$ac_objext conftest$ac_exeext
21242 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21243   (eval $ac_link) 2>&5
21244   ac_status=$?
21245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21246   (exit $ac_status); } &&
21247          { ac_try='test -s conftest$ac_exeext'
21248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21249   (eval $ac_try) 2>&5
21250   ac_status=$?
21251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21252   (exit $ac_status); }; }; then
21253   eval "$as_ac_var=yes"
21254 else
21255   echo "$as_me: failed program was:" >&5
21256 sed 's/^/| /' conftest.$ac_ext >&5
21257
21258 eval "$as_ac_var=no"
21259 fi
21260 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21261 fi
21262 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21263 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21264 if test `eval echo '${'$as_ac_var'}'` = yes; then
21265   cat >>confdefs.h <<_ACEOF
21266 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21267 _ACEOF
21268
21269 fi
21270 done
21271
21272
21273                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
21274 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
21275 if test "${ol_cv_func_pthread_detach+set}" = set; then
21276   echo $ECHO_N "(cached) $ECHO_C" >&6
21277 else
21278
21279                                                                 cat >conftest.$ac_ext <<_ACEOF
21280 #line $LINENO "configure"
21281 /* confdefs.h.  */
21282 _ACEOF
21283 cat confdefs.h >>conftest.$ac_ext
21284 cat >>conftest.$ac_ext <<_ACEOF
21285 /* end confdefs.h.  */
21286
21287 #include <pthread.h>
21288 #ifndef NULL
21289 #define NULL (void*)0
21290 #endif
21291
21292 int
21293 main ()
21294 {
21295 pthread_detach(NULL);
21296   ;
21297   return 0;
21298 }
21299 _ACEOF
21300 rm -f conftest.$ac_objext conftest$ac_exeext
21301 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21302   (eval $ac_link) 2>&5
21303   ac_status=$?
21304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21305   (exit $ac_status); } &&
21306          { ac_try='test -s conftest$ac_exeext'
21307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21308   (eval $ac_try) 2>&5
21309   ac_status=$?
21310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21311   (exit $ac_status); }; }; then
21312   ol_cv_func_pthread_detach=yes
21313 else
21314   echo "$as_me: failed program was:" >&5
21315 sed 's/^/| /' conftest.$ac_ext >&5
21316
21317 ol_cv_func_pthread_detach=no
21318 fi
21319 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21320
21321 fi
21322 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
21323 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
21324
21325                         if test $ol_cv_func_pthread_detach = no ; then
21326                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
21327 echo "$as_me: error: could not locate pthread_detach()" >&2;}
21328    { (exit 1); exit 1; }; }
21329                         fi
21330
21331
21332 cat >>confdefs.h <<\_ACEOF
21333 #define HAVE_PTHREAD_DETACH 1
21334 _ACEOF
21335
21336
21337
21338
21339
21340
21341 for ac_func in \
21342                                 pthread_setconcurrency \
21343                                 pthread_getconcurrency \
21344                                 thr_setconcurrency \
21345                                 thr_getconcurrency \
21346
21347 do
21348 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21349 echo "$as_me:$LINENO: checking for $ac_func" >&5
21350 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21351 if eval "test \"\${$as_ac_var+set}\" = set"; then
21352   echo $ECHO_N "(cached) $ECHO_C" >&6
21353 else
21354   cat >conftest.$ac_ext <<_ACEOF
21355 #line $LINENO "configure"
21356 /* confdefs.h.  */
21357 _ACEOF
21358 cat confdefs.h >>conftest.$ac_ext
21359 cat >>conftest.$ac_ext <<_ACEOF
21360 /* end confdefs.h.  */
21361 /* System header to define __stub macros and hopefully few prototypes,
21362     which can conflict with char $ac_func (); below.
21363     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21364     <limits.h> exists even on freestanding compilers.  */
21365 #ifdef __STDC__
21366 # include <limits.h>
21367 #else
21368 # include <assert.h>
21369 #endif
21370 /* Override any gcc2 internal prototype to avoid an error.  */
21371 #ifdef __cplusplus
21372 extern "C"
21373 {
21374 #endif
21375 /* We use char because int might match the return type of a gcc2
21376    builtin and then its argument prototype would still apply.  */
21377 char $ac_func ();
21378 /* The GNU C library defines this for functions which it implements
21379     to always fail with ENOSYS.  Some functions are actually named
21380     something starting with __ and the normal name is an alias.  */
21381 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21382 choke me
21383 #else
21384 char (*f) () = $ac_func;
21385 #endif
21386 #ifdef __cplusplus
21387 }
21388 #endif
21389
21390 int
21391 main ()
21392 {
21393 return f != $ac_func;
21394   ;
21395   return 0;
21396 }
21397 _ACEOF
21398 rm -f conftest.$ac_objext conftest$ac_exeext
21399 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21400   (eval $ac_link) 2>&5
21401   ac_status=$?
21402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21403   (exit $ac_status); } &&
21404          { ac_try='test -s conftest$ac_exeext'
21405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21406   (eval $ac_try) 2>&5
21407   ac_status=$?
21408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21409   (exit $ac_status); }; }; then
21410   eval "$as_ac_var=yes"
21411 else
21412   echo "$as_me: failed program was:" >&5
21413 sed 's/^/| /' conftest.$ac_ext >&5
21414
21415 eval "$as_ac_var=no"
21416 fi
21417 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21418 fi
21419 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21420 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21421 if test `eval echo '${'$as_ac_var'}'` = yes; then
21422   cat >>confdefs.h <<_ACEOF
21423 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21424 _ACEOF
21425
21426 fi
21427 done
21428
21429
21430
21431
21432 for ac_func in pthread_kill_other_threads_np
21433 do
21434 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21435 echo "$as_me:$LINENO: checking for $ac_func" >&5
21436 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21437 if eval "test \"\${$as_ac_var+set}\" = set"; then
21438   echo $ECHO_N "(cached) $ECHO_C" >&6
21439 else
21440   cat >conftest.$ac_ext <<_ACEOF
21441 #line $LINENO "configure"
21442 /* confdefs.h.  */
21443 _ACEOF
21444 cat confdefs.h >>conftest.$ac_ext
21445 cat >>conftest.$ac_ext <<_ACEOF
21446 /* end confdefs.h.  */
21447 /* System header to define __stub macros and hopefully few prototypes,
21448     which can conflict with char $ac_func (); below.
21449     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21450     <limits.h> exists even on freestanding compilers.  */
21451 #ifdef __STDC__
21452 # include <limits.h>
21453 #else
21454 # include <assert.h>
21455 #endif
21456 /* Override any gcc2 internal prototype to avoid an error.  */
21457 #ifdef __cplusplus
21458 extern "C"
21459 {
21460 #endif
21461 /* We use char because int might match the return type of a gcc2
21462    builtin and then its argument prototype would still apply.  */
21463 char $ac_func ();
21464 /* The GNU C library defines this for functions which it implements
21465     to always fail with ENOSYS.  Some functions are actually named
21466     something starting with __ and the normal name is an alias.  */
21467 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21468 choke me
21469 #else
21470 char (*f) () = $ac_func;
21471 #endif
21472 #ifdef __cplusplus
21473 }
21474 #endif
21475
21476 int
21477 main ()
21478 {
21479 return f != $ac_func;
21480   ;
21481   return 0;
21482 }
21483 _ACEOF
21484 rm -f conftest.$ac_objext conftest$ac_exeext
21485 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21486   (eval $ac_link) 2>&5
21487   ac_status=$?
21488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21489   (exit $ac_status); } &&
21490          { ac_try='test -s conftest$ac_exeext'
21491   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21492   (eval $ac_try) 2>&5
21493   ac_status=$?
21494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21495   (exit $ac_status); }; }; then
21496   eval "$as_ac_var=yes"
21497 else
21498   echo "$as_me: failed program was:" >&5
21499 sed 's/^/| /' conftest.$ac_ext >&5
21500
21501 eval "$as_ac_var=no"
21502 fi
21503 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21504 fi
21505 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21506 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21507 if test `eval echo '${'$as_ac_var'}'` = yes; then
21508   cat >>confdefs.h <<_ACEOF
21509 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21510 _ACEOF
21511
21512 fi
21513 done
21514
21515         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
21516 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
21517 if test "${ol_cv_sys_linux_threads+set}" = set; then
21518   echo $ECHO_N "(cached) $ECHO_C" >&6
21519 else
21520   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
21521 fi
21522 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
21523 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
21524
21525
21526
21527
21528         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
21529 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
21530 if test "${ol_cv_linux_threads+set}" = set; then
21531   echo $ECHO_N "(cached) $ECHO_C" >&6
21532 else
21533
21534                 if test $ol_cv_header_linux_threads = yes -a \
21535                         $ol_cv_sys_linux_threads = yes; then
21536                         ol_cv_linux_threads=yes
21537                 elif test $ol_cv_header_linux_threads = no -a \
21538                         $ol_cv_sys_linux_threads = no; then
21539                         ol_cv_linux_threads=no
21540                 else
21541                         ol_cv_linux_threads=error
21542                 fi
21543
21544 fi
21545 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
21546 echo "${ECHO_T}$ol_cv_linux_threads" >&6
21547
21548
21549                         if test $ol_cv_linux_threads = error; then
21550                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
21551 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
21552    { (exit 1); exit 1; }; };
21553                         fi
21554
21555                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
21556 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
21557 if test "${ol_cv_pthread_create_works+set}" = set; then
21558   echo $ECHO_N "(cached) $ECHO_C" >&6
21559 else
21560
21561                         if test "$cross_compiling" = yes; then
21562                                 ol_cv_pthread_create_works=yes
21563 else
21564   cat >conftest.$ac_ext <<_ACEOF
21565 #line $LINENO "configure"
21566 /* confdefs.h.  */
21567 _ACEOF
21568 cat confdefs.h >>conftest.$ac_ext
21569 cat >>conftest.$ac_ext <<_ACEOF
21570 /* end confdefs.h.  */
21571 /* pthread test headers */
21572 #include <pthread.h>
21573 #if HAVE_PTHREADS < 7
21574 #include <errno.h>
21575 #endif
21576 #ifndef NULL
21577 #define NULL (void*)0
21578 #endif
21579
21580 static void *task(p)
21581         void *p;
21582 {
21583         return (void *) (p == NULL);
21584 }
21585
21586
21587 int main(argc, argv)
21588         int argc;
21589         char **argv;
21590 {
21591
21592         /* pthread test function */
21593 #ifndef PTHREAD_CREATE_DETACHED
21594 #define PTHREAD_CREATE_DETACHED 1
21595 #endif
21596         pthread_t t;
21597         int status;
21598         int detach = PTHREAD_CREATE_DETACHED;
21599
21600 #if HAVE_PTHREADS > 4
21601         /* Final pthreads */
21602         pthread_attr_t attr;
21603
21604         status = pthread_attr_init(&attr);
21605         if( status ) return status;
21606
21607 #if HAVE_PTHREADS < 7
21608         status = pthread_attr_setdetachstate(&attr, &detach);
21609         if( status < 0 ) status = errno;
21610 #else
21611         status = pthread_attr_setdetachstate(&attr, detach);
21612 #endif
21613         if( status ) return status;
21614         status = pthread_create( &t, &attr, task, NULL );
21615 #if HAVE_PTHREADS < 7
21616         if( status < 0 ) status = errno;
21617 #endif
21618         if( status ) return status;
21619 #else
21620         /* Draft 4 pthreads */
21621         status = pthread_create( &t, pthread_attr_default, task, NULL );
21622         if( status ) return errno;
21623
21624         /* give thread a chance to complete */
21625         /* it should remain joinable and hence detachable */
21626         sleep( 1 );
21627
21628         status = pthread_detach( &t );
21629         if( status ) return errno;
21630 #endif
21631
21632 #ifdef HAVE_LINUX_THREADS
21633         pthread_kill_other_threads_np();
21634 #endif
21635
21636         return 0;
21637
21638 }
21639
21640 _ACEOF
21641 rm -f conftest$ac_exeext
21642 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21643   (eval $ac_link) 2>&5
21644   ac_status=$?
21645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21646   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21647   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21648   (eval $ac_try) 2>&5
21649   ac_status=$?
21650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21651   (exit $ac_status); }; }; then
21652   ol_cv_pthread_create_works=yes
21653 else
21654   echo "$as_me: program exited with status $ac_status" >&5
21655 echo "$as_me: failed program was:" >&5
21656 sed 's/^/| /' conftest.$ac_ext >&5
21657
21658 ( exit $ac_status )
21659 ol_cv_pthread_create_works=no
21660 fi
21661 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21662 fi
21663 fi
21664 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
21665 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
21666
21667                         if test $ol_cv_pthread_create_works = no ; then
21668                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
21669 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
21670    { (exit 1); exit 1; }; }
21671                         fi
21672
21673                                                 if test $ol_with_yielding_select = auto ; then
21674                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
21675 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
21676 if test "${ol_cv_pthread_select_yields+set}" = set; then
21677   echo $ECHO_N "(cached) $ECHO_C" >&6
21678 else
21679
21680                                 if test "$cross_compiling" = yes; then
21681   ol_cv_pthread_select_yields=cross
21682 else
21683   cat >conftest.$ac_ext <<_ACEOF
21684 #line $LINENO "configure"
21685 /* confdefs.h.  */
21686 _ACEOF
21687 cat confdefs.h >>conftest.$ac_ext
21688 cat >>conftest.$ac_ext <<_ACEOF
21689 /* end confdefs.h.  */
21690
21691 #include <sys/types.h>
21692 #include <sys/time.h>
21693 #include <unistd.h>
21694 #include <pthread.h>
21695 #ifndef NULL
21696 #define NULL (void*) 0
21697 #endif
21698
21699 static int fildes[2];
21700
21701 static void *task(p)
21702         void *p;
21703 {
21704         int i;
21705         struct timeval tv;
21706
21707         fd_set rfds;
21708
21709         tv.tv_sec=10;
21710         tv.tv_usec=0;
21711
21712         FD_ZERO(&rfds);
21713         FD_SET(fildes[0], &rfds);
21714
21715         /* we're not interested in any fds */
21716         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
21717
21718         if(i < 0) {
21719                 perror("select");
21720                 exit(10);
21721         }
21722
21723         exit(0); /* if we exit here, the select blocked the whole process */
21724 }
21725
21726 int main(argc, argv)
21727         int argc;
21728         char **argv;
21729 {
21730         pthread_t t;
21731
21732         /* create a pipe to select */
21733         if(pipe(&fildes[0])) {
21734                 perror("select");
21735                 exit(1);
21736         }
21737
21738 #ifdef HAVE_PTHREAD_SETCONCURRENCY
21739         (void) pthread_setconcurrency(2);
21740 #else
21741 #ifdef HAVE_THR_SETCONCURRENCY
21742         /* Set Solaris LWP concurrency to 2 */
21743         thr_setconcurrency(2);
21744 #endif
21745 #endif
21746
21747 #if HAVE_PTHREADS < 6
21748         pthread_create(&t, pthread_attr_default, task, NULL);
21749 #else
21750         pthread_create(&t, NULL, task, NULL);
21751 #endif
21752
21753         /* make sure task runs first */
21754 #if HAVE_THR_YIELD
21755         thr_yield();
21756 #elif defined( HAVE_SCHED_YIELD )
21757         sched_yield();
21758 #elif defined( HAVE_PTHREAD_YIELD )
21759         pthread_yield();
21760 #endif
21761
21762         exit(2);
21763 }
21764 _ACEOF
21765 rm -f conftest$ac_exeext
21766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21767   (eval $ac_link) 2>&5
21768   ac_status=$?
21769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21770   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21771   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21772   (eval $ac_try) 2>&5
21773   ac_status=$?
21774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21775   (exit $ac_status); }; }; then
21776   ol_cv_pthread_select_yields=no
21777 else
21778   echo "$as_me: program exited with status $ac_status" >&5
21779 echo "$as_me: failed program was:" >&5
21780 sed 's/^/| /' conftest.$ac_ext >&5
21781
21782 ( exit $ac_status )
21783 ol_cv_pthread_select_yields=yes
21784 fi
21785 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21786 fi
21787 fi
21788 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
21789 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
21790
21791                                 if test $ol_cv_pthread_select_yields = cross ; then
21792                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
21793 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
21794    { (exit 1); exit 1; }; }
21795                                 fi
21796
21797                                 if test $ol_cv_pthread_select_yields = yes ; then
21798                                         ol_with_yielding_select=yes
21799                                 fi
21800                         fi
21801
21802                                                 CPPFLAGS="$save_CPPFLAGS"
21803                         LIBS="$save_LIBS"
21804                 else
21805                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
21806 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
21807    { (exit 1); exit 1; }; }
21808                 fi
21809         fi
21810
21811         if test $ol_with_threads = posix ; then
21812                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
21813 echo "$as_me: error: could not locate POSIX Threads" >&2;}
21814    { (exit 1); exit 1; }; }
21815         fi
21816 fi
21817
21818 if test $ol_with_threads = auto -o $ol_with_threads = yes \
21819         -o $ol_with_threads = mach ; then
21820
21821
21822
21823 for ac_header in mach/cthreads.h cthreads.h
21824 do
21825 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21826 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21827   echo "$as_me:$LINENO: checking for $ac_header" >&5
21828 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21829 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21830   echo $ECHO_N "(cached) $ECHO_C" >&6
21831 fi
21832 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21833 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21834 else
21835   # Is the header compilable?
21836 echo "$as_me:$LINENO: checking $ac_header usability" >&5
21837 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21838 cat >conftest.$ac_ext <<_ACEOF
21839 #line $LINENO "configure"
21840 /* confdefs.h.  */
21841 _ACEOF
21842 cat confdefs.h >>conftest.$ac_ext
21843 cat >>conftest.$ac_ext <<_ACEOF
21844 /* end confdefs.h.  */
21845 $ac_includes_default
21846 #include <$ac_header>
21847 _ACEOF
21848 rm -f conftest.$ac_objext
21849 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21850   (eval $ac_compile) 2>&5
21851   ac_status=$?
21852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21853   (exit $ac_status); } &&
21854          { ac_try='test -s conftest.$ac_objext'
21855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21856   (eval $ac_try) 2>&5
21857   ac_status=$?
21858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21859   (exit $ac_status); }; }; then
21860   ac_header_compiler=yes
21861 else
21862   echo "$as_me: failed program was:" >&5
21863 sed 's/^/| /' conftest.$ac_ext >&5
21864
21865 ac_header_compiler=no
21866 fi
21867 rm -f conftest.$ac_objext conftest.$ac_ext
21868 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21869 echo "${ECHO_T}$ac_header_compiler" >&6
21870
21871 # Is the header present?
21872 echo "$as_me:$LINENO: checking $ac_header presence" >&5
21873 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21874 cat >conftest.$ac_ext <<_ACEOF
21875 #line $LINENO "configure"
21876 /* confdefs.h.  */
21877 _ACEOF
21878 cat confdefs.h >>conftest.$ac_ext
21879 cat >>conftest.$ac_ext <<_ACEOF
21880 /* end confdefs.h.  */
21881 #include <$ac_header>
21882 _ACEOF
21883 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21884   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21885   ac_status=$?
21886   grep -v '^ *+' conftest.er1 >conftest.err
21887   rm -f conftest.er1
21888   cat conftest.err >&5
21889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21890   (exit $ac_status); } >/dev/null; then
21891   if test -s conftest.err; then
21892     ac_cpp_err=$ac_c_preproc_warn_flag
21893   else
21894     ac_cpp_err=
21895   fi
21896 else
21897   ac_cpp_err=yes
21898 fi
21899 if test -z "$ac_cpp_err"; then
21900   ac_header_preproc=yes
21901 else
21902   echo "$as_me: failed program was:" >&5
21903 sed 's/^/| /' conftest.$ac_ext >&5
21904
21905   ac_header_preproc=no
21906 fi
21907 rm -f conftest.err conftest.$ac_ext
21908 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21909 echo "${ECHO_T}$ac_header_preproc" >&6
21910
21911 # So?  What about this header?
21912 case $ac_header_compiler:$ac_header_preproc in
21913   yes:no )
21914     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21915 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21916     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21917 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21918     (
21919       cat <<\_ASBOX
21920 ## ------------------------------------ ##
21921 ## Report this to bug-autoconf@gnu.org. ##
21922 ## ------------------------------------ ##
21923 _ASBOX
21924     ) |
21925       sed "s/^/$as_me: WARNING:     /" >&2
21926     ;;
21927   no:yes )
21928     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21929 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21930     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21931 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21932     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21933 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21934     (
21935       cat <<\_ASBOX
21936 ## ------------------------------------ ##
21937 ## Report this to bug-autoconf@gnu.org. ##
21938 ## ------------------------------------ ##
21939 _ASBOX
21940     ) |
21941       sed "s/^/$as_me: WARNING:     /" >&2
21942     ;;
21943 esac
21944 echo "$as_me:$LINENO: checking for $ac_header" >&5
21945 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21946 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21947   echo $ECHO_N "(cached) $ECHO_C" >&6
21948 else
21949   eval "$as_ac_Header=$ac_header_preproc"
21950 fi
21951 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21952 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21953
21954 fi
21955 if test `eval echo '${'$as_ac_Header'}'` = yes; then
21956   cat >>confdefs.h <<_ACEOF
21957 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21958 _ACEOF
21959
21960 fi
21961
21962 done
21963
21964         if test $ac_cv_header_mach_cthreads_h = yes ; then
21965                 ol_with_threads=found
21966
21967                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
21968 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
21969 if test "${ac_cv_func_cthread_fork+set}" = set; then
21970   echo $ECHO_N "(cached) $ECHO_C" >&6
21971 else
21972   cat >conftest.$ac_ext <<_ACEOF
21973 #line $LINENO "configure"
21974 /* confdefs.h.  */
21975 _ACEOF
21976 cat confdefs.h >>conftest.$ac_ext
21977 cat >>conftest.$ac_ext <<_ACEOF
21978 /* end confdefs.h.  */
21979 /* System header to define __stub macros and hopefully few prototypes,
21980     which can conflict with char cthread_fork (); below.
21981     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21982     <limits.h> exists even on freestanding compilers.  */
21983 #ifdef __STDC__
21984 # include <limits.h>
21985 #else
21986 # include <assert.h>
21987 #endif
21988 /* Override any gcc2 internal prototype to avoid an error.  */
21989 #ifdef __cplusplus
21990 extern "C"
21991 {
21992 #endif
21993 /* We use char because int might match the return type of a gcc2
21994    builtin and then its argument prototype would still apply.  */
21995 char cthread_fork ();
21996 /* The GNU C library defines this for functions which it implements
21997     to always fail with ENOSYS.  Some functions are actually named
21998     something starting with __ and the normal name is an alias.  */
21999 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
22000 choke me
22001 #else
22002 char (*f) () = cthread_fork;
22003 #endif
22004 #ifdef __cplusplus
22005 }
22006 #endif
22007
22008 int
22009 main ()
22010 {
22011 return f != cthread_fork;
22012   ;
22013   return 0;
22014 }
22015 _ACEOF
22016 rm -f conftest.$ac_objext conftest$ac_exeext
22017 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22018   (eval $ac_link) 2>&5
22019   ac_status=$?
22020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22021   (exit $ac_status); } &&
22022          { ac_try='test -s conftest$ac_exeext'
22023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22024   (eval $ac_try) 2>&5
22025   ac_status=$?
22026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22027   (exit $ac_status); }; }; then
22028   ac_cv_func_cthread_fork=yes
22029 else
22030   echo "$as_me: failed program was:" >&5
22031 sed 's/^/| /' conftest.$ac_ext >&5
22032
22033 ac_cv_func_cthread_fork=no
22034 fi
22035 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22036 fi
22037 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
22038 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
22039 if test $ac_cv_func_cthread_fork = yes; then
22040   ol_link_threads=yes
22041 fi
22042
22043
22044                 if test $ol_link_threads = no ; then
22045                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
22046 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
22047 if test "${ol_cv_cthread_all_load+set}" = set; then
22048   echo $ECHO_N "(cached) $ECHO_C" >&6
22049 else
22050
22051                                                                 save_LIBS="$LIBS"
22052                                 LIBS="-all_load $LIBS"
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 #include <mach/cthreads.h>
22061 int
22062 main ()
22063 {
22064
22065                                         cthread_fork((void *)0, (void *)0);
22066
22067   ;
22068   return 0;
22069 }
22070 _ACEOF
22071 rm -f conftest.$ac_objext conftest$ac_exeext
22072 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22073   (eval $ac_link) 2>&5
22074   ac_status=$?
22075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22076   (exit $ac_status); } &&
22077          { ac_try='test -s conftest$ac_exeext'
22078   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22079   (eval $ac_try) 2>&5
22080   ac_status=$?
22081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22082   (exit $ac_status); }; }; then
22083   ol_cv_cthread_all_load=yes
22084 else
22085   echo "$as_me: failed program was:" >&5
22086 sed 's/^/| /' conftest.$ac_ext >&5
22087
22088 ol_cv_cthread_all_load=no
22089 fi
22090 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22091                                                                 LIBS="$save_LIBS"
22092
22093 fi
22094 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
22095 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
22096
22097                         if test $ol_cv_cthread_all_load = yes ; then
22098                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
22099                                 ol_link_threads=mach
22100                                 ol_with_threads=found
22101                         fi
22102                 fi
22103
22104         elif test $ac_cv_header_cthreads_h = yes ; then
22105
22106                 ol_with_threads=found
22107
22108                                 save_LIBS="$LIBS"
22109                 LIBS="$LIBS -lthreads"
22110                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
22111 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
22112 if test "${ac_cv_func_cthread_fork+set}" = set; then
22113   echo $ECHO_N "(cached) $ECHO_C" >&6
22114 else
22115   cat >conftest.$ac_ext <<_ACEOF
22116 #line $LINENO "configure"
22117 /* confdefs.h.  */
22118 _ACEOF
22119 cat confdefs.h >>conftest.$ac_ext
22120 cat >>conftest.$ac_ext <<_ACEOF
22121 /* end confdefs.h.  */
22122 /* System header to define __stub macros and hopefully few prototypes,
22123     which can conflict with char cthread_fork (); below.
22124     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22125     <limits.h> exists even on freestanding compilers.  */
22126 #ifdef __STDC__
22127 # include <limits.h>
22128 #else
22129 # include <assert.h>
22130 #endif
22131 /* Override any gcc2 internal prototype to avoid an error.  */
22132 #ifdef __cplusplus
22133 extern "C"
22134 {
22135 #endif
22136 /* We use char because int might match the return type of a gcc2
22137    builtin and then its argument prototype would still apply.  */
22138 char cthread_fork ();
22139 /* The GNU C library defines this for functions which it implements
22140     to always fail with ENOSYS.  Some functions are actually named
22141     something starting with __ and the normal name is an alias.  */
22142 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
22143 choke me
22144 #else
22145 char (*f) () = cthread_fork;
22146 #endif
22147 #ifdef __cplusplus
22148 }
22149 #endif
22150
22151 int
22152 main ()
22153 {
22154 return f != cthread_fork;
22155   ;
22156   return 0;
22157 }
22158 _ACEOF
22159 rm -f conftest.$ac_objext conftest$ac_exeext
22160 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22161   (eval $ac_link) 2>&5
22162   ac_status=$?
22163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22164   (exit $ac_status); } &&
22165          { ac_try='test -s conftest$ac_exeext'
22166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22167   (eval $ac_try) 2>&5
22168   ac_status=$?
22169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22170   (exit $ac_status); }; }; then
22171   ac_cv_func_cthread_fork=yes
22172 else
22173   echo "$as_me: failed program was:" >&5
22174 sed 's/^/| /' conftest.$ac_ext >&5
22175
22176 ac_cv_func_cthread_fork=no
22177 fi
22178 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22179 fi
22180 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
22181 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
22182 if test $ac_cv_func_cthread_fork = yes; then
22183   ol_link_threads=yes
22184 fi
22185
22186                 LIBS="$save_LIBS"
22187
22188                 if test $ol_link_threads = yes ; then
22189                         LTHREAD_LIBS="-lthreads"
22190                         ol_link_threads=mach
22191                         ol_with_threads=found
22192                 else
22193                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
22194 echo "$as_me: error: could not link with Mach CThreads" >&2;}
22195    { (exit 1); exit 1; }; }
22196                 fi
22197
22198         elif test $ol_with_threads = mach ; then
22199                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
22200 echo "$as_me: error: could not locate Mach CThreads" >&2;}
22201    { (exit 1); exit 1; }; }
22202         fi
22203
22204         if test $ol_link_threads = mach ; then
22205
22206 cat >>confdefs.h <<\_ACEOF
22207 #define HAVE_MACH_CTHREADS 1
22208 _ACEOF
22209
22210         elif test $ol_with_threads = found ; then
22211                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
22212 echo "$as_me: error: could not link with Mach CThreads" >&2;}
22213    { (exit 1); exit 1; }; }
22214         fi
22215 fi
22216
22217 if test $ol_with_threads = auto -o $ol_with_threads = yes \
22218         -o $ol_with_threads = pth ; then
22219
22220
22221 for ac_header in pth.h
22222 do
22223 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22224 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22225   echo "$as_me:$LINENO: checking for $ac_header" >&5
22226 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22227 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22228   echo $ECHO_N "(cached) $ECHO_C" >&6
22229 fi
22230 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22231 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22232 else
22233   # Is the header compilable?
22234 echo "$as_me:$LINENO: checking $ac_header usability" >&5
22235 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
22236 cat >conftest.$ac_ext <<_ACEOF
22237 #line $LINENO "configure"
22238 /* confdefs.h.  */
22239 _ACEOF
22240 cat confdefs.h >>conftest.$ac_ext
22241 cat >>conftest.$ac_ext <<_ACEOF
22242 /* end confdefs.h.  */
22243 $ac_includes_default
22244 #include <$ac_header>
22245 _ACEOF
22246 rm -f conftest.$ac_objext
22247 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22248   (eval $ac_compile) 2>&5
22249   ac_status=$?
22250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22251   (exit $ac_status); } &&
22252          { ac_try='test -s conftest.$ac_objext'
22253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22254   (eval $ac_try) 2>&5
22255   ac_status=$?
22256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22257   (exit $ac_status); }; }; then
22258   ac_header_compiler=yes
22259 else
22260   echo "$as_me: failed program was:" >&5
22261 sed 's/^/| /' conftest.$ac_ext >&5
22262
22263 ac_header_compiler=no
22264 fi
22265 rm -f conftest.$ac_objext conftest.$ac_ext
22266 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22267 echo "${ECHO_T}$ac_header_compiler" >&6
22268
22269 # Is the header present?
22270 echo "$as_me:$LINENO: checking $ac_header presence" >&5
22271 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
22272 cat >conftest.$ac_ext <<_ACEOF
22273 #line $LINENO "configure"
22274 /* confdefs.h.  */
22275 _ACEOF
22276 cat confdefs.h >>conftest.$ac_ext
22277 cat >>conftest.$ac_ext <<_ACEOF
22278 /* end confdefs.h.  */
22279 #include <$ac_header>
22280 _ACEOF
22281 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22282   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22283   ac_status=$?
22284   grep -v '^ *+' conftest.er1 >conftest.err
22285   rm -f conftest.er1
22286   cat conftest.err >&5
22287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22288   (exit $ac_status); } >/dev/null; then
22289   if test -s conftest.err; then
22290     ac_cpp_err=$ac_c_preproc_warn_flag
22291   else
22292     ac_cpp_err=
22293   fi
22294 else
22295   ac_cpp_err=yes
22296 fi
22297 if test -z "$ac_cpp_err"; then
22298   ac_header_preproc=yes
22299 else
22300   echo "$as_me: failed program was:" >&5
22301 sed 's/^/| /' conftest.$ac_ext >&5
22302
22303   ac_header_preproc=no
22304 fi
22305 rm -f conftest.err conftest.$ac_ext
22306 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22307 echo "${ECHO_T}$ac_header_preproc" >&6
22308
22309 # So?  What about this header?
22310 case $ac_header_compiler:$ac_header_preproc in
22311   yes:no )
22312     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22313 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22314     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22315 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22316     (
22317       cat <<\_ASBOX
22318 ## ------------------------------------ ##
22319 ## Report this to bug-autoconf@gnu.org. ##
22320 ## ------------------------------------ ##
22321 _ASBOX
22322     ) |
22323       sed "s/^/$as_me: WARNING:     /" >&2
22324     ;;
22325   no:yes )
22326     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22327 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22328     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22329 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22330     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22331 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22332     (
22333       cat <<\_ASBOX
22334 ## ------------------------------------ ##
22335 ## Report this to bug-autoconf@gnu.org. ##
22336 ## ------------------------------------ ##
22337 _ASBOX
22338     ) |
22339       sed "s/^/$as_me: WARNING:     /" >&2
22340     ;;
22341 esac
22342 echo "$as_me:$LINENO: checking for $ac_header" >&5
22343 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22344 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22345   echo $ECHO_N "(cached) $ECHO_C" >&6
22346 else
22347   eval "$as_ac_Header=$ac_header_preproc"
22348 fi
22349 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22350 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22351
22352 fi
22353 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22354   cat >>confdefs.h <<_ACEOF
22355 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22356 _ACEOF
22357
22358 fi
22359
22360 done
22361
22362
22363         if test $ac_cv_header_pth_h = yes ; then
22364                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
22365 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
22366 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
22367   echo $ECHO_N "(cached) $ECHO_C" >&6
22368 else
22369   ac_check_lib_save_LIBS=$LIBS
22370 LIBS="-lpth  $LIBS"
22371 cat >conftest.$ac_ext <<_ACEOF
22372 #line $LINENO "configure"
22373 /* confdefs.h.  */
22374 _ACEOF
22375 cat confdefs.h >>conftest.$ac_ext
22376 cat >>conftest.$ac_ext <<_ACEOF
22377 /* end confdefs.h.  */
22378
22379 /* Override any gcc2 internal prototype to avoid an error.  */
22380 #ifdef __cplusplus
22381 extern "C"
22382 #endif
22383 /* We use char because int might match the return type of a gcc2
22384    builtin and then its argument prototype would still apply.  */
22385 char pth_version ();
22386 int
22387 main ()
22388 {
22389 pth_version ();
22390   ;
22391   return 0;
22392 }
22393 _ACEOF
22394 rm -f conftest.$ac_objext conftest$ac_exeext
22395 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22396   (eval $ac_link) 2>&5
22397   ac_status=$?
22398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22399   (exit $ac_status); } &&
22400          { ac_try='test -s conftest$ac_exeext'
22401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22402   (eval $ac_try) 2>&5
22403   ac_status=$?
22404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22405   (exit $ac_status); }; }; then
22406   ac_cv_lib_pth_pth_version=yes
22407 else
22408   echo "$as_me: failed program was:" >&5
22409 sed 's/^/| /' conftest.$ac_ext >&5
22410
22411 ac_cv_lib_pth_pth_version=no
22412 fi
22413 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22414 LIBS=$ac_check_lib_save_LIBS
22415 fi
22416 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
22417 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
22418 if test $ac_cv_lib_pth_pth_version = yes; then
22419   have_pth=yes
22420 else
22421   have_pth=no
22422 fi
22423
22424
22425                 if test $have_pth = yes ; then
22426
22427 cat >>confdefs.h <<\_ACEOF
22428 #define HAVE_GNU_PTH 1
22429 _ACEOF
22430
22431                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
22432                         ol_link_threads=pth
22433                         ol_with_threads=found
22434
22435                         if test $ol_with_yielding_select = auto ; then
22436                                 ol_with_yielding_select=yes
22437                         fi
22438                 fi
22439         fi
22440 fi
22441
22442 if test $ol_with_threads = auto -o $ol_with_threads = yes \
22443         -o $ol_with_threads = lwp ; then
22444
22445
22446
22447 for ac_header in thread.h synch.h
22448 do
22449 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22450 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22451   echo "$as_me:$LINENO: checking for $ac_header" >&5
22452 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22453 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22454   echo $ECHO_N "(cached) $ECHO_C" >&6
22455 fi
22456 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22457 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22458 else
22459   # Is the header compilable?
22460 echo "$as_me:$LINENO: checking $ac_header usability" >&5
22461 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
22462 cat >conftest.$ac_ext <<_ACEOF
22463 #line $LINENO "configure"
22464 /* confdefs.h.  */
22465 _ACEOF
22466 cat confdefs.h >>conftest.$ac_ext
22467 cat >>conftest.$ac_ext <<_ACEOF
22468 /* end confdefs.h.  */
22469 $ac_includes_default
22470 #include <$ac_header>
22471 _ACEOF
22472 rm -f conftest.$ac_objext
22473 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22474   (eval $ac_compile) 2>&5
22475   ac_status=$?
22476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22477   (exit $ac_status); } &&
22478          { ac_try='test -s conftest.$ac_objext'
22479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22480   (eval $ac_try) 2>&5
22481   ac_status=$?
22482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22483   (exit $ac_status); }; }; then
22484   ac_header_compiler=yes
22485 else
22486   echo "$as_me: failed program was:" >&5
22487 sed 's/^/| /' conftest.$ac_ext >&5
22488
22489 ac_header_compiler=no
22490 fi
22491 rm -f conftest.$ac_objext conftest.$ac_ext
22492 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22493 echo "${ECHO_T}$ac_header_compiler" >&6
22494
22495 # Is the header present?
22496 echo "$as_me:$LINENO: checking $ac_header presence" >&5
22497 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
22498 cat >conftest.$ac_ext <<_ACEOF
22499 #line $LINENO "configure"
22500 /* confdefs.h.  */
22501 _ACEOF
22502 cat confdefs.h >>conftest.$ac_ext
22503 cat >>conftest.$ac_ext <<_ACEOF
22504 /* end confdefs.h.  */
22505 #include <$ac_header>
22506 _ACEOF
22507 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22508   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22509   ac_status=$?
22510   grep -v '^ *+' conftest.er1 >conftest.err
22511   rm -f conftest.er1
22512   cat conftest.err >&5
22513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22514   (exit $ac_status); } >/dev/null; then
22515   if test -s conftest.err; then
22516     ac_cpp_err=$ac_c_preproc_warn_flag
22517   else
22518     ac_cpp_err=
22519   fi
22520 else
22521   ac_cpp_err=yes
22522 fi
22523 if test -z "$ac_cpp_err"; then
22524   ac_header_preproc=yes
22525 else
22526   echo "$as_me: failed program was:" >&5
22527 sed 's/^/| /' conftest.$ac_ext >&5
22528
22529   ac_header_preproc=no
22530 fi
22531 rm -f conftest.err conftest.$ac_ext
22532 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22533 echo "${ECHO_T}$ac_header_preproc" >&6
22534
22535 # So?  What about this header?
22536 case $ac_header_compiler:$ac_header_preproc in
22537   yes:no )
22538     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22539 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22540     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22541 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22542     (
22543       cat <<\_ASBOX
22544 ## ------------------------------------ ##
22545 ## Report this to bug-autoconf@gnu.org. ##
22546 ## ------------------------------------ ##
22547 _ASBOX
22548     ) |
22549       sed "s/^/$as_me: WARNING:     /" >&2
22550     ;;
22551   no:yes )
22552     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22553 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22554     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22555 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22556     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22557 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22558     (
22559       cat <<\_ASBOX
22560 ## ------------------------------------ ##
22561 ## Report this to bug-autoconf@gnu.org. ##
22562 ## ------------------------------------ ##
22563 _ASBOX
22564     ) |
22565       sed "s/^/$as_me: WARNING:     /" >&2
22566     ;;
22567 esac
22568 echo "$as_me:$LINENO: checking for $ac_header" >&5
22569 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22570 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22571   echo $ECHO_N "(cached) $ECHO_C" >&6
22572 else
22573   eval "$as_ac_Header=$ac_header_preproc"
22574 fi
22575 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22576 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22577
22578 fi
22579 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22580   cat >>confdefs.h <<_ACEOF
22581 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22582 _ACEOF
22583
22584 fi
22585
22586 done
22587
22588         if test $ac_cv_header_thread_h = yes -a $ac_cv_header_synch_h = yes ; then
22589                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
22590 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
22591 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
22592   echo $ECHO_N "(cached) $ECHO_C" >&6
22593 else
22594   ac_check_lib_save_LIBS=$LIBS
22595 LIBS="-lthread  $LIBS"
22596 cat >conftest.$ac_ext <<_ACEOF
22597 #line $LINENO "configure"
22598 /* confdefs.h.  */
22599 _ACEOF
22600 cat confdefs.h >>conftest.$ac_ext
22601 cat >>conftest.$ac_ext <<_ACEOF
22602 /* end confdefs.h.  */
22603
22604 /* Override any gcc2 internal prototype to avoid an error.  */
22605 #ifdef __cplusplus
22606 extern "C"
22607 #endif
22608 /* We use char because int might match the return type of a gcc2
22609    builtin and then its argument prototype would still apply.  */
22610 char thr_create ();
22611 int
22612 main ()
22613 {
22614 thr_create ();
22615   ;
22616   return 0;
22617 }
22618 _ACEOF
22619 rm -f conftest.$ac_objext conftest$ac_exeext
22620 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22621   (eval $ac_link) 2>&5
22622   ac_status=$?
22623   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22624   (exit $ac_status); } &&
22625          { ac_try='test -s conftest$ac_exeext'
22626   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22627   (eval $ac_try) 2>&5
22628   ac_status=$?
22629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22630   (exit $ac_status); }; }; then
22631   ac_cv_lib_thread_thr_create=yes
22632 else
22633   echo "$as_me: failed program was:" >&5
22634 sed 's/^/| /' conftest.$ac_ext >&5
22635
22636 ac_cv_lib_thread_thr_create=no
22637 fi
22638 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22639 LIBS=$ac_check_lib_save_LIBS
22640 fi
22641 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
22642 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
22643 if test $ac_cv_lib_thread_thr_create = yes; then
22644   have_thr=yes
22645 else
22646   have_thr=no
22647 fi
22648
22649
22650                 if test $have_thr = yes ; then
22651
22652 cat >>confdefs.h <<\_ACEOF
22653 #define HAVE_THR 1
22654 _ACEOF
22655
22656                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
22657                         ol_link_threads=thr
22658
22659                         if test $ol_with_yielding_select = auto ; then
22660                                 ol_with_yielding_select=yes
22661                         fi
22662
22663
22664
22665 for ac_func in \
22666                                 thr_setconcurrency \
22667                                 thr_getconcurrency \
22668
22669 do
22670 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22671 echo "$as_me:$LINENO: checking for $ac_func" >&5
22672 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
22673 if eval "test \"\${$as_ac_var+set}\" = set"; then
22674   echo $ECHO_N "(cached) $ECHO_C" >&6
22675 else
22676   cat >conftest.$ac_ext <<_ACEOF
22677 #line $LINENO "configure"
22678 /* confdefs.h.  */
22679 _ACEOF
22680 cat confdefs.h >>conftest.$ac_ext
22681 cat >>conftest.$ac_ext <<_ACEOF
22682 /* end confdefs.h.  */
22683 /* System header to define __stub macros and hopefully few prototypes,
22684     which can conflict with char $ac_func (); below.
22685     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22686     <limits.h> exists even on freestanding compilers.  */
22687 #ifdef __STDC__
22688 # include <limits.h>
22689 #else
22690 # include <assert.h>
22691 #endif
22692 /* Override any gcc2 internal prototype to avoid an error.  */
22693 #ifdef __cplusplus
22694 extern "C"
22695 {
22696 #endif
22697 /* We use char because int might match the return type of a gcc2
22698    builtin and then its argument prototype would still apply.  */
22699 char $ac_func ();
22700 /* The GNU C library defines this for functions which it implements
22701     to always fail with ENOSYS.  Some functions are actually named
22702     something starting with __ and the normal name is an alias.  */
22703 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
22704 choke me
22705 #else
22706 char (*f) () = $ac_func;
22707 #endif
22708 #ifdef __cplusplus
22709 }
22710 #endif
22711
22712 int
22713 main ()
22714 {
22715 return f != $ac_func;
22716   ;
22717   return 0;
22718 }
22719 _ACEOF
22720 rm -f conftest.$ac_objext conftest$ac_exeext
22721 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22722   (eval $ac_link) 2>&5
22723   ac_status=$?
22724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22725   (exit $ac_status); } &&
22726          { ac_try='test -s conftest$ac_exeext'
22727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22728   (eval $ac_try) 2>&5
22729   ac_status=$?
22730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22731   (exit $ac_status); }; }; then
22732   eval "$as_ac_var=yes"
22733 else
22734   echo "$as_me: failed program was:" >&5
22735 sed 's/^/| /' conftest.$ac_ext >&5
22736
22737 eval "$as_ac_var=no"
22738 fi
22739 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22740 fi
22741 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
22742 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
22743 if test `eval echo '${'$as_ac_var'}'` = yes; then
22744   cat >>confdefs.h <<_ACEOF
22745 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22746 _ACEOF
22747
22748 fi
22749 done
22750
22751                 fi
22752         fi
22753
22754
22755 for ac_header in lwp/lwp.h
22756 do
22757 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22758 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22759   echo "$as_me:$LINENO: checking for $ac_header" >&5
22760 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22761 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22762   echo $ECHO_N "(cached) $ECHO_C" >&6
22763 fi
22764 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22765 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22766 else
22767   # Is the header compilable?
22768 echo "$as_me:$LINENO: checking $ac_header usability" >&5
22769 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
22770 cat >conftest.$ac_ext <<_ACEOF
22771 #line $LINENO "configure"
22772 /* confdefs.h.  */
22773 _ACEOF
22774 cat confdefs.h >>conftest.$ac_ext
22775 cat >>conftest.$ac_ext <<_ACEOF
22776 /* end confdefs.h.  */
22777 $ac_includes_default
22778 #include <$ac_header>
22779 _ACEOF
22780 rm -f conftest.$ac_objext
22781 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22782   (eval $ac_compile) 2>&5
22783   ac_status=$?
22784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22785   (exit $ac_status); } &&
22786          { ac_try='test -s conftest.$ac_objext'
22787   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22788   (eval $ac_try) 2>&5
22789   ac_status=$?
22790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22791   (exit $ac_status); }; }; then
22792   ac_header_compiler=yes
22793 else
22794   echo "$as_me: failed program was:" >&5
22795 sed 's/^/| /' conftest.$ac_ext >&5
22796
22797 ac_header_compiler=no
22798 fi
22799 rm -f conftest.$ac_objext conftest.$ac_ext
22800 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22801 echo "${ECHO_T}$ac_header_compiler" >&6
22802
22803 # Is the header present?
22804 echo "$as_me:$LINENO: checking $ac_header presence" >&5
22805 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
22806 cat >conftest.$ac_ext <<_ACEOF
22807 #line $LINENO "configure"
22808 /* confdefs.h.  */
22809 _ACEOF
22810 cat confdefs.h >>conftest.$ac_ext
22811 cat >>conftest.$ac_ext <<_ACEOF
22812 /* end confdefs.h.  */
22813 #include <$ac_header>
22814 _ACEOF
22815 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22816   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22817   ac_status=$?
22818   grep -v '^ *+' conftest.er1 >conftest.err
22819   rm -f conftest.er1
22820   cat conftest.err >&5
22821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22822   (exit $ac_status); } >/dev/null; then
22823   if test -s conftest.err; then
22824     ac_cpp_err=$ac_c_preproc_warn_flag
22825   else
22826     ac_cpp_err=
22827   fi
22828 else
22829   ac_cpp_err=yes
22830 fi
22831 if test -z "$ac_cpp_err"; then
22832   ac_header_preproc=yes
22833 else
22834   echo "$as_me: failed program was:" >&5
22835 sed 's/^/| /' conftest.$ac_ext >&5
22836
22837   ac_header_preproc=no
22838 fi
22839 rm -f conftest.err conftest.$ac_ext
22840 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22841 echo "${ECHO_T}$ac_header_preproc" >&6
22842
22843 # So?  What about this header?
22844 case $ac_header_compiler:$ac_header_preproc in
22845   yes:no )
22846     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22847 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22848     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22849 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22850     (
22851       cat <<\_ASBOX
22852 ## ------------------------------------ ##
22853 ## Report this to bug-autoconf@gnu.org. ##
22854 ## ------------------------------------ ##
22855 _ASBOX
22856     ) |
22857       sed "s/^/$as_me: WARNING:     /" >&2
22858     ;;
22859   no:yes )
22860     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22861 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22862     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22863 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22864     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22865 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22866     (
22867       cat <<\_ASBOX
22868 ## ------------------------------------ ##
22869 ## Report this to bug-autoconf@gnu.org. ##
22870 ## ------------------------------------ ##
22871 _ASBOX
22872     ) |
22873       sed "s/^/$as_me: WARNING:     /" >&2
22874     ;;
22875 esac
22876 echo "$as_me:$LINENO: checking for $ac_header" >&5
22877 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22878 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22879   echo $ECHO_N "(cached) $ECHO_C" >&6
22880 else
22881   eval "$as_ac_Header=$ac_header_preproc"
22882 fi
22883 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22884 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22885
22886 fi
22887 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22888   cat >>confdefs.h <<_ACEOF
22889 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22890 _ACEOF
22891
22892 fi
22893
22894 done
22895
22896         if test $ac_cv_header_lwp_lwp_h = yes ; then
22897                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
22898 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
22899 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
22900   echo $ECHO_N "(cached) $ECHO_C" >&6
22901 else
22902   ac_check_lib_save_LIBS=$LIBS
22903 LIBS="-llwp  $LIBS"
22904 cat >conftest.$ac_ext <<_ACEOF
22905 #line $LINENO "configure"
22906 /* confdefs.h.  */
22907 _ACEOF
22908 cat confdefs.h >>conftest.$ac_ext
22909 cat >>conftest.$ac_ext <<_ACEOF
22910 /* end confdefs.h.  */
22911
22912 /* Override any gcc2 internal prototype to avoid an error.  */
22913 #ifdef __cplusplus
22914 extern "C"
22915 #endif
22916 /* We use char because int might match the return type of a gcc2
22917    builtin and then its argument prototype would still apply.  */
22918 char lwp_create ();
22919 int
22920 main ()
22921 {
22922 lwp_create ();
22923   ;
22924   return 0;
22925 }
22926 _ACEOF
22927 rm -f conftest.$ac_objext conftest$ac_exeext
22928 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22929   (eval $ac_link) 2>&5
22930   ac_status=$?
22931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22932   (exit $ac_status); } &&
22933          { ac_try='test -s conftest$ac_exeext'
22934   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22935   (eval $ac_try) 2>&5
22936   ac_status=$?
22937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22938   (exit $ac_status); }; }; then
22939   ac_cv_lib_lwp_lwp_create=yes
22940 else
22941   echo "$as_me: failed program was:" >&5
22942 sed 's/^/| /' conftest.$ac_ext >&5
22943
22944 ac_cv_lib_lwp_lwp_create=no
22945 fi
22946 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22947 LIBS=$ac_check_lib_save_LIBS
22948 fi
22949 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
22950 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
22951 if test $ac_cv_lib_lwp_lwp_create = yes; then
22952   have_lwp=yes
22953 else
22954   have_lwp=no
22955 fi
22956
22957
22958                 if test $have_lwp = yes ; then
22959
22960 cat >>confdefs.h <<\_ACEOF
22961 #define HAVE_LWP 1
22962 _ACEOF
22963
22964                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
22965                         ol_link_threads=lwp
22966
22967                         if test $ol_with_yielding_select = auto ; then
22968                                 ol_with_yielding_select=no
22969                         fi
22970                 fi
22971         fi
22972 fi
22973
22974 if test $ol_with_yielding_select = yes ; then
22975
22976 cat >>confdefs.h <<\_ACEOF
22977 #define HAVE_YIELDING_SELECT 1
22978 _ACEOF
22979
22980 fi
22981
22982 if test $ol_with_threads = manual ; then
22983                 ol_link_threads=yes
22984
22985         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
22986 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
22987
22988
22989
22990 for ac_header in pthread.h sched.h
22991 do
22992 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22993 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22994   echo "$as_me:$LINENO: checking for $ac_header" >&5
22995 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22996 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22997   echo $ECHO_N "(cached) $ECHO_C" >&6
22998 fi
22999 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23000 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23001 else
23002   # Is the header compilable?
23003 echo "$as_me:$LINENO: checking $ac_header usability" >&5
23004 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
23005 cat >conftest.$ac_ext <<_ACEOF
23006 #line $LINENO "configure"
23007 /* confdefs.h.  */
23008 _ACEOF
23009 cat confdefs.h >>conftest.$ac_ext
23010 cat >>conftest.$ac_ext <<_ACEOF
23011 /* end confdefs.h.  */
23012 $ac_includes_default
23013 #include <$ac_header>
23014 _ACEOF
23015 rm -f conftest.$ac_objext
23016 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23017   (eval $ac_compile) 2>&5
23018   ac_status=$?
23019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23020   (exit $ac_status); } &&
23021          { ac_try='test -s conftest.$ac_objext'
23022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23023   (eval $ac_try) 2>&5
23024   ac_status=$?
23025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23026   (exit $ac_status); }; }; then
23027   ac_header_compiler=yes
23028 else
23029   echo "$as_me: failed program was:" >&5
23030 sed 's/^/| /' conftest.$ac_ext >&5
23031
23032 ac_header_compiler=no
23033 fi
23034 rm -f conftest.$ac_objext conftest.$ac_ext
23035 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23036 echo "${ECHO_T}$ac_header_compiler" >&6
23037
23038 # Is the header present?
23039 echo "$as_me:$LINENO: checking $ac_header presence" >&5
23040 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
23041 cat >conftest.$ac_ext <<_ACEOF
23042 #line $LINENO "configure"
23043 /* confdefs.h.  */
23044 _ACEOF
23045 cat confdefs.h >>conftest.$ac_ext
23046 cat >>conftest.$ac_ext <<_ACEOF
23047 /* end confdefs.h.  */
23048 #include <$ac_header>
23049 _ACEOF
23050 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
23051   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
23052   ac_status=$?
23053   grep -v '^ *+' conftest.er1 >conftest.err
23054   rm -f conftest.er1
23055   cat conftest.err >&5
23056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23057   (exit $ac_status); } >/dev/null; then
23058   if test -s conftest.err; then
23059     ac_cpp_err=$ac_c_preproc_warn_flag
23060   else
23061     ac_cpp_err=
23062   fi
23063 else
23064   ac_cpp_err=yes
23065 fi
23066 if test -z "$ac_cpp_err"; then
23067   ac_header_preproc=yes
23068 else
23069   echo "$as_me: failed program was:" >&5
23070 sed 's/^/| /' conftest.$ac_ext >&5
23071
23072   ac_header_preproc=no
23073 fi
23074 rm -f conftest.err conftest.$ac_ext
23075 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23076 echo "${ECHO_T}$ac_header_preproc" >&6
23077
23078 # So?  What about this header?
23079 case $ac_header_compiler:$ac_header_preproc in
23080   yes:no )
23081     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
23082 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
23083     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23084 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23085     (
23086       cat <<\_ASBOX
23087 ## ------------------------------------ ##
23088 ## Report this to bug-autoconf@gnu.org. ##
23089 ## ------------------------------------ ##
23090 _ASBOX
23091     ) |
23092       sed "s/^/$as_me: WARNING:     /" >&2
23093     ;;
23094   no:yes )
23095     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
23096 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
23097     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
23098 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
23099     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23100 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23101     (
23102       cat <<\_ASBOX
23103 ## ------------------------------------ ##
23104 ## Report this to bug-autoconf@gnu.org. ##
23105 ## ------------------------------------ ##
23106 _ASBOX
23107     ) |
23108       sed "s/^/$as_me: WARNING:     /" >&2
23109     ;;
23110 esac
23111 echo "$as_me:$LINENO: checking for $ac_header" >&5
23112 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23113 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23114   echo $ECHO_N "(cached) $ECHO_C" >&6
23115 else
23116   eval "$as_ac_Header=$ac_header_preproc"
23117 fi
23118 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23119 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23120
23121 fi
23122 if test `eval echo '${'$as_ac_Header'}'` = yes; then
23123   cat >>confdefs.h <<_ACEOF
23124 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
23125 _ACEOF
23126
23127 fi
23128
23129 done
23130
23131
23132
23133 for ac_func in sched_yield pthread_yield
23134 do
23135 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23136 echo "$as_me:$LINENO: checking for $ac_func" >&5
23137 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23138 if eval "test \"\${$as_ac_var+set}\" = set"; then
23139   echo $ECHO_N "(cached) $ECHO_C" >&6
23140 else
23141   cat >conftest.$ac_ext <<_ACEOF
23142 #line $LINENO "configure"
23143 /* confdefs.h.  */
23144 _ACEOF
23145 cat confdefs.h >>conftest.$ac_ext
23146 cat >>conftest.$ac_ext <<_ACEOF
23147 /* end confdefs.h.  */
23148 /* System header to define __stub macros and hopefully few prototypes,
23149     which can conflict with char $ac_func (); below.
23150     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23151     <limits.h> exists even on freestanding compilers.  */
23152 #ifdef __STDC__
23153 # include <limits.h>
23154 #else
23155 # include <assert.h>
23156 #endif
23157 /* Override any gcc2 internal prototype to avoid an error.  */
23158 #ifdef __cplusplus
23159 extern "C"
23160 {
23161 #endif
23162 /* We use char because int might match the return type of a gcc2
23163    builtin and then its argument prototype would still apply.  */
23164 char $ac_func ();
23165 /* The GNU C library defines this for functions which it implements
23166     to always fail with ENOSYS.  Some functions are actually named
23167     something starting with __ and the normal name is an alias.  */
23168 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23169 choke me
23170 #else
23171 char (*f) () = $ac_func;
23172 #endif
23173 #ifdef __cplusplus
23174 }
23175 #endif
23176
23177 int
23178 main ()
23179 {
23180 return f != $ac_func;
23181   ;
23182   return 0;
23183 }
23184 _ACEOF
23185 rm -f conftest.$ac_objext conftest$ac_exeext
23186 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23187   (eval $ac_link) 2>&5
23188   ac_status=$?
23189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23190   (exit $ac_status); } &&
23191          { ac_try='test -s conftest$ac_exeext'
23192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23193   (eval $ac_try) 2>&5
23194   ac_status=$?
23195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23196   (exit $ac_status); }; }; then
23197   eval "$as_ac_var=yes"
23198 else
23199   echo "$as_me: failed program was:" >&5
23200 sed 's/^/| /' conftest.$ac_ext >&5
23201
23202 eval "$as_ac_var=no"
23203 fi
23204 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23205 fi
23206 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23207 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23208 if test `eval echo '${'$as_ac_var'}'` = yes; then
23209   cat >>confdefs.h <<_ACEOF
23210 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23211 _ACEOF
23212
23213 fi
23214 done
23215
23216
23217         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
23218 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
23219 if test "${ol_cv_header_linux_threads+set}" = set; then
23220   echo $ECHO_N "(cached) $ECHO_C" >&6
23221 else
23222   cat >conftest.$ac_ext <<_ACEOF
23223 #line $LINENO "configure"
23224 /* confdefs.h.  */
23225 _ACEOF
23226 cat confdefs.h >>conftest.$ac_ext
23227 cat >>conftest.$ac_ext <<_ACEOF
23228 /* end confdefs.h.  */
23229 #include <pthread.h>
23230 _ACEOF
23231 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23232   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
23233   ol_cv_header_linux_threads=yes
23234 else
23235   ol_cv_header_linux_threads=no
23236 fi
23237 rm -f conftest*
23238
23239
23240 fi
23241 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
23242 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
23243         if test $ol_cv_header_linux_threads = yes; then
23244
23245 cat >>confdefs.h <<\_ACEOF
23246 #define HAVE_LINUX_THREADS 1
23247 _ACEOF
23248
23249         fi
23250
23251
23252
23253 for ac_header in mach/cthreads.h
23254 do
23255 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
23256 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23257   echo "$as_me:$LINENO: checking for $ac_header" >&5
23258 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23259 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23260   echo $ECHO_N "(cached) $ECHO_C" >&6
23261 fi
23262 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23263 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23264 else
23265   # Is the header compilable?
23266 echo "$as_me:$LINENO: checking $ac_header usability" >&5
23267 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
23268 cat >conftest.$ac_ext <<_ACEOF
23269 #line $LINENO "configure"
23270 /* confdefs.h.  */
23271 _ACEOF
23272 cat confdefs.h >>conftest.$ac_ext
23273 cat >>conftest.$ac_ext <<_ACEOF
23274 /* end confdefs.h.  */
23275 $ac_includes_default
23276 #include <$ac_header>
23277 _ACEOF
23278 rm -f conftest.$ac_objext
23279 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23280   (eval $ac_compile) 2>&5
23281   ac_status=$?
23282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23283   (exit $ac_status); } &&
23284          { ac_try='test -s conftest.$ac_objext'
23285   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23286   (eval $ac_try) 2>&5
23287   ac_status=$?
23288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23289   (exit $ac_status); }; }; then
23290   ac_header_compiler=yes
23291 else
23292   echo "$as_me: failed program was:" >&5
23293 sed 's/^/| /' conftest.$ac_ext >&5
23294
23295 ac_header_compiler=no
23296 fi
23297 rm -f conftest.$ac_objext conftest.$ac_ext
23298 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23299 echo "${ECHO_T}$ac_header_compiler" >&6
23300
23301 # Is the header present?
23302 echo "$as_me:$LINENO: checking $ac_header presence" >&5
23303 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
23304 cat >conftest.$ac_ext <<_ACEOF
23305 #line $LINENO "configure"
23306 /* confdefs.h.  */
23307 _ACEOF
23308 cat confdefs.h >>conftest.$ac_ext
23309 cat >>conftest.$ac_ext <<_ACEOF
23310 /* end confdefs.h.  */
23311 #include <$ac_header>
23312 _ACEOF
23313 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
23314   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
23315   ac_status=$?
23316   grep -v '^ *+' conftest.er1 >conftest.err
23317   rm -f conftest.er1
23318   cat conftest.err >&5
23319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23320   (exit $ac_status); } >/dev/null; then
23321   if test -s conftest.err; then
23322     ac_cpp_err=$ac_c_preproc_warn_flag
23323   else
23324     ac_cpp_err=
23325   fi
23326 else
23327   ac_cpp_err=yes
23328 fi
23329 if test -z "$ac_cpp_err"; then
23330   ac_header_preproc=yes
23331 else
23332   echo "$as_me: failed program was:" >&5
23333 sed 's/^/| /' conftest.$ac_ext >&5
23334
23335   ac_header_preproc=no
23336 fi
23337 rm -f conftest.err conftest.$ac_ext
23338 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23339 echo "${ECHO_T}$ac_header_preproc" >&6
23340
23341 # So?  What about this header?
23342 case $ac_header_compiler:$ac_header_preproc in
23343   yes:no )
23344     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
23345 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
23346     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23347 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23348     (
23349       cat <<\_ASBOX
23350 ## ------------------------------------ ##
23351 ## Report this to bug-autoconf@gnu.org. ##
23352 ## ------------------------------------ ##
23353 _ASBOX
23354     ) |
23355       sed "s/^/$as_me: WARNING:     /" >&2
23356     ;;
23357   no:yes )
23358     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
23359 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
23360     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
23361 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
23362     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23363 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23364     (
23365       cat <<\_ASBOX
23366 ## ------------------------------------ ##
23367 ## Report this to bug-autoconf@gnu.org. ##
23368 ## ------------------------------------ ##
23369 _ASBOX
23370     ) |
23371       sed "s/^/$as_me: WARNING:     /" >&2
23372     ;;
23373 esac
23374 echo "$as_me:$LINENO: checking for $ac_header" >&5
23375 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23376 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23377   echo $ECHO_N "(cached) $ECHO_C" >&6
23378 else
23379   eval "$as_ac_Header=$ac_header_preproc"
23380 fi
23381 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23382 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23383
23384 fi
23385 if test `eval echo '${'$as_ac_Header'}'` = yes; then
23386   cat >>confdefs.h <<_ACEOF
23387 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
23388 _ACEOF
23389
23390 fi
23391
23392 done
23393
23394
23395 for ac_header in lwp/lwp.h
23396 do
23397 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
23398 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23399   echo "$as_me:$LINENO: checking for $ac_header" >&5
23400 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23401 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23402   echo $ECHO_N "(cached) $ECHO_C" >&6
23403 fi
23404 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23405 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23406 else
23407   # Is the header compilable?
23408 echo "$as_me:$LINENO: checking $ac_header usability" >&5
23409 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
23410 cat >conftest.$ac_ext <<_ACEOF
23411 #line $LINENO "configure"
23412 /* confdefs.h.  */
23413 _ACEOF
23414 cat confdefs.h >>conftest.$ac_ext
23415 cat >>conftest.$ac_ext <<_ACEOF
23416 /* end confdefs.h.  */
23417 $ac_includes_default
23418 #include <$ac_header>
23419 _ACEOF
23420 rm -f conftest.$ac_objext
23421 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23422   (eval $ac_compile) 2>&5
23423   ac_status=$?
23424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23425   (exit $ac_status); } &&
23426          { ac_try='test -s conftest.$ac_objext'
23427   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23428   (eval $ac_try) 2>&5
23429   ac_status=$?
23430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23431   (exit $ac_status); }; }; then
23432   ac_header_compiler=yes
23433 else
23434   echo "$as_me: failed program was:" >&5
23435 sed 's/^/| /' conftest.$ac_ext >&5
23436
23437 ac_header_compiler=no
23438 fi
23439 rm -f conftest.$ac_objext conftest.$ac_ext
23440 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23441 echo "${ECHO_T}$ac_header_compiler" >&6
23442
23443 # Is the header present?
23444 echo "$as_me:$LINENO: checking $ac_header presence" >&5
23445 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
23446 cat >conftest.$ac_ext <<_ACEOF
23447 #line $LINENO "configure"
23448 /* confdefs.h.  */
23449 _ACEOF
23450 cat confdefs.h >>conftest.$ac_ext
23451 cat >>conftest.$ac_ext <<_ACEOF
23452 /* end confdefs.h.  */
23453 #include <$ac_header>
23454 _ACEOF
23455 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
23456   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
23457   ac_status=$?
23458   grep -v '^ *+' conftest.er1 >conftest.err
23459   rm -f conftest.er1
23460   cat conftest.err >&5
23461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23462   (exit $ac_status); } >/dev/null; then
23463   if test -s conftest.err; then
23464     ac_cpp_err=$ac_c_preproc_warn_flag
23465   else
23466     ac_cpp_err=
23467   fi
23468 else
23469   ac_cpp_err=yes
23470 fi
23471 if test -z "$ac_cpp_err"; then
23472   ac_header_preproc=yes
23473 else
23474   echo "$as_me: failed program was:" >&5
23475 sed 's/^/| /' conftest.$ac_ext >&5
23476
23477   ac_header_preproc=no
23478 fi
23479 rm -f conftest.err conftest.$ac_ext
23480 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23481 echo "${ECHO_T}$ac_header_preproc" >&6
23482
23483 # So?  What about this header?
23484 case $ac_header_compiler:$ac_header_preproc in
23485   yes:no )
23486     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
23487 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
23488     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23489 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23490     (
23491       cat <<\_ASBOX
23492 ## ------------------------------------ ##
23493 ## Report this to bug-autoconf@gnu.org. ##
23494 ## ------------------------------------ ##
23495 _ASBOX
23496     ) |
23497       sed "s/^/$as_me: WARNING:     /" >&2
23498     ;;
23499   no:yes )
23500     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
23501 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
23502     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
23503 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
23504     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23505 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23506     (
23507       cat <<\_ASBOX
23508 ## ------------------------------------ ##
23509 ## Report this to bug-autoconf@gnu.org. ##
23510 ## ------------------------------------ ##
23511 _ASBOX
23512     ) |
23513       sed "s/^/$as_me: WARNING:     /" >&2
23514     ;;
23515 esac
23516 echo "$as_me:$LINENO: checking for $ac_header" >&5
23517 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23518 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23519   echo $ECHO_N "(cached) $ECHO_C" >&6
23520 else
23521   eval "$as_ac_Header=$ac_header_preproc"
23522 fi
23523 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23524 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23525
23526 fi
23527 if test `eval echo '${'$as_ac_Header'}'` = yes; then
23528   cat >>confdefs.h <<_ACEOF
23529 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
23530 _ACEOF
23531
23532 fi
23533
23534 done
23535
23536
23537
23538 for ac_header in thread.h synch.h
23539 do
23540 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
23541 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23542   echo "$as_me:$LINENO: checking for $ac_header" >&5
23543 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23544 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23545   echo $ECHO_N "(cached) $ECHO_C" >&6
23546 fi
23547 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23548 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23549 else
23550   # Is the header compilable?
23551 echo "$as_me:$LINENO: checking $ac_header usability" >&5
23552 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
23553 cat >conftest.$ac_ext <<_ACEOF
23554 #line $LINENO "configure"
23555 /* confdefs.h.  */
23556 _ACEOF
23557 cat confdefs.h >>conftest.$ac_ext
23558 cat >>conftest.$ac_ext <<_ACEOF
23559 /* end confdefs.h.  */
23560 $ac_includes_default
23561 #include <$ac_header>
23562 _ACEOF
23563 rm -f conftest.$ac_objext
23564 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23565   (eval $ac_compile) 2>&5
23566   ac_status=$?
23567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23568   (exit $ac_status); } &&
23569          { ac_try='test -s conftest.$ac_objext'
23570   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23571   (eval $ac_try) 2>&5
23572   ac_status=$?
23573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23574   (exit $ac_status); }; }; then
23575   ac_header_compiler=yes
23576 else
23577   echo "$as_me: failed program was:" >&5
23578 sed 's/^/| /' conftest.$ac_ext >&5
23579
23580 ac_header_compiler=no
23581 fi
23582 rm -f conftest.$ac_objext conftest.$ac_ext
23583 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23584 echo "${ECHO_T}$ac_header_compiler" >&6
23585
23586 # Is the header present?
23587 echo "$as_me:$LINENO: checking $ac_header presence" >&5
23588 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
23589 cat >conftest.$ac_ext <<_ACEOF
23590 #line $LINENO "configure"
23591 /* confdefs.h.  */
23592 _ACEOF
23593 cat confdefs.h >>conftest.$ac_ext
23594 cat >>conftest.$ac_ext <<_ACEOF
23595 /* end confdefs.h.  */
23596 #include <$ac_header>
23597 _ACEOF
23598 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
23599   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
23600   ac_status=$?
23601   grep -v '^ *+' conftest.er1 >conftest.err
23602   rm -f conftest.er1
23603   cat conftest.err >&5
23604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23605   (exit $ac_status); } >/dev/null; then
23606   if test -s conftest.err; then
23607     ac_cpp_err=$ac_c_preproc_warn_flag
23608   else
23609     ac_cpp_err=
23610   fi
23611 else
23612   ac_cpp_err=yes
23613 fi
23614 if test -z "$ac_cpp_err"; then
23615   ac_header_preproc=yes
23616 else
23617   echo "$as_me: failed program was:" >&5
23618 sed 's/^/| /' conftest.$ac_ext >&5
23619
23620   ac_header_preproc=no
23621 fi
23622 rm -f conftest.err conftest.$ac_ext
23623 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23624 echo "${ECHO_T}$ac_header_preproc" >&6
23625
23626 # So?  What about this header?
23627 case $ac_header_compiler:$ac_header_preproc in
23628   yes:no )
23629     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
23630 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
23631     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23632 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23633     (
23634       cat <<\_ASBOX
23635 ## ------------------------------------ ##
23636 ## Report this to bug-autoconf@gnu.org. ##
23637 ## ------------------------------------ ##
23638 _ASBOX
23639     ) |
23640       sed "s/^/$as_me: WARNING:     /" >&2
23641     ;;
23642   no:yes )
23643     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
23644 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
23645     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
23646 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
23647     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
23648 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
23649     (
23650       cat <<\_ASBOX
23651 ## ------------------------------------ ##
23652 ## Report this to bug-autoconf@gnu.org. ##
23653 ## ------------------------------------ ##
23654 _ASBOX
23655     ) |
23656       sed "s/^/$as_me: WARNING:     /" >&2
23657     ;;
23658 esac
23659 echo "$as_me:$LINENO: checking for $ac_header" >&5
23660 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
23661 if eval "test \"\${$as_ac_Header+set}\" = set"; then
23662   echo $ECHO_N "(cached) $ECHO_C" >&6
23663 else
23664   eval "$as_ac_Header=$ac_header_preproc"
23665 fi
23666 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
23667 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
23668
23669 fi
23670 if test `eval echo '${'$as_ac_Header'}'` = yes; then
23671   cat >>confdefs.h <<_ACEOF
23672 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
23673 _ACEOF
23674
23675 fi
23676
23677 done
23678
23679 fi
23680
23681 if test $ol_link_threads != no -a $ol_link_threads != nt ; then
23682                         cat >>confdefs.h <<\_ACEOF
23683 #define REENTRANT 1
23684 _ACEOF
23685
23686         cat >>confdefs.h <<\_ACEOF
23687 #define _REENTRANT 1
23688 _ACEOF
23689
23690         cat >>confdefs.h <<\_ACEOF
23691 #define THREAD_SAFE 1
23692 _ACEOF
23693
23694         cat >>confdefs.h <<\_ACEOF
23695 #define _THREAD_SAFE 1
23696 _ACEOF
23697
23698         cat >>confdefs.h <<\_ACEOF
23699 #define THREADSAFE 1
23700 _ACEOF
23701
23702         cat >>confdefs.h <<\_ACEOF
23703 #define _THREADSAFE 1
23704 _ACEOF
23705
23706         cat >>confdefs.h <<\_ACEOF
23707 #define _SGI_MP_SOURCE 1
23708 _ACEOF
23709
23710
23711                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
23712 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
23713 if test "${ol_cv_errno_thread_specific+set}" = set; then
23714   echo $ECHO_N "(cached) $ECHO_C" >&6
23715 else
23716
23717                 cat >conftest.$ac_ext <<_ACEOF
23718 #line $LINENO "configure"
23719 /* confdefs.h.  */
23720 _ACEOF
23721 cat confdefs.h >>conftest.$ac_ext
23722 cat >>conftest.$ac_ext <<_ACEOF
23723 /* end confdefs.h.  */
23724 #include <errno.h>
23725 int
23726 main ()
23727 {
23728 errno = 0;
23729   ;
23730   return 0;
23731 }
23732 _ACEOF
23733 rm -f conftest.$ac_objext conftest$ac_exeext
23734 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23735   (eval $ac_link) 2>&5
23736   ac_status=$?
23737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23738   (exit $ac_status); } &&
23739          { ac_try='test -s conftest$ac_exeext'
23740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23741   (eval $ac_try) 2>&5
23742   ac_status=$?
23743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23744   (exit $ac_status); }; }; then
23745   ol_cv_errno_thread_specific=yes
23746 else
23747   echo "$as_me: failed program was:" >&5
23748 sed 's/^/| /' conftest.$ac_ext >&5
23749
23750 ol_cv_errno_thread_specific=no
23751 fi
23752 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23753
23754 fi
23755 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
23756 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
23757
23758                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
23759 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
23760 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
23761   echo $ECHO_N "(cached) $ECHO_C" >&6
23762 else
23763
23764                 cat >conftest.$ac_ext <<_ACEOF
23765 #line $LINENO "configure"
23766 /* confdefs.h.  */
23767 _ACEOF
23768 cat confdefs.h >>conftest.$ac_ext
23769 cat >>conftest.$ac_ext <<_ACEOF
23770 /* end confdefs.h.  */
23771 #include <netdb.h>
23772 int
23773 main ()
23774 {
23775 h_errno = 0;
23776   ;
23777   return 0;
23778 }
23779 _ACEOF
23780 rm -f conftest.$ac_objext conftest$ac_exeext
23781 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23782   (eval $ac_link) 2>&5
23783   ac_status=$?
23784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23785   (exit $ac_status); } &&
23786          { ac_try='test -s conftest$ac_exeext'
23787   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23788   (eval $ac_try) 2>&5
23789   ac_status=$?
23790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23791   (exit $ac_status); }; }; then
23792   ol_cv_h_errno_thread_specific=yes
23793 else
23794   echo "$as_me: failed program was:" >&5
23795 sed 's/^/| /' conftest.$ac_ext >&5
23796
23797 ol_cv_h_errno_thread_specific=no
23798 fi
23799 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23800
23801 fi
23802 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
23803 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
23804
23805         if test $ol_cv_errno_thread_specific != yes \
23806                 -o $ol_cv_h_errno_thread_specific != yes ; then
23807                 LIBS="$LTHREAD_LIBS $LIBS"
23808                 LTHREAD_LIBS=""
23809         fi
23810
23811 fi
23812
23813 if test $ol_link_threads = no ; then
23814         if test $ol_with_threads = yes ; then
23815                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
23816 echo "$as_me: error: no suitable thread support" >&2;}
23817    { (exit 1); exit 1; }; }
23818         fi
23819
23820         if test $ol_with_threads = auto ; then
23821                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
23822 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
23823                 ol_with_threads=no
23824         fi
23825
23826
23827 cat >>confdefs.h <<\_ACEOF
23828 #define NO_THREADS 1
23829 _ACEOF
23830
23831         LTHREAD_LIBS=""
23832 fi
23833
23834 if test $ol_link_threads != no ; then
23835         cat >>confdefs.h <<\_ACEOF
23836 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
23837 _ACEOF
23838
23839 fi
23840
23841
23842
23843
23844 for ac_func in \
23845         ctime_r                 \
23846         gethostbyname_r gethostbyaddr_r \
23847
23848 do
23849 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23850 echo "$as_me:$LINENO: checking for $ac_func" >&5
23851 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23852 if eval "test \"\${$as_ac_var+set}\" = set"; then
23853   echo $ECHO_N "(cached) $ECHO_C" >&6
23854 else
23855   cat >conftest.$ac_ext <<_ACEOF
23856 #line $LINENO "configure"
23857 /* confdefs.h.  */
23858 _ACEOF
23859 cat confdefs.h >>conftest.$ac_ext
23860 cat >>conftest.$ac_ext <<_ACEOF
23861 /* end confdefs.h.  */
23862 /* System header to define __stub macros and hopefully few prototypes,
23863     which can conflict with char $ac_func (); below.
23864     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23865     <limits.h> exists even on freestanding compilers.  */
23866 #ifdef __STDC__
23867 # include <limits.h>
23868 #else
23869 # include <assert.h>
23870 #endif
23871 /* Override any gcc2 internal prototype to avoid an error.  */
23872 #ifdef __cplusplus
23873 extern "C"
23874 {
23875 #endif
23876 /* We use char because int might match the return type of a gcc2
23877    builtin and then its argument prototype would still apply.  */
23878 char $ac_func ();
23879 /* The GNU C library defines this for functions which it implements
23880     to always fail with ENOSYS.  Some functions are actually named
23881     something starting with __ and the normal name is an alias.  */
23882 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23883 choke me
23884 #else
23885 char (*f) () = $ac_func;
23886 #endif
23887 #ifdef __cplusplus
23888 }
23889 #endif
23890
23891 int
23892 main ()
23893 {
23894 return f != $ac_func;
23895   ;
23896   return 0;
23897 }
23898 _ACEOF
23899 rm -f conftest.$ac_objext conftest$ac_exeext
23900 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23901   (eval $ac_link) 2>&5
23902   ac_status=$?
23903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23904   (exit $ac_status); } &&
23905          { ac_try='test -s conftest$ac_exeext'
23906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23907   (eval $ac_try) 2>&5
23908   ac_status=$?
23909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23910   (exit $ac_status); }; }; then
23911   eval "$as_ac_var=yes"
23912 else
23913   echo "$as_me: failed program was:" >&5
23914 sed 's/^/| /' conftest.$ac_ext >&5
23915
23916 eval "$as_ac_var=no"
23917 fi
23918 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23919 fi
23920 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23921 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23922 if test `eval echo '${'$as_ac_var'}'` = yes; then
23923   cat >>confdefs.h <<_ACEOF
23924 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23925 _ACEOF
23926
23927 fi
23928 done
23929
23930
23931 if test "$ac_cv_func_ctime_r" = no ; then
23932         ol_cv_func_ctime_r_nargs=0
23933 else
23934         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
23935 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
23936 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
23937   echo $ECHO_N "(cached) $ECHO_C" >&6
23938 else
23939   cat >conftest.$ac_ext <<_ACEOF
23940 #line $LINENO "configure"
23941 /* confdefs.h.  */
23942 _ACEOF
23943 cat confdefs.h >>conftest.$ac_ext
23944 cat >>conftest.$ac_ext <<_ACEOF
23945 /* end confdefs.h.  */
23946 #include <time.h>
23947 int
23948 main ()
23949 {
23950 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
23951   ;
23952   return 0;
23953 }
23954 _ACEOF
23955 rm -f conftest.$ac_objext
23956 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23957   (eval $ac_compile) 2>&5
23958   ac_status=$?
23959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23960   (exit $ac_status); } &&
23961          { ac_try='test -s conftest.$ac_objext'
23962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23963   (eval $ac_try) 2>&5
23964   ac_status=$?
23965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23966   (exit $ac_status); }; }; then
23967   ol_cv_func_ctime_r_nargs3=yes
23968 else
23969   echo "$as_me: failed program was:" >&5
23970 sed 's/^/| /' conftest.$ac_ext >&5
23971
23972 ol_cv_func_ctime_r_nargs3=no
23973 fi
23974 rm -f conftest.$ac_objext conftest.$ac_ext
23975
23976         cat >conftest.$ac_ext <<_ACEOF
23977 #line $LINENO "configure"
23978 /* confdefs.h.  */
23979 _ACEOF
23980 cat confdefs.h >>conftest.$ac_ext
23981 cat >>conftest.$ac_ext <<_ACEOF
23982 /* end confdefs.h.  */
23983 #include <time.h>
23984 int
23985 main ()
23986 {
23987 time_t ti; char *buffer; ctime_r(&ti,buffer);
23988   ;
23989   return 0;
23990 }
23991 _ACEOF
23992 rm -f conftest.$ac_objext
23993 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23994   (eval $ac_compile) 2>&5
23995   ac_status=$?
23996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23997   (exit $ac_status); } &&
23998          { ac_try='test -s conftest.$ac_objext'
23999   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24000   (eval $ac_try) 2>&5
24001   ac_status=$?
24002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24003   (exit $ac_status); }; }; then
24004   ol_cv_func_ctime_r_nargs2=yes
24005 else
24006   echo "$as_me: failed program was:" >&5
24007 sed 's/^/| /' conftest.$ac_ext >&5
24008
24009 ol_cv_func_ctime_r_nargs2=no
24010 fi
24011 rm -f conftest.$ac_objext conftest.$ac_ext
24012
24013         if test $ol_cv_func_ctime_r_nargs3 = yes -a \
24014                 $ol_cv_func_ctime_r_nargs2 = no ; then
24015
24016                 ol_cv_func_ctime_r_nargs=3
24017
24018         elif test $ol_cv_func_ctime_r_nargs3 = no -a \
24019                 $ol_cv_func_ctime_r_nargs2 = yes ; then
24020
24021                 ol_cv_func_ctime_r_nargs=2
24022
24023         else
24024                 ol_cv_func_ctime_r_nargs=0
24025         fi
24026
24027 fi
24028 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
24029 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
24030
24031   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
24032
24033 cat >>confdefs.h <<_ACEOF
24034 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
24035 _ACEOF
24036
24037   fi
24038
24039 fi
24040
24041 if test "$ac_cv_func_gethostbyname_r" = yes ; then
24042         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
24043 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
24044 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
24045   echo $ECHO_N "(cached) $ECHO_C" >&6
24046 else
24047   cat >conftest.$ac_ext <<_ACEOF
24048 #line $LINENO "configure"
24049 /* confdefs.h.  */
24050 _ACEOF
24051 cat confdefs.h >>conftest.$ac_ext
24052 cat >>conftest.$ac_ext <<_ACEOF
24053 /* end confdefs.h.  */
24054 #include <sys/types.h>
24055 #include <sys/socket.h>
24056 #include <netinet/in.h>
24057 #include <netdb.h>
24058 #define BUFSIZE (sizeof(struct hostent)+10)
24059 int
24060 main ()
24061 {
24062 struct hostent hent; char buffer[BUFSIZE];
24063                 int bufsize=BUFSIZE;int h_errno;
24064                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
24065                         buffer, bufsize, &h_errno);
24066   ;
24067   return 0;
24068 }
24069 _ACEOF
24070 rm -f conftest.$ac_objext
24071 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24072   (eval $ac_compile) 2>&5
24073   ac_status=$?
24074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24075   (exit $ac_status); } &&
24076          { ac_try='test -s conftest.$ac_objext'
24077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24078   (eval $ac_try) 2>&5
24079   ac_status=$?
24080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24081   (exit $ac_status); }; }; then
24082   ol_cv_func_gethostbyname_r_nargs5=yes
24083 else
24084   echo "$as_me: failed program was:" >&5
24085 sed 's/^/| /' conftest.$ac_ext >&5
24086
24087 ol_cv_func_gethostbyname_r_nargs5=no
24088 fi
24089 rm -f conftest.$ac_objext conftest.$ac_ext
24090
24091         cat >conftest.$ac_ext <<_ACEOF
24092 #line $LINENO "configure"
24093 /* confdefs.h.  */
24094 _ACEOF
24095 cat confdefs.h >>conftest.$ac_ext
24096 cat >>conftest.$ac_ext <<_ACEOF
24097 /* end confdefs.h.  */
24098 #include <sys/types.h>
24099 #include <sys/socket.h>
24100 #include <netinet/in.h>
24101 #include <netdb.h>
24102 #define BUFSIZE (sizeof(struct hostent)+10)
24103 int
24104 main ()
24105 {
24106 struct hostent hent;struct hostent *rhent;
24107                 char buffer[BUFSIZE];
24108                 int bufsize=BUFSIZE;int h_errno;
24109                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
24110                         &rhent, &h_errno);
24111   ;
24112   return 0;
24113 }
24114 _ACEOF
24115 rm -f conftest.$ac_objext
24116 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24117   (eval $ac_compile) 2>&5
24118   ac_status=$?
24119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24120   (exit $ac_status); } &&
24121          { ac_try='test -s conftest.$ac_objext'
24122   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24123   (eval $ac_try) 2>&5
24124   ac_status=$?
24125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24126   (exit $ac_status); }; }; then
24127   ol_cv_func_gethostbyname_r_nargs6=yes
24128 else
24129   echo "$as_me: failed program was:" >&5
24130 sed 's/^/| /' conftest.$ac_ext >&5
24131
24132 ol_cv_func_gethostbyname_r_nargs6=no
24133 fi
24134 rm -f conftest.$ac_objext conftest.$ac_ext
24135
24136         if test $ol_cv_func_gethostbyname_r_nargs5 = yes -a \
24137                 $ol_cv_func_gethostbyname_r_nargs6 = no ; then
24138
24139                 ol_cv_func_gethostbyname_r_nargs=5
24140
24141         elif test $ol_cv_func_gethostbyname_r_nargs5 = no -a \
24142                 $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
24143
24144                 ol_cv_func_gethostbyname_r_nargs=6
24145
24146         else
24147                 ol_cv_func_gethostbyname_r_nargs=0
24148         fi
24149
24150 fi
24151 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
24152 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
24153   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
24154
24155 cat >>confdefs.h <<_ACEOF
24156 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
24157 _ACEOF
24158
24159   fi
24160
24161 else
24162         ol_cv_func_gethostbyname_r_nargs=0
24163 fi
24164
24165 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
24166         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
24167 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
24168 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
24169   echo $ECHO_N "(cached) $ECHO_C" >&6
24170 else
24171   cat >conftest.$ac_ext <<_ACEOF
24172 #line $LINENO "configure"
24173 /* confdefs.h.  */
24174 _ACEOF
24175 cat confdefs.h >>conftest.$ac_ext
24176 cat >>conftest.$ac_ext <<_ACEOF
24177 /* end confdefs.h.  */
24178 #include <sys/types.h>
24179 #include <sys/socket.h>
24180 #include <netinet/in.h>
24181 #include <netdb.h>
24182 #define BUFSIZE (sizeof(struct hostent)+10)
24183 int
24184 main ()
24185 {
24186 struct hostent hent; char buffer[BUFSIZE];
24187             struct in_addr add;
24188             size_t alen=sizeof(struct in_addr);
24189             int bufsize=BUFSIZE;int h_errno;
24190                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
24191                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
24192   ;
24193   return 0;
24194 }
24195 _ACEOF
24196 rm -f conftest.$ac_objext
24197 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24198   (eval $ac_compile) 2>&5
24199   ac_status=$?
24200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24201   (exit $ac_status); } &&
24202          { ac_try='test -s conftest.$ac_objext'
24203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24204   (eval $ac_try) 2>&5
24205   ac_status=$?
24206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24207   (exit $ac_status); }; }; then
24208   ol_cv_func_gethostbyaddr_r_nargs7=yes
24209 else
24210   echo "$as_me: failed program was:" >&5
24211 sed 's/^/| /' conftest.$ac_ext >&5
24212
24213 ol_cv_func_gethostbyaddr_r_nargs7=no
24214 fi
24215 rm -f conftest.$ac_objext conftest.$ac_ext
24216
24217         cat >conftest.$ac_ext <<_ACEOF
24218 #line $LINENO "configure"
24219 /* confdefs.h.  */
24220 _ACEOF
24221 cat confdefs.h >>conftest.$ac_ext
24222 cat >>conftest.$ac_ext <<_ACEOF
24223 /* end confdefs.h.  */
24224 #include <sys/types.h>
24225 #include <sys/socket.h>
24226 #include <netinet/in.h>
24227 #include <netdb.h>
24228 #define BUFSIZE (sizeof(struct hostent)+10)
24229 int
24230 main ()
24231 {
24232 struct hostent hent;
24233                 struct hostent *rhent; char buffer[BUFSIZE];
24234                 struct in_addr add;
24235                 size_t alen=sizeof(struct in_addr);
24236                 int bufsize=BUFSIZE;int h_errno;
24237                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
24238                         alen, AF_INET, &hent, buffer, bufsize,
24239                         &rhent, &h_errno);
24240   ;
24241   return 0;
24242 }
24243 _ACEOF
24244 rm -f conftest.$ac_objext
24245 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24246   (eval $ac_compile) 2>&5
24247   ac_status=$?
24248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24249   (exit $ac_status); } &&
24250          { ac_try='test -s conftest.$ac_objext'
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_func_gethostbyaddr_r_nargs8=yes
24257 else
24258   echo "$as_me: failed program was:" >&5
24259 sed 's/^/| /' conftest.$ac_ext >&5
24260
24261 ol_cv_func_gethostbyaddr_r_nargs8=no
24262 fi
24263 rm -f conftest.$ac_objext conftest.$ac_ext
24264
24265         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes -a \
24266                 $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
24267
24268                 ol_cv_func_gethostbyaddr_r_nargs=7
24269
24270         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no -a \
24271                 $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
24272
24273                 ol_cv_func_gethostbyaddr_r_nargs=8
24274
24275         else
24276                 ol_cv_func_gethostbyaddr_r_nargs=0
24277         fi
24278
24279 fi
24280 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
24281 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
24282   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
24283
24284 cat >>confdefs.h <<_ACEOF
24285 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
24286 _ACEOF
24287
24288   fi
24289
24290 else
24291         ol_cv_func_gethostbyaddr_r_nargs=0
24292 fi
24293
24294 ol_link_ldbm=no
24295
24296 if test $ol_with_ldbm_api = auto \
24297         -o $ol_with_ldbm_api = berkeley \
24298         -o $ol_with_ldbm_api = bcompat ; then
24299
24300         if test $ol_with_ldbm_api = bcompat; then \
24301
24302
24303 for ac_header in db_185.h db.h
24304 do
24305 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24306 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24307   echo "$as_me:$LINENO: checking for $ac_header" >&5
24308 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24309 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24310   echo $ECHO_N "(cached) $ECHO_C" >&6
24311 fi
24312 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24313 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24314 else
24315   # Is the header compilable?
24316 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24317 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24318 cat >conftest.$ac_ext <<_ACEOF
24319 #line $LINENO "configure"
24320 /* confdefs.h.  */
24321 _ACEOF
24322 cat confdefs.h >>conftest.$ac_ext
24323 cat >>conftest.$ac_ext <<_ACEOF
24324 /* end confdefs.h.  */
24325 $ac_includes_default
24326 #include <$ac_header>
24327 _ACEOF
24328 rm -f conftest.$ac_objext
24329 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24330   (eval $ac_compile) 2>&5
24331   ac_status=$?
24332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24333   (exit $ac_status); } &&
24334          { ac_try='test -s conftest.$ac_objext'
24335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24336   (eval $ac_try) 2>&5
24337   ac_status=$?
24338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24339   (exit $ac_status); }; }; then
24340   ac_header_compiler=yes
24341 else
24342   echo "$as_me: failed program was:" >&5
24343 sed 's/^/| /' conftest.$ac_ext >&5
24344
24345 ac_header_compiler=no
24346 fi
24347 rm -f conftest.$ac_objext conftest.$ac_ext
24348 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24349 echo "${ECHO_T}$ac_header_compiler" >&6
24350
24351 # Is the header present?
24352 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24353 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24354 cat >conftest.$ac_ext <<_ACEOF
24355 #line $LINENO "configure"
24356 /* confdefs.h.  */
24357 _ACEOF
24358 cat confdefs.h >>conftest.$ac_ext
24359 cat >>conftest.$ac_ext <<_ACEOF
24360 /* end confdefs.h.  */
24361 #include <$ac_header>
24362 _ACEOF
24363 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24364   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24365   ac_status=$?
24366   grep -v '^ *+' conftest.er1 >conftest.err
24367   rm -f conftest.er1
24368   cat conftest.err >&5
24369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24370   (exit $ac_status); } >/dev/null; then
24371   if test -s conftest.err; then
24372     ac_cpp_err=$ac_c_preproc_warn_flag
24373   else
24374     ac_cpp_err=
24375   fi
24376 else
24377   ac_cpp_err=yes
24378 fi
24379 if test -z "$ac_cpp_err"; then
24380   ac_header_preproc=yes
24381 else
24382   echo "$as_me: failed program was:" >&5
24383 sed 's/^/| /' conftest.$ac_ext >&5
24384
24385   ac_header_preproc=no
24386 fi
24387 rm -f conftest.err conftest.$ac_ext
24388 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24389 echo "${ECHO_T}$ac_header_preproc" >&6
24390
24391 # So?  What about this header?
24392 case $ac_header_compiler:$ac_header_preproc in
24393   yes:no )
24394     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
24395 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
24396     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24397 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24398     (
24399       cat <<\_ASBOX
24400 ## ------------------------------------ ##
24401 ## Report this to bug-autoconf@gnu.org. ##
24402 ## ------------------------------------ ##
24403 _ASBOX
24404     ) |
24405       sed "s/^/$as_me: WARNING:     /" >&2
24406     ;;
24407   no:yes )
24408     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
24409 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
24410     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
24411 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
24412     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24413 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24414     (
24415       cat <<\_ASBOX
24416 ## ------------------------------------ ##
24417 ## Report this to bug-autoconf@gnu.org. ##
24418 ## ------------------------------------ ##
24419 _ASBOX
24420     ) |
24421       sed "s/^/$as_me: WARNING:     /" >&2
24422     ;;
24423 esac
24424 echo "$as_me:$LINENO: checking for $ac_header" >&5
24425 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24426 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24427   echo $ECHO_N "(cached) $ECHO_C" >&6
24428 else
24429   eval "$as_ac_Header=$ac_header_preproc"
24430 fi
24431 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24432 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24433
24434 fi
24435 if test `eval echo '${'$as_ac_Header'}'` = yes; then
24436   cat >>confdefs.h <<_ACEOF
24437 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
24438 _ACEOF
24439
24440 fi
24441
24442 done
24443
24444 if test $ac_cv_header_db_185_h = yes -o $ac_cv_header_db_h = yes; then
24445         echo "$as_me:$LINENO: checking if Berkeley DB header compatibility" >&5
24446 echo $ECHO_N "checking if Berkeley DB header compatibility... $ECHO_C" >&6
24447 if test "${ol_cv_header_db1+set}" = set; then
24448   echo $ECHO_N "(cached) $ECHO_C" >&6
24449 else
24450
24451                 cat >conftest.$ac_ext <<_ACEOF
24452 #line $LINENO "configure"
24453 /* confdefs.h.  */
24454 _ACEOF
24455 cat confdefs.h >>conftest.$ac_ext
24456 cat >>conftest.$ac_ext <<_ACEOF
24457 /* end confdefs.h.  */
24458
24459 #if HAVE_DB_185_H
24460 #       include <db_185.h>
24461 #else
24462 #       include <db.h>
24463 #endif
24464
24465  /* this check could be improved */
24466 #ifndef DB_VERSION_MAJOR
24467 #       define DB_VERSION_MAJOR 1
24468 #endif
24469
24470 #if DB_VERSION_MAJOR == 1
24471         __db_version_1
24472 #endif
24473
24474 _ACEOF
24475 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24476   $EGREP "__db_version_1" >/dev/null 2>&1; then
24477   ol_cv_header_db1=yes
24478 else
24479   ol_cv_header_db1=no
24480 fi
24481 rm -f conftest*
24482
24483 fi
24484 echo "$as_me:$LINENO: result: $ol_cv_header_db1" >&5
24485 echo "${ECHO_T}$ol_cv_header_db1" >&6
24486
24487         if test $ol_cv_header_db1 = yes ; then
24488                 ol_cv_lib_db=no
24489 if test $ol_cv_lib_db = no ; then
24490         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
24491 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
24492 if test "${ol_cv_db_none+set}" = set; then
24493   echo $ECHO_N "(cached) $ECHO_C" >&6
24494 else
24495
24496         ol_DB_LIB=
24497         ol_LIBS=$LIBS
24498         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24499
24500         cat >conftest.$ac_ext <<_ACEOF
24501 #line $LINENO "configure"
24502 /* confdefs.h.  */
24503 _ACEOF
24504 cat confdefs.h >>conftest.$ac_ext
24505 cat >>conftest.$ac_ext <<_ACEOF
24506 /* end confdefs.h.  */
24507
24508 #ifdef HAVE_DB_185_H
24509 # include <db_185.h>
24510 #else
24511 # include <db.h>
24512 #endif
24513
24514 #ifndef DB_VERSION_MAJOR
24515 # define DB_VERSION_MAJOR 1
24516 #endif
24517
24518 #ifndef NULL
24519 #define NULL ((void*)0)
24520 #endif
24521
24522 int
24523 main ()
24524 {
24525
24526 #if DB_VERSION_MAJOR > 1
24527         {
24528                 char *version;
24529                 int major, minor, patch;
24530
24531                 version = db_version( &major, &minor, &patch );
24532
24533                 if( major != DB_VERSION_MAJOR ||
24534                         minor < DB_VERSION_MINOR )
24535                 {
24536                         printf("Berkeley DB version mismatch\n"
24537                                 "\texpected: %s\n\tgot: %s\n",
24538                                 DB_VERSION_STRING, version);
24539                         return 1;
24540                 }
24541         }
24542 #endif
24543
24544 #if DB_VERSION_MAJOR > 2
24545         db_env_create( NULL, 0 );
24546 #elif DB_VERSION_MAJOR > 1
24547         db_appexit( NULL );
24548 #else
24549         (void) dbopen( NULL, 0, 0, 0, NULL);
24550 #endif
24551
24552   ;
24553   return 0;
24554 }
24555 _ACEOF
24556 rm -f conftest.$ac_objext conftest$ac_exeext
24557 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24558   (eval $ac_link) 2>&5
24559   ac_status=$?
24560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24561   (exit $ac_status); } &&
24562          { ac_try='test -s conftest$ac_exeext'
24563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24564   (eval $ac_try) 2>&5
24565   ac_status=$?
24566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24567   (exit $ac_status); }; }; then
24568   ol_cv_db_none=yes
24569 else
24570   echo "$as_me: failed program was:" >&5
24571 sed 's/^/| /' conftest.$ac_ext >&5
24572
24573 ol_cv_db_none=no
24574 fi
24575 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24576
24577         LIBS="$ol_LIBS"
24578
24579 fi
24580 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
24581 echo "${ECHO_T}$ol_cv_db_none" >&6
24582
24583         if test $ol_cv_db_none = yes ; then
24584                 ol_cv_lib_db=yes
24585         fi
24586 fi
24587
24588 if test $ol_cv_lib_db = no ; then
24589         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb41)" >&5
24590 echo $ECHO_N "checking for Berkeley DB link (-ldb41)... $ECHO_C" >&6
24591 if test "${ol_cv_db_db41+set}" = set; then
24592   echo $ECHO_N "(cached) $ECHO_C" >&6
24593 else
24594
24595         ol_DB_LIB=-ldb41
24596         ol_LIBS=$LIBS
24597         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24598
24599         cat >conftest.$ac_ext <<_ACEOF
24600 #line $LINENO "configure"
24601 /* confdefs.h.  */
24602 _ACEOF
24603 cat confdefs.h >>conftest.$ac_ext
24604 cat >>conftest.$ac_ext <<_ACEOF
24605 /* end confdefs.h.  */
24606
24607 #ifdef HAVE_DB_185_H
24608 # include <db_185.h>
24609 #else
24610 # include <db.h>
24611 #endif
24612
24613 #ifndef DB_VERSION_MAJOR
24614 # define DB_VERSION_MAJOR 1
24615 #endif
24616
24617 #ifndef NULL
24618 #define NULL ((void*)0)
24619 #endif
24620
24621 int
24622 main ()
24623 {
24624
24625 #if DB_VERSION_MAJOR > 1
24626         {
24627                 char *version;
24628                 int major, minor, patch;
24629
24630                 version = db_version( &major, &minor, &patch );
24631
24632                 if( major != DB_VERSION_MAJOR ||
24633                         minor < DB_VERSION_MINOR )
24634                 {
24635                         printf("Berkeley DB version mismatch\n"
24636                                 "\texpected: %s\n\tgot: %s\n",
24637                                 DB_VERSION_STRING, version);
24638                         return 1;
24639                 }
24640         }
24641 #endif
24642
24643 #if DB_VERSION_MAJOR > 2
24644         db_env_create( NULL, 0 );
24645 #elif DB_VERSION_MAJOR > 1
24646         db_appexit( NULL );
24647 #else
24648         (void) dbopen( NULL, 0, 0, 0, NULL);
24649 #endif
24650
24651   ;
24652   return 0;
24653 }
24654 _ACEOF
24655 rm -f conftest.$ac_objext conftest$ac_exeext
24656 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24657   (eval $ac_link) 2>&5
24658   ac_status=$?
24659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24660   (exit $ac_status); } &&
24661          { ac_try='test -s conftest$ac_exeext'
24662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24663   (eval $ac_try) 2>&5
24664   ac_status=$?
24665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24666   (exit $ac_status); }; }; then
24667   ol_cv_db_db41=yes
24668 else
24669   echo "$as_me: failed program was:" >&5
24670 sed 's/^/| /' conftest.$ac_ext >&5
24671
24672 ol_cv_db_db41=no
24673 fi
24674 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24675
24676         LIBS="$ol_LIBS"
24677
24678 fi
24679 echo "$as_me:$LINENO: result: $ol_cv_db_db41" >&5
24680 echo "${ECHO_T}$ol_cv_db_db41" >&6
24681
24682         if test $ol_cv_db_db41 = yes ; then
24683                 ol_cv_lib_db=-ldb41
24684         fi
24685 fi
24686
24687 if test $ol_cv_lib_db = no ; then
24688         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-41)" >&5
24689 echo $ECHO_N "checking for Berkeley DB link (-ldb-41)... $ECHO_C" >&6
24690 if test "${ol_cv_db_db_41+set}" = set; then
24691   echo $ECHO_N "(cached) $ECHO_C" >&6
24692 else
24693
24694         ol_DB_LIB=-ldb-41
24695         ol_LIBS=$LIBS
24696         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24697
24698         cat >conftest.$ac_ext <<_ACEOF
24699 #line $LINENO "configure"
24700 /* confdefs.h.  */
24701 _ACEOF
24702 cat confdefs.h >>conftest.$ac_ext
24703 cat >>conftest.$ac_ext <<_ACEOF
24704 /* end confdefs.h.  */
24705
24706 #ifdef HAVE_DB_185_H
24707 # include <db_185.h>
24708 #else
24709 # include <db.h>
24710 #endif
24711
24712 #ifndef DB_VERSION_MAJOR
24713 # define DB_VERSION_MAJOR 1
24714 #endif
24715
24716 #ifndef NULL
24717 #define NULL ((void*)0)
24718 #endif
24719
24720 int
24721 main ()
24722 {
24723
24724 #if DB_VERSION_MAJOR > 1
24725         {
24726                 char *version;
24727                 int major, minor, patch;
24728
24729                 version = db_version( &major, &minor, &patch );
24730
24731                 if( major != DB_VERSION_MAJOR ||
24732                         minor < DB_VERSION_MINOR )
24733                 {
24734                         printf("Berkeley DB version mismatch\n"
24735                                 "\texpected: %s\n\tgot: %s\n",
24736                                 DB_VERSION_STRING, version);
24737                         return 1;
24738                 }
24739         }
24740 #endif
24741
24742 #if DB_VERSION_MAJOR > 2
24743         db_env_create( NULL, 0 );
24744 #elif DB_VERSION_MAJOR > 1
24745         db_appexit( NULL );
24746 #else
24747         (void) dbopen( NULL, 0, 0, 0, NULL);
24748 #endif
24749
24750   ;
24751   return 0;
24752 }
24753 _ACEOF
24754 rm -f conftest.$ac_objext conftest$ac_exeext
24755 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24756   (eval $ac_link) 2>&5
24757   ac_status=$?
24758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24759   (exit $ac_status); } &&
24760          { ac_try='test -s conftest$ac_exeext'
24761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24762   (eval $ac_try) 2>&5
24763   ac_status=$?
24764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24765   (exit $ac_status); }; }; then
24766   ol_cv_db_db_41=yes
24767 else
24768   echo "$as_me: failed program was:" >&5
24769 sed 's/^/| /' conftest.$ac_ext >&5
24770
24771 ol_cv_db_db_41=no
24772 fi
24773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24774
24775         LIBS="$ol_LIBS"
24776
24777 fi
24778 echo "$as_me:$LINENO: result: $ol_cv_db_db_41" >&5
24779 echo "${ECHO_T}$ol_cv_db_db_41" >&6
24780
24781         if test $ol_cv_db_db_41 = yes ; then
24782                 ol_cv_lib_db=-ldb-41
24783         fi
24784 fi
24785
24786 if test $ol_cv_lib_db = no ; then
24787         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.1)" >&5
24788 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.1)... $ECHO_C" >&6
24789 if test "${ol_cv_db_db_4_dot_1+set}" = set; then
24790   echo $ECHO_N "(cached) $ECHO_C" >&6
24791 else
24792
24793         ol_DB_LIB=-ldb-4.1
24794         ol_LIBS=$LIBS
24795         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24796
24797         cat >conftest.$ac_ext <<_ACEOF
24798 #line $LINENO "configure"
24799 /* confdefs.h.  */
24800 _ACEOF
24801 cat confdefs.h >>conftest.$ac_ext
24802 cat >>conftest.$ac_ext <<_ACEOF
24803 /* end confdefs.h.  */
24804
24805 #ifdef HAVE_DB_185_H
24806 # include <db_185.h>
24807 #else
24808 # include <db.h>
24809 #endif
24810
24811 #ifndef DB_VERSION_MAJOR
24812 # define DB_VERSION_MAJOR 1
24813 #endif
24814
24815 #ifndef NULL
24816 #define NULL ((void*)0)
24817 #endif
24818
24819 int
24820 main ()
24821 {
24822
24823 #if DB_VERSION_MAJOR > 1
24824         {
24825                 char *version;
24826                 int major, minor, patch;
24827
24828                 version = db_version( &major, &minor, &patch );
24829
24830                 if( major != DB_VERSION_MAJOR ||
24831                         minor < DB_VERSION_MINOR )
24832                 {
24833                         printf("Berkeley DB version mismatch\n"
24834                                 "\texpected: %s\n\tgot: %s\n",
24835                                 DB_VERSION_STRING, version);
24836                         return 1;
24837                 }
24838         }
24839 #endif
24840
24841 #if DB_VERSION_MAJOR > 2
24842         db_env_create( NULL, 0 );
24843 #elif DB_VERSION_MAJOR > 1
24844         db_appexit( NULL );
24845 #else
24846         (void) dbopen( NULL, 0, 0, 0, NULL);
24847 #endif
24848
24849   ;
24850   return 0;
24851 }
24852 _ACEOF
24853 rm -f conftest.$ac_objext conftest$ac_exeext
24854 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24855   (eval $ac_link) 2>&5
24856   ac_status=$?
24857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24858   (exit $ac_status); } &&
24859          { ac_try='test -s conftest$ac_exeext'
24860   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24861   (eval $ac_try) 2>&5
24862   ac_status=$?
24863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24864   (exit $ac_status); }; }; then
24865   ol_cv_db_db_4_dot_1=yes
24866 else
24867   echo "$as_me: failed program was:" >&5
24868 sed 's/^/| /' conftest.$ac_ext >&5
24869
24870 ol_cv_db_db_4_dot_1=no
24871 fi
24872 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24873
24874         LIBS="$ol_LIBS"
24875
24876 fi
24877 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_1" >&5
24878 echo "${ECHO_T}$ol_cv_db_db_4_dot_1" >&6
24879
24880         if test $ol_cv_db_db_4_dot_1 = yes ; then
24881                 ol_cv_lib_db=-ldb-4.1
24882         fi
24883 fi
24884
24885 if test $ol_cv_lib_db = no ; then
24886         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-1)" >&5
24887 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-1)... $ECHO_C" >&6
24888 if test "${ol_cv_db_db_4_1+set}" = set; then
24889   echo $ECHO_N "(cached) $ECHO_C" >&6
24890 else
24891
24892         ol_DB_LIB=-ldb-4-1
24893         ol_LIBS=$LIBS
24894         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24895
24896         cat >conftest.$ac_ext <<_ACEOF
24897 #line $LINENO "configure"
24898 /* confdefs.h.  */
24899 _ACEOF
24900 cat confdefs.h >>conftest.$ac_ext
24901 cat >>conftest.$ac_ext <<_ACEOF
24902 /* end confdefs.h.  */
24903
24904 #ifdef HAVE_DB_185_H
24905 # include <db_185.h>
24906 #else
24907 # include <db.h>
24908 #endif
24909
24910 #ifndef DB_VERSION_MAJOR
24911 # define DB_VERSION_MAJOR 1
24912 #endif
24913
24914 #ifndef NULL
24915 #define NULL ((void*)0)
24916 #endif
24917
24918 int
24919 main ()
24920 {
24921
24922 #if DB_VERSION_MAJOR > 1
24923         {
24924                 char *version;
24925                 int major, minor, patch;
24926
24927                 version = db_version( &major, &minor, &patch );
24928
24929                 if( major != DB_VERSION_MAJOR ||
24930                         minor < DB_VERSION_MINOR )
24931                 {
24932                         printf("Berkeley DB version mismatch\n"
24933                                 "\texpected: %s\n\tgot: %s\n",
24934                                 DB_VERSION_STRING, version);
24935                         return 1;
24936                 }
24937         }
24938 #endif
24939
24940 #if DB_VERSION_MAJOR > 2
24941         db_env_create( NULL, 0 );
24942 #elif DB_VERSION_MAJOR > 1
24943         db_appexit( NULL );
24944 #else
24945         (void) dbopen( NULL, 0, 0, 0, NULL);
24946 #endif
24947
24948   ;
24949   return 0;
24950 }
24951 _ACEOF
24952 rm -f conftest.$ac_objext conftest$ac_exeext
24953 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24954   (eval $ac_link) 2>&5
24955   ac_status=$?
24956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24957   (exit $ac_status); } &&
24958          { ac_try='test -s conftest$ac_exeext'
24959   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24960   (eval $ac_try) 2>&5
24961   ac_status=$?
24962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24963   (exit $ac_status); }; }; then
24964   ol_cv_db_db_4_1=yes
24965 else
24966   echo "$as_me: failed program was:" >&5
24967 sed 's/^/| /' conftest.$ac_ext >&5
24968
24969 ol_cv_db_db_4_1=no
24970 fi
24971 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24972
24973         LIBS="$ol_LIBS"
24974
24975 fi
24976 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_1" >&5
24977 echo "${ECHO_T}$ol_cv_db_db_4_1" >&6
24978
24979         if test $ol_cv_db_db_4_1 = yes ; then
24980                 ol_cv_lib_db=-ldb-4-1
24981         fi
24982 fi
24983
24984 if test $ol_cv_lib_db = no ; then
24985         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
24986 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
24987 if test "${ol_cv_db_db_4+set}" = set; then
24988   echo $ECHO_N "(cached) $ECHO_C" >&6
24989 else
24990
24991         ol_DB_LIB=-ldb-4
24992         ol_LIBS=$LIBS
24993         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24994
24995         cat >conftest.$ac_ext <<_ACEOF
24996 #line $LINENO "configure"
24997 /* confdefs.h.  */
24998 _ACEOF
24999 cat confdefs.h >>conftest.$ac_ext
25000 cat >>conftest.$ac_ext <<_ACEOF
25001 /* end confdefs.h.  */
25002
25003 #ifdef HAVE_DB_185_H
25004 # include <db_185.h>
25005 #else
25006 # include <db.h>
25007 #endif
25008
25009 #ifndef DB_VERSION_MAJOR
25010 # define DB_VERSION_MAJOR 1
25011 #endif
25012
25013 #ifndef NULL
25014 #define NULL ((void*)0)
25015 #endif
25016
25017 int
25018 main ()
25019 {
25020
25021 #if DB_VERSION_MAJOR > 1
25022         {
25023                 char *version;
25024                 int major, minor, patch;
25025
25026                 version = db_version( &major, &minor, &patch );
25027
25028                 if( major != DB_VERSION_MAJOR ||
25029                         minor < DB_VERSION_MINOR )
25030                 {
25031                         printf("Berkeley DB version mismatch\n"
25032                                 "\texpected: %s\n\tgot: %s\n",
25033                                 DB_VERSION_STRING, version);
25034                         return 1;
25035                 }
25036         }
25037 #endif
25038
25039 #if DB_VERSION_MAJOR > 2
25040         db_env_create( NULL, 0 );
25041 #elif DB_VERSION_MAJOR > 1
25042         db_appexit( NULL );
25043 #else
25044         (void) dbopen( NULL, 0, 0, 0, NULL);
25045 #endif
25046
25047   ;
25048   return 0;
25049 }
25050 _ACEOF
25051 rm -f conftest.$ac_objext conftest$ac_exeext
25052 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25053   (eval $ac_link) 2>&5
25054   ac_status=$?
25055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25056   (exit $ac_status); } &&
25057          { ac_try='test -s conftest$ac_exeext'
25058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25059   (eval $ac_try) 2>&5
25060   ac_status=$?
25061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25062   (exit $ac_status); }; }; then
25063   ol_cv_db_db_4=yes
25064 else
25065   echo "$as_me: failed program was:" >&5
25066 sed 's/^/| /' conftest.$ac_ext >&5
25067
25068 ol_cv_db_db_4=no
25069 fi
25070 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25071
25072         LIBS="$ol_LIBS"
25073
25074 fi
25075 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
25076 echo "${ECHO_T}$ol_cv_db_db_4" >&6
25077
25078         if test $ol_cv_db_db_4 = yes ; then
25079                 ol_cv_lib_db=-ldb-4
25080         fi
25081 fi
25082
25083 if test $ol_cv_lib_db = no ; then
25084         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
25085 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
25086 if test "${ol_cv_db_db4+set}" = set; then
25087   echo $ECHO_N "(cached) $ECHO_C" >&6
25088 else
25089
25090         ol_DB_LIB=-ldb4
25091         ol_LIBS=$LIBS
25092         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25093
25094         cat >conftest.$ac_ext <<_ACEOF
25095 #line $LINENO "configure"
25096 /* confdefs.h.  */
25097 _ACEOF
25098 cat confdefs.h >>conftest.$ac_ext
25099 cat >>conftest.$ac_ext <<_ACEOF
25100 /* end confdefs.h.  */
25101
25102 #ifdef HAVE_DB_185_H
25103 # include <db_185.h>
25104 #else
25105 # include <db.h>
25106 #endif
25107
25108 #ifndef DB_VERSION_MAJOR
25109 # define DB_VERSION_MAJOR 1
25110 #endif
25111
25112 #ifndef NULL
25113 #define NULL ((void*)0)
25114 #endif
25115
25116 int
25117 main ()
25118 {
25119
25120 #if DB_VERSION_MAJOR > 1
25121         {
25122                 char *version;
25123                 int major, minor, patch;
25124
25125                 version = db_version( &major, &minor, &patch );
25126
25127                 if( major != DB_VERSION_MAJOR ||
25128                         minor < DB_VERSION_MINOR )
25129                 {
25130                         printf("Berkeley DB version mismatch\n"
25131                                 "\texpected: %s\n\tgot: %s\n",
25132                                 DB_VERSION_STRING, version);
25133                         return 1;
25134                 }
25135         }
25136 #endif
25137
25138 #if DB_VERSION_MAJOR > 2
25139         db_env_create( NULL, 0 );
25140 #elif DB_VERSION_MAJOR > 1
25141         db_appexit( NULL );
25142 #else
25143         (void) dbopen( NULL, 0, 0, 0, NULL);
25144 #endif
25145
25146   ;
25147   return 0;
25148 }
25149 _ACEOF
25150 rm -f conftest.$ac_objext conftest$ac_exeext
25151 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25152   (eval $ac_link) 2>&5
25153   ac_status=$?
25154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25155   (exit $ac_status); } &&
25156          { ac_try='test -s conftest$ac_exeext'
25157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25158   (eval $ac_try) 2>&5
25159   ac_status=$?
25160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25161   (exit $ac_status); }; }; then
25162   ol_cv_db_db4=yes
25163 else
25164   echo "$as_me: failed program was:" >&5
25165 sed 's/^/| /' conftest.$ac_ext >&5
25166
25167 ol_cv_db_db4=no
25168 fi
25169 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25170
25171         LIBS="$ol_LIBS"
25172
25173 fi
25174 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
25175 echo "${ECHO_T}$ol_cv_db_db4" >&6
25176
25177         if test $ol_cv_db_db4 = yes ; then
25178                 ol_cv_lib_db=-ldb4
25179         fi
25180 fi
25181
25182 if test $ol_cv_lib_db = no ; then
25183         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
25184 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
25185 if test "${ol_cv_db_db+set}" = set; then
25186   echo $ECHO_N "(cached) $ECHO_C" >&6
25187 else
25188
25189         ol_DB_LIB=-ldb
25190         ol_LIBS=$LIBS
25191         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25192
25193         cat >conftest.$ac_ext <<_ACEOF
25194 #line $LINENO "configure"
25195 /* confdefs.h.  */
25196 _ACEOF
25197 cat confdefs.h >>conftest.$ac_ext
25198 cat >>conftest.$ac_ext <<_ACEOF
25199 /* end confdefs.h.  */
25200
25201 #ifdef HAVE_DB_185_H
25202 # include <db_185.h>
25203 #else
25204 # include <db.h>
25205 #endif
25206
25207 #ifndef DB_VERSION_MAJOR
25208 # define DB_VERSION_MAJOR 1
25209 #endif
25210
25211 #ifndef NULL
25212 #define NULL ((void*)0)
25213 #endif
25214
25215 int
25216 main ()
25217 {
25218
25219 #if DB_VERSION_MAJOR > 1
25220         {
25221                 char *version;
25222                 int major, minor, patch;
25223
25224                 version = db_version( &major, &minor, &patch );
25225
25226                 if( major != DB_VERSION_MAJOR ||
25227                         minor < DB_VERSION_MINOR )
25228                 {
25229                         printf("Berkeley DB version mismatch\n"
25230                                 "\texpected: %s\n\tgot: %s\n",
25231                                 DB_VERSION_STRING, version);
25232                         return 1;
25233                 }
25234         }
25235 #endif
25236
25237 #if DB_VERSION_MAJOR > 2
25238         db_env_create( NULL, 0 );
25239 #elif DB_VERSION_MAJOR > 1
25240         db_appexit( NULL );
25241 #else
25242         (void) dbopen( NULL, 0, 0, 0, NULL);
25243 #endif
25244
25245   ;
25246   return 0;
25247 }
25248 _ACEOF
25249 rm -f conftest.$ac_objext conftest$ac_exeext
25250 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25251   (eval $ac_link) 2>&5
25252   ac_status=$?
25253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25254   (exit $ac_status); } &&
25255          { ac_try='test -s conftest$ac_exeext'
25256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25257   (eval $ac_try) 2>&5
25258   ac_status=$?
25259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25260   (exit $ac_status); }; }; then
25261   ol_cv_db_db=yes
25262 else
25263   echo "$as_me: failed program was:" >&5
25264 sed 's/^/| /' conftest.$ac_ext >&5
25265
25266 ol_cv_db_db=no
25267 fi
25268 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25269
25270         LIBS="$ol_LIBS"
25271
25272 fi
25273 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
25274 echo "${ECHO_T}$ol_cv_db_db" >&6
25275
25276         if test $ol_cv_db_db = yes ; then
25277                 ol_cv_lib_db=-ldb
25278         fi
25279 fi
25280
25281 if test $ol_cv_lib_db = no ; then
25282         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
25283 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
25284 if test "${ol_cv_db_db3+set}" = set; then
25285   echo $ECHO_N "(cached) $ECHO_C" >&6
25286 else
25287
25288         ol_DB_LIB=-ldb3
25289         ol_LIBS=$LIBS
25290         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25291
25292         cat >conftest.$ac_ext <<_ACEOF
25293 #line $LINENO "configure"
25294 /* confdefs.h.  */
25295 _ACEOF
25296 cat confdefs.h >>conftest.$ac_ext
25297 cat >>conftest.$ac_ext <<_ACEOF
25298 /* end confdefs.h.  */
25299
25300 #ifdef HAVE_DB_185_H
25301 # include <db_185.h>
25302 #else
25303 # include <db.h>
25304 #endif
25305
25306 #ifndef DB_VERSION_MAJOR
25307 # define DB_VERSION_MAJOR 1
25308 #endif
25309
25310 #ifndef NULL
25311 #define NULL ((void*)0)
25312 #endif
25313
25314 int
25315 main ()
25316 {
25317
25318 #if DB_VERSION_MAJOR > 1
25319         {
25320                 char *version;
25321                 int major, minor, patch;
25322
25323                 version = db_version( &major, &minor, &patch );
25324
25325                 if( major != DB_VERSION_MAJOR ||
25326                         minor < DB_VERSION_MINOR )
25327                 {
25328                         printf("Berkeley DB version mismatch\n"
25329                                 "\texpected: %s\n\tgot: %s\n",
25330                                 DB_VERSION_STRING, version);
25331                         return 1;
25332                 }
25333         }
25334 #endif
25335
25336 #if DB_VERSION_MAJOR > 2
25337         db_env_create( NULL, 0 );
25338 #elif DB_VERSION_MAJOR > 1
25339         db_appexit( NULL );
25340 #else
25341         (void) dbopen( NULL, 0, 0, 0, NULL);
25342 #endif
25343
25344   ;
25345   return 0;
25346 }
25347 _ACEOF
25348 rm -f conftest.$ac_objext conftest$ac_exeext
25349 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25350   (eval $ac_link) 2>&5
25351   ac_status=$?
25352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25353   (exit $ac_status); } &&
25354          { ac_try='test -s conftest$ac_exeext'
25355   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25356   (eval $ac_try) 2>&5
25357   ac_status=$?
25358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25359   (exit $ac_status); }; }; then
25360   ol_cv_db_db3=yes
25361 else
25362   echo "$as_me: failed program was:" >&5
25363 sed 's/^/| /' conftest.$ac_ext >&5
25364
25365 ol_cv_db_db3=no
25366 fi
25367 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25368
25369         LIBS="$ol_LIBS"
25370
25371 fi
25372 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
25373 echo "${ECHO_T}$ol_cv_db_db3" >&6
25374
25375         if test $ol_cv_db_db3 = yes ; then
25376                 ol_cv_lib_db=-ldb3
25377         fi
25378 fi
25379
25380 if test $ol_cv_lib_db = no ; then
25381         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
25382 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
25383 if test "${ol_cv_db_db_3+set}" = set; then
25384   echo $ECHO_N "(cached) $ECHO_C" >&6
25385 else
25386
25387         ol_DB_LIB=-ldb-3
25388         ol_LIBS=$LIBS
25389         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25390
25391         cat >conftest.$ac_ext <<_ACEOF
25392 #line $LINENO "configure"
25393 /* confdefs.h.  */
25394 _ACEOF
25395 cat confdefs.h >>conftest.$ac_ext
25396 cat >>conftest.$ac_ext <<_ACEOF
25397 /* end confdefs.h.  */
25398
25399 #ifdef HAVE_DB_185_H
25400 # include <db_185.h>
25401 #else
25402 # include <db.h>
25403 #endif
25404
25405 #ifndef DB_VERSION_MAJOR
25406 # define DB_VERSION_MAJOR 1
25407 #endif
25408
25409 #ifndef NULL
25410 #define NULL ((void*)0)
25411 #endif
25412
25413 int
25414 main ()
25415 {
25416
25417 #if DB_VERSION_MAJOR > 1
25418         {
25419                 char *version;
25420                 int major, minor, patch;
25421
25422                 version = db_version( &major, &minor, &patch );
25423
25424                 if( major != DB_VERSION_MAJOR ||
25425                         minor < DB_VERSION_MINOR )
25426                 {
25427                         printf("Berkeley DB version mismatch\n"
25428                                 "\texpected: %s\n\tgot: %s\n",
25429                                 DB_VERSION_STRING, version);
25430                         return 1;
25431                 }
25432         }
25433 #endif
25434
25435 #if DB_VERSION_MAJOR > 2
25436         db_env_create( NULL, 0 );
25437 #elif DB_VERSION_MAJOR > 1
25438         db_appexit( NULL );
25439 #else
25440         (void) dbopen( NULL, 0, 0, 0, NULL);
25441 #endif
25442
25443   ;
25444   return 0;
25445 }
25446 _ACEOF
25447 rm -f conftest.$ac_objext conftest$ac_exeext
25448 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25449   (eval $ac_link) 2>&5
25450   ac_status=$?
25451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25452   (exit $ac_status); } &&
25453          { ac_try='test -s conftest$ac_exeext'
25454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25455   (eval $ac_try) 2>&5
25456   ac_status=$?
25457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25458   (exit $ac_status); }; }; then
25459   ol_cv_db_db_3=yes
25460 else
25461   echo "$as_me: failed program was:" >&5
25462 sed 's/^/| /' conftest.$ac_ext >&5
25463
25464 ol_cv_db_db_3=no
25465 fi
25466 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25467
25468         LIBS="$ol_LIBS"
25469
25470 fi
25471 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
25472 echo "${ECHO_T}$ol_cv_db_db_3" >&6
25473
25474         if test $ol_cv_db_db_3 = yes ; then
25475                 ol_cv_lib_db=-ldb-3
25476         fi
25477 fi
25478
25479 if test $ol_cv_lib_db = no ; then
25480         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
25481 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
25482 if test "${ol_cv_db_db2+set}" = set; then
25483   echo $ECHO_N "(cached) $ECHO_C" >&6
25484 else
25485
25486         ol_DB_LIB=-ldb2
25487         ol_LIBS=$LIBS
25488         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25489
25490         cat >conftest.$ac_ext <<_ACEOF
25491 #line $LINENO "configure"
25492 /* confdefs.h.  */
25493 _ACEOF
25494 cat confdefs.h >>conftest.$ac_ext
25495 cat >>conftest.$ac_ext <<_ACEOF
25496 /* end confdefs.h.  */
25497
25498 #ifdef HAVE_DB_185_H
25499 # include <db_185.h>
25500 #else
25501 # include <db.h>
25502 #endif
25503
25504 #ifndef DB_VERSION_MAJOR
25505 # define DB_VERSION_MAJOR 1
25506 #endif
25507
25508 #ifndef NULL
25509 #define NULL ((void*)0)
25510 #endif
25511
25512 int
25513 main ()
25514 {
25515
25516 #if DB_VERSION_MAJOR > 1
25517         {
25518                 char *version;
25519                 int major, minor, patch;
25520
25521                 version = db_version( &major, &minor, &patch );
25522
25523                 if( major != DB_VERSION_MAJOR ||
25524                         minor < DB_VERSION_MINOR )
25525                 {
25526                         printf("Berkeley DB version mismatch\n"
25527                                 "\texpected: %s\n\tgot: %s\n",
25528                                 DB_VERSION_STRING, version);
25529                         return 1;
25530                 }
25531         }
25532 #endif
25533
25534 #if DB_VERSION_MAJOR > 2
25535         db_env_create( NULL, 0 );
25536 #elif DB_VERSION_MAJOR > 1
25537         db_appexit( NULL );
25538 #else
25539         (void) dbopen( NULL, 0, 0, 0, NULL);
25540 #endif
25541
25542   ;
25543   return 0;
25544 }
25545 _ACEOF
25546 rm -f conftest.$ac_objext conftest$ac_exeext
25547 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25548   (eval $ac_link) 2>&5
25549   ac_status=$?
25550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25551   (exit $ac_status); } &&
25552          { ac_try='test -s conftest$ac_exeext'
25553   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25554   (eval $ac_try) 2>&5
25555   ac_status=$?
25556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25557   (exit $ac_status); }; }; then
25558   ol_cv_db_db2=yes
25559 else
25560   echo "$as_me: failed program was:" >&5
25561 sed 's/^/| /' conftest.$ac_ext >&5
25562
25563 ol_cv_db_db2=no
25564 fi
25565 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25566
25567         LIBS="$ol_LIBS"
25568
25569 fi
25570 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
25571 echo "${ECHO_T}$ol_cv_db_db2" >&6
25572
25573         if test $ol_cv_db_db2 = yes ; then
25574                 ol_cv_lib_db=-ldb2
25575         fi
25576 fi
25577
25578 if test $ol_cv_lib_db = no ; then
25579         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
25580 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
25581 if test "${ol_cv_db_db_2+set}" = set; then
25582   echo $ECHO_N "(cached) $ECHO_C" >&6
25583 else
25584
25585         ol_DB_LIB=-ldb-2
25586         ol_LIBS=$LIBS
25587         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25588
25589         cat >conftest.$ac_ext <<_ACEOF
25590 #line $LINENO "configure"
25591 /* confdefs.h.  */
25592 _ACEOF
25593 cat confdefs.h >>conftest.$ac_ext
25594 cat >>conftest.$ac_ext <<_ACEOF
25595 /* end confdefs.h.  */
25596
25597 #ifdef HAVE_DB_185_H
25598 # include <db_185.h>
25599 #else
25600 # include <db.h>
25601 #endif
25602
25603 #ifndef DB_VERSION_MAJOR
25604 # define DB_VERSION_MAJOR 1
25605 #endif
25606
25607 #ifndef NULL
25608 #define NULL ((void*)0)
25609 #endif
25610
25611 int
25612 main ()
25613 {
25614
25615 #if DB_VERSION_MAJOR > 1
25616         {
25617                 char *version;
25618                 int major, minor, patch;
25619
25620                 version = db_version( &major, &minor, &patch );
25621
25622                 if( major != DB_VERSION_MAJOR ||
25623                         minor < DB_VERSION_MINOR )
25624                 {
25625                         printf("Berkeley DB version mismatch\n"
25626                                 "\texpected: %s\n\tgot: %s\n",
25627                                 DB_VERSION_STRING, version);
25628                         return 1;
25629                 }
25630         }
25631 #endif
25632
25633 #if DB_VERSION_MAJOR > 2
25634         db_env_create( NULL, 0 );
25635 #elif DB_VERSION_MAJOR > 1
25636         db_appexit( NULL );
25637 #else
25638         (void) dbopen( NULL, 0, 0, 0, NULL);
25639 #endif
25640
25641   ;
25642   return 0;
25643 }
25644 _ACEOF
25645 rm -f conftest.$ac_objext conftest$ac_exeext
25646 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25647   (eval $ac_link) 2>&5
25648   ac_status=$?
25649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25650   (exit $ac_status); } &&
25651          { ac_try='test -s conftest$ac_exeext'
25652   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25653   (eval $ac_try) 2>&5
25654   ac_status=$?
25655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25656   (exit $ac_status); }; }; then
25657   ol_cv_db_db_2=yes
25658 else
25659   echo "$as_me: failed program was:" >&5
25660 sed 's/^/| /' conftest.$ac_ext >&5
25661
25662 ol_cv_db_db_2=no
25663 fi
25664 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25665
25666         LIBS="$ol_LIBS"
25667
25668 fi
25669 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
25670 echo "${ECHO_T}$ol_cv_db_db_2" >&6
25671
25672         if test $ol_cv_db_db_2 = yes ; then
25673                 ol_cv_lib_db=-ldb-2
25674         fi
25675 fi
25676
25677 if test $ol_cv_lib_db = no ; then
25678         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
25679 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
25680 if test "${ol_cv_db_db1+set}" = set; then
25681   echo $ECHO_N "(cached) $ECHO_C" >&6
25682 else
25683
25684         ol_DB_LIB=-ldb1
25685         ol_LIBS=$LIBS
25686         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25687
25688         cat >conftest.$ac_ext <<_ACEOF
25689 #line $LINENO "configure"
25690 /* confdefs.h.  */
25691 _ACEOF
25692 cat confdefs.h >>conftest.$ac_ext
25693 cat >>conftest.$ac_ext <<_ACEOF
25694 /* end confdefs.h.  */
25695
25696 #ifdef HAVE_DB_185_H
25697 # include <db_185.h>
25698 #else
25699 # include <db.h>
25700 #endif
25701
25702 #ifndef DB_VERSION_MAJOR
25703 # define DB_VERSION_MAJOR 1
25704 #endif
25705
25706 #ifndef NULL
25707 #define NULL ((void*)0)
25708 #endif
25709
25710 int
25711 main ()
25712 {
25713
25714 #if DB_VERSION_MAJOR > 1
25715         {
25716                 char *version;
25717                 int major, minor, patch;
25718
25719                 version = db_version( &major, &minor, &patch );
25720
25721                 if( major != DB_VERSION_MAJOR ||
25722                         minor < DB_VERSION_MINOR )
25723                 {
25724                         printf("Berkeley DB version mismatch\n"
25725                                 "\texpected: %s\n\tgot: %s\n",
25726                                 DB_VERSION_STRING, version);
25727                         return 1;
25728                 }
25729         }
25730 #endif
25731
25732 #if DB_VERSION_MAJOR > 2
25733         db_env_create( NULL, 0 );
25734 #elif DB_VERSION_MAJOR > 1
25735         db_appexit( NULL );
25736 #else
25737         (void) dbopen( NULL, 0, 0, 0, NULL);
25738 #endif
25739
25740   ;
25741   return 0;
25742 }
25743 _ACEOF
25744 rm -f conftest.$ac_objext conftest$ac_exeext
25745 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25746   (eval $ac_link) 2>&5
25747   ac_status=$?
25748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25749   (exit $ac_status); } &&
25750          { ac_try='test -s conftest$ac_exeext'
25751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25752   (eval $ac_try) 2>&5
25753   ac_status=$?
25754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25755   (exit $ac_status); }; }; then
25756   ol_cv_db_db1=yes
25757 else
25758   echo "$as_me: failed program was:" >&5
25759 sed 's/^/| /' conftest.$ac_ext >&5
25760
25761 ol_cv_db_db1=no
25762 fi
25763 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25764
25765         LIBS="$ol_LIBS"
25766
25767 fi
25768 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
25769 echo "${ECHO_T}$ol_cv_db_db1" >&6
25770
25771         if test $ol_cv_db_db1 = yes ; then
25772                 ol_cv_lib_db=-ldb1
25773         fi
25774 fi
25775
25776 if test $ol_cv_lib_db = no ; then
25777         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
25778 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
25779 if test "${ol_cv_db_db_1+set}" = set; then
25780   echo $ECHO_N "(cached) $ECHO_C" >&6
25781 else
25782
25783         ol_DB_LIB=-ldb-1
25784         ol_LIBS=$LIBS
25785         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25786
25787         cat >conftest.$ac_ext <<_ACEOF
25788 #line $LINENO "configure"
25789 /* confdefs.h.  */
25790 _ACEOF
25791 cat confdefs.h >>conftest.$ac_ext
25792 cat >>conftest.$ac_ext <<_ACEOF
25793 /* end confdefs.h.  */
25794
25795 #ifdef HAVE_DB_185_H
25796 # include <db_185.h>
25797 #else
25798 # include <db.h>
25799 #endif
25800
25801 #ifndef DB_VERSION_MAJOR
25802 # define DB_VERSION_MAJOR 1
25803 #endif
25804
25805 #ifndef NULL
25806 #define NULL ((void*)0)
25807 #endif
25808
25809 int
25810 main ()
25811 {
25812
25813 #if DB_VERSION_MAJOR > 1
25814         {
25815                 char *version;
25816                 int major, minor, patch;
25817
25818                 version = db_version( &major, &minor, &patch );
25819
25820                 if( major != DB_VERSION_MAJOR ||
25821                         minor < DB_VERSION_MINOR )
25822                 {
25823                         printf("Berkeley DB version mismatch\n"
25824                                 "\texpected: %s\n\tgot: %s\n",
25825                                 DB_VERSION_STRING, version);
25826                         return 1;
25827                 }
25828         }
25829 #endif
25830
25831 #if DB_VERSION_MAJOR > 2
25832         db_env_create( NULL, 0 );
25833 #elif DB_VERSION_MAJOR > 1
25834         db_appexit( NULL );
25835 #else
25836         (void) dbopen( NULL, 0, 0, 0, NULL);
25837 #endif
25838
25839   ;
25840   return 0;
25841 }
25842 _ACEOF
25843 rm -f conftest.$ac_objext conftest$ac_exeext
25844 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25845   (eval $ac_link) 2>&5
25846   ac_status=$?
25847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25848   (exit $ac_status); } &&
25849          { ac_try='test -s conftest$ac_exeext'
25850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25851   (eval $ac_try) 2>&5
25852   ac_status=$?
25853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25854   (exit $ac_status); }; }; then
25855   ol_cv_db_db_1=yes
25856 else
25857   echo "$as_me: failed program was:" >&5
25858 sed 's/^/| /' conftest.$ac_ext >&5
25859
25860 ol_cv_db_db_1=no
25861 fi
25862 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25863
25864         LIBS="$ol_LIBS"
25865
25866 fi
25867 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
25868 echo "${ECHO_T}$ol_cv_db_db_1" >&6
25869
25870         if test $ol_cv_db_db_1 = yes ; then
25871                 ol_cv_lib_db=-ldb-1
25872         fi
25873 fi
25874
25875
25876                 if test "$ol_cv_lib_db" != no ; then
25877                         ol_cv_berkeley_db=yes
25878                 fi
25879         fi
25880 fi
25881
25882         else
25883                 ol_cv_berkeley_db=no
25884
25885 for ac_header in db.h
25886 do
25887 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25888 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25889   echo "$as_me:$LINENO: checking for $ac_header" >&5
25890 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25891 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25892   echo $ECHO_N "(cached) $ECHO_C" >&6
25893 fi
25894 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25895 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25896 else
25897   # Is the header compilable?
25898 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25899 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25900 cat >conftest.$ac_ext <<_ACEOF
25901 #line $LINENO "configure"
25902 /* confdefs.h.  */
25903 _ACEOF
25904 cat confdefs.h >>conftest.$ac_ext
25905 cat >>conftest.$ac_ext <<_ACEOF
25906 /* end confdefs.h.  */
25907 $ac_includes_default
25908 #include <$ac_header>
25909 _ACEOF
25910 rm -f conftest.$ac_objext
25911 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25912   (eval $ac_compile) 2>&5
25913   ac_status=$?
25914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25915   (exit $ac_status); } &&
25916          { ac_try='test -s conftest.$ac_objext'
25917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25918   (eval $ac_try) 2>&5
25919   ac_status=$?
25920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25921   (exit $ac_status); }; }; then
25922   ac_header_compiler=yes
25923 else
25924   echo "$as_me: failed program was:" >&5
25925 sed 's/^/| /' conftest.$ac_ext >&5
25926
25927 ac_header_compiler=no
25928 fi
25929 rm -f conftest.$ac_objext conftest.$ac_ext
25930 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25931 echo "${ECHO_T}$ac_header_compiler" >&6
25932
25933 # Is the header present?
25934 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25935 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25936 cat >conftest.$ac_ext <<_ACEOF
25937 #line $LINENO "configure"
25938 /* confdefs.h.  */
25939 _ACEOF
25940 cat confdefs.h >>conftest.$ac_ext
25941 cat >>conftest.$ac_ext <<_ACEOF
25942 /* end confdefs.h.  */
25943 #include <$ac_header>
25944 _ACEOF
25945 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25946   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25947   ac_status=$?
25948   grep -v '^ *+' conftest.er1 >conftest.err
25949   rm -f conftest.er1
25950   cat conftest.err >&5
25951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25952   (exit $ac_status); } >/dev/null; then
25953   if test -s conftest.err; then
25954     ac_cpp_err=$ac_c_preproc_warn_flag
25955   else
25956     ac_cpp_err=
25957   fi
25958 else
25959   ac_cpp_err=yes
25960 fi
25961 if test -z "$ac_cpp_err"; then
25962   ac_header_preproc=yes
25963 else
25964   echo "$as_me: failed program was:" >&5
25965 sed 's/^/| /' conftest.$ac_ext >&5
25966
25967   ac_header_preproc=no
25968 fi
25969 rm -f conftest.err conftest.$ac_ext
25970 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25971 echo "${ECHO_T}$ac_header_preproc" >&6
25972
25973 # So?  What about this header?
25974 case $ac_header_compiler:$ac_header_preproc in
25975   yes:no )
25976     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25977 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25978     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25979 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25980     (
25981       cat <<\_ASBOX
25982 ## ------------------------------------ ##
25983 ## Report this to bug-autoconf@gnu.org. ##
25984 ## ------------------------------------ ##
25985 _ASBOX
25986     ) |
25987       sed "s/^/$as_me: WARNING:     /" >&2
25988     ;;
25989   no:yes )
25990     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25991 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25992     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
25993 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
25994     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25995 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25996     (
25997       cat <<\_ASBOX
25998 ## ------------------------------------ ##
25999 ## Report this to bug-autoconf@gnu.org. ##
26000 ## ------------------------------------ ##
26001 _ASBOX
26002     ) |
26003       sed "s/^/$as_me: WARNING:     /" >&2
26004     ;;
26005 esac
26006 echo "$as_me:$LINENO: checking for $ac_header" >&5
26007 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26008 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26009   echo $ECHO_N "(cached) $ECHO_C" >&6
26010 else
26011   eval "$as_ac_Header=$ac_header_preproc"
26012 fi
26013 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26014 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26015
26016 fi
26017 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26018   cat >>confdefs.h <<_ACEOF
26019 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26020 _ACEOF
26021
26022 fi
26023
26024 done
26025
26026 if test $ac_cv_header_db_h = yes; then
26027         ol_cv_lib_db=no
26028 if test $ol_cv_lib_db = no ; then
26029         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
26030 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
26031 if test "${ol_cv_db_none+set}" = set; then
26032   echo $ECHO_N "(cached) $ECHO_C" >&6
26033 else
26034
26035         ol_DB_LIB=
26036         ol_LIBS=$LIBS
26037         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26038
26039         cat >conftest.$ac_ext <<_ACEOF
26040 #line $LINENO "configure"
26041 /* confdefs.h.  */
26042 _ACEOF
26043 cat confdefs.h >>conftest.$ac_ext
26044 cat >>conftest.$ac_ext <<_ACEOF
26045 /* end confdefs.h.  */
26046
26047 #ifdef HAVE_DB_185_H
26048 # include <db_185.h>
26049 #else
26050 # include <db.h>
26051 #endif
26052
26053 #ifndef DB_VERSION_MAJOR
26054 # define DB_VERSION_MAJOR 1
26055 #endif
26056
26057 #ifndef NULL
26058 #define NULL ((void*)0)
26059 #endif
26060
26061 int
26062 main ()
26063 {
26064
26065 #if DB_VERSION_MAJOR > 1
26066         {
26067                 char *version;
26068                 int major, minor, patch;
26069
26070                 version = db_version( &major, &minor, &patch );
26071
26072                 if( major != DB_VERSION_MAJOR ||
26073                         minor < DB_VERSION_MINOR )
26074                 {
26075                         printf("Berkeley DB version mismatch\n"
26076                                 "\texpected: %s\n\tgot: %s\n",
26077                                 DB_VERSION_STRING, version);
26078                         return 1;
26079                 }
26080         }
26081 #endif
26082
26083 #if DB_VERSION_MAJOR > 2
26084         db_env_create( NULL, 0 );
26085 #elif DB_VERSION_MAJOR > 1
26086         db_appexit( NULL );
26087 #else
26088         (void) dbopen( NULL, 0, 0, 0, NULL);
26089 #endif
26090
26091   ;
26092   return 0;
26093 }
26094 _ACEOF
26095 rm -f conftest.$ac_objext conftest$ac_exeext
26096 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26097   (eval $ac_link) 2>&5
26098   ac_status=$?
26099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26100   (exit $ac_status); } &&
26101          { ac_try='test -s conftest$ac_exeext'
26102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26103   (eval $ac_try) 2>&5
26104   ac_status=$?
26105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26106   (exit $ac_status); }; }; then
26107   ol_cv_db_none=yes
26108 else
26109   echo "$as_me: failed program was:" >&5
26110 sed 's/^/| /' conftest.$ac_ext >&5
26111
26112 ol_cv_db_none=no
26113 fi
26114 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26115
26116         LIBS="$ol_LIBS"
26117
26118 fi
26119 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
26120 echo "${ECHO_T}$ol_cv_db_none" >&6
26121
26122         if test $ol_cv_db_none = yes ; then
26123                 ol_cv_lib_db=yes
26124         fi
26125 fi
26126
26127 if test $ol_cv_lib_db = no ; then
26128         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb41)" >&5
26129 echo $ECHO_N "checking for Berkeley DB link (-ldb41)... $ECHO_C" >&6
26130 if test "${ol_cv_db_db41+set}" = set; then
26131   echo $ECHO_N "(cached) $ECHO_C" >&6
26132 else
26133
26134         ol_DB_LIB=-ldb41
26135         ol_LIBS=$LIBS
26136         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26137
26138         cat >conftest.$ac_ext <<_ACEOF
26139 #line $LINENO "configure"
26140 /* confdefs.h.  */
26141 _ACEOF
26142 cat confdefs.h >>conftest.$ac_ext
26143 cat >>conftest.$ac_ext <<_ACEOF
26144 /* end confdefs.h.  */
26145
26146 #ifdef HAVE_DB_185_H
26147 # include <db_185.h>
26148 #else
26149 # include <db.h>
26150 #endif
26151
26152 #ifndef DB_VERSION_MAJOR
26153 # define DB_VERSION_MAJOR 1
26154 #endif
26155
26156 #ifndef NULL
26157 #define NULL ((void*)0)
26158 #endif
26159
26160 int
26161 main ()
26162 {
26163
26164 #if DB_VERSION_MAJOR > 1
26165         {
26166                 char *version;
26167                 int major, minor, patch;
26168
26169                 version = db_version( &major, &minor, &patch );
26170
26171                 if( major != DB_VERSION_MAJOR ||
26172                         minor < DB_VERSION_MINOR )
26173                 {
26174                         printf("Berkeley DB version mismatch\n"
26175                                 "\texpected: %s\n\tgot: %s\n",
26176                                 DB_VERSION_STRING, version);
26177                         return 1;
26178                 }
26179         }
26180 #endif
26181
26182 #if DB_VERSION_MAJOR > 2
26183         db_env_create( NULL, 0 );
26184 #elif DB_VERSION_MAJOR > 1
26185         db_appexit( NULL );
26186 #else
26187         (void) dbopen( NULL, 0, 0, 0, NULL);
26188 #endif
26189
26190   ;
26191   return 0;
26192 }
26193 _ACEOF
26194 rm -f conftest.$ac_objext conftest$ac_exeext
26195 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26196   (eval $ac_link) 2>&5
26197   ac_status=$?
26198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26199   (exit $ac_status); } &&
26200          { ac_try='test -s conftest$ac_exeext'
26201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26202   (eval $ac_try) 2>&5
26203   ac_status=$?
26204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26205   (exit $ac_status); }; }; then
26206   ol_cv_db_db41=yes
26207 else
26208   echo "$as_me: failed program was:" >&5
26209 sed 's/^/| /' conftest.$ac_ext >&5
26210
26211 ol_cv_db_db41=no
26212 fi
26213 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26214
26215         LIBS="$ol_LIBS"
26216
26217 fi
26218 echo "$as_me:$LINENO: result: $ol_cv_db_db41" >&5
26219 echo "${ECHO_T}$ol_cv_db_db41" >&6
26220
26221         if test $ol_cv_db_db41 = yes ; then
26222                 ol_cv_lib_db=-ldb41
26223         fi
26224 fi
26225
26226 if test $ol_cv_lib_db = no ; then
26227         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-41)" >&5
26228 echo $ECHO_N "checking for Berkeley DB link (-ldb-41)... $ECHO_C" >&6
26229 if test "${ol_cv_db_db_41+set}" = set; then
26230   echo $ECHO_N "(cached) $ECHO_C" >&6
26231 else
26232
26233         ol_DB_LIB=-ldb-41
26234         ol_LIBS=$LIBS
26235         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26236
26237         cat >conftest.$ac_ext <<_ACEOF
26238 #line $LINENO "configure"
26239 /* confdefs.h.  */
26240 _ACEOF
26241 cat confdefs.h >>conftest.$ac_ext
26242 cat >>conftest.$ac_ext <<_ACEOF
26243 /* end confdefs.h.  */
26244
26245 #ifdef HAVE_DB_185_H
26246 # include <db_185.h>
26247 #else
26248 # include <db.h>
26249 #endif
26250
26251 #ifndef DB_VERSION_MAJOR
26252 # define DB_VERSION_MAJOR 1
26253 #endif
26254
26255 #ifndef NULL
26256 #define NULL ((void*)0)
26257 #endif
26258
26259 int
26260 main ()
26261 {
26262
26263 #if DB_VERSION_MAJOR > 1
26264         {
26265                 char *version;
26266                 int major, minor, patch;
26267
26268                 version = db_version( &major, &minor, &patch );
26269
26270                 if( major != DB_VERSION_MAJOR ||
26271                         minor < DB_VERSION_MINOR )
26272                 {
26273                         printf("Berkeley DB version mismatch\n"
26274                                 "\texpected: %s\n\tgot: %s\n",
26275                                 DB_VERSION_STRING, version);
26276                         return 1;
26277                 }
26278         }
26279 #endif
26280
26281 #if DB_VERSION_MAJOR > 2
26282         db_env_create( NULL, 0 );
26283 #elif DB_VERSION_MAJOR > 1
26284         db_appexit( NULL );
26285 #else
26286         (void) dbopen( NULL, 0, 0, 0, NULL);
26287 #endif
26288
26289   ;
26290   return 0;
26291 }
26292 _ACEOF
26293 rm -f conftest.$ac_objext conftest$ac_exeext
26294 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26295   (eval $ac_link) 2>&5
26296   ac_status=$?
26297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26298   (exit $ac_status); } &&
26299          { ac_try='test -s conftest$ac_exeext'
26300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26301   (eval $ac_try) 2>&5
26302   ac_status=$?
26303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26304   (exit $ac_status); }; }; then
26305   ol_cv_db_db_41=yes
26306 else
26307   echo "$as_me: failed program was:" >&5
26308 sed 's/^/| /' conftest.$ac_ext >&5
26309
26310 ol_cv_db_db_41=no
26311 fi
26312 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26313
26314         LIBS="$ol_LIBS"
26315
26316 fi
26317 echo "$as_me:$LINENO: result: $ol_cv_db_db_41" >&5
26318 echo "${ECHO_T}$ol_cv_db_db_41" >&6
26319
26320         if test $ol_cv_db_db_41 = yes ; then
26321                 ol_cv_lib_db=-ldb-41
26322         fi
26323 fi
26324
26325 if test $ol_cv_lib_db = no ; then
26326         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.1)" >&5
26327 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.1)... $ECHO_C" >&6
26328 if test "${ol_cv_db_db_4_dot_1+set}" = set; then
26329   echo $ECHO_N "(cached) $ECHO_C" >&6
26330 else
26331
26332         ol_DB_LIB=-ldb-4.1
26333         ol_LIBS=$LIBS
26334         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26335
26336         cat >conftest.$ac_ext <<_ACEOF
26337 #line $LINENO "configure"
26338 /* confdefs.h.  */
26339 _ACEOF
26340 cat confdefs.h >>conftest.$ac_ext
26341 cat >>conftest.$ac_ext <<_ACEOF
26342 /* end confdefs.h.  */
26343
26344 #ifdef HAVE_DB_185_H
26345 # include <db_185.h>
26346 #else
26347 # include <db.h>
26348 #endif
26349
26350 #ifndef DB_VERSION_MAJOR
26351 # define DB_VERSION_MAJOR 1
26352 #endif
26353
26354 #ifndef NULL
26355 #define NULL ((void*)0)
26356 #endif
26357
26358 int
26359 main ()
26360 {
26361
26362 #if DB_VERSION_MAJOR > 1
26363         {
26364                 char *version;
26365                 int major, minor, patch;
26366
26367                 version = db_version( &major, &minor, &patch );
26368
26369                 if( major != DB_VERSION_MAJOR ||
26370                         minor < DB_VERSION_MINOR )
26371                 {
26372                         printf("Berkeley DB version mismatch\n"
26373                                 "\texpected: %s\n\tgot: %s\n",
26374                                 DB_VERSION_STRING, version);
26375                         return 1;
26376                 }
26377         }
26378 #endif
26379
26380 #if DB_VERSION_MAJOR > 2
26381         db_env_create( NULL, 0 );
26382 #elif DB_VERSION_MAJOR > 1
26383         db_appexit( NULL );
26384 #else
26385         (void) dbopen( NULL, 0, 0, 0, NULL);
26386 #endif
26387
26388   ;
26389   return 0;
26390 }
26391 _ACEOF
26392 rm -f conftest.$ac_objext conftest$ac_exeext
26393 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26394   (eval $ac_link) 2>&5
26395   ac_status=$?
26396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26397   (exit $ac_status); } &&
26398          { ac_try='test -s conftest$ac_exeext'
26399   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26400   (eval $ac_try) 2>&5
26401   ac_status=$?
26402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26403   (exit $ac_status); }; }; then
26404   ol_cv_db_db_4_dot_1=yes
26405 else
26406   echo "$as_me: failed program was:" >&5
26407 sed 's/^/| /' conftest.$ac_ext >&5
26408
26409 ol_cv_db_db_4_dot_1=no
26410 fi
26411 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26412
26413         LIBS="$ol_LIBS"
26414
26415 fi
26416 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_1" >&5
26417 echo "${ECHO_T}$ol_cv_db_db_4_dot_1" >&6
26418
26419         if test $ol_cv_db_db_4_dot_1 = yes ; then
26420                 ol_cv_lib_db=-ldb-4.1
26421         fi
26422 fi
26423
26424 if test $ol_cv_lib_db = no ; then
26425         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-1)" >&5
26426 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-1)... $ECHO_C" >&6
26427 if test "${ol_cv_db_db_4_1+set}" = set; then
26428   echo $ECHO_N "(cached) $ECHO_C" >&6
26429 else
26430
26431         ol_DB_LIB=-ldb-4-1
26432         ol_LIBS=$LIBS
26433         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26434
26435         cat >conftest.$ac_ext <<_ACEOF
26436 #line $LINENO "configure"
26437 /* confdefs.h.  */
26438 _ACEOF
26439 cat confdefs.h >>conftest.$ac_ext
26440 cat >>conftest.$ac_ext <<_ACEOF
26441 /* end confdefs.h.  */
26442
26443 #ifdef HAVE_DB_185_H
26444 # include <db_185.h>
26445 #else
26446 # include <db.h>
26447 #endif
26448
26449 #ifndef DB_VERSION_MAJOR
26450 # define DB_VERSION_MAJOR 1
26451 #endif
26452
26453 #ifndef NULL
26454 #define NULL ((void*)0)
26455 #endif
26456
26457 int
26458 main ()
26459 {
26460
26461 #if DB_VERSION_MAJOR > 1
26462         {
26463                 char *version;
26464                 int major, minor, patch;
26465
26466                 version = db_version( &major, &minor, &patch );
26467
26468                 if( major != DB_VERSION_MAJOR ||
26469                         minor < DB_VERSION_MINOR )
26470                 {
26471                         printf("Berkeley DB version mismatch\n"
26472                                 "\texpected: %s\n\tgot: %s\n",
26473                                 DB_VERSION_STRING, version);
26474                         return 1;
26475                 }
26476         }
26477 #endif
26478
26479 #if DB_VERSION_MAJOR > 2
26480         db_env_create( NULL, 0 );
26481 #elif DB_VERSION_MAJOR > 1
26482         db_appexit( NULL );
26483 #else
26484         (void) dbopen( NULL, 0, 0, 0, NULL);
26485 #endif
26486
26487   ;
26488   return 0;
26489 }
26490 _ACEOF
26491 rm -f conftest.$ac_objext conftest$ac_exeext
26492 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26493   (eval $ac_link) 2>&5
26494   ac_status=$?
26495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26496   (exit $ac_status); } &&
26497          { ac_try='test -s conftest$ac_exeext'
26498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26499   (eval $ac_try) 2>&5
26500   ac_status=$?
26501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26502   (exit $ac_status); }; }; then
26503   ol_cv_db_db_4_1=yes
26504 else
26505   echo "$as_me: failed program was:" >&5
26506 sed 's/^/| /' conftest.$ac_ext >&5
26507
26508 ol_cv_db_db_4_1=no
26509 fi
26510 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26511
26512         LIBS="$ol_LIBS"
26513
26514 fi
26515 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_1" >&5
26516 echo "${ECHO_T}$ol_cv_db_db_4_1" >&6
26517
26518         if test $ol_cv_db_db_4_1 = yes ; then
26519                 ol_cv_lib_db=-ldb-4-1
26520         fi
26521 fi
26522
26523 if test $ol_cv_lib_db = no ; then
26524         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
26525 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
26526 if test "${ol_cv_db_db_4+set}" = set; then
26527   echo $ECHO_N "(cached) $ECHO_C" >&6
26528 else
26529
26530         ol_DB_LIB=-ldb-4
26531         ol_LIBS=$LIBS
26532         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26533
26534         cat >conftest.$ac_ext <<_ACEOF
26535 #line $LINENO "configure"
26536 /* confdefs.h.  */
26537 _ACEOF
26538 cat confdefs.h >>conftest.$ac_ext
26539 cat >>conftest.$ac_ext <<_ACEOF
26540 /* end confdefs.h.  */
26541
26542 #ifdef HAVE_DB_185_H
26543 # include <db_185.h>
26544 #else
26545 # include <db.h>
26546 #endif
26547
26548 #ifndef DB_VERSION_MAJOR
26549 # define DB_VERSION_MAJOR 1
26550 #endif
26551
26552 #ifndef NULL
26553 #define NULL ((void*)0)
26554 #endif
26555
26556 int
26557 main ()
26558 {
26559
26560 #if DB_VERSION_MAJOR > 1
26561         {
26562                 char *version;
26563                 int major, minor, patch;
26564
26565                 version = db_version( &major, &minor, &patch );
26566
26567                 if( major != DB_VERSION_MAJOR ||
26568                         minor < DB_VERSION_MINOR )
26569                 {
26570                         printf("Berkeley DB version mismatch\n"
26571                                 "\texpected: %s\n\tgot: %s\n",
26572                                 DB_VERSION_STRING, version);
26573                         return 1;
26574                 }
26575         }
26576 #endif
26577
26578 #if DB_VERSION_MAJOR > 2
26579         db_env_create( NULL, 0 );
26580 #elif DB_VERSION_MAJOR > 1
26581         db_appexit( NULL );
26582 #else
26583         (void) dbopen( NULL, 0, 0, 0, NULL);
26584 #endif
26585
26586   ;
26587   return 0;
26588 }
26589 _ACEOF
26590 rm -f conftest.$ac_objext conftest$ac_exeext
26591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26592   (eval $ac_link) 2>&5
26593   ac_status=$?
26594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26595   (exit $ac_status); } &&
26596          { ac_try='test -s conftest$ac_exeext'
26597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26598   (eval $ac_try) 2>&5
26599   ac_status=$?
26600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26601   (exit $ac_status); }; }; then
26602   ol_cv_db_db_4=yes
26603 else
26604   echo "$as_me: failed program was:" >&5
26605 sed 's/^/| /' conftest.$ac_ext >&5
26606
26607 ol_cv_db_db_4=no
26608 fi
26609 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26610
26611         LIBS="$ol_LIBS"
26612
26613 fi
26614 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
26615 echo "${ECHO_T}$ol_cv_db_db_4" >&6
26616
26617         if test $ol_cv_db_db_4 = yes ; then
26618                 ol_cv_lib_db=-ldb-4
26619         fi
26620 fi
26621
26622 if test $ol_cv_lib_db = no ; then
26623         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
26624 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
26625 if test "${ol_cv_db_db4+set}" = set; then
26626   echo $ECHO_N "(cached) $ECHO_C" >&6
26627 else
26628
26629         ol_DB_LIB=-ldb4
26630         ol_LIBS=$LIBS
26631         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26632
26633         cat >conftest.$ac_ext <<_ACEOF
26634 #line $LINENO "configure"
26635 /* confdefs.h.  */
26636 _ACEOF
26637 cat confdefs.h >>conftest.$ac_ext
26638 cat >>conftest.$ac_ext <<_ACEOF
26639 /* end confdefs.h.  */
26640
26641 #ifdef HAVE_DB_185_H
26642 # include <db_185.h>
26643 #else
26644 # include <db.h>
26645 #endif
26646
26647 #ifndef DB_VERSION_MAJOR
26648 # define DB_VERSION_MAJOR 1
26649 #endif
26650
26651 #ifndef NULL
26652 #define NULL ((void*)0)
26653 #endif
26654
26655 int
26656 main ()
26657 {
26658
26659 #if DB_VERSION_MAJOR > 1
26660         {
26661                 char *version;
26662                 int major, minor, patch;
26663
26664                 version = db_version( &major, &minor, &patch );
26665
26666                 if( major != DB_VERSION_MAJOR ||
26667                         minor < DB_VERSION_MINOR )
26668                 {
26669                         printf("Berkeley DB version mismatch\n"
26670                                 "\texpected: %s\n\tgot: %s\n",
26671                                 DB_VERSION_STRING, version);
26672                         return 1;
26673                 }
26674         }
26675 #endif
26676
26677 #if DB_VERSION_MAJOR > 2
26678         db_env_create( NULL, 0 );
26679 #elif DB_VERSION_MAJOR > 1
26680         db_appexit( NULL );
26681 #else
26682         (void) dbopen( NULL, 0, 0, 0, NULL);
26683 #endif
26684
26685   ;
26686   return 0;
26687 }
26688 _ACEOF
26689 rm -f conftest.$ac_objext conftest$ac_exeext
26690 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26691   (eval $ac_link) 2>&5
26692   ac_status=$?
26693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26694   (exit $ac_status); } &&
26695          { ac_try='test -s conftest$ac_exeext'
26696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26697   (eval $ac_try) 2>&5
26698   ac_status=$?
26699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26700   (exit $ac_status); }; }; then
26701   ol_cv_db_db4=yes
26702 else
26703   echo "$as_me: failed program was:" >&5
26704 sed 's/^/| /' conftest.$ac_ext >&5
26705
26706 ol_cv_db_db4=no
26707 fi
26708 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26709
26710         LIBS="$ol_LIBS"
26711
26712 fi
26713 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
26714 echo "${ECHO_T}$ol_cv_db_db4" >&6
26715
26716         if test $ol_cv_db_db4 = yes ; then
26717                 ol_cv_lib_db=-ldb4
26718         fi
26719 fi
26720
26721 if test $ol_cv_lib_db = no ; then
26722         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
26723 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
26724 if test "${ol_cv_db_db+set}" = set; then
26725   echo $ECHO_N "(cached) $ECHO_C" >&6
26726 else
26727
26728         ol_DB_LIB=-ldb
26729         ol_LIBS=$LIBS
26730         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26731
26732         cat >conftest.$ac_ext <<_ACEOF
26733 #line $LINENO "configure"
26734 /* confdefs.h.  */
26735 _ACEOF
26736 cat confdefs.h >>conftest.$ac_ext
26737 cat >>conftest.$ac_ext <<_ACEOF
26738 /* end confdefs.h.  */
26739
26740 #ifdef HAVE_DB_185_H
26741 # include <db_185.h>
26742 #else
26743 # include <db.h>
26744 #endif
26745
26746 #ifndef DB_VERSION_MAJOR
26747 # define DB_VERSION_MAJOR 1
26748 #endif
26749
26750 #ifndef NULL
26751 #define NULL ((void*)0)
26752 #endif
26753
26754 int
26755 main ()
26756 {
26757
26758 #if DB_VERSION_MAJOR > 1
26759         {
26760                 char *version;
26761                 int major, minor, patch;
26762
26763                 version = db_version( &major, &minor, &patch );
26764
26765                 if( major != DB_VERSION_MAJOR ||
26766                         minor < DB_VERSION_MINOR )
26767                 {
26768                         printf("Berkeley DB version mismatch\n"
26769                                 "\texpected: %s\n\tgot: %s\n",
26770                                 DB_VERSION_STRING, version);
26771                         return 1;
26772                 }
26773         }
26774 #endif
26775
26776 #if DB_VERSION_MAJOR > 2
26777         db_env_create( NULL, 0 );
26778 #elif DB_VERSION_MAJOR > 1
26779         db_appexit( NULL );
26780 #else
26781         (void) dbopen( NULL, 0, 0, 0, NULL);
26782 #endif
26783
26784   ;
26785   return 0;
26786 }
26787 _ACEOF
26788 rm -f conftest.$ac_objext conftest$ac_exeext
26789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26790   (eval $ac_link) 2>&5
26791   ac_status=$?
26792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26793   (exit $ac_status); } &&
26794          { ac_try='test -s conftest$ac_exeext'
26795   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26796   (eval $ac_try) 2>&5
26797   ac_status=$?
26798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26799   (exit $ac_status); }; }; then
26800   ol_cv_db_db=yes
26801 else
26802   echo "$as_me: failed program was:" >&5
26803 sed 's/^/| /' conftest.$ac_ext >&5
26804
26805 ol_cv_db_db=no
26806 fi
26807 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26808
26809         LIBS="$ol_LIBS"
26810
26811 fi
26812 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
26813 echo "${ECHO_T}$ol_cv_db_db" >&6
26814
26815         if test $ol_cv_db_db = yes ; then
26816                 ol_cv_lib_db=-ldb
26817         fi
26818 fi
26819
26820 if test $ol_cv_lib_db = no ; then
26821         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
26822 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
26823 if test "${ol_cv_db_db3+set}" = set; then
26824   echo $ECHO_N "(cached) $ECHO_C" >&6
26825 else
26826
26827         ol_DB_LIB=-ldb3
26828         ol_LIBS=$LIBS
26829         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26830
26831         cat >conftest.$ac_ext <<_ACEOF
26832 #line $LINENO "configure"
26833 /* confdefs.h.  */
26834 _ACEOF
26835 cat confdefs.h >>conftest.$ac_ext
26836 cat >>conftest.$ac_ext <<_ACEOF
26837 /* end confdefs.h.  */
26838
26839 #ifdef HAVE_DB_185_H
26840 # include <db_185.h>
26841 #else
26842 # include <db.h>
26843 #endif
26844
26845 #ifndef DB_VERSION_MAJOR
26846 # define DB_VERSION_MAJOR 1
26847 #endif
26848
26849 #ifndef NULL
26850 #define NULL ((void*)0)
26851 #endif
26852
26853 int
26854 main ()
26855 {
26856
26857 #if DB_VERSION_MAJOR > 1
26858         {
26859                 char *version;
26860                 int major, minor, patch;
26861
26862                 version = db_version( &major, &minor, &patch );
26863
26864                 if( major != DB_VERSION_MAJOR ||
26865                         minor < DB_VERSION_MINOR )
26866                 {
26867                         printf("Berkeley DB version mismatch\n"
26868                                 "\texpected: %s\n\tgot: %s\n",
26869                                 DB_VERSION_STRING, version);
26870                         return 1;
26871                 }
26872         }
26873 #endif
26874
26875 #if DB_VERSION_MAJOR > 2
26876         db_env_create( NULL, 0 );
26877 #elif DB_VERSION_MAJOR > 1
26878         db_appexit( NULL );
26879 #else
26880         (void) dbopen( NULL, 0, 0, 0, NULL);
26881 #endif
26882
26883   ;
26884   return 0;
26885 }
26886 _ACEOF
26887 rm -f conftest.$ac_objext conftest$ac_exeext
26888 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26889   (eval $ac_link) 2>&5
26890   ac_status=$?
26891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26892   (exit $ac_status); } &&
26893          { ac_try='test -s conftest$ac_exeext'
26894   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26895   (eval $ac_try) 2>&5
26896   ac_status=$?
26897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26898   (exit $ac_status); }; }; then
26899   ol_cv_db_db3=yes
26900 else
26901   echo "$as_me: failed program was:" >&5
26902 sed 's/^/| /' conftest.$ac_ext >&5
26903
26904 ol_cv_db_db3=no
26905 fi
26906 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26907
26908         LIBS="$ol_LIBS"
26909
26910 fi
26911 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
26912 echo "${ECHO_T}$ol_cv_db_db3" >&6
26913
26914         if test $ol_cv_db_db3 = yes ; then
26915                 ol_cv_lib_db=-ldb3
26916         fi
26917 fi
26918
26919 if test $ol_cv_lib_db = no ; then
26920         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
26921 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
26922 if test "${ol_cv_db_db_3+set}" = set; then
26923   echo $ECHO_N "(cached) $ECHO_C" >&6
26924 else
26925
26926         ol_DB_LIB=-ldb-3
26927         ol_LIBS=$LIBS
26928         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
26929
26930         cat >conftest.$ac_ext <<_ACEOF
26931 #line $LINENO "configure"
26932 /* confdefs.h.  */
26933 _ACEOF
26934 cat confdefs.h >>conftest.$ac_ext
26935 cat >>conftest.$ac_ext <<_ACEOF
26936 /* end confdefs.h.  */
26937
26938 #ifdef HAVE_DB_185_H
26939 # include <db_185.h>
26940 #else
26941 # include <db.h>
26942 #endif
26943
26944 #ifndef DB_VERSION_MAJOR
26945 # define DB_VERSION_MAJOR 1
26946 #endif
26947
26948 #ifndef NULL
26949 #define NULL ((void*)0)
26950 #endif
26951
26952 int
26953 main ()
26954 {
26955
26956 #if DB_VERSION_MAJOR > 1
26957         {
26958                 char *version;
26959                 int major, minor, patch;
26960
26961                 version = db_version( &major, &minor, &patch );
26962
26963                 if( major != DB_VERSION_MAJOR ||
26964                         minor < DB_VERSION_MINOR )
26965                 {
26966                         printf("Berkeley DB version mismatch\n"
26967                                 "\texpected: %s\n\tgot: %s\n",
26968                                 DB_VERSION_STRING, version);
26969                         return 1;
26970                 }
26971         }
26972 #endif
26973
26974 #if DB_VERSION_MAJOR > 2
26975         db_env_create( NULL, 0 );
26976 #elif DB_VERSION_MAJOR > 1
26977         db_appexit( NULL );
26978 #else
26979         (void) dbopen( NULL, 0, 0, 0, NULL);
26980 #endif
26981
26982   ;
26983   return 0;
26984 }
26985 _ACEOF
26986 rm -f conftest.$ac_objext conftest$ac_exeext
26987 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26988   (eval $ac_link) 2>&5
26989   ac_status=$?
26990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26991   (exit $ac_status); } &&
26992          { ac_try='test -s conftest$ac_exeext'
26993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26994   (eval $ac_try) 2>&5
26995   ac_status=$?
26996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26997   (exit $ac_status); }; }; then
26998   ol_cv_db_db_3=yes
26999 else
27000   echo "$as_me: failed program was:" >&5
27001 sed 's/^/| /' conftest.$ac_ext >&5
27002
27003 ol_cv_db_db_3=no
27004 fi
27005 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27006
27007         LIBS="$ol_LIBS"
27008
27009 fi
27010 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
27011 echo "${ECHO_T}$ol_cv_db_db_3" >&6
27012
27013         if test $ol_cv_db_db_3 = yes ; then
27014                 ol_cv_lib_db=-ldb-3
27015         fi
27016 fi
27017
27018 if test $ol_cv_lib_db = no ; then
27019         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
27020 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
27021 if test "${ol_cv_db_db2+set}" = set; then
27022   echo $ECHO_N "(cached) $ECHO_C" >&6
27023 else
27024
27025         ol_DB_LIB=-ldb2
27026         ol_LIBS=$LIBS
27027         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27028
27029         cat >conftest.$ac_ext <<_ACEOF
27030 #line $LINENO "configure"
27031 /* confdefs.h.  */
27032 _ACEOF
27033 cat confdefs.h >>conftest.$ac_ext
27034 cat >>conftest.$ac_ext <<_ACEOF
27035 /* end confdefs.h.  */
27036
27037 #ifdef HAVE_DB_185_H
27038 # include <db_185.h>
27039 #else
27040 # include <db.h>
27041 #endif
27042
27043 #ifndef DB_VERSION_MAJOR
27044 # define DB_VERSION_MAJOR 1
27045 #endif
27046
27047 #ifndef NULL
27048 #define NULL ((void*)0)
27049 #endif
27050
27051 int
27052 main ()
27053 {
27054
27055 #if DB_VERSION_MAJOR > 1
27056         {
27057                 char *version;
27058                 int major, minor, patch;
27059
27060                 version = db_version( &major, &minor, &patch );
27061
27062                 if( major != DB_VERSION_MAJOR ||
27063                         minor < DB_VERSION_MINOR )
27064                 {
27065                         printf("Berkeley DB version mismatch\n"
27066                                 "\texpected: %s\n\tgot: %s\n",
27067                                 DB_VERSION_STRING, version);
27068                         return 1;
27069                 }
27070         }
27071 #endif
27072
27073 #if DB_VERSION_MAJOR > 2
27074         db_env_create( NULL, 0 );
27075 #elif DB_VERSION_MAJOR > 1
27076         db_appexit( NULL );
27077 #else
27078         (void) dbopen( NULL, 0, 0, 0, NULL);
27079 #endif
27080
27081   ;
27082   return 0;
27083 }
27084 _ACEOF
27085 rm -f conftest.$ac_objext conftest$ac_exeext
27086 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27087   (eval $ac_link) 2>&5
27088   ac_status=$?
27089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27090   (exit $ac_status); } &&
27091          { ac_try='test -s conftest$ac_exeext'
27092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27093   (eval $ac_try) 2>&5
27094   ac_status=$?
27095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27096   (exit $ac_status); }; }; then
27097   ol_cv_db_db2=yes
27098 else
27099   echo "$as_me: failed program was:" >&5
27100 sed 's/^/| /' conftest.$ac_ext >&5
27101
27102 ol_cv_db_db2=no
27103 fi
27104 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27105
27106         LIBS="$ol_LIBS"
27107
27108 fi
27109 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
27110 echo "${ECHO_T}$ol_cv_db_db2" >&6
27111
27112         if test $ol_cv_db_db2 = yes ; then
27113                 ol_cv_lib_db=-ldb2
27114         fi
27115 fi
27116
27117 if test $ol_cv_lib_db = no ; then
27118         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
27119 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
27120 if test "${ol_cv_db_db_2+set}" = set; then
27121   echo $ECHO_N "(cached) $ECHO_C" >&6
27122 else
27123
27124         ol_DB_LIB=-ldb-2
27125         ol_LIBS=$LIBS
27126         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27127
27128         cat >conftest.$ac_ext <<_ACEOF
27129 #line $LINENO "configure"
27130 /* confdefs.h.  */
27131 _ACEOF
27132 cat confdefs.h >>conftest.$ac_ext
27133 cat >>conftest.$ac_ext <<_ACEOF
27134 /* end confdefs.h.  */
27135
27136 #ifdef HAVE_DB_185_H
27137 # include <db_185.h>
27138 #else
27139 # include <db.h>
27140 #endif
27141
27142 #ifndef DB_VERSION_MAJOR
27143 # define DB_VERSION_MAJOR 1
27144 #endif
27145
27146 #ifndef NULL
27147 #define NULL ((void*)0)
27148 #endif
27149
27150 int
27151 main ()
27152 {
27153
27154 #if DB_VERSION_MAJOR > 1
27155         {
27156                 char *version;
27157                 int major, minor, patch;
27158
27159                 version = db_version( &major, &minor, &patch );
27160
27161                 if( major != DB_VERSION_MAJOR ||
27162                         minor < DB_VERSION_MINOR )
27163                 {
27164                         printf("Berkeley DB version mismatch\n"
27165                                 "\texpected: %s\n\tgot: %s\n",
27166                                 DB_VERSION_STRING, version);
27167                         return 1;
27168                 }
27169         }
27170 #endif
27171
27172 #if DB_VERSION_MAJOR > 2
27173         db_env_create( NULL, 0 );
27174 #elif DB_VERSION_MAJOR > 1
27175         db_appexit( NULL );
27176 #else
27177         (void) dbopen( NULL, 0, 0, 0, NULL);
27178 #endif
27179
27180   ;
27181   return 0;
27182 }
27183 _ACEOF
27184 rm -f conftest.$ac_objext conftest$ac_exeext
27185 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27186   (eval $ac_link) 2>&5
27187   ac_status=$?
27188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27189   (exit $ac_status); } &&
27190          { ac_try='test -s conftest$ac_exeext'
27191   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27192   (eval $ac_try) 2>&5
27193   ac_status=$?
27194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27195   (exit $ac_status); }; }; then
27196   ol_cv_db_db_2=yes
27197 else
27198   echo "$as_me: failed program was:" >&5
27199 sed 's/^/| /' conftest.$ac_ext >&5
27200
27201 ol_cv_db_db_2=no
27202 fi
27203 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27204
27205         LIBS="$ol_LIBS"
27206
27207 fi
27208 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
27209 echo "${ECHO_T}$ol_cv_db_db_2" >&6
27210
27211         if test $ol_cv_db_db_2 = yes ; then
27212                 ol_cv_lib_db=-ldb-2
27213         fi
27214 fi
27215
27216 if test $ol_cv_lib_db = no ; then
27217         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
27218 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
27219 if test "${ol_cv_db_db1+set}" = set; then
27220   echo $ECHO_N "(cached) $ECHO_C" >&6
27221 else
27222
27223         ol_DB_LIB=-ldb1
27224         ol_LIBS=$LIBS
27225         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27226
27227         cat >conftest.$ac_ext <<_ACEOF
27228 #line $LINENO "configure"
27229 /* confdefs.h.  */
27230 _ACEOF
27231 cat confdefs.h >>conftest.$ac_ext
27232 cat >>conftest.$ac_ext <<_ACEOF
27233 /* end confdefs.h.  */
27234
27235 #ifdef HAVE_DB_185_H
27236 # include <db_185.h>
27237 #else
27238 # include <db.h>
27239 #endif
27240
27241 #ifndef DB_VERSION_MAJOR
27242 # define DB_VERSION_MAJOR 1
27243 #endif
27244
27245 #ifndef NULL
27246 #define NULL ((void*)0)
27247 #endif
27248
27249 int
27250 main ()
27251 {
27252
27253 #if DB_VERSION_MAJOR > 1
27254         {
27255                 char *version;
27256                 int major, minor, patch;
27257
27258                 version = db_version( &major, &minor, &patch );
27259
27260                 if( major != DB_VERSION_MAJOR ||
27261                         minor < DB_VERSION_MINOR )
27262                 {
27263                         printf("Berkeley DB version mismatch\n"
27264                                 "\texpected: %s\n\tgot: %s\n",
27265                                 DB_VERSION_STRING, version);
27266                         return 1;
27267                 }
27268         }
27269 #endif
27270
27271 #if DB_VERSION_MAJOR > 2
27272         db_env_create( NULL, 0 );
27273 #elif DB_VERSION_MAJOR > 1
27274         db_appexit( NULL );
27275 #else
27276         (void) dbopen( NULL, 0, 0, 0, NULL);
27277 #endif
27278
27279   ;
27280   return 0;
27281 }
27282 _ACEOF
27283 rm -f conftest.$ac_objext conftest$ac_exeext
27284 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27285   (eval $ac_link) 2>&5
27286   ac_status=$?
27287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27288   (exit $ac_status); } &&
27289          { ac_try='test -s conftest$ac_exeext'
27290   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27291   (eval $ac_try) 2>&5
27292   ac_status=$?
27293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27294   (exit $ac_status); }; }; then
27295   ol_cv_db_db1=yes
27296 else
27297   echo "$as_me: failed program was:" >&5
27298 sed 's/^/| /' conftest.$ac_ext >&5
27299
27300 ol_cv_db_db1=no
27301 fi
27302 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27303
27304         LIBS="$ol_LIBS"
27305
27306 fi
27307 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
27308 echo "${ECHO_T}$ol_cv_db_db1" >&6
27309
27310         if test $ol_cv_db_db1 = yes ; then
27311                 ol_cv_lib_db=-ldb1
27312         fi
27313 fi
27314
27315 if test $ol_cv_lib_db = no ; then
27316         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
27317 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
27318 if test "${ol_cv_db_db_1+set}" = set; then
27319   echo $ECHO_N "(cached) $ECHO_C" >&6
27320 else
27321
27322         ol_DB_LIB=-ldb-1
27323         ol_LIBS=$LIBS
27324         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27325
27326         cat >conftest.$ac_ext <<_ACEOF
27327 #line $LINENO "configure"
27328 /* confdefs.h.  */
27329 _ACEOF
27330 cat confdefs.h >>conftest.$ac_ext
27331 cat >>conftest.$ac_ext <<_ACEOF
27332 /* end confdefs.h.  */
27333
27334 #ifdef HAVE_DB_185_H
27335 # include <db_185.h>
27336 #else
27337 # include <db.h>
27338 #endif
27339
27340 #ifndef DB_VERSION_MAJOR
27341 # define DB_VERSION_MAJOR 1
27342 #endif
27343
27344 #ifndef NULL
27345 #define NULL ((void*)0)
27346 #endif
27347
27348 int
27349 main ()
27350 {
27351
27352 #if DB_VERSION_MAJOR > 1
27353         {
27354                 char *version;
27355                 int major, minor, patch;
27356
27357                 version = db_version( &major, &minor, &patch );
27358
27359                 if( major != DB_VERSION_MAJOR ||
27360                         minor < DB_VERSION_MINOR )
27361                 {
27362                         printf("Berkeley DB version mismatch\n"
27363                                 "\texpected: %s\n\tgot: %s\n",
27364                                 DB_VERSION_STRING, version);
27365                         return 1;
27366                 }
27367         }
27368 #endif
27369
27370 #if DB_VERSION_MAJOR > 2
27371         db_env_create( NULL, 0 );
27372 #elif DB_VERSION_MAJOR > 1
27373         db_appexit( NULL );
27374 #else
27375         (void) dbopen( NULL, 0, 0, 0, NULL);
27376 #endif
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   ol_cv_db_db_1=yes
27395 else
27396   echo "$as_me: failed program was:" >&5
27397 sed 's/^/| /' conftest.$ac_ext >&5
27398
27399 ol_cv_db_db_1=no
27400 fi
27401 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27402
27403         LIBS="$ol_LIBS"
27404
27405 fi
27406 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
27407 echo "${ECHO_T}$ol_cv_db_db_1" >&6
27408
27409         if test $ol_cv_db_db_1 = yes ; then
27410                 ol_cv_lib_db=-ldb-1
27411         fi
27412 fi
27413
27414
27415         if test "$ol_cv_lib_db" != no ; then
27416                 ol_cv_berkeley_db=yes
27417                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
27418 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
27419 if test "${ol_cv_berkeley_db_thread+set}" = set; then
27420   echo $ECHO_N "(cached) $ECHO_C" >&6
27421 else
27422
27423         ol_LIBS="$LIBS"
27424         LIBS="$LTHREAD_LIBS $LIBS"
27425         if test $ol_cv_lib_db != yes ; then
27426                 LIBS="$ol_cv_lib_db $LIBS"
27427         fi
27428
27429         if test "$cross_compiling" = yes; then
27430   ol_cv_berkeley_db_thread=cross
27431 else
27432   cat >conftest.$ac_ext <<_ACEOF
27433 #line $LINENO "configure"
27434 /* confdefs.h.  */
27435 _ACEOF
27436 cat confdefs.h >>conftest.$ac_ext
27437 cat >>conftest.$ac_ext <<_ACEOF
27438 /* end confdefs.h.  */
27439
27440 #ifdef HAVE_DB_185_H
27441         choke me;
27442 #else
27443 #include <db.h>
27444 #endif
27445 #ifndef NULL
27446 #define NULL ((void *)0)
27447 #endif
27448 main()
27449 {
27450         int rc;
27451         u_int32_t flags = DB_CREATE |
27452 #ifdef DB_PRIVATE
27453                 DB_PRIVATE |
27454 #endif
27455                 DB_THREAD;
27456
27457 #if DB_VERSION_MAJOR > 2
27458         DB_ENV *env = NULL;
27459
27460         rc = db_env_create( &env, 0 );
27461
27462         flags |= DB_INIT_MPOOL;
27463 #ifdef DB_MPOOL_PRIVATE
27464         flags |= DB_MPOOL_PRIVATE;
27465 #endif
27466
27467         if( rc ) {
27468                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
27469                 return rc;
27470         }
27471
27472 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
27473         rc = env->open( env, NULL, flags, 0 );
27474 #else
27475         rc = env->open( env, NULL, NULL, flags, 0 );
27476 #endif
27477
27478         if ( rc == 0 ) {
27479                 rc = env->close( env, 0 );
27480         }
27481
27482         if( rc ) {
27483                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
27484                 return rc;
27485         }
27486
27487 #else
27488         DB_ENV env;
27489         memset( &env, '\0', sizeof(env) );
27490
27491         rc = db_appinit( NULL, NULL, &env, flags );
27492
27493         if( rc == 0 ) {
27494                 db_appexit( &env );
27495         }
27496
27497         unlink("__db_mpool.share");
27498         unlink("__db_lock.share");
27499 #endif
27500
27501         return rc;
27502 }
27503 _ACEOF
27504 rm -f conftest$ac_exeext
27505 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27506   (eval $ac_link) 2>&5
27507   ac_status=$?
27508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27509   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27511   (eval $ac_try) 2>&5
27512   ac_status=$?
27513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27514   (exit $ac_status); }; }; then
27515   ol_cv_berkeley_db_thread=yes
27516 else
27517   echo "$as_me: program exited with status $ac_status" >&5
27518 echo "$as_me: failed program was:" >&5
27519 sed 's/^/| /' conftest.$ac_ext >&5
27520
27521 ( exit $ac_status )
27522 ol_cv_berkeley_db_thread=no
27523 fi
27524 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27525 fi
27526
27527         LIBS="$ol_LIBS"
27528
27529 fi
27530 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
27531 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
27532
27533         if test $ol_cv_berkeley_db_thread != no ; then
27534
27535 cat >>confdefs.h <<\_ACEOF
27536 #define HAVE_BERKELEY_DB_THREAD 1
27537 _ACEOF
27538
27539         fi
27540
27541         fi
27542 fi
27543
27544         fi
27545
27546         if test $ol_cv_berkeley_db != no ; then
27547
27548 cat >>confdefs.h <<\_ACEOF
27549 #define HAVE_BERKELEY_DB 1
27550 _ACEOF
27551
27552
27553                 ol_link_ldbm=berkeley
27554                 ol_with_ldbm_api=berkeley
27555
27556                 if test $ol_with_ldbm_type = hash ; then
27557
27558 cat >>confdefs.h <<\_ACEOF
27559 #define LDBM_USE_DBHASH 1
27560 _ACEOF
27561
27562                 else
27563
27564 cat >>confdefs.h <<\_ACEOF
27565 #define LDBM_USE_DBBTREE 1
27566 _ACEOF
27567
27568                 fi
27569
27570                                                 if test $ol_cv_lib_db != yes ; then
27571                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_db"
27572                 fi
27573         fi
27574 fi
27575
27576 if test $ol_enable_bdb = yes -a $ol_link_ldbm != berkeley ; then
27577         { { echo "$as_me:$LINENO: error: BDB: BerkeleyDB not available" >&5
27578 echo "$as_me: error: BDB: BerkeleyDB not available" >&2;}
27579    { (exit 1); exit 1; }; }
27580 elif test $ol_enable_bdb != no -a $ol_link_ldbm = berkeley ; then
27581         echo "$as_me:$LINENO: checking Berkeley DB version for BDB backend" >&5
27582 echo $ECHO_N "checking Berkeley DB version for BDB backend... $ECHO_C" >&6
27583 if test "${ol_cv_bdb_compat+set}" = set; then
27584   echo $ECHO_N "(cached) $ECHO_C" >&6
27585 else
27586
27587         cat >conftest.$ac_ext <<_ACEOF
27588 #line $LINENO "configure"
27589 /* confdefs.h.  */
27590 _ACEOF
27591 cat confdefs.h >>conftest.$ac_ext
27592 cat >>conftest.$ac_ext <<_ACEOF
27593 /* end confdefs.h.  */
27594
27595 #include <db.h>
27596
27597  /* this check could be improved */
27598 #ifndef DB_VERSION_MAJOR
27599 #       define DB_VERSION_MAJOR 1
27600 #endif
27601 #ifndef DB_VERSION_MINOR
27602 #       define DB_VERSION_MINOR 0
27603 #endif
27604
27605 /* require 4.1 or later */
27606 #if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 1)
27607         __db_version_compat
27608 #endif
27609
27610 _ACEOF
27611 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27612   $EGREP "__db_version_compat" >/dev/null 2>&1; then
27613   ol_cv_bdb_compat=yes
27614 else
27615   ol_cv_bdb_compat=no
27616 fi
27617 rm -f conftest*
27618
27619 fi
27620 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
27621 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
27622
27623
27624         if test $ol_cv_bdb_compat = yes ; then
27625                 ol_enable_bdb=yes
27626         elif test $ol_enable_bdb = yes ; then
27627                 { { echo "$as_me:$LINENO: error: BDB: BerkeleyDB version incompatible" >&5
27628 echo "$as_me: error: BDB: BerkeleyDB version incompatible" >&2;}
27629    { (exit 1); exit 1; }; }
27630         else
27631                 ol_enable_bdb=no
27632         fi
27633 fi
27634
27635 if test $ol_link_ldbm = no -a $ol_with_ldbm_type = btree ; then
27636         { echo "$as_me:$LINENO: WARNING: Could not find LDBM with BTREE support" >&5
27637 echo "$as_me: WARNING: Could not find LDBM with BTREE support" >&2;}
27638         ol_with_ldbm_api=none
27639 fi
27640
27641 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = mdbm ; then
27642         echo "$as_me:$LINENO: checking for MDBM library" >&5
27643 echo $ECHO_N "checking for MDBM library... $ECHO_C" >&6
27644 if test "${ol_cv_lib_mdbm+set}" = set; then
27645   echo $ECHO_N "(cached) $ECHO_C" >&6
27646 else
27647         ol_LIBS="$LIBS"
27648         echo "$as_me:$LINENO: checking for mdbm_set_chain" >&5
27649 echo $ECHO_N "checking for mdbm_set_chain... $ECHO_C" >&6
27650 if test "${ac_cv_func_mdbm_set_chain+set}" = set; then
27651   echo $ECHO_N "(cached) $ECHO_C" >&6
27652 else
27653   cat >conftest.$ac_ext <<_ACEOF
27654 #line $LINENO "configure"
27655 /* confdefs.h.  */
27656 _ACEOF
27657 cat confdefs.h >>conftest.$ac_ext
27658 cat >>conftest.$ac_ext <<_ACEOF
27659 /* end confdefs.h.  */
27660 /* System header to define __stub macros and hopefully few prototypes,
27661     which can conflict with char mdbm_set_chain (); below.
27662     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
27663     <limits.h> exists even on freestanding compilers.  */
27664 #ifdef __STDC__
27665 # include <limits.h>
27666 #else
27667 # include <assert.h>
27668 #endif
27669 /* Override any gcc2 internal prototype to avoid an error.  */
27670 #ifdef __cplusplus
27671 extern "C"
27672 {
27673 #endif
27674 /* We use char because int might match the return type of a gcc2
27675    builtin and then its argument prototype would still apply.  */
27676 char mdbm_set_chain ();
27677 /* The GNU C library defines this for functions which it implements
27678     to always fail with ENOSYS.  Some functions are actually named
27679     something starting with __ and the normal name is an alias.  */
27680 #if defined (__stub_mdbm_set_chain) || defined (__stub___mdbm_set_chain)
27681 choke me
27682 #else
27683 char (*f) () = mdbm_set_chain;
27684 #endif
27685 #ifdef __cplusplus
27686 }
27687 #endif
27688
27689 int
27690 main ()
27691 {
27692 return f != mdbm_set_chain;
27693   ;
27694   return 0;
27695 }
27696 _ACEOF
27697 rm -f conftest.$ac_objext conftest$ac_exeext
27698 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27699   (eval $ac_link) 2>&5
27700   ac_status=$?
27701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27702   (exit $ac_status); } &&
27703          { ac_try='test -s conftest$ac_exeext'
27704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27705   (eval $ac_try) 2>&5
27706   ac_status=$?
27707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27708   (exit $ac_status); }; }; then
27709   ac_cv_func_mdbm_set_chain=yes
27710 else
27711   echo "$as_me: failed program was:" >&5
27712 sed 's/^/| /' conftest.$ac_ext >&5
27713
27714 ac_cv_func_mdbm_set_chain=no
27715 fi
27716 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27717 fi
27718 echo "$as_me:$LINENO: result: $ac_cv_func_mdbm_set_chain" >&5
27719 echo "${ECHO_T}$ac_cv_func_mdbm_set_chain" >&6
27720 if test $ac_cv_func_mdbm_set_chain = yes; then
27721   ol_cv_lib_mdbm=yes
27722 else
27723
27724                 echo "$as_me:$LINENO: checking for mdbm_set_chain in -lmdbm" >&5
27725 echo $ECHO_N "checking for mdbm_set_chain in -lmdbm... $ECHO_C" >&6
27726 if test "${ac_cv_lib_mdbm_mdbm_set_chain+set}" = set; then
27727   echo $ECHO_N "(cached) $ECHO_C" >&6
27728 else
27729   ac_check_lib_save_LIBS=$LIBS
27730 LIBS="-lmdbm  $LIBS"
27731 cat >conftest.$ac_ext <<_ACEOF
27732 #line $LINENO "configure"
27733 /* confdefs.h.  */
27734 _ACEOF
27735 cat confdefs.h >>conftest.$ac_ext
27736 cat >>conftest.$ac_ext <<_ACEOF
27737 /* end confdefs.h.  */
27738
27739 /* Override any gcc2 internal prototype to avoid an error.  */
27740 #ifdef __cplusplus
27741 extern "C"
27742 #endif
27743 /* We use char because int might match the return type of a gcc2
27744    builtin and then its argument prototype would still apply.  */
27745 char mdbm_set_chain ();
27746 int
27747 main ()
27748 {
27749 mdbm_set_chain ();
27750   ;
27751   return 0;
27752 }
27753 _ACEOF
27754 rm -f conftest.$ac_objext conftest$ac_exeext
27755 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27756   (eval $ac_link) 2>&5
27757   ac_status=$?
27758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27759   (exit $ac_status); } &&
27760          { ac_try='test -s conftest$ac_exeext'
27761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27762   (eval $ac_try) 2>&5
27763   ac_status=$?
27764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27765   (exit $ac_status); }; }; then
27766   ac_cv_lib_mdbm_mdbm_set_chain=yes
27767 else
27768   echo "$as_me: failed program was:" >&5
27769 sed 's/^/| /' conftest.$ac_ext >&5
27770
27771 ac_cv_lib_mdbm_mdbm_set_chain=no
27772 fi
27773 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27774 LIBS=$ac_check_lib_save_LIBS
27775 fi
27776 echo "$as_me:$LINENO: result: $ac_cv_lib_mdbm_mdbm_set_chain" >&5
27777 echo "${ECHO_T}$ac_cv_lib_mdbm_mdbm_set_chain" >&6
27778 if test $ac_cv_lib_mdbm_mdbm_set_chain = yes; then
27779   ol_cv_lib_mdbm=-lmdbm
27780 else
27781   ol_cv_lib_mdbm=no
27782 fi
27783
27784
27785 fi
27786
27787         LIBS="$ol_LIBS"
27788
27789 fi
27790 echo "$as_me:$LINENO: result: $ol_cv_lib_mdbm" >&5
27791 echo "${ECHO_T}$ol_cv_lib_mdbm" >&6
27792
27793
27794
27795 for ac_header in mdbm.h
27796 do
27797 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27798 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27799   echo "$as_me:$LINENO: checking for $ac_header" >&5
27800 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27801 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27802   echo $ECHO_N "(cached) $ECHO_C" >&6
27803 fi
27804 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27805 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27806 else
27807   # Is the header compilable?
27808 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27809 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27810 cat >conftest.$ac_ext <<_ACEOF
27811 #line $LINENO "configure"
27812 /* confdefs.h.  */
27813 _ACEOF
27814 cat confdefs.h >>conftest.$ac_ext
27815 cat >>conftest.$ac_ext <<_ACEOF
27816 /* end confdefs.h.  */
27817 $ac_includes_default
27818 #include <$ac_header>
27819 _ACEOF
27820 rm -f conftest.$ac_objext
27821 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27822   (eval $ac_compile) 2>&5
27823   ac_status=$?
27824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27825   (exit $ac_status); } &&
27826          { ac_try='test -s conftest.$ac_objext'
27827   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27828   (eval $ac_try) 2>&5
27829   ac_status=$?
27830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27831   (exit $ac_status); }; }; then
27832   ac_header_compiler=yes
27833 else
27834   echo "$as_me: failed program was:" >&5
27835 sed 's/^/| /' conftest.$ac_ext >&5
27836
27837 ac_header_compiler=no
27838 fi
27839 rm -f conftest.$ac_objext conftest.$ac_ext
27840 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27841 echo "${ECHO_T}$ac_header_compiler" >&6
27842
27843 # Is the header present?
27844 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27845 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27846 cat >conftest.$ac_ext <<_ACEOF
27847 #line $LINENO "configure"
27848 /* confdefs.h.  */
27849 _ACEOF
27850 cat confdefs.h >>conftest.$ac_ext
27851 cat >>conftest.$ac_ext <<_ACEOF
27852 /* end confdefs.h.  */
27853 #include <$ac_header>
27854 _ACEOF
27855 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27856   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27857   ac_status=$?
27858   grep -v '^ *+' conftest.er1 >conftest.err
27859   rm -f conftest.er1
27860   cat conftest.err >&5
27861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27862   (exit $ac_status); } >/dev/null; then
27863   if test -s conftest.err; then
27864     ac_cpp_err=$ac_c_preproc_warn_flag
27865   else
27866     ac_cpp_err=
27867   fi
27868 else
27869   ac_cpp_err=yes
27870 fi
27871 if test -z "$ac_cpp_err"; then
27872   ac_header_preproc=yes
27873 else
27874   echo "$as_me: failed program was:" >&5
27875 sed 's/^/| /' conftest.$ac_ext >&5
27876
27877   ac_header_preproc=no
27878 fi
27879 rm -f conftest.err conftest.$ac_ext
27880 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27881 echo "${ECHO_T}$ac_header_preproc" >&6
27882
27883 # So?  What about this header?
27884 case $ac_header_compiler:$ac_header_preproc in
27885   yes:no )
27886     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27887 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27888     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27889 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27890     (
27891       cat <<\_ASBOX
27892 ## ------------------------------------ ##
27893 ## Report this to bug-autoconf@gnu.org. ##
27894 ## ------------------------------------ ##
27895 _ASBOX
27896     ) |
27897       sed "s/^/$as_me: WARNING:     /" >&2
27898     ;;
27899   no:yes )
27900     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27901 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27902     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
27903 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
27904     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27905 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27906     (
27907       cat <<\_ASBOX
27908 ## ------------------------------------ ##
27909 ## Report this to bug-autoconf@gnu.org. ##
27910 ## ------------------------------------ ##
27911 _ASBOX
27912     ) |
27913       sed "s/^/$as_me: WARNING:     /" >&2
27914     ;;
27915 esac
27916 echo "$as_me:$LINENO: checking for $ac_header" >&5
27917 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27918 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27919   echo $ECHO_N "(cached) $ECHO_C" >&6
27920 else
27921   eval "$as_ac_Header=$ac_header_preproc"
27922 fi
27923 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27924 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27925
27926 fi
27927 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27928   cat >>confdefs.h <<_ACEOF
27929 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27930 _ACEOF
27931
27932 fi
27933
27934 done
27935
27936  echo "$as_me:$LINENO: checking for db" >&5
27937 echo $ECHO_N "checking for db... $ECHO_C" >&6
27938 if test "${ol_cv_mdbm+set}" = set; then
27939   echo $ECHO_N "(cached) $ECHO_C" >&6
27940 else
27941
27942         if test $ol_cv_lib_mdbm = no -o $ac_cv_header_mdbm_h = no ; then
27943                 ol_cv_mdbm=no
27944         else
27945                 ol_cv_mdbm=yes
27946         fi
27947
27948 fi
27949 echo "$as_me:$LINENO: result: $ol_cv_mdbm" >&5
27950 echo "${ECHO_T}$ol_cv_mdbm" >&6
27951  if test $ol_cv_mdbm = yes ; then
27952
27953 cat >>confdefs.h <<\_ACEOF
27954 #define HAVE_MDBM 1
27955 _ACEOF
27956
27957  fi
27958
27959
27960         if test $ol_cv_mdbm = yes ; then
27961                 ol_link_ldbm=mdbm
27962                 ol_with_ldbm_api=mdbm
27963                 if test $ol_cv_lib_mdbm != yes ; then
27964                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_mdbm"
27965                 fi
27966         fi
27967 fi
27968
27969 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = gdbm ; then
27970         echo "$as_me:$LINENO: checking for GDBM library" >&5
27971 echo $ECHO_N "checking for GDBM library... $ECHO_C" >&6
27972 if test "${ol_cv_lib_gdbm+set}" = set; then
27973   echo $ECHO_N "(cached) $ECHO_C" >&6
27974 else
27975         ol_LIBS="$LIBS"
27976         echo "$as_me:$LINENO: checking for gdbm_open" >&5
27977 echo $ECHO_N "checking for gdbm_open... $ECHO_C" >&6
27978 if test "${ac_cv_func_gdbm_open+set}" = set; then
27979   echo $ECHO_N "(cached) $ECHO_C" >&6
27980 else
27981   cat >conftest.$ac_ext <<_ACEOF
27982 #line $LINENO "configure"
27983 /* confdefs.h.  */
27984 _ACEOF
27985 cat confdefs.h >>conftest.$ac_ext
27986 cat >>conftest.$ac_ext <<_ACEOF
27987 /* end confdefs.h.  */
27988 /* System header to define __stub macros and hopefully few prototypes,
27989     which can conflict with char gdbm_open (); below.
27990     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
27991     <limits.h> exists even on freestanding compilers.  */
27992 #ifdef __STDC__
27993 # include <limits.h>
27994 #else
27995 # include <assert.h>
27996 #endif
27997 /* Override any gcc2 internal prototype to avoid an error.  */
27998 #ifdef __cplusplus
27999 extern "C"
28000 {
28001 #endif
28002 /* We use char because int might match the return type of a gcc2
28003    builtin and then its argument prototype would still apply.  */
28004 char gdbm_open ();
28005 /* The GNU C library defines this for functions which it implements
28006     to always fail with ENOSYS.  Some functions are actually named
28007     something starting with __ and the normal name is an alias.  */
28008 #if defined (__stub_gdbm_open) || defined (__stub___gdbm_open)
28009 choke me
28010 #else
28011 char (*f) () = gdbm_open;
28012 #endif
28013 #ifdef __cplusplus
28014 }
28015 #endif
28016
28017 int
28018 main ()
28019 {
28020 return f != gdbm_open;
28021   ;
28022   return 0;
28023 }
28024 _ACEOF
28025 rm -f conftest.$ac_objext conftest$ac_exeext
28026 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28027   (eval $ac_link) 2>&5
28028   ac_status=$?
28029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28030   (exit $ac_status); } &&
28031          { ac_try='test -s conftest$ac_exeext'
28032   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28033   (eval $ac_try) 2>&5
28034   ac_status=$?
28035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28036   (exit $ac_status); }; }; then
28037   ac_cv_func_gdbm_open=yes
28038 else
28039   echo "$as_me: failed program was:" >&5
28040 sed 's/^/| /' conftest.$ac_ext >&5
28041
28042 ac_cv_func_gdbm_open=no
28043 fi
28044 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28045 fi
28046 echo "$as_me:$LINENO: result: $ac_cv_func_gdbm_open" >&5
28047 echo "${ECHO_T}$ac_cv_func_gdbm_open" >&6
28048 if test $ac_cv_func_gdbm_open = yes; then
28049   ol_cv_lib_gdbm=yes
28050 else
28051
28052                 echo "$as_me:$LINENO: checking for gdbm_open in -lgdbm" >&5
28053 echo $ECHO_N "checking for gdbm_open in -lgdbm... $ECHO_C" >&6
28054 if test "${ac_cv_lib_gdbm_gdbm_open+set}" = set; then
28055   echo $ECHO_N "(cached) $ECHO_C" >&6
28056 else
28057   ac_check_lib_save_LIBS=$LIBS
28058 LIBS="-lgdbm  $LIBS"
28059 cat >conftest.$ac_ext <<_ACEOF
28060 #line $LINENO "configure"
28061 /* confdefs.h.  */
28062 _ACEOF
28063 cat confdefs.h >>conftest.$ac_ext
28064 cat >>conftest.$ac_ext <<_ACEOF
28065 /* end confdefs.h.  */
28066
28067 /* Override any gcc2 internal prototype to avoid an error.  */
28068 #ifdef __cplusplus
28069 extern "C"
28070 #endif
28071 /* We use char because int might match the return type of a gcc2
28072    builtin and then its argument prototype would still apply.  */
28073 char gdbm_open ();
28074 int
28075 main ()
28076 {
28077 gdbm_open ();
28078   ;
28079   return 0;
28080 }
28081 _ACEOF
28082 rm -f conftest.$ac_objext conftest$ac_exeext
28083 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28084   (eval $ac_link) 2>&5
28085   ac_status=$?
28086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28087   (exit $ac_status); } &&
28088          { ac_try='test -s conftest$ac_exeext'
28089   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28090   (eval $ac_try) 2>&5
28091   ac_status=$?
28092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28093   (exit $ac_status); }; }; then
28094   ac_cv_lib_gdbm_gdbm_open=yes
28095 else
28096   echo "$as_me: failed program was:" >&5
28097 sed 's/^/| /' conftest.$ac_ext >&5
28098
28099 ac_cv_lib_gdbm_gdbm_open=no
28100 fi
28101 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28102 LIBS=$ac_check_lib_save_LIBS
28103 fi
28104 echo "$as_me:$LINENO: result: $ac_cv_lib_gdbm_gdbm_open" >&5
28105 echo "${ECHO_T}$ac_cv_lib_gdbm_gdbm_open" >&6
28106 if test $ac_cv_lib_gdbm_gdbm_open = yes; then
28107   ol_cv_lib_gdbm=-lgdbm
28108 else
28109   ol_cv_lib_gdbm=no
28110 fi
28111
28112
28113 fi
28114
28115         LIBS="$ol_LIBS"
28116
28117 fi
28118 echo "$as_me:$LINENO: result: $ol_cv_lib_gdbm" >&5
28119 echo "${ECHO_T}$ol_cv_lib_gdbm" >&6
28120
28121
28122
28123 for ac_header in gdbm.h
28124 do
28125 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28126 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28127   echo "$as_me:$LINENO: checking for $ac_header" >&5
28128 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28129 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28130   echo $ECHO_N "(cached) $ECHO_C" >&6
28131 fi
28132 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28133 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28134 else
28135   # Is the header compilable?
28136 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28137 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28138 cat >conftest.$ac_ext <<_ACEOF
28139 #line $LINENO "configure"
28140 /* confdefs.h.  */
28141 _ACEOF
28142 cat confdefs.h >>conftest.$ac_ext
28143 cat >>conftest.$ac_ext <<_ACEOF
28144 /* end confdefs.h.  */
28145 $ac_includes_default
28146 #include <$ac_header>
28147 _ACEOF
28148 rm -f conftest.$ac_objext
28149 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28150   (eval $ac_compile) 2>&5
28151   ac_status=$?
28152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28153   (exit $ac_status); } &&
28154          { ac_try='test -s conftest.$ac_objext'
28155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28156   (eval $ac_try) 2>&5
28157   ac_status=$?
28158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28159   (exit $ac_status); }; }; then
28160   ac_header_compiler=yes
28161 else
28162   echo "$as_me: failed program was:" >&5
28163 sed 's/^/| /' conftest.$ac_ext >&5
28164
28165 ac_header_compiler=no
28166 fi
28167 rm -f conftest.$ac_objext conftest.$ac_ext
28168 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28169 echo "${ECHO_T}$ac_header_compiler" >&6
28170
28171 # Is the header present?
28172 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28173 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28174 cat >conftest.$ac_ext <<_ACEOF
28175 #line $LINENO "configure"
28176 /* confdefs.h.  */
28177 _ACEOF
28178 cat confdefs.h >>conftest.$ac_ext
28179 cat >>conftest.$ac_ext <<_ACEOF
28180 /* end confdefs.h.  */
28181 #include <$ac_header>
28182 _ACEOF
28183 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28184   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28185   ac_status=$?
28186   grep -v '^ *+' conftest.er1 >conftest.err
28187   rm -f conftest.er1
28188   cat conftest.err >&5
28189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28190   (exit $ac_status); } >/dev/null; then
28191   if test -s conftest.err; then
28192     ac_cpp_err=$ac_c_preproc_warn_flag
28193   else
28194     ac_cpp_err=
28195   fi
28196 else
28197   ac_cpp_err=yes
28198 fi
28199 if test -z "$ac_cpp_err"; then
28200   ac_header_preproc=yes
28201 else
28202   echo "$as_me: failed program was:" >&5
28203 sed 's/^/| /' conftest.$ac_ext >&5
28204
28205   ac_header_preproc=no
28206 fi
28207 rm -f conftest.err conftest.$ac_ext
28208 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28209 echo "${ECHO_T}$ac_header_preproc" >&6
28210
28211 # So?  What about this header?
28212 case $ac_header_compiler:$ac_header_preproc in
28213   yes:no )
28214     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
28215 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
28216     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28217 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28218     (
28219       cat <<\_ASBOX
28220 ## ------------------------------------ ##
28221 ## Report this to bug-autoconf@gnu.org. ##
28222 ## ------------------------------------ ##
28223 _ASBOX
28224     ) |
28225       sed "s/^/$as_me: WARNING:     /" >&2
28226     ;;
28227   no:yes )
28228     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
28229 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
28230     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
28231 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
28232     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28233 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28234     (
28235       cat <<\_ASBOX
28236 ## ------------------------------------ ##
28237 ## Report this to bug-autoconf@gnu.org. ##
28238 ## ------------------------------------ ##
28239 _ASBOX
28240     ) |
28241       sed "s/^/$as_me: WARNING:     /" >&2
28242     ;;
28243 esac
28244 echo "$as_me:$LINENO: checking for $ac_header" >&5
28245 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28246 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28247   echo $ECHO_N "(cached) $ECHO_C" >&6
28248 else
28249   eval "$as_ac_Header=$ac_header_preproc"
28250 fi
28251 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28252 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28253
28254 fi
28255 if test `eval echo '${'$as_ac_Header'}'` = yes; then
28256   cat >>confdefs.h <<_ACEOF
28257 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
28258 _ACEOF
28259
28260 fi
28261
28262 done
28263
28264  echo "$as_me:$LINENO: checking for db" >&5
28265 echo $ECHO_N "checking for db... $ECHO_C" >&6
28266 if test "${ol_cv_gdbm+set}" = set; then
28267   echo $ECHO_N "(cached) $ECHO_C" >&6
28268 else
28269
28270         if test $ol_cv_lib_gdbm = no -o $ac_cv_header_gdbm_h = no ; then
28271                 ol_cv_gdbm=no
28272         else
28273                 ol_cv_gdbm=yes
28274         fi
28275
28276 fi
28277 echo "$as_me:$LINENO: result: $ol_cv_gdbm" >&5
28278 echo "${ECHO_T}$ol_cv_gdbm" >&6
28279  if test $ol_cv_gdbm = yes ; then
28280
28281 cat >>confdefs.h <<\_ACEOF
28282 #define HAVE_GDBM 1
28283 _ACEOF
28284
28285  fi
28286
28287
28288         if test $ol_cv_gdbm = yes ; then
28289                 ol_link_ldbm=gdbm
28290                 ol_with_ldbm_api=gdbm
28291
28292                 if test $ol_cv_lib_gdbm != yes ; then
28293                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_gdbm"
28294                 fi
28295         fi
28296 fi
28297
28298 if test $ol_with_ldbm_api = ndbm ; then
28299         echo "$as_me:$LINENO: checking for NDBM library" >&5
28300 echo $ECHO_N "checking for NDBM library... $ECHO_C" >&6
28301 if test "${ol_cv_lib_ndbm+set}" = set; then
28302   echo $ECHO_N "(cached) $ECHO_C" >&6
28303 else
28304         ol_LIBS="$LIBS"
28305         echo "$as_me:$LINENO: checking for dbm_open" >&5
28306 echo $ECHO_N "checking for dbm_open... $ECHO_C" >&6
28307 if test "${ac_cv_func_dbm_open+set}" = set; then
28308   echo $ECHO_N "(cached) $ECHO_C" >&6
28309 else
28310   cat >conftest.$ac_ext <<_ACEOF
28311 #line $LINENO "configure"
28312 /* confdefs.h.  */
28313 _ACEOF
28314 cat confdefs.h >>conftest.$ac_ext
28315 cat >>conftest.$ac_ext <<_ACEOF
28316 /* end confdefs.h.  */
28317 /* System header to define __stub macros and hopefully few prototypes,
28318     which can conflict with char dbm_open (); below.
28319     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
28320     <limits.h> exists even on freestanding compilers.  */
28321 #ifdef __STDC__
28322 # include <limits.h>
28323 #else
28324 # include <assert.h>
28325 #endif
28326 /* Override any gcc2 internal prototype to avoid an error.  */
28327 #ifdef __cplusplus
28328 extern "C"
28329 {
28330 #endif
28331 /* We use char because int might match the return type of a gcc2
28332    builtin and then its argument prototype would still apply.  */
28333 char dbm_open ();
28334 /* The GNU C library defines this for functions which it implements
28335     to always fail with ENOSYS.  Some functions are actually named
28336     something starting with __ and the normal name is an alias.  */
28337 #if defined (__stub_dbm_open) || defined (__stub___dbm_open)
28338 choke me
28339 #else
28340 char (*f) () = dbm_open;
28341 #endif
28342 #ifdef __cplusplus
28343 }
28344 #endif
28345
28346 int
28347 main ()
28348 {
28349 return f != dbm_open;
28350   ;
28351   return 0;
28352 }
28353 _ACEOF
28354 rm -f conftest.$ac_objext conftest$ac_exeext
28355 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28356   (eval $ac_link) 2>&5
28357   ac_status=$?
28358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28359   (exit $ac_status); } &&
28360          { ac_try='test -s conftest$ac_exeext'
28361   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28362   (eval $ac_try) 2>&5
28363   ac_status=$?
28364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28365   (exit $ac_status); }; }; then
28366   ac_cv_func_dbm_open=yes
28367 else
28368   echo "$as_me: failed program was:" >&5
28369 sed 's/^/| /' conftest.$ac_ext >&5
28370
28371 ac_cv_func_dbm_open=no
28372 fi
28373 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28374 fi
28375 echo "$as_me:$LINENO: result: $ac_cv_func_dbm_open" >&5
28376 echo "${ECHO_T}$ac_cv_func_dbm_open" >&6
28377 if test $ac_cv_func_dbm_open = yes; then
28378   ol_cv_lib_ndbm=yes
28379 else
28380
28381                 echo "$as_me:$LINENO: checking for dbm_open in -lndbm" >&5
28382 echo $ECHO_N "checking for dbm_open in -lndbm... $ECHO_C" >&6
28383 if test "${ac_cv_lib_ndbm_dbm_open+set}" = set; then
28384   echo $ECHO_N "(cached) $ECHO_C" >&6
28385 else
28386   ac_check_lib_save_LIBS=$LIBS
28387 LIBS="-lndbm  $LIBS"
28388 cat >conftest.$ac_ext <<_ACEOF
28389 #line $LINENO "configure"
28390 /* confdefs.h.  */
28391 _ACEOF
28392 cat confdefs.h >>conftest.$ac_ext
28393 cat >>conftest.$ac_ext <<_ACEOF
28394 /* end confdefs.h.  */
28395
28396 /* Override any gcc2 internal prototype to avoid an error.  */
28397 #ifdef __cplusplus
28398 extern "C"
28399 #endif
28400 /* We use char because int might match the return type of a gcc2
28401    builtin and then its argument prototype would still apply.  */
28402 char dbm_open ();
28403 int
28404 main ()
28405 {
28406 dbm_open ();
28407   ;
28408   return 0;
28409 }
28410 _ACEOF
28411 rm -f conftest.$ac_objext conftest$ac_exeext
28412 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28413   (eval $ac_link) 2>&5
28414   ac_status=$?
28415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28416   (exit $ac_status); } &&
28417          { ac_try='test -s conftest$ac_exeext'
28418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28419   (eval $ac_try) 2>&5
28420   ac_status=$?
28421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28422   (exit $ac_status); }; }; then
28423   ac_cv_lib_ndbm_dbm_open=yes
28424 else
28425   echo "$as_me: failed program was:" >&5
28426 sed 's/^/| /' conftest.$ac_ext >&5
28427
28428 ac_cv_lib_ndbm_dbm_open=no
28429 fi
28430 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28431 LIBS=$ac_check_lib_save_LIBS
28432 fi
28433 echo "$as_me:$LINENO: result: $ac_cv_lib_ndbm_dbm_open" >&5
28434 echo "${ECHO_T}$ac_cv_lib_ndbm_dbm_open" >&6
28435 if test $ac_cv_lib_ndbm_dbm_open = yes; then
28436   ol_cv_lib_ndbm=-lndbm
28437 else
28438
28439                         echo "$as_me:$LINENO: checking for dbm_open in -ldbm" >&5
28440 echo $ECHO_N "checking for dbm_open in -ldbm... $ECHO_C" >&6
28441 if test "${ac_cv_lib_dbm_dbm_open+set}" = set; then
28442   echo $ECHO_N "(cached) $ECHO_C" >&6
28443 else
28444   ac_check_lib_save_LIBS=$LIBS
28445 LIBS="-ldbm  $LIBS"
28446 cat >conftest.$ac_ext <<_ACEOF
28447 #line $LINENO "configure"
28448 /* confdefs.h.  */
28449 _ACEOF
28450 cat confdefs.h >>conftest.$ac_ext
28451 cat >>conftest.$ac_ext <<_ACEOF
28452 /* end confdefs.h.  */
28453
28454 /* Override any gcc2 internal prototype to avoid an error.  */
28455 #ifdef __cplusplus
28456 extern "C"
28457 #endif
28458 /* We use char because int might match the return type of a gcc2
28459    builtin and then its argument prototype would still apply.  */
28460 char dbm_open ();
28461 int
28462 main ()
28463 {
28464 dbm_open ();
28465   ;
28466   return 0;
28467 }
28468 _ACEOF
28469 rm -f conftest.$ac_objext conftest$ac_exeext
28470 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28471   (eval $ac_link) 2>&5
28472   ac_status=$?
28473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28474   (exit $ac_status); } &&
28475          { ac_try='test -s conftest$ac_exeext'
28476   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28477   (eval $ac_try) 2>&5
28478   ac_status=$?
28479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28480   (exit $ac_status); }; }; then
28481   ac_cv_lib_dbm_dbm_open=yes
28482 else
28483   echo "$as_me: failed program was:" >&5
28484 sed 's/^/| /' conftest.$ac_ext >&5
28485
28486 ac_cv_lib_dbm_dbm_open=no
28487 fi
28488 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28489 LIBS=$ac_check_lib_save_LIBS
28490 fi
28491 echo "$as_me:$LINENO: result: $ac_cv_lib_dbm_dbm_open" >&5
28492 echo "${ECHO_T}$ac_cv_lib_dbm_dbm_open" >&6
28493 if test $ac_cv_lib_dbm_dbm_open = yes; then
28494   ol_cv_lib_ndbm=-ldbm
28495 else
28496   ol_cv_lib_ndbm=no
28497 fi
28498
28499 fi
28500
28501
28502 fi
28503
28504         LIBS="$ol_LIBS"
28505
28506 fi
28507 echo "$as_me:$LINENO: result: $ol_cv_lib_ndbm" >&5
28508 echo "${ECHO_T}$ol_cv_lib_ndbm" >&6
28509
28510
28511
28512 for ac_header in ndbm.h
28513 do
28514 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28515 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28516   echo "$as_me:$LINENO: checking for $ac_header" >&5
28517 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28518 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28519   echo $ECHO_N "(cached) $ECHO_C" >&6
28520 fi
28521 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28522 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28523 else
28524   # Is the header compilable?
28525 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28526 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28527 cat >conftest.$ac_ext <<_ACEOF
28528 #line $LINENO "configure"
28529 /* confdefs.h.  */
28530 _ACEOF
28531 cat confdefs.h >>conftest.$ac_ext
28532 cat >>conftest.$ac_ext <<_ACEOF
28533 /* end confdefs.h.  */
28534 $ac_includes_default
28535 #include <$ac_header>
28536 _ACEOF
28537 rm -f conftest.$ac_objext
28538 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28539   (eval $ac_compile) 2>&5
28540   ac_status=$?
28541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28542   (exit $ac_status); } &&
28543          { ac_try='test -s conftest.$ac_objext'
28544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28545   (eval $ac_try) 2>&5
28546   ac_status=$?
28547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28548   (exit $ac_status); }; }; then
28549   ac_header_compiler=yes
28550 else
28551   echo "$as_me: failed program was:" >&5
28552 sed 's/^/| /' conftest.$ac_ext >&5
28553
28554 ac_header_compiler=no
28555 fi
28556 rm -f conftest.$ac_objext conftest.$ac_ext
28557 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28558 echo "${ECHO_T}$ac_header_compiler" >&6
28559
28560 # Is the header present?
28561 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28562 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28563 cat >conftest.$ac_ext <<_ACEOF
28564 #line $LINENO "configure"
28565 /* confdefs.h.  */
28566 _ACEOF
28567 cat confdefs.h >>conftest.$ac_ext
28568 cat >>conftest.$ac_ext <<_ACEOF
28569 /* end confdefs.h.  */
28570 #include <$ac_header>
28571 _ACEOF
28572 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28573   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28574   ac_status=$?
28575   grep -v '^ *+' conftest.er1 >conftest.err
28576   rm -f conftest.er1
28577   cat conftest.err >&5
28578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28579   (exit $ac_status); } >/dev/null; then
28580   if test -s conftest.err; then
28581     ac_cpp_err=$ac_c_preproc_warn_flag
28582   else
28583     ac_cpp_err=
28584   fi
28585 else
28586   ac_cpp_err=yes
28587 fi
28588 if test -z "$ac_cpp_err"; then
28589   ac_header_preproc=yes
28590 else
28591   echo "$as_me: failed program was:" >&5
28592 sed 's/^/| /' conftest.$ac_ext >&5
28593
28594   ac_header_preproc=no
28595 fi
28596 rm -f conftest.err conftest.$ac_ext
28597 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28598 echo "${ECHO_T}$ac_header_preproc" >&6
28599
28600 # So?  What about this header?
28601 case $ac_header_compiler:$ac_header_preproc in
28602   yes:no )
28603     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
28604 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
28605     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28606 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28607     (
28608       cat <<\_ASBOX
28609 ## ------------------------------------ ##
28610 ## Report this to bug-autoconf@gnu.org. ##
28611 ## ------------------------------------ ##
28612 _ASBOX
28613     ) |
28614       sed "s/^/$as_me: WARNING:     /" >&2
28615     ;;
28616   no:yes )
28617     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
28618 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
28619     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
28620 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
28621     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28622 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28623     (
28624       cat <<\_ASBOX
28625 ## ------------------------------------ ##
28626 ## Report this to bug-autoconf@gnu.org. ##
28627 ## ------------------------------------ ##
28628 _ASBOX
28629     ) |
28630       sed "s/^/$as_me: WARNING:     /" >&2
28631     ;;
28632 esac
28633 echo "$as_me:$LINENO: checking for $ac_header" >&5
28634 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28635 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28636   echo $ECHO_N "(cached) $ECHO_C" >&6
28637 else
28638   eval "$as_ac_Header=$ac_header_preproc"
28639 fi
28640 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28641 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28642
28643 fi
28644 if test `eval echo '${'$as_ac_Header'}'` = yes; then
28645   cat >>confdefs.h <<_ACEOF
28646 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
28647 _ACEOF
28648
28649 fi
28650
28651 done
28652
28653  echo "$as_me:$LINENO: checking for db" >&5
28654 echo $ECHO_N "checking for db... $ECHO_C" >&6
28655 if test "${ol_cv_ndbm+set}" = set; then
28656   echo $ECHO_N "(cached) $ECHO_C" >&6
28657 else
28658
28659         if test $ol_cv_lib_ndbm = no -o $ac_cv_header_ndbm_h = no ; then
28660                 ol_cv_ndbm=no
28661         else
28662                 ol_cv_ndbm=yes
28663         fi
28664
28665 fi
28666 echo "$as_me:$LINENO: result: $ol_cv_ndbm" >&5
28667 echo "${ECHO_T}$ol_cv_ndbm" >&6
28668  if test $ol_cv_ndbm = yes ; then
28669
28670 cat >>confdefs.h <<\_ACEOF
28671 #define HAVE_NDBM 1
28672 _ACEOF
28673
28674  fi
28675
28676
28677         if test $ol_cv_ndbm = yes ; then
28678                 ol_link_ldbm=ndbm
28679                 ol_with_ldbm_api=ndbm
28680
28681                 if test $ol_cv_lib_ndbm != yes ; then
28682                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_ndbm"
28683                 fi
28684         fi
28685 fi
28686
28687 if test $ol_link_ldbm = no -a $ol_enable_ldbm != no ; then
28688         { echo "$as_me:$LINENO: WARNING: could not find suitable LDBM backend" >&5
28689 echo "$as_me: WARNING: could not find suitable LDBM backend" >&2;}
28690         if test $ol_enable_ldbm = yes ; then
28691                 { { echo "$as_me:$LINENO: error: select appropriate LDBM options or disable" >&5
28692 echo "$as_me: error: select appropriate LDBM options or disable" >&2;}
28693    { (exit 1); exit 1; }; }
28694         fi
28695
28696         { echo "$as_me:$LINENO: WARNING: disabling LDBM" >&5
28697 echo "$as_me: WARNING: disabling LDBM" >&2;}
28698         ol_enable_ldbm=no
28699 fi
28700
28701
28702 if test $ol_enable_dynamic = yes -a $enable_shared = yes ; then
28703         BUILD_LIBS_DYNAMIC=shared
28704
28705 cat >>confdefs.h <<\_ACEOF
28706 #define LDAP_LIBS_DYNAMIC 1
28707 _ACEOF
28708
28709         LTSTATIC=""
28710 else
28711         BUILD_LIBS_DYNAMIC=static
28712         LTSTATIC="-static"
28713 fi
28714
28715 if test $ol_enable_wrappers != no ; then
28716
28717 for ac_header in tcpd.h
28718 do
28719 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28720 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28721   echo "$as_me:$LINENO: checking for $ac_header" >&5
28722 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28723 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28724   echo $ECHO_N "(cached) $ECHO_C" >&6
28725 fi
28726 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28727 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28728 else
28729   # Is the header compilable?
28730 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28731 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28732 cat >conftest.$ac_ext <<_ACEOF
28733 #line $LINENO "configure"
28734 /* confdefs.h.  */
28735 _ACEOF
28736 cat confdefs.h >>conftest.$ac_ext
28737 cat >>conftest.$ac_ext <<_ACEOF
28738 /* end confdefs.h.  */
28739 $ac_includes_default
28740 #include <$ac_header>
28741 _ACEOF
28742 rm -f conftest.$ac_objext
28743 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28744   (eval $ac_compile) 2>&5
28745   ac_status=$?
28746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28747   (exit $ac_status); } &&
28748          { ac_try='test -s conftest.$ac_objext'
28749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28750   (eval $ac_try) 2>&5
28751   ac_status=$?
28752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28753   (exit $ac_status); }; }; then
28754   ac_header_compiler=yes
28755 else
28756   echo "$as_me: failed program was:" >&5
28757 sed 's/^/| /' conftest.$ac_ext >&5
28758
28759 ac_header_compiler=no
28760 fi
28761 rm -f conftest.$ac_objext conftest.$ac_ext
28762 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28763 echo "${ECHO_T}$ac_header_compiler" >&6
28764
28765 # Is the header present?
28766 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28767 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28768 cat >conftest.$ac_ext <<_ACEOF
28769 #line $LINENO "configure"
28770 /* confdefs.h.  */
28771 _ACEOF
28772 cat confdefs.h >>conftest.$ac_ext
28773 cat >>conftest.$ac_ext <<_ACEOF
28774 /* end confdefs.h.  */
28775 #include <$ac_header>
28776 _ACEOF
28777 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28778   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28779   ac_status=$?
28780   grep -v '^ *+' conftest.er1 >conftest.err
28781   rm -f conftest.er1
28782   cat conftest.err >&5
28783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28784   (exit $ac_status); } >/dev/null; then
28785   if test -s conftest.err; then
28786     ac_cpp_err=$ac_c_preproc_warn_flag
28787   else
28788     ac_cpp_err=
28789   fi
28790 else
28791   ac_cpp_err=yes
28792 fi
28793 if test -z "$ac_cpp_err"; then
28794   ac_header_preproc=yes
28795 else
28796   echo "$as_me: failed program was:" >&5
28797 sed 's/^/| /' conftest.$ac_ext >&5
28798
28799   ac_header_preproc=no
28800 fi
28801 rm -f conftest.err conftest.$ac_ext
28802 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28803 echo "${ECHO_T}$ac_header_preproc" >&6
28804
28805 # So?  What about this header?
28806 case $ac_header_compiler:$ac_header_preproc in
28807   yes:no )
28808     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
28809 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
28810     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28811 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28812     (
28813       cat <<\_ASBOX
28814 ## ------------------------------------ ##
28815 ## Report this to bug-autoconf@gnu.org. ##
28816 ## ------------------------------------ ##
28817 _ASBOX
28818     ) |
28819       sed "s/^/$as_me: WARNING:     /" >&2
28820     ;;
28821   no:yes )
28822     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
28823 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
28824     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
28825 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
28826     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28827 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28828     (
28829       cat <<\_ASBOX
28830 ## ------------------------------------ ##
28831 ## Report this to bug-autoconf@gnu.org. ##
28832 ## ------------------------------------ ##
28833 _ASBOX
28834     ) |
28835       sed "s/^/$as_me: WARNING:     /" >&2
28836     ;;
28837 esac
28838 echo "$as_me:$LINENO: checking for $ac_header" >&5
28839 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28840 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28841   echo $ECHO_N "(cached) $ECHO_C" >&6
28842 else
28843   eval "$as_ac_Header=$ac_header_preproc"
28844 fi
28845 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28846 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28847
28848 fi
28849 if test `eval echo '${'$as_ac_Header'}'` = yes; then
28850   cat >>confdefs.h <<_ACEOF
28851 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
28852 _ACEOF
28853
28854                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
28855 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
28856                 save_LIBS="$LIBS"
28857                 LIBS="$LIBS -lwrap"
28858                 cat >conftest.$ac_ext <<_ACEOF
28859 #line $LINENO "configure"
28860 /* confdefs.h.  */
28861 _ACEOF
28862 cat confdefs.h >>conftest.$ac_ext
28863 cat >>conftest.$ac_ext <<_ACEOF
28864 /* end confdefs.h.  */
28865
28866 #include <tcpd.h>
28867 int allow_severity = 0;
28868 int deny_severity  = 0;
28869
28870 struct request_info *req;
28871
28872 int
28873 main ()
28874 {
28875
28876 hosts_access(req)
28877
28878   ;
28879   return 0;
28880 }
28881 _ACEOF
28882 rm -f conftest.$ac_objext conftest$ac_exeext
28883 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28884   (eval $ac_link) 2>&5
28885   ac_status=$?
28886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28887   (exit $ac_status); } &&
28888          { ac_try='test -s conftest$ac_exeext'
28889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28890   (eval $ac_try) 2>&5
28891   ac_status=$?
28892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28893   (exit $ac_status); }; }; then
28894   echo "$as_me:$LINENO: result: -lwrap" >&5
28895 echo "${ECHO_T}-lwrap" >&6
28896                 have_wrappers=yes
28897                 LIBS="$save_LIBS"
28898 else
28899   echo "$as_me: failed program was:" >&5
28900 sed 's/^/| /' conftest.$ac_ext >&5
28901
28902
28903                                 LIBS="$LIBS -lnsl"
28904                 cat >conftest.$ac_ext <<_ACEOF
28905 #line $LINENO "configure"
28906 /* confdefs.h.  */
28907 _ACEOF
28908 cat confdefs.h >>conftest.$ac_ext
28909 cat >>conftest.$ac_ext <<_ACEOF
28910 /* end confdefs.h.  */
28911
28912 #include <tcpd.h>
28913 int allow_severity = 0;
28914 int deny_severity  = 0;
28915
28916 struct request_info *req;
28917
28918 int
28919 main ()
28920 {
28921
28922 hosts_access(req)
28923
28924   ;
28925   return 0;
28926 }
28927 _ACEOF
28928 rm -f conftest.$ac_objext conftest$ac_exeext
28929 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28930   (eval $ac_link) 2>&5
28931   ac_status=$?
28932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28933   (exit $ac_status); } &&
28934          { ac_try='test -s conftest$ac_exeext'
28935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28936   (eval $ac_try) 2>&5
28937   ac_status=$?
28938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28939   (exit $ac_status); }; }; then
28940   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
28941 echo "${ECHO_T}-lwrap -lnsl" >&6
28942                 have_wrappers=yes
28943                 LIBS="$save_LIBS -lnsl"
28944 else
28945   echo "$as_me: failed program was:" >&5
28946 sed 's/^/| /' conftest.$ac_ext >&5
28947
28948
28949                 echo "$as_me:$LINENO: result: no" >&5
28950 echo "${ECHO_T}no" >&6
28951                 have_wrappers=no
28952                 LIBS=$save_LIBS
28953 fi
28954 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28955 fi
28956 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28957 else
28958   have_wrappers=no
28959 fi
28960
28961 done
28962
28963
28964         if test $have_wrappers = yes ; then
28965
28966 cat >>confdefs.h <<\_ACEOF
28967 #define HAVE_TCPD 1
28968 _ACEOF
28969
28970                 WRAP_LIBS="-lwrap"
28971         elif test $ol_enable_wrappers = yes ; then
28972                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options ore disable" >&5
28973 echo "$as_me: error: could not find TCP wrappers, select apppropriate options ore disable" >&2;}
28974    { (exit 1); exit 1; }; }
28975         else
28976                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
28977 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
28978                 WRAP_LIBS=""
28979         fi
28980 fi
28981
28982 if test $ol_enable_syslog != no ; then
28983         echo "$as_me:$LINENO: checking for openlog" >&5
28984 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
28985 if test "${ac_cv_func_openlog+set}" = set; then
28986   echo $ECHO_N "(cached) $ECHO_C" >&6
28987 else
28988   cat >conftest.$ac_ext <<_ACEOF
28989 #line $LINENO "configure"
28990 /* confdefs.h.  */
28991 _ACEOF
28992 cat confdefs.h >>conftest.$ac_ext
28993 cat >>conftest.$ac_ext <<_ACEOF
28994 /* end confdefs.h.  */
28995 /* System header to define __stub macros and hopefully few prototypes,
28996     which can conflict with char openlog (); below.
28997     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
28998     <limits.h> exists even on freestanding compilers.  */
28999 #ifdef __STDC__
29000 # include <limits.h>
29001 #else
29002 # include <assert.h>
29003 #endif
29004 /* Override any gcc2 internal prototype to avoid an error.  */
29005 #ifdef __cplusplus
29006 extern "C"
29007 {
29008 #endif
29009 /* We use char because int might match the return type of a gcc2
29010    builtin and then its argument prototype would still apply.  */
29011 char openlog ();
29012 /* The GNU C library defines this for functions which it implements
29013     to always fail with ENOSYS.  Some functions are actually named
29014     something starting with __ and the normal name is an alias.  */
29015 #if defined (__stub_openlog) || defined (__stub___openlog)
29016 choke me
29017 #else
29018 char (*f) () = openlog;
29019 #endif
29020 #ifdef __cplusplus
29021 }
29022 #endif
29023
29024 int
29025 main ()
29026 {
29027 return f != openlog;
29028   ;
29029   return 0;
29030 }
29031 _ACEOF
29032 rm -f conftest.$ac_objext conftest$ac_exeext
29033 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29034   (eval $ac_link) 2>&5
29035   ac_status=$?
29036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29037   (exit $ac_status); } &&
29038          { ac_try='test -s conftest$ac_exeext'
29039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29040   (eval $ac_try) 2>&5
29041   ac_status=$?
29042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29043   (exit $ac_status); }; }; then
29044   ac_cv_func_openlog=yes
29045 else
29046   echo "$as_me: failed program was:" >&5
29047 sed 's/^/| /' conftest.$ac_ext >&5
29048
29049 ac_cv_func_openlog=no
29050 fi
29051 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29052 fi
29053 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
29054 echo "${ECHO_T}$ac_cv_func_openlog" >&6
29055
29056         if test $ac_cv_func_openlog = no -a $ol_enable_syslog = yes; then
29057                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
29058 echo "$as_me: error: could not find syslog" >&2;}
29059    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
29060         fi
29061         ol_enable_syslog=$ac_cv_func_openlog
29062 fi
29063
29064
29065 ol_link_sql=no
29066 if test $ol_enable_sql != no ; then
29067
29068
29069 for ac_header in sql.h sqlext.h
29070 do
29071 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29072 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29073   echo "$as_me:$LINENO: checking for $ac_header" >&5
29074 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29075 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29076   echo $ECHO_N "(cached) $ECHO_C" >&6
29077 fi
29078 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29079 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29080 else
29081   # Is the header compilable?
29082 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29083 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29084 cat >conftest.$ac_ext <<_ACEOF
29085 #line $LINENO "configure"
29086 /* confdefs.h.  */
29087 _ACEOF
29088 cat confdefs.h >>conftest.$ac_ext
29089 cat >>conftest.$ac_ext <<_ACEOF
29090 /* end confdefs.h.  */
29091 $ac_includes_default
29092 #include <$ac_header>
29093 _ACEOF
29094 rm -f conftest.$ac_objext
29095 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29096   (eval $ac_compile) 2>&5
29097   ac_status=$?
29098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29099   (exit $ac_status); } &&
29100          { ac_try='test -s conftest.$ac_objext'
29101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29102   (eval $ac_try) 2>&5
29103   ac_status=$?
29104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29105   (exit $ac_status); }; }; then
29106   ac_header_compiler=yes
29107 else
29108   echo "$as_me: failed program was:" >&5
29109 sed 's/^/| /' conftest.$ac_ext >&5
29110
29111 ac_header_compiler=no
29112 fi
29113 rm -f conftest.$ac_objext conftest.$ac_ext
29114 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29115 echo "${ECHO_T}$ac_header_compiler" >&6
29116
29117 # Is the header present?
29118 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29119 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29120 cat >conftest.$ac_ext <<_ACEOF
29121 #line $LINENO "configure"
29122 /* confdefs.h.  */
29123 _ACEOF
29124 cat confdefs.h >>conftest.$ac_ext
29125 cat >>conftest.$ac_ext <<_ACEOF
29126 /* end confdefs.h.  */
29127 #include <$ac_header>
29128 _ACEOF
29129 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29130   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29131   ac_status=$?
29132   grep -v '^ *+' conftest.er1 >conftest.err
29133   rm -f conftest.er1
29134   cat conftest.err >&5
29135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29136   (exit $ac_status); } >/dev/null; then
29137   if test -s conftest.err; then
29138     ac_cpp_err=$ac_c_preproc_warn_flag
29139   else
29140     ac_cpp_err=
29141   fi
29142 else
29143   ac_cpp_err=yes
29144 fi
29145 if test -z "$ac_cpp_err"; then
29146   ac_header_preproc=yes
29147 else
29148   echo "$as_me: failed program was:" >&5
29149 sed 's/^/| /' conftest.$ac_ext >&5
29150
29151   ac_header_preproc=no
29152 fi
29153 rm -f conftest.err conftest.$ac_ext
29154 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29155 echo "${ECHO_T}$ac_header_preproc" >&6
29156
29157 # So?  What about this header?
29158 case $ac_header_compiler:$ac_header_preproc in
29159   yes:no )
29160     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29161 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29162     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29163 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29164     (
29165       cat <<\_ASBOX
29166 ## ------------------------------------ ##
29167 ## Report this to bug-autoconf@gnu.org. ##
29168 ## ------------------------------------ ##
29169 _ASBOX
29170     ) |
29171       sed "s/^/$as_me: WARNING:     /" >&2
29172     ;;
29173   no:yes )
29174     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29175 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29176     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29177 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29178     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29179 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29180     (
29181       cat <<\_ASBOX
29182 ## ------------------------------------ ##
29183 ## Report this to bug-autoconf@gnu.org. ##
29184 ## ------------------------------------ ##
29185 _ASBOX
29186     ) |
29187       sed "s/^/$as_me: WARNING:     /" >&2
29188     ;;
29189 esac
29190 echo "$as_me:$LINENO: checking for $ac_header" >&5
29191 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29192 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29193   echo $ECHO_N "(cached) $ECHO_C" >&6
29194 else
29195   eval "$as_ac_Header=$ac_header_preproc"
29196 fi
29197 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29198 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29199
29200 fi
29201 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29202   cat >>confdefs.h <<_ACEOF
29203 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29204 _ACEOF
29205
29206 else
29207
29208                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
29209 echo "$as_me: error: could not locate SQL headers" >&2;}
29210    { (exit 1); exit 1; }; }
29211
29212 fi
29213
29214 done
29215
29216
29217         echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
29218 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
29219 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
29220   echo $ECHO_N "(cached) $ECHO_C" >&6
29221 else
29222   ac_check_lib_save_LIBS=$LIBS
29223 LIBS="-liodbc  $LIBS"
29224 cat >conftest.$ac_ext <<_ACEOF
29225 #line $LINENO "configure"
29226 /* confdefs.h.  */
29227 _ACEOF
29228 cat confdefs.h >>conftest.$ac_ext
29229 cat >>conftest.$ac_ext <<_ACEOF
29230 /* end confdefs.h.  */
29231
29232 /* Override any gcc2 internal prototype to avoid an error.  */
29233 #ifdef __cplusplus
29234 extern "C"
29235 #endif
29236 /* We use char because int might match the return type of a gcc2
29237    builtin and then its argument prototype would still apply.  */
29238 char SQLDriverConnect ();
29239 int
29240 main ()
29241 {
29242 SQLDriverConnect ();
29243   ;
29244   return 0;
29245 }
29246 _ACEOF
29247 rm -f conftest.$ac_objext conftest$ac_exeext
29248 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29249   (eval $ac_link) 2>&5
29250   ac_status=$?
29251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29252   (exit $ac_status); } &&
29253          { ac_try='test -s conftest$ac_exeext'
29254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29255   (eval $ac_try) 2>&5
29256   ac_status=$?
29257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29258   (exit $ac_status); }; }; then
29259   ac_cv_lib_iodbc_SQLDriverConnect=yes
29260 else
29261   echo "$as_me: failed program was:" >&5
29262 sed 's/^/| /' conftest.$ac_ext >&5
29263
29264 ac_cv_lib_iodbc_SQLDriverConnect=no
29265 fi
29266 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29267 LIBS=$ac_check_lib_save_LIBS
29268 fi
29269 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
29270 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
29271 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
29272   have_iodbc=yes
29273 else
29274   have_iodbc=no
29275 fi
29276
29277         if test $have_iodbc = yes ; then
29278                 ol_link_sql="-liodbc"
29279         else
29280                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
29281 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
29282 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
29283   echo $ECHO_N "(cached) $ECHO_C" >&6
29284 else
29285   ac_check_lib_save_LIBS=$LIBS
29286 LIBS="-lodbc  $LIBS"
29287 cat >conftest.$ac_ext <<_ACEOF
29288 #line $LINENO "configure"
29289 /* confdefs.h.  */
29290 _ACEOF
29291 cat confdefs.h >>conftest.$ac_ext
29292 cat >>conftest.$ac_ext <<_ACEOF
29293 /* end confdefs.h.  */
29294
29295 /* Override any gcc2 internal prototype to avoid an error.  */
29296 #ifdef __cplusplus
29297 extern "C"
29298 #endif
29299 /* We use char because int might match the return type of a gcc2
29300    builtin and then its argument prototype would still apply.  */
29301 char SQLDriverConnect ();
29302 int
29303 main ()
29304 {
29305 SQLDriverConnect ();
29306   ;
29307   return 0;
29308 }
29309 _ACEOF
29310 rm -f conftest.$ac_objext conftest$ac_exeext
29311 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29312   (eval $ac_link) 2>&5
29313   ac_status=$?
29314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29315   (exit $ac_status); } &&
29316          { ac_try='test -s conftest$ac_exeext'
29317   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29318   (eval $ac_try) 2>&5
29319   ac_status=$?
29320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29321   (exit $ac_status); }; }; then
29322   ac_cv_lib_odbc_SQLDriverConnect=yes
29323 else
29324   echo "$as_me: failed program was:" >&5
29325 sed 's/^/| /' conftest.$ac_ext >&5
29326
29327 ac_cv_lib_odbc_SQLDriverConnect=no
29328 fi
29329 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29330 LIBS=$ac_check_lib_save_LIBS
29331 fi
29332 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
29333 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
29334 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
29335   have_odbc=yes
29336 else
29337   have_odbc=no
29338 fi
29339
29340                 if test $have_odbc = yes ; then
29341                         ol_link_sql="-lodbc"
29342                 fi
29343         fi
29344
29345         if test $ol_link_sql != no ; then
29346                 SLAPD_SQL_LIBS="$ol_link_sql"
29347
29348         elif test $ol_enable_sql != auto ; then
29349                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
29350 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
29351    { (exit 1); exit 1; }; }
29352         fi
29353 fi
29354
29355 if test $ol_enable_tcl != no ; then
29356
29357 for ac_header in tcl.h
29358 do
29359 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29360 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29361   echo "$as_me:$LINENO: checking for $ac_header" >&5
29362 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29363 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29364   echo $ECHO_N "(cached) $ECHO_C" >&6
29365 fi
29366 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29367 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29368 else
29369   # Is the header compilable?
29370 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29371 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29372 cat >conftest.$ac_ext <<_ACEOF
29373 #line $LINENO "configure"
29374 /* confdefs.h.  */
29375 _ACEOF
29376 cat confdefs.h >>conftest.$ac_ext
29377 cat >>conftest.$ac_ext <<_ACEOF
29378 /* end confdefs.h.  */
29379 $ac_includes_default
29380 #include <$ac_header>
29381 _ACEOF
29382 rm -f conftest.$ac_objext
29383 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29384   (eval $ac_compile) 2>&5
29385   ac_status=$?
29386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29387   (exit $ac_status); } &&
29388          { ac_try='test -s conftest.$ac_objext'
29389   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29390   (eval $ac_try) 2>&5
29391   ac_status=$?
29392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29393   (exit $ac_status); }; }; then
29394   ac_header_compiler=yes
29395 else
29396   echo "$as_me: failed program was:" >&5
29397 sed 's/^/| /' conftest.$ac_ext >&5
29398
29399 ac_header_compiler=no
29400 fi
29401 rm -f conftest.$ac_objext conftest.$ac_ext
29402 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29403 echo "${ECHO_T}$ac_header_compiler" >&6
29404
29405 # Is the header present?
29406 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29407 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29408 cat >conftest.$ac_ext <<_ACEOF
29409 #line $LINENO "configure"
29410 /* confdefs.h.  */
29411 _ACEOF
29412 cat confdefs.h >>conftest.$ac_ext
29413 cat >>conftest.$ac_ext <<_ACEOF
29414 /* end confdefs.h.  */
29415 #include <$ac_header>
29416 _ACEOF
29417 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29418   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29419   ac_status=$?
29420   grep -v '^ *+' conftest.er1 >conftest.err
29421   rm -f conftest.er1
29422   cat conftest.err >&5
29423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29424   (exit $ac_status); } >/dev/null; then
29425   if test -s conftest.err; then
29426     ac_cpp_err=$ac_c_preproc_warn_flag
29427   else
29428     ac_cpp_err=
29429   fi
29430 else
29431   ac_cpp_err=yes
29432 fi
29433 if test -z "$ac_cpp_err"; then
29434   ac_header_preproc=yes
29435 else
29436   echo "$as_me: failed program was:" >&5
29437 sed 's/^/| /' conftest.$ac_ext >&5
29438
29439   ac_header_preproc=no
29440 fi
29441 rm -f conftest.err conftest.$ac_ext
29442 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29443 echo "${ECHO_T}$ac_header_preproc" >&6
29444
29445 # So?  What about this header?
29446 case $ac_header_compiler:$ac_header_preproc in
29447   yes:no )
29448     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29449 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29450     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29451 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29452     (
29453       cat <<\_ASBOX
29454 ## ------------------------------------ ##
29455 ## Report this to bug-autoconf@gnu.org. ##
29456 ## ------------------------------------ ##
29457 _ASBOX
29458     ) |
29459       sed "s/^/$as_me: WARNING:     /" >&2
29460     ;;
29461   no:yes )
29462     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29463 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29464     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29465 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29466     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29467 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29468     (
29469       cat <<\_ASBOX
29470 ## ------------------------------------ ##
29471 ## Report this to bug-autoconf@gnu.org. ##
29472 ## ------------------------------------ ##
29473 _ASBOX
29474     ) |
29475       sed "s/^/$as_me: WARNING:     /" >&2
29476     ;;
29477 esac
29478 echo "$as_me:$LINENO: checking for $ac_header" >&5
29479 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29480 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29481   echo $ECHO_N "(cached) $ECHO_C" >&6
29482 else
29483   eval "$as_ac_Header=$ac_header_preproc"
29484 fi
29485 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29486 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29487
29488 fi
29489 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29490   cat >>confdefs.h <<_ACEOF
29491 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29492 _ACEOF
29493
29494 fi
29495
29496 done
29497
29498
29499         if test $ac_cv_header_tcl_h != yes ; then
29500                 have_tcl=no
29501         else
29502                 for lib in tcl tcl7.6 tcl8.0 tcl8.2 ; do
29503                         as_ac_Lib=`echo "ac_cv_lib_$lib''_main" | $as_tr_sh`
29504 echo "$as_me:$LINENO: checking for main in -l$lib" >&5
29505 echo $ECHO_N "checking for main in -l$lib... $ECHO_C" >&6
29506 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
29507   echo $ECHO_N "(cached) $ECHO_C" >&6
29508 else
29509   ac_check_lib_save_LIBS=$LIBS
29510 LIBS="-l$lib  $LIBS"
29511 cat >conftest.$ac_ext <<_ACEOF
29512 #line $LINENO "configure"
29513 /* confdefs.h.  */
29514 _ACEOF
29515 cat confdefs.h >>conftest.$ac_ext
29516 cat >>conftest.$ac_ext <<_ACEOF
29517 /* end confdefs.h.  */
29518
29519
29520 int
29521 main ()
29522 {
29523 main ();
29524   ;
29525   return 0;
29526 }
29527 _ACEOF
29528 rm -f conftest.$ac_objext conftest$ac_exeext
29529 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29530   (eval $ac_link) 2>&5
29531   ac_status=$?
29532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29533   (exit $ac_status); } &&
29534          { ac_try='test -s conftest$ac_exeext'
29535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29536   (eval $ac_try) 2>&5
29537   ac_status=$?
29538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29539   (exit $ac_status); }; }; then
29540   eval "$as_ac_Lib=yes"
29541 else
29542   echo "$as_me: failed program was:" >&5
29543 sed 's/^/| /' conftest.$ac_ext >&5
29544
29545 eval "$as_ac_Lib=no"
29546 fi
29547 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29548 LIBS=$ac_check_lib_save_LIBS
29549 fi
29550 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
29551 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
29552 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
29553   have_tcl=yes
29554                            if test x"$ol_with_tcl_module" = "xstatic" ; then
29555                                         SLAPD_LIBS="$SLAPD_LIBS -l${lib}"
29556                            else
29557                                         MOD_TCL_LIB="-l${lib}"
29558                            fi;break
29559 else
29560   have_tcl=no
29561 fi
29562
29563                 done
29564         fi
29565
29566         if test $have_tcl != yes ; then
29567                 { echo "$as_me:$LINENO: WARNING: could not find -ltcl" >&5
29568 echo "$as_me: WARNING: could not find -ltcl" >&2;}
29569                 if test $ol_enable_tcl = yes ; then
29570                         { { echo "$as_me:$LINENO: error: could not find tcl, select appropriate options or disable" >&5
29571 echo "$as_me: error: could not find tcl, select appropriate options or disable" >&2;}
29572    { (exit 1); exit 1; }; }
29573                 fi
29574
29575                 ol_enable_tcl=no
29576         fi
29577 fi
29578
29579 ol_link_termcap=no
29580
29581
29582 for ac_header in termcap.h ncurses.h
29583 do
29584 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29585 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29586   echo "$as_me:$LINENO: checking for $ac_header" >&5
29587 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29588 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29589   echo $ECHO_N "(cached) $ECHO_C" >&6
29590 fi
29591 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29592 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29593 else
29594   # Is the header compilable?
29595 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29596 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29597 cat >conftest.$ac_ext <<_ACEOF
29598 #line $LINENO "configure"
29599 /* confdefs.h.  */
29600 _ACEOF
29601 cat confdefs.h >>conftest.$ac_ext
29602 cat >>conftest.$ac_ext <<_ACEOF
29603 /* end confdefs.h.  */
29604 $ac_includes_default
29605 #include <$ac_header>
29606 _ACEOF
29607 rm -f conftest.$ac_objext
29608 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29609   (eval $ac_compile) 2>&5
29610   ac_status=$?
29611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29612   (exit $ac_status); } &&
29613          { ac_try='test -s conftest.$ac_objext'
29614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29615   (eval $ac_try) 2>&5
29616   ac_status=$?
29617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29618   (exit $ac_status); }; }; then
29619   ac_header_compiler=yes
29620 else
29621   echo "$as_me: failed program was:" >&5
29622 sed 's/^/| /' conftest.$ac_ext >&5
29623
29624 ac_header_compiler=no
29625 fi
29626 rm -f conftest.$ac_objext conftest.$ac_ext
29627 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29628 echo "${ECHO_T}$ac_header_compiler" >&6
29629
29630 # Is the header present?
29631 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29632 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29633 cat >conftest.$ac_ext <<_ACEOF
29634 #line $LINENO "configure"
29635 /* confdefs.h.  */
29636 _ACEOF
29637 cat confdefs.h >>conftest.$ac_ext
29638 cat >>conftest.$ac_ext <<_ACEOF
29639 /* end confdefs.h.  */
29640 #include <$ac_header>
29641 _ACEOF
29642 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29643   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29644   ac_status=$?
29645   grep -v '^ *+' conftest.er1 >conftest.err
29646   rm -f conftest.er1
29647   cat conftest.err >&5
29648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29649   (exit $ac_status); } >/dev/null; then
29650   if test -s conftest.err; then
29651     ac_cpp_err=$ac_c_preproc_warn_flag
29652   else
29653     ac_cpp_err=
29654   fi
29655 else
29656   ac_cpp_err=yes
29657 fi
29658 if test -z "$ac_cpp_err"; then
29659   ac_header_preproc=yes
29660 else
29661   echo "$as_me: failed program was:" >&5
29662 sed 's/^/| /' conftest.$ac_ext >&5
29663
29664   ac_header_preproc=no
29665 fi
29666 rm -f conftest.err conftest.$ac_ext
29667 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29668 echo "${ECHO_T}$ac_header_preproc" >&6
29669
29670 # So?  What about this header?
29671 case $ac_header_compiler:$ac_header_preproc in
29672   yes:no )
29673     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29674 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29675     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29676 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29677     (
29678       cat <<\_ASBOX
29679 ## ------------------------------------ ##
29680 ## Report this to bug-autoconf@gnu.org. ##
29681 ## ------------------------------------ ##
29682 _ASBOX
29683     ) |
29684       sed "s/^/$as_me: WARNING:     /" >&2
29685     ;;
29686   no:yes )
29687     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29688 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29689     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29690 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29691     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29692 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29693     (
29694       cat <<\_ASBOX
29695 ## ------------------------------------ ##
29696 ## Report this to bug-autoconf@gnu.org. ##
29697 ## ------------------------------------ ##
29698 _ASBOX
29699     ) |
29700       sed "s/^/$as_me: WARNING:     /" >&2
29701     ;;
29702 esac
29703 echo "$as_me:$LINENO: checking for $ac_header" >&5
29704 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29705 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29706   echo $ECHO_N "(cached) $ECHO_C" >&6
29707 else
29708   eval "$as_ac_Header=$ac_header_preproc"
29709 fi
29710 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29711 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29712
29713 fi
29714 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29715   cat >>confdefs.h <<_ACEOF
29716 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29717 _ACEOF
29718
29719 fi
29720
29721 done
29722
29723
29724 if test $ol_link_termcap = no ; then
29725         echo "$as_me:$LINENO: checking for tputs in -ltermcap" >&5
29726 echo $ECHO_N "checking for tputs in -ltermcap... $ECHO_C" >&6
29727 if test "${ac_cv_lib_termcap_tputs+set}" = set; then
29728   echo $ECHO_N "(cached) $ECHO_C" >&6
29729 else
29730   ac_check_lib_save_LIBS=$LIBS
29731 LIBS="-ltermcap  $LIBS"
29732 cat >conftest.$ac_ext <<_ACEOF
29733 #line $LINENO "configure"
29734 /* confdefs.h.  */
29735 _ACEOF
29736 cat confdefs.h >>conftest.$ac_ext
29737 cat >>conftest.$ac_ext <<_ACEOF
29738 /* end confdefs.h.  */
29739
29740 /* Override any gcc2 internal prototype to avoid an error.  */
29741 #ifdef __cplusplus
29742 extern "C"
29743 #endif
29744 /* We use char because int might match the return type of a gcc2
29745    builtin and then its argument prototype would still apply.  */
29746 char tputs ();
29747 int
29748 main ()
29749 {
29750 tputs ();
29751   ;
29752   return 0;
29753 }
29754 _ACEOF
29755 rm -f conftest.$ac_objext conftest$ac_exeext
29756 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29757   (eval $ac_link) 2>&5
29758   ac_status=$?
29759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29760   (exit $ac_status); } &&
29761          { ac_try='test -s conftest$ac_exeext'
29762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29763   (eval $ac_try) 2>&5
29764   ac_status=$?
29765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29766   (exit $ac_status); }; }; then
29767   ac_cv_lib_termcap_tputs=yes
29768 else
29769   echo "$as_me: failed program was:" >&5
29770 sed 's/^/| /' conftest.$ac_ext >&5
29771
29772 ac_cv_lib_termcap_tputs=no
29773 fi
29774 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29775 LIBS=$ac_check_lib_save_LIBS
29776 fi
29777 echo "$as_me:$LINENO: result: $ac_cv_lib_termcap_tputs" >&5
29778 echo "${ECHO_T}$ac_cv_lib_termcap_tputs" >&6
29779 if test $ac_cv_lib_termcap_tputs = yes; then
29780   have_termcap=yes
29781 else
29782   have_termcap=no
29783 fi
29784
29785         if test $have_termcap = yes ; then
29786
29787 cat >>confdefs.h <<\_ACEOF
29788 #define HAVE_TERMCAP 1
29789 _ACEOF
29790
29791                 ol_link_termcap=yes
29792                 TERMCAP_LIBS=-ltermcap
29793         fi
29794 fi
29795
29796 if test $ol_link_termcap = no ; then
29797         echo "$as_me:$LINENO: checking for initscr in -lncurses" >&5
29798 echo $ECHO_N "checking for initscr in -lncurses... $ECHO_C" >&6
29799 if test "${ac_cv_lib_ncurses_initscr+set}" = set; then
29800   echo $ECHO_N "(cached) $ECHO_C" >&6
29801 else
29802   ac_check_lib_save_LIBS=$LIBS
29803 LIBS="-lncurses  $LIBS"
29804 cat >conftest.$ac_ext <<_ACEOF
29805 #line $LINENO "configure"
29806 /* confdefs.h.  */
29807 _ACEOF
29808 cat confdefs.h >>conftest.$ac_ext
29809 cat >>conftest.$ac_ext <<_ACEOF
29810 /* end confdefs.h.  */
29811
29812 /* Override any gcc2 internal prototype to avoid an error.  */
29813 #ifdef __cplusplus
29814 extern "C"
29815 #endif
29816 /* We use char because int might match the return type of a gcc2
29817    builtin and then its argument prototype would still apply.  */
29818 char initscr ();
29819 int
29820 main ()
29821 {
29822 initscr ();
29823   ;
29824   return 0;
29825 }
29826 _ACEOF
29827 rm -f conftest.$ac_objext conftest$ac_exeext
29828 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29829   (eval $ac_link) 2>&5
29830   ac_status=$?
29831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29832   (exit $ac_status); } &&
29833          { ac_try='test -s conftest$ac_exeext'
29834   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29835   (eval $ac_try) 2>&5
29836   ac_status=$?
29837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29838   (exit $ac_status); }; }; then
29839   ac_cv_lib_ncurses_initscr=yes
29840 else
29841   echo "$as_me: failed program was:" >&5
29842 sed 's/^/| /' conftest.$ac_ext >&5
29843
29844 ac_cv_lib_ncurses_initscr=no
29845 fi
29846 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29847 LIBS=$ac_check_lib_save_LIBS
29848 fi
29849 echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_initscr" >&5
29850 echo "${ECHO_T}$ac_cv_lib_ncurses_initscr" >&6
29851 if test $ac_cv_lib_ncurses_initscr = yes; then
29852   have_ncurses=yes
29853 else
29854   have_ncurses=no
29855 fi
29856
29857         if test $have_ncurses = yes ; then
29858
29859 cat >>confdefs.h <<\_ACEOF
29860 #define HAVE_NCURSES 1
29861 _ACEOF
29862
29863                 ol_link_termcap=yes
29864                 TERMCAP_LIBS=-lncurses
29865         fi
29866 fi
29867
29868 if test $ol_link_termcap = no ; then
29869
29870 cat >>confdefs.h <<\_ACEOF
29871 #define NO_TERMCAP 1
29872 _ACEOF
29873
29874         TERMCAP_LIBS=
29875 fi
29876
29877 ol_link_sasl=no
29878 ol_link_spasswd=no
29879 if test $ol_with_cyrus_sasl != no ; then
29880
29881
29882 for ac_header in sasl/sasl.h sasl.h
29883 do
29884 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29885 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29886   echo "$as_me:$LINENO: checking for $ac_header" >&5
29887 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29888 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29889   echo $ECHO_N "(cached) $ECHO_C" >&6
29890 fi
29891 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29892 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29893 else
29894   # Is the header compilable?
29895 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29896 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29897 cat >conftest.$ac_ext <<_ACEOF
29898 #line $LINENO "configure"
29899 /* confdefs.h.  */
29900 _ACEOF
29901 cat confdefs.h >>conftest.$ac_ext
29902 cat >>conftest.$ac_ext <<_ACEOF
29903 /* end confdefs.h.  */
29904 $ac_includes_default
29905 #include <$ac_header>
29906 _ACEOF
29907 rm -f conftest.$ac_objext
29908 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29909   (eval $ac_compile) 2>&5
29910   ac_status=$?
29911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29912   (exit $ac_status); } &&
29913          { ac_try='test -s conftest.$ac_objext'
29914   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29915   (eval $ac_try) 2>&5
29916   ac_status=$?
29917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29918   (exit $ac_status); }; }; then
29919   ac_header_compiler=yes
29920 else
29921   echo "$as_me: failed program was:" >&5
29922 sed 's/^/| /' conftest.$ac_ext >&5
29923
29924 ac_header_compiler=no
29925 fi
29926 rm -f conftest.$ac_objext conftest.$ac_ext
29927 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29928 echo "${ECHO_T}$ac_header_compiler" >&6
29929
29930 # Is the header present?
29931 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29932 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29933 cat >conftest.$ac_ext <<_ACEOF
29934 #line $LINENO "configure"
29935 /* confdefs.h.  */
29936 _ACEOF
29937 cat confdefs.h >>conftest.$ac_ext
29938 cat >>conftest.$ac_ext <<_ACEOF
29939 /* end confdefs.h.  */
29940 #include <$ac_header>
29941 _ACEOF
29942 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29943   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29944   ac_status=$?
29945   grep -v '^ *+' conftest.er1 >conftest.err
29946   rm -f conftest.er1
29947   cat conftest.err >&5
29948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29949   (exit $ac_status); } >/dev/null; then
29950   if test -s conftest.err; then
29951     ac_cpp_err=$ac_c_preproc_warn_flag
29952   else
29953     ac_cpp_err=
29954   fi
29955 else
29956   ac_cpp_err=yes
29957 fi
29958 if test -z "$ac_cpp_err"; then
29959   ac_header_preproc=yes
29960 else
29961   echo "$as_me: failed program was:" >&5
29962 sed 's/^/| /' conftest.$ac_ext >&5
29963
29964   ac_header_preproc=no
29965 fi
29966 rm -f conftest.err conftest.$ac_ext
29967 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29968 echo "${ECHO_T}$ac_header_preproc" >&6
29969
29970 # So?  What about this header?
29971 case $ac_header_compiler:$ac_header_preproc in
29972   yes:no )
29973     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29974 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29975     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29976 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29977     (
29978       cat <<\_ASBOX
29979 ## ------------------------------------ ##
29980 ## Report this to bug-autoconf@gnu.org. ##
29981 ## ------------------------------------ ##
29982 _ASBOX
29983     ) |
29984       sed "s/^/$as_me: WARNING:     /" >&2
29985     ;;
29986   no:yes )
29987     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29988 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29989     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29990 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29991     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29992 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29993     (
29994       cat <<\_ASBOX
29995 ## ------------------------------------ ##
29996 ## Report this to bug-autoconf@gnu.org. ##
29997 ## ------------------------------------ ##
29998 _ASBOX
29999     ) |
30000       sed "s/^/$as_me: WARNING:     /" >&2
30001     ;;
30002 esac
30003 echo "$as_me:$LINENO: checking for $ac_header" >&5
30004 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30005 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30006   echo $ECHO_N "(cached) $ECHO_C" >&6
30007 else
30008   eval "$as_ac_Header=$ac_header_preproc"
30009 fi
30010 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30011 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30012
30013 fi
30014 if test `eval echo '${'$as_ac_Header'}'` = yes; then
30015   cat >>confdefs.h <<_ACEOF
30016 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
30017 _ACEOF
30018
30019 fi
30020
30021 done
30022
30023
30024         if test $ac_cv_header_sasl_sasl_h = yes -o $ac_cv_header_sasl_h = yes; then
30025                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
30026 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
30027 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
30028   echo $ECHO_N "(cached) $ECHO_C" >&6
30029 else
30030   ac_check_lib_save_LIBS=$LIBS
30031 LIBS="-lsasl2  $LIBS"
30032 cat >conftest.$ac_ext <<_ACEOF
30033 #line $LINENO "configure"
30034 /* confdefs.h.  */
30035 _ACEOF
30036 cat confdefs.h >>conftest.$ac_ext
30037 cat >>conftest.$ac_ext <<_ACEOF
30038 /* end confdefs.h.  */
30039
30040 /* Override any gcc2 internal prototype to avoid an error.  */
30041 #ifdef __cplusplus
30042 extern "C"
30043 #endif
30044 /* We use char because int might match the return type of a gcc2
30045    builtin and then its argument prototype would still apply.  */
30046 char sasl_client_init ();
30047 int
30048 main ()
30049 {
30050 sasl_client_init ();
30051   ;
30052   return 0;
30053 }
30054 _ACEOF
30055 rm -f conftest.$ac_objext conftest$ac_exeext
30056 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30057   (eval $ac_link) 2>&5
30058   ac_status=$?
30059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30060   (exit $ac_status); } &&
30061          { ac_try='test -s conftest$ac_exeext'
30062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30063   (eval $ac_try) 2>&5
30064   ac_status=$?
30065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30066   (exit $ac_status); }; }; then
30067   ac_cv_lib_sasl2_sasl_client_init=yes
30068 else
30069   echo "$as_me: failed program was:" >&5
30070 sed 's/^/| /' conftest.$ac_ext >&5
30071
30072 ac_cv_lib_sasl2_sasl_client_init=no
30073 fi
30074 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30075 LIBS=$ac_check_lib_save_LIBS
30076 fi
30077 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
30078 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
30079 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
30080   ol_link_sasl="-lsasl2"
30081 else
30082   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
30083 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
30084 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
30085   echo $ECHO_N "(cached) $ECHO_C" >&6
30086 else
30087   ac_check_lib_save_LIBS=$LIBS
30088 LIBS="-lsasl  $LIBS"
30089 cat >conftest.$ac_ext <<_ACEOF
30090 #line $LINENO "configure"
30091 /* confdefs.h.  */
30092 _ACEOF
30093 cat confdefs.h >>conftest.$ac_ext
30094 cat >>conftest.$ac_ext <<_ACEOF
30095 /* end confdefs.h.  */
30096
30097 /* Override any gcc2 internal prototype to avoid an error.  */
30098 #ifdef __cplusplus
30099 extern "C"
30100 #endif
30101 /* We use char because int might match the return type of a gcc2
30102    builtin and then its argument prototype would still apply.  */
30103 char sasl_client_init ();
30104 int
30105 main ()
30106 {
30107 sasl_client_init ();
30108   ;
30109   return 0;
30110 }
30111 _ACEOF
30112 rm -f conftest.$ac_objext conftest$ac_exeext
30113 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30114   (eval $ac_link) 2>&5
30115   ac_status=$?
30116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30117   (exit $ac_status); } &&
30118          { ac_try='test -s conftest$ac_exeext'
30119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30120   (eval $ac_try) 2>&5
30121   ac_status=$?
30122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30123   (exit $ac_status); }; }; then
30124   ac_cv_lib_sasl_sasl_client_init=yes
30125 else
30126   echo "$as_me: failed program was:" >&5
30127 sed 's/^/| /' conftest.$ac_ext >&5
30128
30129 ac_cv_lib_sasl_sasl_client_init=no
30130 fi
30131 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30132 LIBS=$ac_check_lib_save_LIBS
30133 fi
30134 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
30135 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
30136 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
30137   ol_link_sasl="-lsasl"
30138 fi
30139
30140 fi
30141
30142         fi
30143
30144         if test $ol_link_sasl = no ; then
30145                 if test $ol_with_cyrus_sasl != auto ; then
30146                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
30147 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
30148    { (exit 1); exit 1; }; }
30149                 else
30150                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
30151 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
30152                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
30153 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
30154                         if test $ol_link_tls = no ; then
30155                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
30156 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
30157                         fi
30158                 fi
30159         else
30160                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
30161 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
30162 if test "${ol_cv_sasl_compat+set}" = set; then
30163   echo $ECHO_N "(cached) $ECHO_C" >&6
30164 else
30165
30166         cat >conftest.$ac_ext <<_ACEOF
30167 #line $LINENO "configure"
30168 /* confdefs.h.  */
30169 _ACEOF
30170 cat confdefs.h >>conftest.$ac_ext
30171 cat >>conftest.$ac_ext <<_ACEOF
30172 /* end confdefs.h.  */
30173
30174 #ifdef HAVE_SASL_SASL_H
30175 #include <sasl/sasl.h>
30176 #else
30177 #include <sasl.h>
30178 #endif
30179
30180 /* require 2.1.3 or later */
30181 #if SASL_VERSION_MAJOR == 1  && SASL_VERSION_MINOR >= 5
30182         char *__sasl_compat = "1.5.x okay";
30183 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
30184         __sasl_compat "2.2+ or better okay (we guess)";
30185 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
30186         && SASL_VERSION_STEP >=3
30187         __sasl_compat = "2.1.3+ or better okay";
30188 #endif
30189
30190 _ACEOF
30191 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30192   $EGREP "__sasl_compat" >/dev/null 2>&1; then
30193   ol_cv_sasl_compat=yes
30194 else
30195   ol_cv_sasl_compat=no
30196 fi
30197 rm -f conftest*
30198
30199 fi
30200 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
30201 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
30202
30203                 if test $ol_cv_sasl_compat = no ; then
30204                         ol_link_sasl=no
30205                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but incompatible" >&5
30206 echo "$as_me: error: Cyrus SASL library located but incompatible" >&2;}
30207    { (exit 1); exit 1; }; }
30208                 fi
30209
30210
30211 cat >>confdefs.h <<\_ACEOF
30212 #define HAVE_CYRUS_SASL 1
30213 _ACEOF
30214
30215                 SASL_LIBS="$ol_link_sasl"
30216                 if test $ol_enable_spasswd != no ; then
30217                         ol_link_spasswd=yes
30218                 fi
30219
30220                 ac_save_LIBS="$LIBS"
30221                 LIBS="$LIBS $ol_link_sasl"
30222                 echo "$as_me:$LINENO: checking for sasl_version" >&5
30223 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
30224 if test "${ac_cv_func_sasl_version+set}" = set; then
30225   echo $ECHO_N "(cached) $ECHO_C" >&6
30226 else
30227   cat >conftest.$ac_ext <<_ACEOF
30228 #line $LINENO "configure"
30229 /* confdefs.h.  */
30230 _ACEOF
30231 cat confdefs.h >>conftest.$ac_ext
30232 cat >>conftest.$ac_ext <<_ACEOF
30233 /* end confdefs.h.  */
30234 /* System header to define __stub macros and hopefully few prototypes,
30235     which can conflict with char sasl_version (); below.
30236     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30237     <limits.h> exists even on freestanding compilers.  */
30238 #ifdef __STDC__
30239 # include <limits.h>
30240 #else
30241 # include <assert.h>
30242 #endif
30243 /* Override any gcc2 internal prototype to avoid an error.  */
30244 #ifdef __cplusplus
30245 extern "C"
30246 {
30247 #endif
30248 /* We use char because int might match the return type of a gcc2
30249    builtin and then its argument prototype would still apply.  */
30250 char sasl_version ();
30251 /* The GNU C library defines this for functions which it implements
30252     to always fail with ENOSYS.  Some functions are actually named
30253     something starting with __ and the normal name is an alias.  */
30254 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
30255 choke me
30256 #else
30257 char (*f) () = sasl_version;
30258 #endif
30259 #ifdef __cplusplus
30260 }
30261 #endif
30262
30263 int
30264 main ()
30265 {
30266 return f != sasl_version;
30267   ;
30268   return 0;
30269 }
30270 _ACEOF
30271 rm -f conftest.$ac_objext conftest$ac_exeext
30272 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30273   (eval $ac_link) 2>&5
30274   ac_status=$?
30275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30276   (exit $ac_status); } &&
30277          { ac_try='test -s conftest$ac_exeext'
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_func_sasl_version=yes
30284 else
30285   echo "$as_me: failed program was:" >&5
30286 sed 's/^/| /' conftest.$ac_ext >&5
30287
30288 ac_cv_func_sasl_version=no
30289 fi
30290 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30291 fi
30292 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
30293 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
30294 if test $ac_cv_func_sasl_version = yes; then
30295
30296 cat >>confdefs.h <<\_ACEOF
30297 #define HAVE_SASL_VERSION 1
30298 _ACEOF
30299
30300 fi
30301
30302                 LIBS="$ac_save_LIBS"
30303         fi
30304
30305 else
30306         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
30307 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
30308         if test $ol_link_tls = no ; then
30309                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
30310 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
30311         fi
30312 fi
30313
30314 if test $cross_compiling != yes -a "$ac_cv_mingw32" != yes ; then
30315         dev=no
30316         if test -r /dev/urandom ; then
30317                 dev="/dev/urandom";
30318         elif test -r /idev/urandom ; then
30319                 dev="/idev/urandom";
30320         elif test -r /dev/srandom ; then
30321                 dev="/dev/srandom";
30322         elif test -r /dev/random ; then
30323                 dev="/dev/random";
30324         elif test -r /idev/random ; then
30325                 dev="/idev/random";
30326         fi
30327
30328         if test $dev != no ; then
30329
30330 cat >>confdefs.h <<_ACEOF
30331 #define URANDOM_DEVICE "$dev"
30332 _ACEOF
30333
30334         fi
30335 fi
30336
30337 ol_link_fetch=no
30338 if test $ol_with_fetch != no ; then
30339         ol_LIBS=$LIBS
30340 LIBS="-lfetch -lcom_err $LIBS"
30341 echo "$as_me:$LINENO: checking fetch(3) library" >&5
30342 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
30343 if test "${ol_cv_lib_fetch+set}" = set; then
30344   echo $ECHO_N "(cached) $ECHO_C" >&6
30345 else
30346
30347         cat >conftest.$ac_ext <<_ACEOF
30348 #line $LINENO "configure"
30349 /* confdefs.h.  */
30350 _ACEOF
30351 cat confdefs.h >>conftest.$ac_ext
30352 cat >>conftest.$ac_ext <<_ACEOF
30353 /* end confdefs.h.  */
30354
30355 #include <sys/param.h>
30356 #include <stdio.h>
30357 #include <fetch.h>
30358 int
30359 main ()
30360 {
30361 struct url *u = fetchParseURL("file:///");
30362   ;
30363   return 0;
30364 }
30365 _ACEOF
30366 rm -f conftest.$ac_objext conftest$ac_exeext
30367 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30368   (eval $ac_link) 2>&5
30369   ac_status=$?
30370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30371   (exit $ac_status); } &&
30372          { ac_try='test -s conftest$ac_exeext'
30373   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30374   (eval $ac_try) 2>&5
30375   ac_status=$?
30376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30377   (exit $ac_status); }; }; then
30378   ol_cv_lib_fetch=yes
30379 else
30380   echo "$as_me: failed program was:" >&5
30381 sed 's/^/| /' conftest.$ac_ext >&5
30382
30383 ol_cv_lib_fetch=no
30384 fi
30385 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30386 fi
30387 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
30388 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
30389 LIBS=$ol_LIBS
30390 if test $ol_cv_lib_fetch != no ; then
30391         ol_link_fetch="-lfetch -lcom_err"
30392
30393 cat >>confdefs.h <<\_ACEOF
30394 #define HAVE_FETCH 1
30395 _ACEOF
30396
30397 fi
30398
30399
30400         if test $ol_cv_lib_fetch != no ; then
30401                 LDIF_LIBS="$LDIF_LIBS $ol_link_fetch"
30402                 ol_link_fetch=freebsd
30403
30404         elif test $ol_with_fetch != auto ; then
30405                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
30406 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
30407    { (exit 1); exit 1; }; }
30408         fi
30409 fi
30410
30411 ol_link_readline=no
30412 if test $ol_with_readline != no ; then
30413
30414
30415 for ac_header in readline/readline.h readline/history.h
30416 do
30417 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
30418 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30419   echo "$as_me:$LINENO: checking for $ac_header" >&5
30420 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30421 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30422   echo $ECHO_N "(cached) $ECHO_C" >&6
30423 fi
30424 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30425 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30426 else
30427   # Is the header compilable?
30428 echo "$as_me:$LINENO: checking $ac_header usability" >&5
30429 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
30430 cat >conftest.$ac_ext <<_ACEOF
30431 #line $LINENO "configure"
30432 /* confdefs.h.  */
30433 _ACEOF
30434 cat confdefs.h >>conftest.$ac_ext
30435 cat >>conftest.$ac_ext <<_ACEOF
30436 /* end confdefs.h.  */
30437 $ac_includes_default
30438 #include <$ac_header>
30439 _ACEOF
30440 rm -f conftest.$ac_objext
30441 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30442   (eval $ac_compile) 2>&5
30443   ac_status=$?
30444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30445   (exit $ac_status); } &&
30446          { ac_try='test -s conftest.$ac_objext'
30447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30448   (eval $ac_try) 2>&5
30449   ac_status=$?
30450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30451   (exit $ac_status); }; }; then
30452   ac_header_compiler=yes
30453 else
30454   echo "$as_me: failed program was:" >&5
30455 sed 's/^/| /' conftest.$ac_ext >&5
30456
30457 ac_header_compiler=no
30458 fi
30459 rm -f conftest.$ac_objext conftest.$ac_ext
30460 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
30461 echo "${ECHO_T}$ac_header_compiler" >&6
30462
30463 # Is the header present?
30464 echo "$as_me:$LINENO: checking $ac_header presence" >&5
30465 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
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 <$ac_header>
30474 _ACEOF
30475 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
30476   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
30477   ac_status=$?
30478   grep -v '^ *+' conftest.er1 >conftest.err
30479   rm -f conftest.er1
30480   cat conftest.err >&5
30481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30482   (exit $ac_status); } >/dev/null; then
30483   if test -s conftest.err; then
30484     ac_cpp_err=$ac_c_preproc_warn_flag
30485   else
30486     ac_cpp_err=
30487   fi
30488 else
30489   ac_cpp_err=yes
30490 fi
30491 if test -z "$ac_cpp_err"; then
30492   ac_header_preproc=yes
30493 else
30494   echo "$as_me: failed program was:" >&5
30495 sed 's/^/| /' conftest.$ac_ext >&5
30496
30497   ac_header_preproc=no
30498 fi
30499 rm -f conftest.err conftest.$ac_ext
30500 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
30501 echo "${ECHO_T}$ac_header_preproc" >&6
30502
30503 # So?  What about this header?
30504 case $ac_header_compiler:$ac_header_preproc in
30505   yes:no )
30506     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
30507 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
30508     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
30509 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
30510     (
30511       cat <<\_ASBOX
30512 ## ------------------------------------ ##
30513 ## Report this to bug-autoconf@gnu.org. ##
30514 ## ------------------------------------ ##
30515 _ASBOX
30516     ) |
30517       sed "s/^/$as_me: WARNING:     /" >&2
30518     ;;
30519   no:yes )
30520     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
30521 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
30522     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
30523 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
30524     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
30525 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
30526     (
30527       cat <<\_ASBOX
30528 ## ------------------------------------ ##
30529 ## Report this to bug-autoconf@gnu.org. ##
30530 ## ------------------------------------ ##
30531 _ASBOX
30532     ) |
30533       sed "s/^/$as_me: WARNING:     /" >&2
30534     ;;
30535 esac
30536 echo "$as_me:$LINENO: checking for $ac_header" >&5
30537 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30538 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30539   echo $ECHO_N "(cached) $ECHO_C" >&6
30540 else
30541   eval "$as_ac_Header=$ac_header_preproc"
30542 fi
30543 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30544 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30545
30546 fi
30547 if test `eval echo '${'$as_ac_Header'}'` = yes; then
30548   cat >>confdefs.h <<_ACEOF
30549 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
30550 _ACEOF
30551
30552 fi
30553
30554 done
30555
30556
30557         if test $ac_cv_header_readline_readline_h = yes ; then
30558                 save_LIBS="$LIBS"
30559                 LIBS="$TERMCAP_LIBS $LIBS"
30560                 echo "$as_me:$LINENO: checking for readline in -lreadline" >&5
30561 echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6
30562 if test "${ac_cv_lib_readline_readline+set}" = set; then
30563   echo $ECHO_N "(cached) $ECHO_C" >&6
30564 else
30565   ac_check_lib_save_LIBS=$LIBS
30566 LIBS="-lreadline  $LIBS"
30567 cat >conftest.$ac_ext <<_ACEOF
30568 #line $LINENO "configure"
30569 /* confdefs.h.  */
30570 _ACEOF
30571 cat confdefs.h >>conftest.$ac_ext
30572 cat >>conftest.$ac_ext <<_ACEOF
30573 /* end confdefs.h.  */
30574
30575 /* Override any gcc2 internal prototype to avoid an error.  */
30576 #ifdef __cplusplus
30577 extern "C"
30578 #endif
30579 /* We use char because int might match the return type of a gcc2
30580    builtin and then its argument prototype would still apply.  */
30581 char readline ();
30582 int
30583 main ()
30584 {
30585 readline ();
30586   ;
30587   return 0;
30588 }
30589 _ACEOF
30590 rm -f conftest.$ac_objext conftest$ac_exeext
30591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30592   (eval $ac_link) 2>&5
30593   ac_status=$?
30594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30595   (exit $ac_status); } &&
30596          { ac_try='test -s conftest$ac_exeext'
30597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30598   (eval $ac_try) 2>&5
30599   ac_status=$?
30600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30601   (exit $ac_status); }; }; then
30602   ac_cv_lib_readline_readline=yes
30603 else
30604   echo "$as_me: failed program was:" >&5
30605 sed 's/^/| /' conftest.$ac_ext >&5
30606
30607 ac_cv_lib_readline_readline=no
30608 fi
30609 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30610 LIBS=$ac_check_lib_save_LIBS
30611 fi
30612 echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5
30613 echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6
30614 if test $ac_cv_lib_readline_readline = yes; then
30615   have_readline=yes
30616 else
30617   have_readline=no
30618 fi
30619
30620                 LIBS="$save_LIBS"
30621
30622                 if test $have_readline = yes ; then
30623                         ol_with_readline=found
30624                         ol_link_readline=yes
30625
30626                         READLINE_LIBS="-lreadline"
30627                 fi
30628         fi
30629 fi
30630
30631 if test $ol_link_readline = yes ; then
30632
30633 cat >>confdefs.h <<\_ACEOF
30634 #define HAVE_READLINE 1
30635 _ACEOF
30636
30637 fi
30638
30639
30640 if test $ol_enable_crypt != no ; then
30641         save_LIBS="$LIBS"
30642         LIBS="$TLS_LIBS $LIBS"
30643
30644         echo "$as_me:$LINENO: checking for crypt" >&5
30645 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
30646 if test "${ac_cv_func_crypt+set}" = set; then
30647   echo $ECHO_N "(cached) $ECHO_C" >&6
30648 else
30649   cat >conftest.$ac_ext <<_ACEOF
30650 #line $LINENO "configure"
30651 /* confdefs.h.  */
30652 _ACEOF
30653 cat confdefs.h >>conftest.$ac_ext
30654 cat >>conftest.$ac_ext <<_ACEOF
30655 /* end confdefs.h.  */
30656 /* System header to define __stub macros and hopefully few prototypes,
30657     which can conflict with char crypt (); below.
30658     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30659     <limits.h> exists even on freestanding compilers.  */
30660 #ifdef __STDC__
30661 # include <limits.h>
30662 #else
30663 # include <assert.h>
30664 #endif
30665 /* Override any gcc2 internal prototype to avoid an error.  */
30666 #ifdef __cplusplus
30667 extern "C"
30668 {
30669 #endif
30670 /* We use char because int might match the return type of a gcc2
30671    builtin and then its argument prototype would still apply.  */
30672 char crypt ();
30673 /* The GNU C library defines this for functions which it implements
30674     to always fail with ENOSYS.  Some functions are actually named
30675     something starting with __ and the normal name is an alias.  */
30676 #if defined (__stub_crypt) || defined (__stub___crypt)
30677 choke me
30678 #else
30679 char (*f) () = crypt;
30680 #endif
30681 #ifdef __cplusplus
30682 }
30683 #endif
30684
30685 int
30686 main ()
30687 {
30688 return f != crypt;
30689   ;
30690   return 0;
30691 }
30692 _ACEOF
30693 rm -f conftest.$ac_objext conftest$ac_exeext
30694 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30695   (eval $ac_link) 2>&5
30696   ac_status=$?
30697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30698   (exit $ac_status); } &&
30699          { ac_try='test -s conftest$ac_exeext'
30700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30701   (eval $ac_try) 2>&5
30702   ac_status=$?
30703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30704   (exit $ac_status); }; }; then
30705   ac_cv_func_crypt=yes
30706 else
30707   echo "$as_me: failed program was:" >&5
30708 sed 's/^/| /' conftest.$ac_ext >&5
30709
30710 ac_cv_func_crypt=no
30711 fi
30712 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30713 fi
30714 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
30715 echo "${ECHO_T}$ac_cv_func_crypt" >&6
30716 if test $ac_cv_func_crypt = yes; then
30717   have_crypt=yes
30718 else
30719
30720                 LIBS="$save_LIBS"
30721                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
30722 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
30723 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
30724   echo $ECHO_N "(cached) $ECHO_C" >&6
30725 else
30726   ac_check_lib_save_LIBS=$LIBS
30727 LIBS="-lcrypt  $LIBS"
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
30736 /* Override any gcc2 internal prototype to avoid an error.  */
30737 #ifdef __cplusplus
30738 extern "C"
30739 #endif
30740 /* We use char because int might match the return type of a gcc2
30741    builtin and then its argument prototype would still apply.  */
30742 char crypt ();
30743 int
30744 main ()
30745 {
30746 crypt ();
30747   ;
30748   return 0;
30749 }
30750 _ACEOF
30751 rm -f conftest.$ac_objext conftest$ac_exeext
30752 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30753   (eval $ac_link) 2>&5
30754   ac_status=$?
30755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30756   (exit $ac_status); } &&
30757          { ac_try='test -s conftest$ac_exeext'
30758   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30759   (eval $ac_try) 2>&5
30760   ac_status=$?
30761   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30762   (exit $ac_status); }; }; then
30763   ac_cv_lib_crypt_crypt=yes
30764 else
30765   echo "$as_me: failed program was:" >&5
30766 sed 's/^/| /' conftest.$ac_ext >&5
30767
30768 ac_cv_lib_crypt_crypt=no
30769 fi
30770 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30771 LIBS=$ac_check_lib_save_LIBS
30772 fi
30773 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
30774 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
30775 if test $ac_cv_lib_crypt_crypt = yes; then
30776   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
30777                         have_crypt=yes
30778 else
30779   have_crypt=no
30780 fi
30781
30782 fi
30783
30784
30785         LIBS="$save_LIBS"
30786
30787         if test $have_crypt = yes ; then
30788
30789 cat >>confdefs.h <<\_ACEOF
30790 #define HAVE_CRYPT 1
30791 _ACEOF
30792
30793         else
30794                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
30795 echo "$as_me: WARNING: could not find crypt" >&2;}
30796                 if test $ol_enable_crypt = yes ; then
30797                         { { echo "$as_me:$LINENO: error: could not find crypt" >&5
30798 echo "$as_me: error: could not find crypt" >&2;}
30799    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
30800                 fi
30801
30802                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
30803 echo "$as_me: WARNING: disabling crypt support" >&2;}
30804                 ol_enable_crypt=no
30805         fi
30806 fi
30807
30808 if test $ol_enable_proctitle != no ; then
30809         echo "$as_me:$LINENO: checking for setproctitle" >&5
30810 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
30811 if test "${ac_cv_func_setproctitle+set}" = set; then
30812   echo $ECHO_N "(cached) $ECHO_C" >&6
30813 else
30814   cat >conftest.$ac_ext <<_ACEOF
30815 #line $LINENO "configure"
30816 /* confdefs.h.  */
30817 _ACEOF
30818 cat confdefs.h >>conftest.$ac_ext
30819 cat >>conftest.$ac_ext <<_ACEOF
30820 /* end confdefs.h.  */
30821 /* System header to define __stub macros and hopefully few prototypes,
30822     which can conflict with char setproctitle (); below.
30823     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30824     <limits.h> exists even on freestanding compilers.  */
30825 #ifdef __STDC__
30826 # include <limits.h>
30827 #else
30828 # include <assert.h>
30829 #endif
30830 /* Override any gcc2 internal prototype to avoid an error.  */
30831 #ifdef __cplusplus
30832 extern "C"
30833 {
30834 #endif
30835 /* We use char because int might match the return type of a gcc2
30836    builtin and then its argument prototype would still apply.  */
30837 char setproctitle ();
30838 /* The GNU C library defines this for functions which it implements
30839     to always fail with ENOSYS.  Some functions are actually named
30840     something starting with __ and the normal name is an alias.  */
30841 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
30842 choke me
30843 #else
30844 char (*f) () = setproctitle;
30845 #endif
30846 #ifdef __cplusplus
30847 }
30848 #endif
30849
30850 int
30851 main ()
30852 {
30853 return f != setproctitle;
30854   ;
30855   return 0;
30856 }
30857 _ACEOF
30858 rm -f conftest.$ac_objext conftest$ac_exeext
30859 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30860   (eval $ac_link) 2>&5
30861   ac_status=$?
30862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30863   (exit $ac_status); } &&
30864          { ac_try='test -s conftest$ac_exeext'
30865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30866   (eval $ac_try) 2>&5
30867   ac_status=$?
30868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30869   (exit $ac_status); }; }; then
30870   ac_cv_func_setproctitle=yes
30871 else
30872   echo "$as_me: failed program was:" >&5
30873 sed 's/^/| /' conftest.$ac_ext >&5
30874
30875 ac_cv_func_setproctitle=no
30876 fi
30877 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30878 fi
30879 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
30880 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
30881 if test $ac_cv_func_setproctitle = yes; then
30882   have_setproctitle=yes
30883 else
30884
30885                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
30886 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
30887 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
30888   echo $ECHO_N "(cached) $ECHO_C" >&6
30889 else
30890   ac_check_lib_save_LIBS=$LIBS
30891 LIBS="-lutil  $LIBS"
30892 cat >conftest.$ac_ext <<_ACEOF
30893 #line $LINENO "configure"
30894 /* confdefs.h.  */
30895 _ACEOF
30896 cat confdefs.h >>conftest.$ac_ext
30897 cat >>conftest.$ac_ext <<_ACEOF
30898 /* end confdefs.h.  */
30899
30900 /* Override any gcc2 internal prototype to avoid an error.  */
30901 #ifdef __cplusplus
30902 extern "C"
30903 #endif
30904 /* We use char because int might match the return type of a gcc2
30905    builtin and then its argument prototype would still apply.  */
30906 char setproctitle ();
30907 int
30908 main ()
30909 {
30910 setproctitle ();
30911   ;
30912   return 0;
30913 }
30914 _ACEOF
30915 rm -f conftest.$ac_objext conftest$ac_exeext
30916 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30917   (eval $ac_link) 2>&5
30918   ac_status=$?
30919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30920   (exit $ac_status); } &&
30921          { ac_try='test -s conftest$ac_exeext'
30922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30923   (eval $ac_try) 2>&5
30924   ac_status=$?
30925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30926   (exit $ac_status); }; }; then
30927   ac_cv_lib_util_setproctitle=yes
30928 else
30929   echo "$as_me: failed program was:" >&5
30930 sed 's/^/| /' conftest.$ac_ext >&5
30931
30932 ac_cv_lib_util_setproctitle=no
30933 fi
30934 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
30935 LIBS=$ac_check_lib_save_LIBS
30936 fi
30937 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
30938 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
30939 if test $ac_cv_lib_util_setproctitle = yes; then
30940   have_setproctitle=yes
30941                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
30942 else
30943   have_setproctitle=no
30944                         LIBOBJS="$LIBOBJS setproctitle.$ac_objext"
30945                         LIBSRCS="$LIBSRCS setproctitle.c"
30946 fi
30947
30948 fi
30949
30950
30951         if test $have_setproctitle = yes ; then
30952
30953 cat >>confdefs.h <<\_ACEOF
30954 #define HAVE_SETPROCTITLE 1
30955 _ACEOF
30956
30957         fi
30958 fi
30959
30960 if test $ol_enable_slp != no ; then
30961
30962 for ac_header in slp.h
30963 do
30964 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
30965 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30966   echo "$as_me:$LINENO: checking for $ac_header" >&5
30967 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30968 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30969   echo $ECHO_N "(cached) $ECHO_C" >&6
30970 fi
30971 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30972 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30973 else
30974   # Is the header compilable?
30975 echo "$as_me:$LINENO: checking $ac_header usability" >&5
30976 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
30977 cat >conftest.$ac_ext <<_ACEOF
30978 #line $LINENO "configure"
30979 /* confdefs.h.  */
30980 _ACEOF
30981 cat confdefs.h >>conftest.$ac_ext
30982 cat >>conftest.$ac_ext <<_ACEOF
30983 /* end confdefs.h.  */
30984 $ac_includes_default
30985 #include <$ac_header>
30986 _ACEOF
30987 rm -f conftest.$ac_objext
30988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30989   (eval $ac_compile) 2>&5
30990   ac_status=$?
30991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30992   (exit $ac_status); } &&
30993          { ac_try='test -s conftest.$ac_objext'
30994   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30995   (eval $ac_try) 2>&5
30996   ac_status=$?
30997   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30998   (exit $ac_status); }; }; then
30999   ac_header_compiler=yes
31000 else
31001   echo "$as_me: failed program was:" >&5
31002 sed 's/^/| /' conftest.$ac_ext >&5
31003
31004 ac_header_compiler=no
31005 fi
31006 rm -f conftest.$ac_objext conftest.$ac_ext
31007 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31008 echo "${ECHO_T}$ac_header_compiler" >&6
31009
31010 # Is the header present?
31011 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31012 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31013 cat >conftest.$ac_ext <<_ACEOF
31014 #line $LINENO "configure"
31015 /* confdefs.h.  */
31016 _ACEOF
31017 cat confdefs.h >>conftest.$ac_ext
31018 cat >>conftest.$ac_ext <<_ACEOF
31019 /* end confdefs.h.  */
31020 #include <$ac_header>
31021 _ACEOF
31022 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31023   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31024   ac_status=$?
31025   grep -v '^ *+' conftest.er1 >conftest.err
31026   rm -f conftest.er1
31027   cat conftest.err >&5
31028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31029   (exit $ac_status); } >/dev/null; then
31030   if test -s conftest.err; then
31031     ac_cpp_err=$ac_c_preproc_warn_flag
31032   else
31033     ac_cpp_err=
31034   fi
31035 else
31036   ac_cpp_err=yes
31037 fi
31038 if test -z "$ac_cpp_err"; then
31039   ac_header_preproc=yes
31040 else
31041   echo "$as_me: failed program was:" >&5
31042 sed 's/^/| /' conftest.$ac_ext >&5
31043
31044   ac_header_preproc=no
31045 fi
31046 rm -f conftest.err conftest.$ac_ext
31047 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31048 echo "${ECHO_T}$ac_header_preproc" >&6
31049
31050 # So?  What about this header?
31051 case $ac_header_compiler:$ac_header_preproc in
31052   yes:no )
31053     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31054 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31055     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31056 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31057     (
31058       cat <<\_ASBOX
31059 ## ------------------------------------ ##
31060 ## Report this to bug-autoconf@gnu.org. ##
31061 ## ------------------------------------ ##
31062 _ASBOX
31063     ) |
31064       sed "s/^/$as_me: WARNING:     /" >&2
31065     ;;
31066   no:yes )
31067     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31068 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31069     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
31070 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
31071     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31072 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31073     (
31074       cat <<\_ASBOX
31075 ## ------------------------------------ ##
31076 ## Report this to bug-autoconf@gnu.org. ##
31077 ## ------------------------------------ ##
31078 _ASBOX
31079     ) |
31080       sed "s/^/$as_me: WARNING:     /" >&2
31081     ;;
31082 esac
31083 echo "$as_me:$LINENO: checking for $ac_header" >&5
31084 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31085 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31086   echo $ECHO_N "(cached) $ECHO_C" >&6
31087 else
31088   eval "$as_ac_Header=$ac_header_preproc"
31089 fi
31090 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31091 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31092
31093 fi
31094 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31095   cat >>confdefs.h <<_ACEOF
31096 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31097 _ACEOF
31098
31099 fi
31100
31101 done
31102
31103
31104         if test $ac_cv_header_slp_h = yes ; then
31105                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
31106 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
31107 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
31108   echo $ECHO_N "(cached) $ECHO_C" >&6
31109 else
31110   ac_check_lib_save_LIBS=$LIBS
31111 LIBS="-lslp  $LIBS"
31112 cat >conftest.$ac_ext <<_ACEOF
31113 #line $LINENO "configure"
31114 /* confdefs.h.  */
31115 _ACEOF
31116 cat confdefs.h >>conftest.$ac_ext
31117 cat >>conftest.$ac_ext <<_ACEOF
31118 /* end confdefs.h.  */
31119
31120 /* Override any gcc2 internal prototype to avoid an error.  */
31121 #ifdef __cplusplus
31122 extern "C"
31123 #endif
31124 /* We use char because int might match the return type of a gcc2
31125    builtin and then its argument prototype would still apply.  */
31126 char SLPOpen ();
31127 int
31128 main ()
31129 {
31130 SLPOpen ();
31131   ;
31132   return 0;
31133 }
31134 _ACEOF
31135 rm -f conftest.$ac_objext conftest$ac_exeext
31136 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31137   (eval $ac_link) 2>&5
31138   ac_status=$?
31139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31140   (exit $ac_status); } &&
31141          { ac_try='test -s conftest$ac_exeext'
31142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31143   (eval $ac_try) 2>&5
31144   ac_status=$?
31145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31146   (exit $ac_status); }; }; then
31147   ac_cv_lib_slp_SLPOpen=yes
31148 else
31149   echo "$as_me: failed program was:" >&5
31150 sed 's/^/| /' conftest.$ac_ext >&5
31151
31152 ac_cv_lib_slp_SLPOpen=no
31153 fi
31154 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31155 LIBS=$ac_check_lib_save_LIBS
31156 fi
31157 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
31158 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
31159 if test $ac_cv_lib_slp_SLPOpen = yes; then
31160   have_slp=yes
31161 else
31162   have_slp=no
31163 fi
31164
31165                 if test $have_slp = yes ; then
31166
31167 cat >>confdefs.h <<\_ACEOF
31168 #define HAVE_SLP 1
31169 _ACEOF
31170
31171                         SLAPD_SLP_LIBS=-lslp
31172                 fi
31173
31174         elif test $ol_enable_slp = yes ; then
31175                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
31176 echo "$as_me: error: SLP not found" >&2;}
31177    { (exit 1); exit 1; }; }
31178         fi
31179 fi
31180
31181 echo "$as_me:$LINENO: checking for mode_t" >&5
31182 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
31183 if test "${ac_cv_type_mode_t+set}" = set; then
31184   echo $ECHO_N "(cached) $ECHO_C" >&6
31185 else
31186   cat >conftest.$ac_ext <<_ACEOF
31187 #line $LINENO "configure"
31188 /* confdefs.h.  */
31189 _ACEOF
31190 cat confdefs.h >>conftest.$ac_ext
31191 cat >>conftest.$ac_ext <<_ACEOF
31192 /* end confdefs.h.  */
31193 $ac_includes_default
31194 int
31195 main ()
31196 {
31197 if ((mode_t *) 0)
31198   return 0;
31199 if (sizeof (mode_t))
31200   return 0;
31201   ;
31202   return 0;
31203 }
31204 _ACEOF
31205 rm -f conftest.$ac_objext
31206 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31207   (eval $ac_compile) 2>&5
31208   ac_status=$?
31209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31210   (exit $ac_status); } &&
31211          { ac_try='test -s conftest.$ac_objext'
31212   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31213   (eval $ac_try) 2>&5
31214   ac_status=$?
31215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31216   (exit $ac_status); }; }; then
31217   ac_cv_type_mode_t=yes
31218 else
31219   echo "$as_me: failed program was:" >&5
31220 sed 's/^/| /' conftest.$ac_ext >&5
31221
31222 ac_cv_type_mode_t=no
31223 fi
31224 rm -f conftest.$ac_objext conftest.$ac_ext
31225 fi
31226 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
31227 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
31228 if test $ac_cv_type_mode_t = yes; then
31229   :
31230 else
31231
31232 cat >>confdefs.h <<_ACEOF
31233 #define mode_t int
31234 _ACEOF
31235
31236 fi
31237
31238 echo "$as_me:$LINENO: checking for off_t" >&5
31239 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
31240 if test "${ac_cv_type_off_t+set}" = set; then
31241   echo $ECHO_N "(cached) $ECHO_C" >&6
31242 else
31243   cat >conftest.$ac_ext <<_ACEOF
31244 #line $LINENO "configure"
31245 /* confdefs.h.  */
31246 _ACEOF
31247 cat confdefs.h >>conftest.$ac_ext
31248 cat >>conftest.$ac_ext <<_ACEOF
31249 /* end confdefs.h.  */
31250 $ac_includes_default
31251 int
31252 main ()
31253 {
31254 if ((off_t *) 0)
31255   return 0;
31256 if (sizeof (off_t))
31257   return 0;
31258   ;
31259   return 0;
31260 }
31261 _ACEOF
31262 rm -f conftest.$ac_objext
31263 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31264   (eval $ac_compile) 2>&5
31265   ac_status=$?
31266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31267   (exit $ac_status); } &&
31268          { ac_try='test -s conftest.$ac_objext'
31269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31270   (eval $ac_try) 2>&5
31271   ac_status=$?
31272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31273   (exit $ac_status); }; }; then
31274   ac_cv_type_off_t=yes
31275 else
31276   echo "$as_me: failed program was:" >&5
31277 sed 's/^/| /' conftest.$ac_ext >&5
31278
31279 ac_cv_type_off_t=no
31280 fi
31281 rm -f conftest.$ac_objext conftest.$ac_ext
31282 fi
31283 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
31284 echo "${ECHO_T}$ac_cv_type_off_t" >&6
31285 if test $ac_cv_type_off_t = yes; then
31286   :
31287 else
31288
31289 cat >>confdefs.h <<_ACEOF
31290 #define off_t long
31291 _ACEOF
31292
31293 fi
31294
31295 echo "$as_me:$LINENO: checking for pid_t" >&5
31296 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
31297 if test "${ac_cv_type_pid_t+set}" = set; then
31298   echo $ECHO_N "(cached) $ECHO_C" >&6
31299 else
31300   cat >conftest.$ac_ext <<_ACEOF
31301 #line $LINENO "configure"
31302 /* confdefs.h.  */
31303 _ACEOF
31304 cat confdefs.h >>conftest.$ac_ext
31305 cat >>conftest.$ac_ext <<_ACEOF
31306 /* end confdefs.h.  */
31307 $ac_includes_default
31308 int
31309 main ()
31310 {
31311 if ((pid_t *) 0)
31312   return 0;
31313 if (sizeof (pid_t))
31314   return 0;
31315   ;
31316   return 0;
31317 }
31318 _ACEOF
31319 rm -f conftest.$ac_objext
31320 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31321   (eval $ac_compile) 2>&5
31322   ac_status=$?
31323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31324   (exit $ac_status); } &&
31325          { ac_try='test -s conftest.$ac_objext'
31326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31327   (eval $ac_try) 2>&5
31328   ac_status=$?
31329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31330   (exit $ac_status); }; }; then
31331   ac_cv_type_pid_t=yes
31332 else
31333   echo "$as_me: failed program was:" >&5
31334 sed 's/^/| /' conftest.$ac_ext >&5
31335
31336 ac_cv_type_pid_t=no
31337 fi
31338 rm -f conftest.$ac_objext conftest.$ac_ext
31339 fi
31340 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
31341 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
31342 if test $ac_cv_type_pid_t = yes; then
31343   :
31344 else
31345
31346 cat >>confdefs.h <<_ACEOF
31347 #define pid_t int
31348 _ACEOF
31349
31350 fi
31351
31352 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
31353 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
31354 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
31355   echo $ECHO_N "(cached) $ECHO_C" >&6
31356 else
31357   cat >conftest.$ac_ext <<_ACEOF
31358 #line $LINENO "configure"
31359 /* confdefs.h.  */
31360 _ACEOF
31361 cat confdefs.h >>conftest.$ac_ext
31362 cat >>conftest.$ac_ext <<_ACEOF
31363 /* end confdefs.h.  */
31364 $ac_includes_default
31365 int
31366 main ()
31367 {
31368 if ((ptrdiff_t *) 0)
31369   return 0;
31370 if (sizeof (ptrdiff_t))
31371   return 0;
31372   ;
31373   return 0;
31374 }
31375 _ACEOF
31376 rm -f conftest.$ac_objext
31377 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31378   (eval $ac_compile) 2>&5
31379   ac_status=$?
31380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31381   (exit $ac_status); } &&
31382          { ac_try='test -s conftest.$ac_objext'
31383   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31384   (eval $ac_try) 2>&5
31385   ac_status=$?
31386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31387   (exit $ac_status); }; }; then
31388   ac_cv_type_ptrdiff_t=yes
31389 else
31390   echo "$as_me: failed program was:" >&5
31391 sed 's/^/| /' conftest.$ac_ext >&5
31392
31393 ac_cv_type_ptrdiff_t=no
31394 fi
31395 rm -f conftest.$ac_objext conftest.$ac_ext
31396 fi
31397 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
31398 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
31399 if test $ac_cv_type_ptrdiff_t = yes; then
31400
31401 cat >>confdefs.h <<_ACEOF
31402 #define HAVE_PTRDIFF_T 1
31403 _ACEOF
31404
31405
31406 fi
31407 echo "$as_me:$LINENO: checking for uintmax_t" >&5
31408 echo $ECHO_N "checking for uintmax_t... $ECHO_C" >&6
31409 if test "${ac_cv_type_uintmax_t+set}" = set; then
31410   echo $ECHO_N "(cached) $ECHO_C" >&6
31411 else
31412   cat >conftest.$ac_ext <<_ACEOF
31413 #line $LINENO "configure"
31414 /* confdefs.h.  */
31415 _ACEOF
31416 cat confdefs.h >>conftest.$ac_ext
31417 cat >>conftest.$ac_ext <<_ACEOF
31418 /* end confdefs.h.  */
31419 $ac_includes_default
31420 int
31421 main ()
31422 {
31423 if ((uintmax_t *) 0)
31424   return 0;
31425 if (sizeof (uintmax_t))
31426   return 0;
31427   ;
31428   return 0;
31429 }
31430 _ACEOF
31431 rm -f conftest.$ac_objext
31432 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31433   (eval $ac_compile) 2>&5
31434   ac_status=$?
31435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31436   (exit $ac_status); } &&
31437          { ac_try='test -s conftest.$ac_objext'
31438   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31439   (eval $ac_try) 2>&5
31440   ac_status=$?
31441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31442   (exit $ac_status); }; }; then
31443   ac_cv_type_uintmax_t=yes
31444 else
31445   echo "$as_me: failed program was:" >&5
31446 sed 's/^/| /' conftest.$ac_ext >&5
31447
31448 ac_cv_type_uintmax_t=no
31449 fi
31450 rm -f conftest.$ac_objext conftest.$ac_ext
31451 fi
31452 echo "$as_me:$LINENO: result: $ac_cv_type_uintmax_t" >&5
31453 echo "${ECHO_T}$ac_cv_type_uintmax_t" >&6
31454 if test $ac_cv_type_uintmax_t = yes; then
31455
31456 cat >>confdefs.h <<_ACEOF
31457 #define HAVE_UINTMAX_T 1
31458 _ACEOF
31459
31460
31461 fi
31462
31463 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
31464 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
31465 if test "${ac_cv_type_signal+set}" = set; then
31466   echo $ECHO_N "(cached) $ECHO_C" >&6
31467 else
31468   cat >conftest.$ac_ext <<_ACEOF
31469 #line $LINENO "configure"
31470 /* confdefs.h.  */
31471 _ACEOF
31472 cat confdefs.h >>conftest.$ac_ext
31473 cat >>conftest.$ac_ext <<_ACEOF
31474 /* end confdefs.h.  */
31475 #include <sys/types.h>
31476 #include <signal.h>
31477 #ifdef signal
31478 # undef signal
31479 #endif
31480 #ifdef __cplusplus
31481 extern "C" void (*signal (int, void (*)(int)))(int);
31482 #else
31483 void (*signal ()) ();
31484 #endif
31485
31486 int
31487 main ()
31488 {
31489 int i;
31490   ;
31491   return 0;
31492 }
31493 _ACEOF
31494 rm -f conftest.$ac_objext
31495 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31496   (eval $ac_compile) 2>&5
31497   ac_status=$?
31498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31499   (exit $ac_status); } &&
31500          { ac_try='test -s conftest.$ac_objext'
31501   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31502   (eval $ac_try) 2>&5
31503   ac_status=$?
31504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31505   (exit $ac_status); }; }; then
31506   ac_cv_type_signal=void
31507 else
31508   echo "$as_me: failed program was:" >&5
31509 sed 's/^/| /' conftest.$ac_ext >&5
31510
31511 ac_cv_type_signal=int
31512 fi
31513 rm -f conftest.$ac_objext conftest.$ac_ext
31514 fi
31515 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
31516 echo "${ECHO_T}$ac_cv_type_signal" >&6
31517
31518 cat >>confdefs.h <<_ACEOF
31519 #define RETSIGTYPE $ac_cv_type_signal
31520 _ACEOF
31521
31522
31523 echo "$as_me:$LINENO: checking for size_t" >&5
31524 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
31525 if test "${ac_cv_type_size_t+set}" = set; then
31526   echo $ECHO_N "(cached) $ECHO_C" >&6
31527 else
31528   cat >conftest.$ac_ext <<_ACEOF
31529 #line $LINENO "configure"
31530 /* confdefs.h.  */
31531 _ACEOF
31532 cat confdefs.h >>conftest.$ac_ext
31533 cat >>conftest.$ac_ext <<_ACEOF
31534 /* end confdefs.h.  */
31535 $ac_includes_default
31536 int
31537 main ()
31538 {
31539 if ((size_t *) 0)
31540   return 0;
31541 if (sizeof (size_t))
31542   return 0;
31543   ;
31544   return 0;
31545 }
31546 _ACEOF
31547 rm -f conftest.$ac_objext
31548 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31549   (eval $ac_compile) 2>&5
31550   ac_status=$?
31551   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31552   (exit $ac_status); } &&
31553          { ac_try='test -s conftest.$ac_objext'
31554   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31555   (eval $ac_try) 2>&5
31556   ac_status=$?
31557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31558   (exit $ac_status); }; }; then
31559   ac_cv_type_size_t=yes
31560 else
31561   echo "$as_me: failed program was:" >&5
31562 sed 's/^/| /' conftest.$ac_ext >&5
31563
31564 ac_cv_type_size_t=no
31565 fi
31566 rm -f conftest.$ac_objext conftest.$ac_ext
31567 fi
31568 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
31569 echo "${ECHO_T}$ac_cv_type_size_t" >&6
31570 if test $ac_cv_type_size_t = yes; then
31571   :
31572 else
31573
31574 cat >>confdefs.h <<_ACEOF
31575 #define size_t unsigned
31576 _ACEOF
31577
31578 fi
31579
31580
31581 echo "$as_me:$LINENO: checking for ssize_t" >&5
31582 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
31583 if test "${ac_cv_type_ssize_t+set}" = set; then
31584   echo $ECHO_N "(cached) $ECHO_C" >&6
31585 else
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 $ac_includes_default
31594 int
31595 main ()
31596 {
31597 if ((ssize_t *) 0)
31598   return 0;
31599 if (sizeof (ssize_t))
31600   return 0;
31601   ;
31602   return 0;
31603 }
31604 _ACEOF
31605 rm -f conftest.$ac_objext
31606 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31607   (eval $ac_compile) 2>&5
31608   ac_status=$?
31609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31610   (exit $ac_status); } &&
31611          { ac_try='test -s conftest.$ac_objext'
31612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31613   (eval $ac_try) 2>&5
31614   ac_status=$?
31615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31616   (exit $ac_status); }; }; then
31617   ac_cv_type_ssize_t=yes
31618 else
31619   echo "$as_me: failed program was:" >&5
31620 sed 's/^/| /' conftest.$ac_ext >&5
31621
31622 ac_cv_type_ssize_t=no
31623 fi
31624 rm -f conftest.$ac_objext conftest.$ac_ext
31625 fi
31626 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
31627 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
31628 if test $ac_cv_type_ssize_t = yes; then
31629
31630 cat >>confdefs.h <<_ACEOF
31631 #define HAVE_SSIZE_T 1
31632 _ACEOF
31633
31634
31635 fi
31636 echo "$as_me:$LINENO: checking for signed int" >&5
31637 echo $ECHO_N "checking for signed int... $ECHO_C" >&6
31638 if test "${ac_cv_type_signed_int+set}" = set; then
31639   echo $ECHO_N "(cached) $ECHO_C" >&6
31640 else
31641   cat >conftest.$ac_ext <<_ACEOF
31642 #line $LINENO "configure"
31643 /* confdefs.h.  */
31644 _ACEOF
31645 cat confdefs.h >>conftest.$ac_ext
31646 cat >>conftest.$ac_ext <<_ACEOF
31647 /* end confdefs.h.  */
31648 $ac_includes_default
31649 int
31650 main ()
31651 {
31652 if ((signed int *) 0)
31653   return 0;
31654 if (sizeof (signed int))
31655   return 0;
31656   ;
31657   return 0;
31658 }
31659 _ACEOF
31660 rm -f conftest.$ac_objext
31661 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31662   (eval $ac_compile) 2>&5
31663   ac_status=$?
31664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31665   (exit $ac_status); } &&
31666          { ac_try='test -s conftest.$ac_objext'
31667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31668   (eval $ac_try) 2>&5
31669   ac_status=$?
31670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31671   (exit $ac_status); }; }; then
31672   ac_cv_type_signed_int=yes
31673 else
31674   echo "$as_me: failed program was:" >&5
31675 sed 's/^/| /' conftest.$ac_ext >&5
31676
31677 ac_cv_type_signed_int=no
31678 fi
31679 rm -f conftest.$ac_objext conftest.$ac_ext
31680 fi
31681 echo "$as_me:$LINENO: result: $ac_cv_type_signed_int" >&5
31682 echo "${ECHO_T}$ac_cv_type_signed_int" >&6
31683 if test $ac_cv_type_signed_int = yes; then
31684
31685 cat >>confdefs.h <<_ACEOF
31686 #define HAVE_SIGNED_INT 1
31687 _ACEOF
31688
31689
31690 fi
31691
31692 echo "$as_me:$LINENO: checking for caddr_t" >&5
31693 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
31694 if test "${ac_cv_type_caddr_t+set}" = set; then
31695   echo $ECHO_N "(cached) $ECHO_C" >&6
31696 else
31697   cat >conftest.$ac_ext <<_ACEOF
31698 #line $LINENO "configure"
31699 /* confdefs.h.  */
31700 _ACEOF
31701 cat confdefs.h >>conftest.$ac_ext
31702 cat >>conftest.$ac_ext <<_ACEOF
31703 /* end confdefs.h.  */
31704 $ac_includes_default
31705 int
31706 main ()
31707 {
31708 if ((caddr_t *) 0)
31709   return 0;
31710 if (sizeof (caddr_t))
31711   return 0;
31712   ;
31713   return 0;
31714 }
31715 _ACEOF
31716 rm -f conftest.$ac_objext
31717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31718   (eval $ac_compile) 2>&5
31719   ac_status=$?
31720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31721   (exit $ac_status); } &&
31722          { ac_try='test -s conftest.$ac_objext'
31723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31724   (eval $ac_try) 2>&5
31725   ac_status=$?
31726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31727   (exit $ac_status); }; }; then
31728   ac_cv_type_caddr_t=yes
31729 else
31730   echo "$as_me: failed program was:" >&5
31731 sed 's/^/| /' conftest.$ac_ext >&5
31732
31733 ac_cv_type_caddr_t=no
31734 fi
31735 rm -f conftest.$ac_objext conftest.$ac_ext
31736 fi
31737 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
31738 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
31739 if test $ac_cv_type_caddr_t = yes; then
31740
31741 cat >>confdefs.h <<_ACEOF
31742 #define HAVE_CADDR_T 1
31743 _ACEOF
31744
31745
31746 fi
31747 echo "$as_me:$LINENO: checking for char *" >&5
31748 echo $ECHO_N "checking for char *... $ECHO_C" >&6
31749 if test "${ac_cv_type_char_p+set}" = set; then
31750   echo $ECHO_N "(cached) $ECHO_C" >&6
31751 else
31752   cat >conftest.$ac_ext <<_ACEOF
31753 #line $LINENO "configure"
31754 /* confdefs.h.  */
31755 _ACEOF
31756 cat confdefs.h >>conftest.$ac_ext
31757 cat >>conftest.$ac_ext <<_ACEOF
31758 /* end confdefs.h.  */
31759 $ac_includes_default
31760 int
31761 main ()
31762 {
31763 if ((char * *) 0)
31764   return 0;
31765 if (sizeof (char *))
31766   return 0;
31767   ;
31768   return 0;
31769 }
31770 _ACEOF
31771 rm -f conftest.$ac_objext
31772 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31773   (eval $ac_compile) 2>&5
31774   ac_status=$?
31775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31776   (exit $ac_status); } &&
31777          { ac_try='test -s conftest.$ac_objext'
31778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31779   (eval $ac_try) 2>&5
31780   ac_status=$?
31781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31782   (exit $ac_status); }; }; then
31783   ac_cv_type_char_p=yes
31784 else
31785   echo "$as_me: failed program was:" >&5
31786 sed 's/^/| /' conftest.$ac_ext >&5
31787
31788 ac_cv_type_char_p=no
31789 fi
31790 rm -f conftest.$ac_objext conftest.$ac_ext
31791 fi
31792 echo "$as_me:$LINENO: result: $ac_cv_type_char_p" >&5
31793 echo "${ECHO_T}$ac_cv_type_char_p" >&6
31794 if test $ac_cv_type_char_p = yes; then
31795
31796 cat >>confdefs.h <<_ACEOF
31797 #define HAVE_CHAR_P 1
31798 _ACEOF
31799
31800
31801 fi
31802
31803
31804 echo "$as_me:$LINENO: checking for socklen_t" >&5
31805 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
31806 if test "${ol_cv_type_socklen_t+set}" = set; then
31807   echo $ECHO_N "(cached) $ECHO_C" >&6
31808 else
31809   cat >conftest.$ac_ext <<_ACEOF
31810 #line $LINENO "configure"
31811 /* confdefs.h.  */
31812 _ACEOF
31813 cat confdefs.h >>conftest.$ac_ext
31814 cat >>conftest.$ac_ext <<_ACEOF
31815 /* end confdefs.h.  */
31816
31817 #ifdef HAVE_SYS_TYPES_H
31818 #include <sys/types.h>
31819 #endif
31820 #ifdef HAVE_SYS_SOCKET_H
31821 #include <sys/socket.h>
31822 #endif
31823
31824 int
31825 main ()
31826 {
31827 socklen_t len;
31828   ;
31829   return 0;
31830 }
31831 _ACEOF
31832 rm -f conftest.$ac_objext
31833 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31834   (eval $ac_compile) 2>&5
31835   ac_status=$?
31836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31837   (exit $ac_status); } &&
31838          { ac_try='test -s conftest.$ac_objext'
31839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31840   (eval $ac_try) 2>&5
31841   ac_status=$?
31842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31843   (exit $ac_status); }; }; then
31844   ol_cv_type_socklen_t=yes
31845 else
31846   echo "$as_me: failed program was:" >&5
31847 sed 's/^/| /' conftest.$ac_ext >&5
31848
31849 ol_cv_type_socklen_t=no
31850 fi
31851 rm -f conftest.$ac_objext conftest.$ac_ext
31852 fi
31853 echo "$as_me:$LINENO: result: $ol_cv_type_socklen_t" >&5
31854 echo "${ECHO_T}$ol_cv_type_socklen_t" >&6
31855   if test $ol_cv_type_socklen_t = no; then
31856
31857 cat >>confdefs.h <<\_ACEOF
31858 #define socklen_t int
31859 _ACEOF
31860
31861   fi
31862
31863
31864 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
31865 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
31866 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
31867   echo $ECHO_N "(cached) $ECHO_C" >&6
31868 else
31869   cat >conftest.$ac_ext <<_ACEOF
31870 #line $LINENO "configure"
31871 /* confdefs.h.  */
31872 _ACEOF
31873 cat confdefs.h >>conftest.$ac_ext
31874 cat >>conftest.$ac_ext <<_ACEOF
31875 /* end confdefs.h.  */
31876 $ac_includes_default
31877 int
31878 main ()
31879 {
31880 static struct stat ac_aggr;
31881 if (ac_aggr.st_blksize)
31882 return 0;
31883   ;
31884   return 0;
31885 }
31886 _ACEOF
31887 rm -f conftest.$ac_objext
31888 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31889   (eval $ac_compile) 2>&5
31890   ac_status=$?
31891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31892   (exit $ac_status); } &&
31893          { ac_try='test -s conftest.$ac_objext'
31894   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31895   (eval $ac_try) 2>&5
31896   ac_status=$?
31897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31898   (exit $ac_status); }; }; then
31899   ac_cv_member_struct_stat_st_blksize=yes
31900 else
31901   echo "$as_me: failed program was:" >&5
31902 sed 's/^/| /' conftest.$ac_ext >&5
31903
31904 cat >conftest.$ac_ext <<_ACEOF
31905 #line $LINENO "configure"
31906 /* confdefs.h.  */
31907 _ACEOF
31908 cat confdefs.h >>conftest.$ac_ext
31909 cat >>conftest.$ac_ext <<_ACEOF
31910 /* end confdefs.h.  */
31911 $ac_includes_default
31912 int
31913 main ()
31914 {
31915 static struct stat ac_aggr;
31916 if (sizeof ac_aggr.st_blksize)
31917 return 0;
31918   ;
31919   return 0;
31920 }
31921 _ACEOF
31922 rm -f conftest.$ac_objext
31923 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31924   (eval $ac_compile) 2>&5
31925   ac_status=$?
31926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31927   (exit $ac_status); } &&
31928          { ac_try='test -s conftest.$ac_objext'
31929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31930   (eval $ac_try) 2>&5
31931   ac_status=$?
31932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31933   (exit $ac_status); }; }; then
31934   ac_cv_member_struct_stat_st_blksize=yes
31935 else
31936   echo "$as_me: failed program was:" >&5
31937 sed 's/^/| /' conftest.$ac_ext >&5
31938
31939 ac_cv_member_struct_stat_st_blksize=no
31940 fi
31941 rm -f conftest.$ac_objext conftest.$ac_ext
31942 fi
31943 rm -f conftest.$ac_objext conftest.$ac_ext
31944 fi
31945 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
31946 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
31947 if test $ac_cv_member_struct_stat_st_blksize = yes; then
31948
31949 cat >>confdefs.h <<_ACEOF
31950 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
31951 _ACEOF
31952
31953
31954 cat >>confdefs.h <<\_ACEOF
31955 #define HAVE_ST_BLKSIZE 1
31956 _ACEOF
31957
31958 fi
31959
31960
31961 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
31962 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
31963 if test "${ac_cv_header_time+set}" = set; then
31964   echo $ECHO_N "(cached) $ECHO_C" >&6
31965 else
31966   cat >conftest.$ac_ext <<_ACEOF
31967 #line $LINENO "configure"
31968 /* confdefs.h.  */
31969 _ACEOF
31970 cat confdefs.h >>conftest.$ac_ext
31971 cat >>conftest.$ac_ext <<_ACEOF
31972 /* end confdefs.h.  */
31973 #include <sys/types.h>
31974 #include <sys/time.h>
31975 #include <time.h>
31976
31977 int
31978 main ()
31979 {
31980 if ((struct tm *) 0)
31981 return 0;
31982   ;
31983   return 0;
31984 }
31985 _ACEOF
31986 rm -f conftest.$ac_objext
31987 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31988   (eval $ac_compile) 2>&5
31989   ac_status=$?
31990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31991   (exit $ac_status); } &&
31992          { ac_try='test -s conftest.$ac_objext'
31993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31994   (eval $ac_try) 2>&5
31995   ac_status=$?
31996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31997   (exit $ac_status); }; }; then
31998   ac_cv_header_time=yes
31999 else
32000   echo "$as_me: failed program was:" >&5
32001 sed 's/^/| /' conftest.$ac_ext >&5
32002
32003 ac_cv_header_time=no
32004 fi
32005 rm -f conftest.$ac_objext conftest.$ac_ext
32006 fi
32007 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
32008 echo "${ECHO_T}$ac_cv_header_time" >&6
32009 if test $ac_cv_header_time = yes; then
32010
32011 cat >>confdefs.h <<\_ACEOF
32012 #define TIME_WITH_SYS_TIME 1
32013 _ACEOF
32014
32015 fi
32016
32017 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
32018 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
32019 if test "${ac_cv_struct_tm+set}" = set; then
32020   echo $ECHO_N "(cached) $ECHO_C" >&6
32021 else
32022   cat >conftest.$ac_ext <<_ACEOF
32023 #line $LINENO "configure"
32024 /* confdefs.h.  */
32025 _ACEOF
32026 cat confdefs.h >>conftest.$ac_ext
32027 cat >>conftest.$ac_ext <<_ACEOF
32028 /* end confdefs.h.  */
32029 #include <sys/types.h>
32030 #include <time.h>
32031
32032 int
32033 main ()
32034 {
32035 struct tm *tp; tp->tm_sec;
32036   ;
32037   return 0;
32038 }
32039 _ACEOF
32040 rm -f conftest.$ac_objext
32041 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32042   (eval $ac_compile) 2>&5
32043   ac_status=$?
32044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32045   (exit $ac_status); } &&
32046          { ac_try='test -s conftest.$ac_objext'
32047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32048   (eval $ac_try) 2>&5
32049   ac_status=$?
32050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32051   (exit $ac_status); }; }; then
32052   ac_cv_struct_tm=time.h
32053 else
32054   echo "$as_me: failed program was:" >&5
32055 sed 's/^/| /' conftest.$ac_ext >&5
32056
32057 ac_cv_struct_tm=sys/time.h
32058 fi
32059 rm -f conftest.$ac_objext conftest.$ac_ext
32060 fi
32061 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
32062 echo "${ECHO_T}$ac_cv_struct_tm" >&6
32063 if test $ac_cv_struct_tm = sys/time.h; then
32064
32065 cat >>confdefs.h <<\_ACEOF
32066 #define TM_IN_SYS_TIME 1
32067 _ACEOF
32068
32069 fi
32070
32071 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
32072 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
32073 if test "${ac_cv_type_uid_t+set}" = set; then
32074   echo $ECHO_N "(cached) $ECHO_C" >&6
32075 else
32076   cat >conftest.$ac_ext <<_ACEOF
32077 #line $LINENO "configure"
32078 /* confdefs.h.  */
32079 _ACEOF
32080 cat confdefs.h >>conftest.$ac_ext
32081 cat >>conftest.$ac_ext <<_ACEOF
32082 /* end confdefs.h.  */
32083 #include <sys/types.h>
32084
32085 _ACEOF
32086 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32087   $EGREP "uid_t" >/dev/null 2>&1; then
32088   ac_cv_type_uid_t=yes
32089 else
32090   ac_cv_type_uid_t=no
32091 fi
32092 rm -f conftest*
32093
32094 fi
32095 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
32096 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
32097 if test $ac_cv_type_uid_t = no; then
32098
32099 cat >>confdefs.h <<\_ACEOF
32100 #define uid_t int
32101 _ACEOF
32102
32103
32104 cat >>confdefs.h <<\_ACEOF
32105 #define gid_t int
32106 _ACEOF
32107
32108 fi
32109
32110 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
32111 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
32112 if test "${ol_cv_type_sig_atomic_t+set}" = set; then
32113   echo $ECHO_N "(cached) $ECHO_C" >&6
32114 else
32115   cat >conftest.$ac_ext <<_ACEOF
32116 #line $LINENO "configure"
32117 /* confdefs.h.  */
32118 _ACEOF
32119 cat confdefs.h >>conftest.$ac_ext
32120 cat >>conftest.$ac_ext <<_ACEOF
32121 /* end confdefs.h.  */
32122 #include <signal.h>
32123 int
32124 main ()
32125 {
32126 sig_atomic_t atomic;
32127   ;
32128   return 0;
32129 }
32130 _ACEOF
32131 rm -f conftest.$ac_objext
32132 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32133   (eval $ac_compile) 2>&5
32134   ac_status=$?
32135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32136   (exit $ac_status); } &&
32137          { ac_try='test -s conftest.$ac_objext'
32138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32139   (eval $ac_try) 2>&5
32140   ac_status=$?
32141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32142   (exit $ac_status); }; }; then
32143   ol_cv_type_sig_atomic_t=yes
32144 else
32145   echo "$as_me: failed program was:" >&5
32146 sed 's/^/| /' conftest.$ac_ext >&5
32147
32148 ol_cv_type_sig_atomic_t=no
32149 fi
32150 rm -f conftest.$ac_objext conftest.$ac_ext
32151 fi
32152 echo "$as_me:$LINENO: result: $ol_cv_type_sig_atomic_t" >&5
32153 echo "${ECHO_T}$ol_cv_type_sig_atomic_t" >&6
32154   if test $ol_cv_type_sig_atomic_t = no; then
32155
32156 cat >>confdefs.h <<\_ACEOF
32157 #define sig_atomic_t int
32158 _ACEOF
32159
32160   fi
32161
32162
32163
32164 # test for pw_gecos in struct passwd
32165 echo "$as_me:$LINENO: checking struct passwd for pw_gecos" >&5
32166 echo $ECHO_N "checking struct passwd for pw_gecos... $ECHO_C" >&6
32167 if test "${ol_cv_struct_passwd_pw_gecos+set}" = set; then
32168   echo $ECHO_N "(cached) $ECHO_C" >&6
32169 else
32170
32171         cat >conftest.$ac_ext <<_ACEOF
32172 #line $LINENO "configure"
32173 /* confdefs.h.  */
32174 _ACEOF
32175 cat confdefs.h >>conftest.$ac_ext
32176 cat >>conftest.$ac_ext <<_ACEOF
32177 /* end confdefs.h.  */
32178 #include <pwd.h>
32179 int
32180 main ()
32181 {
32182
32183         struct passwd pwd;
32184         pwd.pw_gecos = pwd.pw_name;
32185
32186   ;
32187   return 0;
32188 }
32189 _ACEOF
32190 rm -f conftest.$ac_objext
32191 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32192   (eval $ac_compile) 2>&5
32193   ac_status=$?
32194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32195   (exit $ac_status); } &&
32196          { ac_try='test -s conftest.$ac_objext'
32197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32198   (eval $ac_try) 2>&5
32199   ac_status=$?
32200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32201   (exit $ac_status); }; }; then
32202   ol_cv_struct_passwd_pw_gecos=yes
32203 else
32204   echo "$as_me: failed program was:" >&5
32205 sed 's/^/| /' conftest.$ac_ext >&5
32206
32207 ol_cv_struct_passwd_pw_gecos=no
32208 fi
32209 rm -f conftest.$ac_objext conftest.$ac_ext
32210 fi
32211 echo "$as_me:$LINENO: result: $ol_cv_struct_passwd_pw_gecos" >&5
32212 echo "${ECHO_T}$ol_cv_struct_passwd_pw_gecos" >&6
32213 if test $ol_cv_struct_passwd_pw_gecos = yes ; then
32214
32215 cat >>confdefs.h <<\_ACEOF
32216 #define HAVE_PW_GECOS 1
32217 _ACEOF
32218
32219 fi
32220
32221 # test for pw_passwd in struct passwd
32222 echo "$as_me:$LINENO: checking struct passwd for pw_passwd" >&5
32223 echo $ECHO_N "checking struct passwd for pw_passwd... $ECHO_C" >&6
32224 if test "${ol_cv_struct_passwd_pw_passwd+set}" = set; then
32225   echo $ECHO_N "(cached) $ECHO_C" >&6
32226 else
32227
32228         cat >conftest.$ac_ext <<_ACEOF
32229 #line $LINENO "configure"
32230 /* confdefs.h.  */
32231 _ACEOF
32232 cat confdefs.h >>conftest.$ac_ext
32233 cat >>conftest.$ac_ext <<_ACEOF
32234 /* end confdefs.h.  */
32235 #include <pwd.h>
32236 int
32237 main ()
32238 {
32239
32240         struct passwd pwd;
32241         pwd.pw_passwd = pwd.pw_name;
32242
32243   ;
32244   return 0;
32245 }
32246 _ACEOF
32247 rm -f conftest.$ac_objext
32248 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32249   (eval $ac_compile) 2>&5
32250   ac_status=$?
32251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32252   (exit $ac_status); } &&
32253          { ac_try='test -s conftest.$ac_objext'
32254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32255   (eval $ac_try) 2>&5
32256   ac_status=$?
32257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32258   (exit $ac_status); }; }; then
32259   ol_cv_struct_passwd_pw_passwd=yes
32260 else
32261   echo "$as_me: failed program was:" >&5
32262 sed 's/^/| /' conftest.$ac_ext >&5
32263
32264 ol_cv_struct_passwd_pw_passwd=no
32265 fi
32266 rm -f conftest.$ac_objext conftest.$ac_ext
32267 fi
32268 echo "$as_me:$LINENO: result: $ol_cv_struct_passwd_pw_passwd" >&5
32269 echo "${ECHO_T}$ol_cv_struct_passwd_pw_passwd" >&6
32270 if test $ol_cv_struct_passwd_pw_passwd = yes ; then
32271
32272 cat >>confdefs.h <<\_ACEOF
32273 #define HAVE_PW_PASSWD 1
32274 _ACEOF
32275
32276 fi
32277
32278
32279 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
32280 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
32281 if test "${ol_cv_c_upper_lower+set}" = set; then
32282   echo $ECHO_N "(cached) $ECHO_C" >&6
32283 else
32284
32285         if test "$cross_compiling" = yes; then
32286   ol_cv_c_upper_lower=safe
32287 else
32288   cat >conftest.$ac_ext <<_ACEOF
32289 #line $LINENO "configure"
32290 /* confdefs.h.  */
32291 _ACEOF
32292 cat confdefs.h >>conftest.$ac_ext
32293 cat >>conftest.$ac_ext <<_ACEOF
32294 /* end confdefs.h.  */
32295
32296 #include <ctype.h>
32297 main()
32298 {
32299         if ('C' == toupper('C'))
32300                 exit(0);
32301         else
32302                 exit(1);
32303 }
32304 _ACEOF
32305 rm -f conftest$ac_exeext
32306 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32307   (eval $ac_link) 2>&5
32308   ac_status=$?
32309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32310   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
32311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32312   (eval $ac_try) 2>&5
32313   ac_status=$?
32314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32315   (exit $ac_status); }; }; then
32316   ol_cv_c_upper_lower=no
32317 else
32318   echo "$as_me: program exited with status $ac_status" >&5
32319 echo "$as_me: failed program was:" >&5
32320 sed 's/^/| /' conftest.$ac_ext >&5
32321
32322 ( exit $ac_status )
32323 ol_cv_c_upper_lower=yes
32324 fi
32325 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
32326 fi
32327 fi
32328 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
32329 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
32330 if test $ol_cv_c_upper_lower != no ; then
32331
32332 cat >>confdefs.h <<\_ACEOF
32333 #define C_UPPER_LOWER 1
32334 _ACEOF
32335
32336 fi
32337
32338 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
32339 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
32340 if test "${ac_cv_c_const+set}" = set; then
32341   echo $ECHO_N "(cached) $ECHO_C" >&6
32342 else
32343   cat >conftest.$ac_ext <<_ACEOF
32344 #line $LINENO "configure"
32345 /* confdefs.h.  */
32346 _ACEOF
32347 cat confdefs.h >>conftest.$ac_ext
32348 cat >>conftest.$ac_ext <<_ACEOF
32349 /* end confdefs.h.  */
32350
32351 int
32352 main ()
32353 {
32354 /* FIXME: Include the comments suggested by Paul. */
32355 #ifndef __cplusplus
32356   /* Ultrix mips cc rejects this.  */
32357   typedef int charset[2];
32358   const charset x;
32359   /* SunOS 4.1.1 cc rejects this.  */
32360   char const *const *ccp;
32361   char **p;
32362   /* NEC SVR4.0.2 mips cc rejects this.  */
32363   struct point {int x, y;};
32364   static struct point const zero = {0,0};
32365   /* AIX XL C 1.02.0.0 rejects this.
32366      It does not let you subtract one const X* pointer from another in
32367      an arm of an if-expression whose if-part is not a constant
32368      expression */
32369   const char *g = "string";
32370   ccp = &g + (g ? g-g : 0);
32371   /* HPUX 7.0 cc rejects these. */
32372   ++ccp;
32373   p = (char**) ccp;
32374   ccp = (char const *const *) p;
32375   { /* SCO 3.2v4 cc rejects this.  */
32376     char *t;
32377     char const *s = 0 ? (char *) 0 : (char const *) 0;
32378
32379     *t++ = 0;
32380   }
32381   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
32382     int x[] = {25, 17};
32383     const int *foo = &x[0];
32384     ++foo;
32385   }
32386   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
32387     typedef const int *iptr;
32388     iptr p = 0;
32389     ++p;
32390   }
32391   { /* AIX XL C 1.02.0.0 rejects this saying
32392        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
32393     struct s { int j; const int *ap[3]; };
32394     struct s *b; b->j = 5;
32395   }
32396   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
32397     const int foo = 10;
32398   }
32399 #endif
32400
32401   ;
32402   return 0;
32403 }
32404 _ACEOF
32405 rm -f conftest.$ac_objext
32406 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32407   (eval $ac_compile) 2>&5
32408   ac_status=$?
32409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32410   (exit $ac_status); } &&
32411          { ac_try='test -s conftest.$ac_objext'
32412   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32413   (eval $ac_try) 2>&5
32414   ac_status=$?
32415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32416   (exit $ac_status); }; }; then
32417   ac_cv_c_const=yes
32418 else
32419   echo "$as_me: failed program was:" >&5
32420 sed 's/^/| /' conftest.$ac_ext >&5
32421
32422 ac_cv_c_const=no
32423 fi
32424 rm -f conftest.$ac_objext conftest.$ac_ext
32425 fi
32426 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
32427 echo "${ECHO_T}$ac_cv_c_const" >&6
32428 if test $ac_cv_c_const = no; then
32429
32430 cat >>confdefs.h <<\_ACEOF
32431 #define const
32432 _ACEOF
32433
32434 fi
32435
32436 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
32437 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
32438 if test "${ol_cv_c_volatile+set}" = set; then
32439   echo $ECHO_N "(cached) $ECHO_C" >&6
32440 else
32441   cat >conftest.$ac_ext <<_ACEOF
32442 #line $LINENO "configure"
32443 /* confdefs.h.  */
32444 _ACEOF
32445 cat confdefs.h >>conftest.$ac_ext
32446 cat >>conftest.$ac_ext <<_ACEOF
32447 /* end confdefs.h.  */
32448 int x, y, z;
32449 int
32450 main ()
32451 {
32452 volatile int a; int * volatile b = x ? &y : &z;
32453       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
32454       *b = 0;
32455   ;
32456   return 0;
32457 }
32458 _ACEOF
32459 rm -f conftest.$ac_objext
32460 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32461   (eval $ac_compile) 2>&5
32462   ac_status=$?
32463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32464   (exit $ac_status); } &&
32465          { ac_try='test -s conftest.$ac_objext'
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   ol_cv_c_volatile=yes
32472 else
32473   echo "$as_me: failed program was:" >&5
32474 sed 's/^/| /' conftest.$ac_ext >&5
32475
32476 ol_cv_c_volatile=no
32477 fi
32478 rm -f conftest.$ac_objext conftest.$ac_ext
32479 fi
32480 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
32481 echo "${ECHO_T}$ol_cv_c_volatile" >&6
32482   if test $ol_cv_c_volatile = yes; then
32483     :
32484   else
32485
32486 cat >>confdefs.h <<\_ACEOF
32487 #define volatile
32488 _ACEOF
32489
32490   fi
32491
32492
32493 if test $cross_compiling = yes ; then
32494
32495 cat >>confdefs.h <<\_ACEOF
32496 #define CROSS_COMPILING 1
32497 _ACEOF
32498
32499 else
32500         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
32501 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
32502 if test "${ac_cv_c_bigendian+set}" = set; then
32503   echo $ECHO_N "(cached) $ECHO_C" >&6
32504 else
32505   # See if sys/param.h defines the BYTE_ORDER macro.
32506 cat >conftest.$ac_ext <<_ACEOF
32507 #line $LINENO "configure"
32508 /* confdefs.h.  */
32509 _ACEOF
32510 cat confdefs.h >>conftest.$ac_ext
32511 cat >>conftest.$ac_ext <<_ACEOF
32512 /* end confdefs.h.  */
32513 #include <sys/types.h>
32514 #include <sys/param.h>
32515
32516 int
32517 main ()
32518 {
32519 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
32520  bogus endian macros
32521 #endif
32522
32523   ;
32524   return 0;
32525 }
32526 _ACEOF
32527 rm -f conftest.$ac_objext
32528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32529   (eval $ac_compile) 2>&5
32530   ac_status=$?
32531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32532   (exit $ac_status); } &&
32533          { ac_try='test -s conftest.$ac_objext'
32534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32535   (eval $ac_try) 2>&5
32536   ac_status=$?
32537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32538   (exit $ac_status); }; }; then
32539   # It does; now see whether it defined to BIG_ENDIAN or not.
32540 cat >conftest.$ac_ext <<_ACEOF
32541 #line $LINENO "configure"
32542 /* confdefs.h.  */
32543 _ACEOF
32544 cat confdefs.h >>conftest.$ac_ext
32545 cat >>conftest.$ac_ext <<_ACEOF
32546 /* end confdefs.h.  */
32547 #include <sys/types.h>
32548 #include <sys/param.h>
32549
32550 int
32551 main ()
32552 {
32553 #if BYTE_ORDER != BIG_ENDIAN
32554  not big endian
32555 #endif
32556
32557   ;
32558   return 0;
32559 }
32560 _ACEOF
32561 rm -f conftest.$ac_objext
32562 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32563   (eval $ac_compile) 2>&5
32564   ac_status=$?
32565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32566   (exit $ac_status); } &&
32567          { ac_try='test -s conftest.$ac_objext'
32568   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32569   (eval $ac_try) 2>&5
32570   ac_status=$?
32571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32572   (exit $ac_status); }; }; then
32573   ac_cv_c_bigendian=yes
32574 else
32575   echo "$as_me: failed program was:" >&5
32576 sed 's/^/| /' conftest.$ac_ext >&5
32577
32578 ac_cv_c_bigendian=no
32579 fi
32580 rm -f conftest.$ac_objext conftest.$ac_ext
32581 else
32582   echo "$as_me: failed program was:" >&5
32583 sed 's/^/| /' conftest.$ac_ext >&5
32584
32585 # It does not; compile a test program.
32586 if test "$cross_compiling" = yes; then
32587   # try to guess the endianness by grepping values into an object file
32588   ac_cv_c_bigendian=unknown
32589   cat >conftest.$ac_ext <<_ACEOF
32590 #line $LINENO "configure"
32591 /* confdefs.h.  */
32592 _ACEOF
32593 cat confdefs.h >>conftest.$ac_ext
32594 cat >>conftest.$ac_ext <<_ACEOF
32595 /* end confdefs.h.  */
32596 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
32597 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
32598 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
32599 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
32600 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
32601 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
32602 int
32603 main ()
32604 {
32605  _ascii (); _ebcdic ();
32606   ;
32607   return 0;
32608 }
32609 _ACEOF
32610 rm -f conftest.$ac_objext
32611 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32612   (eval $ac_compile) 2>&5
32613   ac_status=$?
32614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32615   (exit $ac_status); } &&
32616          { ac_try='test -s conftest.$ac_objext'
32617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32618   (eval $ac_try) 2>&5
32619   ac_status=$?
32620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32621   (exit $ac_status); }; }; then
32622   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
32623   ac_cv_c_bigendian=yes
32624 fi
32625 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
32626   if test "$ac_cv_c_bigendian" = unknown; then
32627     ac_cv_c_bigendian=no
32628   else
32629     # finding both strings is unlikely to happen, but who knows?
32630     ac_cv_c_bigendian=unknown
32631   fi
32632 fi
32633 else
32634   echo "$as_me: failed program was:" >&5
32635 sed 's/^/| /' conftest.$ac_ext >&5
32636
32637 fi
32638 rm -f conftest.$ac_objext conftest.$ac_ext
32639 else
32640   cat >conftest.$ac_ext <<_ACEOF
32641 #line $LINENO "configure"
32642 /* confdefs.h.  */
32643 _ACEOF
32644 cat confdefs.h >>conftest.$ac_ext
32645 cat >>conftest.$ac_ext <<_ACEOF
32646 /* end confdefs.h.  */
32647 int
32648 main ()
32649 {
32650   /* Are we little or big endian?  From Harbison&Steele.  */
32651   union
32652   {
32653     long l;
32654     char c[sizeof (long)];
32655   } u;
32656   u.l = 1;
32657   exit (u.c[sizeof (long) - 1] == 1);
32658 }
32659 _ACEOF
32660 rm -f conftest$ac_exeext
32661 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32662   (eval $ac_link) 2>&5
32663   ac_status=$?
32664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32665   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
32666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32667   (eval $ac_try) 2>&5
32668   ac_status=$?
32669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32670   (exit $ac_status); }; }; then
32671   ac_cv_c_bigendian=no
32672 else
32673   echo "$as_me: program exited with status $ac_status" >&5
32674 echo "$as_me: failed program was:" >&5
32675 sed 's/^/| /' conftest.$ac_ext >&5
32676
32677 ( exit $ac_status )
32678 ac_cv_c_bigendian=yes
32679 fi
32680 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
32681 fi
32682 fi
32683 rm -f conftest.$ac_objext conftest.$ac_ext
32684 fi
32685 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
32686 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
32687 case $ac_cv_c_bigendian in
32688   yes)
32689
32690 cat >>confdefs.h <<\_ACEOF
32691 #define WORDS_BIGENDIAN 1
32692 _ACEOF
32693  ;;
32694   no)
32695      ;;
32696   *)
32697     { { echo "$as_me:$LINENO: error: unknown endianness
32698 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
32699 echo "$as_me: error: unknown endianness
32700 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
32701    { (exit 1); exit 1; }; } ;;
32702 esac
32703
32704 fi
32705
32706 echo "$as_me:$LINENO: checking size of short" >&5
32707 echo $ECHO_N "checking size of short... $ECHO_C" >&6
32708 if test "${ac_cv_sizeof_short+set}" = set; then
32709   echo $ECHO_N "(cached) $ECHO_C" >&6
32710 else
32711   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
32712   cat >conftest.$ac_ext <<_ACEOF
32713 #line $LINENO "configure"
32714 /* confdefs.h.  */
32715 _ACEOF
32716 cat confdefs.h >>conftest.$ac_ext
32717 cat >>conftest.$ac_ext <<_ACEOF
32718 /* end confdefs.h.  */
32719 #include "confdefs.h"
32720 #include <sys/types.h>
32721
32722
32723 int
32724 main ()
32725 {
32726 switch (0) case 0: case (sizeof (short) == $ac_size):;
32727   ;
32728   return 0;
32729 }
32730 _ACEOF
32731 rm -f conftest.$ac_objext
32732 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32733   (eval $ac_compile) 2>&5
32734   ac_status=$?
32735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32736   (exit $ac_status); } &&
32737          { ac_try='test -s conftest.$ac_objext'
32738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32739   (eval $ac_try) 2>&5
32740   ac_status=$?
32741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32742   (exit $ac_status); }; }; then
32743   ac_cv_sizeof_short=$ac_size
32744 else
32745   echo "$as_me: failed program was:" >&5
32746 sed 's/^/| /' conftest.$ac_ext >&5
32747
32748 fi
32749 rm -f conftest.$ac_objext conftest.$ac_ext
32750   if test x$ac_cv_sizeof_short != x ; then break; fi
32751 done
32752
32753 fi
32754
32755 if test x$ac_cv_sizeof_short = x ; then
32756   { { echo "$as_me:$LINENO: error: cannot determine a size for short" >&5
32757 echo "$as_me: error: cannot determine a size for short" >&2;}
32758    { (exit 1); exit 1; }; }
32759 fi
32760 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
32761 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
32762
32763 cat >>confdefs.h <<_ACEOF
32764 #define SIZEOF_SHORT $ac_cv_sizeof_short
32765 _ACEOF
32766
32767
32768 echo "$as_me:$LINENO: checking size of int" >&5
32769 echo $ECHO_N "checking size of int... $ECHO_C" >&6
32770 if test "${ac_cv_sizeof_int+set}" = set; then
32771   echo $ECHO_N "(cached) $ECHO_C" >&6
32772 else
32773   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
32774   cat >conftest.$ac_ext <<_ACEOF
32775 #line $LINENO "configure"
32776 /* confdefs.h.  */
32777 _ACEOF
32778 cat confdefs.h >>conftest.$ac_ext
32779 cat >>conftest.$ac_ext <<_ACEOF
32780 /* end confdefs.h.  */
32781 #include "confdefs.h"
32782 #include <sys/types.h>
32783
32784
32785 int
32786 main ()
32787 {
32788 switch (0) case 0: case (sizeof (int) == $ac_size):;
32789   ;
32790   return 0;
32791 }
32792 _ACEOF
32793 rm -f conftest.$ac_objext
32794 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32795   (eval $ac_compile) 2>&5
32796   ac_status=$?
32797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32798   (exit $ac_status); } &&
32799          { ac_try='test -s conftest.$ac_objext'
32800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32801   (eval $ac_try) 2>&5
32802   ac_status=$?
32803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32804   (exit $ac_status); }; }; then
32805   ac_cv_sizeof_int=$ac_size
32806 else
32807   echo "$as_me: failed program was:" >&5
32808 sed 's/^/| /' conftest.$ac_ext >&5
32809
32810 fi
32811 rm -f conftest.$ac_objext conftest.$ac_ext
32812   if test x$ac_cv_sizeof_int != x ; then break; fi
32813 done
32814
32815 fi
32816
32817 if test x$ac_cv_sizeof_int = x ; then
32818   { { echo "$as_me:$LINENO: error: cannot determine a size for int" >&5
32819 echo "$as_me: error: cannot determine a size for int" >&2;}
32820    { (exit 1); exit 1; }; }
32821 fi
32822 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
32823 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
32824
32825 cat >>confdefs.h <<_ACEOF
32826 #define SIZEOF_INT $ac_cv_sizeof_int
32827 _ACEOF
32828
32829
32830 echo "$as_me:$LINENO: checking size of long" >&5
32831 echo $ECHO_N "checking size of long... $ECHO_C" >&6
32832 if test "${ac_cv_sizeof_long+set}" = set; then
32833   echo $ECHO_N "(cached) $ECHO_C" >&6
32834 else
32835   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
32836   cat >conftest.$ac_ext <<_ACEOF
32837 #line $LINENO "configure"
32838 /* confdefs.h.  */
32839 _ACEOF
32840 cat confdefs.h >>conftest.$ac_ext
32841 cat >>conftest.$ac_ext <<_ACEOF
32842 /* end confdefs.h.  */
32843 #include "confdefs.h"
32844 #include <sys/types.h>
32845
32846
32847 int
32848 main ()
32849 {
32850 switch (0) case 0: case (sizeof (long) == $ac_size):;
32851   ;
32852   return 0;
32853 }
32854 _ACEOF
32855 rm -f conftest.$ac_objext
32856 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32857   (eval $ac_compile) 2>&5
32858   ac_status=$?
32859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32860   (exit $ac_status); } &&
32861          { ac_try='test -s conftest.$ac_objext'
32862   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32863   (eval $ac_try) 2>&5
32864   ac_status=$?
32865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32866   (exit $ac_status); }; }; then
32867   ac_cv_sizeof_long=$ac_size
32868 else
32869   echo "$as_me: failed program was:" >&5
32870 sed 's/^/| /' conftest.$ac_ext >&5
32871
32872 fi
32873 rm -f conftest.$ac_objext conftest.$ac_ext
32874   if test x$ac_cv_sizeof_long != x ; then break; fi
32875 done
32876
32877 fi
32878
32879 if test x$ac_cv_sizeof_long = x ; then
32880   { { echo "$as_me:$LINENO: error: cannot determine a size for long" >&5
32881 echo "$as_me: error: cannot determine a size for long" >&2;}
32882    { (exit 1); exit 1; }; }
32883 fi
32884 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
32885 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
32886
32887 cat >>confdefs.h <<_ACEOF
32888 #define SIZEOF_LONG $ac_cv_sizeof_long
32889 _ACEOF
32890
32891
32892
32893 if test "$ac_cv_sizeof_int" -lt 4 ; then
32894         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
32895 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
32896
32897         cat >>confdefs.h <<\_ACEOF
32898 #define LBER_INT_T long
32899 _ACEOF
32900
32901 else
32902         cat >>confdefs.h <<\_ACEOF
32903 #define LBER_INT_T int
32904 _ACEOF
32905
32906 fi
32907
32908 cat >>confdefs.h <<\_ACEOF
32909 #define LBER_LEN_T long
32910 _ACEOF
32911
32912 cat >>confdefs.h <<\_ACEOF
32913 #define LBER_SOCKET_T int
32914 _ACEOF
32915
32916 cat >>confdefs.h <<\_ACEOF
32917 #define LBER_TAG_T long
32918 _ACEOF
32919
32920
32921 echo "$as_me:$LINENO: checking for working memcmp" >&5
32922 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
32923 if test "${ac_cv_func_memcmp_working+set}" = set; then
32924   echo $ECHO_N "(cached) $ECHO_C" >&6
32925 else
32926   if test "$cross_compiling" = yes; then
32927   ac_cv_func_memcmp_working=no
32928 else
32929   cat >conftest.$ac_ext <<_ACEOF
32930 #line $LINENO "configure"
32931 /* confdefs.h.  */
32932 _ACEOF
32933 cat confdefs.h >>conftest.$ac_ext
32934 cat >>conftest.$ac_ext <<_ACEOF
32935 /* end confdefs.h.  */
32936
32937 int
32938 main ()
32939 {
32940
32941   /* Some versions of memcmp are not 8-bit clean.  */
32942   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
32943   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
32944     exit (1);
32945
32946   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
32947      or more and with at least one buffer not starting on a 4-byte boundary.
32948      William Lewis provided this test program.   */
32949   {
32950     char foo[21];
32951     char bar[21];
32952     int i;
32953     for (i = 0; i < 4; i++)
32954       {
32955         char *a = foo + i;
32956         char *b = bar + i;
32957         strcpy (a, "--------01111111");
32958         strcpy (b, "--------10000000");
32959         if (memcmp (a, b, 16) >= 0)
32960           exit (1);
32961       }
32962     exit (0);
32963   }
32964
32965   ;
32966   return 0;
32967 }
32968 _ACEOF
32969 rm -f conftest$ac_exeext
32970 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32971   (eval $ac_link) 2>&5
32972   ac_status=$?
32973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32974   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
32975   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32976   (eval $ac_try) 2>&5
32977   ac_status=$?
32978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32979   (exit $ac_status); }; }; then
32980   ac_cv_func_memcmp_working=yes
32981 else
32982   echo "$as_me: program exited with status $ac_status" >&5
32983 echo "$as_me: failed program was:" >&5
32984 sed 's/^/| /' conftest.$ac_ext >&5
32985
32986 ( exit $ac_status )
32987 ac_cv_func_memcmp_working=no
32988 fi
32989 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
32990 fi
32991 fi
32992 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
32993 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
32994 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
32995
32996
32997 for ac_func in strftime
32998 do
32999 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33000 echo "$as_me:$LINENO: checking for $ac_func" >&5
33001 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
33002 if eval "test \"\${$as_ac_var+set}\" = set"; then
33003   echo $ECHO_N "(cached) $ECHO_C" >&6
33004 else
33005   cat >conftest.$ac_ext <<_ACEOF
33006 #line $LINENO "configure"
33007 /* confdefs.h.  */
33008 _ACEOF
33009 cat confdefs.h >>conftest.$ac_ext
33010 cat >>conftest.$ac_ext <<_ACEOF
33011 /* end confdefs.h.  */
33012 /* System header to define __stub macros and hopefully few prototypes,
33013     which can conflict with char $ac_func (); below.
33014     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33015     <limits.h> exists even on freestanding compilers.  */
33016 #ifdef __STDC__
33017 # include <limits.h>
33018 #else
33019 # include <assert.h>
33020 #endif
33021 /* Override any gcc2 internal prototype to avoid an error.  */
33022 #ifdef __cplusplus
33023 extern "C"
33024 {
33025 #endif
33026 /* We use char because int might match the return type of a gcc2
33027    builtin and then its argument prototype would still apply.  */
33028 char $ac_func ();
33029 /* The GNU C library defines this for functions which it implements
33030     to always fail with ENOSYS.  Some functions are actually named
33031     something starting with __ and the normal name is an alias.  */
33032 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
33033 choke me
33034 #else
33035 char (*f) () = $ac_func;
33036 #endif
33037 #ifdef __cplusplus
33038 }
33039 #endif
33040
33041 int
33042 main ()
33043 {
33044 return f != $ac_func;
33045   ;
33046   return 0;
33047 }
33048 _ACEOF
33049 rm -f conftest.$ac_objext conftest$ac_exeext
33050 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33051   (eval $ac_link) 2>&5
33052   ac_status=$?
33053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33054   (exit $ac_status); } &&
33055          { ac_try='test -s conftest$ac_exeext'
33056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33057   (eval $ac_try) 2>&5
33058   ac_status=$?
33059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33060   (exit $ac_status); }; }; then
33061   eval "$as_ac_var=yes"
33062 else
33063   echo "$as_me: failed program was:" >&5
33064 sed 's/^/| /' conftest.$ac_ext >&5
33065
33066 eval "$as_ac_var=no"
33067 fi
33068 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33069 fi
33070 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
33071 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
33072 if test `eval echo '${'$as_ac_var'}'` = yes; then
33073   cat >>confdefs.h <<_ACEOF
33074 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33075 _ACEOF
33076
33077 else
33078   # strftime is in -lintl on SCO UNIX.
33079 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
33080 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
33081 if test "${ac_cv_lib_intl_strftime+set}" = set; then
33082   echo $ECHO_N "(cached) $ECHO_C" >&6
33083 else
33084   ac_check_lib_save_LIBS=$LIBS
33085 LIBS="-lintl  $LIBS"
33086 cat >conftest.$ac_ext <<_ACEOF
33087 #line $LINENO "configure"
33088 /* confdefs.h.  */
33089 _ACEOF
33090 cat confdefs.h >>conftest.$ac_ext
33091 cat >>conftest.$ac_ext <<_ACEOF
33092 /* end confdefs.h.  */
33093
33094 /* Override any gcc2 internal prototype to avoid an error.  */
33095 #ifdef __cplusplus
33096 extern "C"
33097 #endif
33098 /* We use char because int might match the return type of a gcc2
33099    builtin and then its argument prototype would still apply.  */
33100 char strftime ();
33101 int
33102 main ()
33103 {
33104 strftime ();
33105   ;
33106   return 0;
33107 }
33108 _ACEOF
33109 rm -f conftest.$ac_objext conftest$ac_exeext
33110 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33111   (eval $ac_link) 2>&5
33112   ac_status=$?
33113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33114   (exit $ac_status); } &&
33115          { ac_try='test -s conftest$ac_exeext'
33116   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33117   (eval $ac_try) 2>&5
33118   ac_status=$?
33119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33120   (exit $ac_status); }; }; then
33121   ac_cv_lib_intl_strftime=yes
33122 else
33123   echo "$as_me: failed program was:" >&5
33124 sed 's/^/| /' conftest.$ac_ext >&5
33125
33126 ac_cv_lib_intl_strftime=no
33127 fi
33128 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33129 LIBS=$ac_check_lib_save_LIBS
33130 fi
33131 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
33132 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
33133 if test $ac_cv_lib_intl_strftime = yes; then
33134   cat >>confdefs.h <<\_ACEOF
33135 #define HAVE_STRFTIME 1
33136 _ACEOF
33137
33138 LIBS="-lintl $LIBS"
33139 fi
33140
33141 fi
33142 done
33143
33144
33145 echo "$as_me:$LINENO: checking for inet_aton()" >&5
33146 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
33147 if test "${ol_cv_func_inet_aton+set}" = set; then
33148   echo $ECHO_N "(cached) $ECHO_C" >&6
33149 else
33150   cat >conftest.$ac_ext <<_ACEOF
33151 #line $LINENO "configure"
33152 /* confdefs.h.  */
33153 _ACEOF
33154 cat confdefs.h >>conftest.$ac_ext
33155 cat >>conftest.$ac_ext <<_ACEOF
33156 /* end confdefs.h.  */
33157
33158 #ifdef HAVE_SYS_TYPES_H
33159 #       include <sys/types.h>
33160 #endif
33161 #ifdef HAVE_SYS_SOCKET_H
33162 #       include <sys/socket.h>
33163 #       ifdef HAVE_SYS_SELECT_H
33164 #               include <sys/select.h>
33165 #       endif
33166 #       include <netinet/in.h>
33167 #       ifdef HAVE_ARPA_INET_H
33168 #               include <arpa/inet.h>
33169 #       endif
33170 #endif
33171
33172 int
33173 main ()
33174 {
33175 struct in_addr in;
33176 int rc = inet_aton( "255.255.255.255", &in );
33177   ;
33178   return 0;
33179 }
33180 _ACEOF
33181 rm -f conftest.$ac_objext conftest$ac_exeext
33182 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33183   (eval $ac_link) 2>&5
33184   ac_status=$?
33185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33186   (exit $ac_status); } &&
33187          { ac_try='test -s conftest$ac_exeext'
33188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33189   (eval $ac_try) 2>&5
33190   ac_status=$?
33191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33192   (exit $ac_status); }; }; then
33193   ol_cv_func_inet_aton=yes
33194 else
33195   echo "$as_me: failed program was:" >&5
33196 sed 's/^/| /' conftest.$ac_ext >&5
33197
33198 ol_cv_func_inet_aton=no
33199 fi
33200 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33201 fi
33202 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
33203 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
33204   if test $ol_cv_func_inet_aton != no; then
33205
33206 cat >>confdefs.h <<\_ACEOF
33207 #define HAVE_INET_ATON 1
33208 _ACEOF
33209
33210   fi
33211
33212
33213 echo "$as_me:$LINENO: checking for _spawnlp" >&5
33214 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
33215 if test "${ac_cv_func__spawnlp+set}" = set; then
33216   echo $ECHO_N "(cached) $ECHO_C" >&6
33217 else
33218   cat >conftest.$ac_ext <<_ACEOF
33219 #line $LINENO "configure"
33220 /* confdefs.h.  */
33221 _ACEOF
33222 cat confdefs.h >>conftest.$ac_ext
33223 cat >>conftest.$ac_ext <<_ACEOF
33224 /* end confdefs.h.  */
33225 /* System header to define __stub macros and hopefully few prototypes,
33226     which can conflict with char _spawnlp (); below.
33227     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33228     <limits.h> exists even on freestanding compilers.  */
33229 #ifdef __STDC__
33230 # include <limits.h>
33231 #else
33232 # include <assert.h>
33233 #endif
33234 /* Override any gcc2 internal prototype to avoid an error.  */
33235 #ifdef __cplusplus
33236 extern "C"
33237 {
33238 #endif
33239 /* We use char because int might match the return type of a gcc2
33240    builtin and then its argument prototype would still apply.  */
33241 char _spawnlp ();
33242 /* The GNU C library defines this for functions which it implements
33243     to always fail with ENOSYS.  Some functions are actually named
33244     something starting with __ and the normal name is an alias.  */
33245 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
33246 choke me
33247 #else
33248 char (*f) () = _spawnlp;
33249 #endif
33250 #ifdef __cplusplus
33251 }
33252 #endif
33253
33254 int
33255 main ()
33256 {
33257 return f != _spawnlp;
33258   ;
33259   return 0;
33260 }
33261 _ACEOF
33262 rm -f conftest.$ac_objext conftest$ac_exeext
33263 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33264   (eval $ac_link) 2>&5
33265   ac_status=$?
33266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33267   (exit $ac_status); } &&
33268          { ac_try='test -s conftest$ac_exeext'
33269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33270   (eval $ac_try) 2>&5
33271   ac_status=$?
33272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33273   (exit $ac_status); }; }; then
33274   ac_cv_func__spawnlp=yes
33275 else
33276   echo "$as_me: failed program was:" >&5
33277 sed 's/^/| /' conftest.$ac_ext >&5
33278
33279 ac_cv_func__spawnlp=no
33280 fi
33281 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33282 fi
33283 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
33284 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
33285 if test $ac_cv_func__spawnlp = yes; then
33286
33287 cat >>confdefs.h <<\_ACEOF
33288 #define HAVE_SPAWNLP 1
33289 _ACEOF
33290
33291 fi
33292
33293
33294 echo "$as_me:$LINENO: checking for _snprintf" >&5
33295 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
33296 if test "${ac_cv_func__snprintf+set}" = set; then
33297   echo $ECHO_N "(cached) $ECHO_C" >&6
33298 else
33299   cat >conftest.$ac_ext <<_ACEOF
33300 #line $LINENO "configure"
33301 /* confdefs.h.  */
33302 _ACEOF
33303 cat confdefs.h >>conftest.$ac_ext
33304 cat >>conftest.$ac_ext <<_ACEOF
33305 /* end confdefs.h.  */
33306 /* System header to define __stub macros and hopefully few prototypes,
33307     which can conflict with char _snprintf (); below.
33308     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33309     <limits.h> exists even on freestanding compilers.  */
33310 #ifdef __STDC__
33311 # include <limits.h>
33312 #else
33313 # include <assert.h>
33314 #endif
33315 /* Override any gcc2 internal prototype to avoid an error.  */
33316 #ifdef __cplusplus
33317 extern "C"
33318 {
33319 #endif
33320 /* We use char because int might match the return type of a gcc2
33321    builtin and then its argument prototype would still apply.  */
33322 char _snprintf ();
33323 /* The GNU C library defines this for functions which it implements
33324     to always fail with ENOSYS.  Some functions are actually named
33325     something starting with __ and the normal name is an alias.  */
33326 #if defined (__stub__snprintf) || defined (__stub____snprintf)
33327 choke me
33328 #else
33329 char (*f) () = _snprintf;
33330 #endif
33331 #ifdef __cplusplus
33332 }
33333 #endif
33334
33335 int
33336 main ()
33337 {
33338 return f != _snprintf;
33339   ;
33340   return 0;
33341 }
33342 _ACEOF
33343 rm -f conftest.$ac_objext conftest$ac_exeext
33344 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33345   (eval $ac_link) 2>&5
33346   ac_status=$?
33347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33348   (exit $ac_status); } &&
33349          { ac_try='test -s conftest$ac_exeext'
33350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33351   (eval $ac_try) 2>&5
33352   ac_status=$?
33353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33354   (exit $ac_status); }; }; then
33355   ac_cv_func__snprintf=yes
33356 else
33357   echo "$as_me: failed program was:" >&5
33358 sed 's/^/| /' conftest.$ac_ext >&5
33359
33360 ac_cv_func__snprintf=no
33361 fi
33362 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33363 fi
33364 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
33365 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
33366 if test $ac_cv_func__snprintf = yes; then
33367   ac_cv_func_snprintf=yes
33368
33369 cat >>confdefs.h <<\_ACEOF
33370 #define snprintf _snprintf
33371 _ACEOF
33372
33373
33374 fi
33375
33376
33377 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
33378 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
33379 if test "${ac_cv_func__vsnprintf+set}" = set; then
33380   echo $ECHO_N "(cached) $ECHO_C" >&6
33381 else
33382   cat >conftest.$ac_ext <<_ACEOF
33383 #line $LINENO "configure"
33384 /* confdefs.h.  */
33385 _ACEOF
33386 cat confdefs.h >>conftest.$ac_ext
33387 cat >>conftest.$ac_ext <<_ACEOF
33388 /* end confdefs.h.  */
33389 /* System header to define __stub macros and hopefully few prototypes,
33390     which can conflict with char _vsnprintf (); below.
33391     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33392     <limits.h> exists even on freestanding compilers.  */
33393 #ifdef __STDC__
33394 # include <limits.h>
33395 #else
33396 # include <assert.h>
33397 #endif
33398 /* Override any gcc2 internal prototype to avoid an error.  */
33399 #ifdef __cplusplus
33400 extern "C"
33401 {
33402 #endif
33403 /* We use char because int might match the return type of a gcc2
33404    builtin and then its argument prototype would still apply.  */
33405 char _vsnprintf ();
33406 /* The GNU C library defines this for functions which it implements
33407     to always fail with ENOSYS.  Some functions are actually named
33408     something starting with __ and the normal name is an alias.  */
33409 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
33410 choke me
33411 #else
33412 char (*f) () = _vsnprintf;
33413 #endif
33414 #ifdef __cplusplus
33415 }
33416 #endif
33417
33418 int
33419 main ()
33420 {
33421 return f != _vsnprintf;
33422   ;
33423   return 0;
33424 }
33425 _ACEOF
33426 rm -f conftest.$ac_objext conftest$ac_exeext
33427 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33428   (eval $ac_link) 2>&5
33429   ac_status=$?
33430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33431   (exit $ac_status); } &&
33432          { ac_try='test -s conftest$ac_exeext'
33433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33434   (eval $ac_try) 2>&5
33435   ac_status=$?
33436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33437   (exit $ac_status); }; }; then
33438   ac_cv_func__vsnprintf=yes
33439 else
33440   echo "$as_me: failed program was:" >&5
33441 sed 's/^/| /' conftest.$ac_ext >&5
33442
33443 ac_cv_func__vsnprintf=no
33444 fi
33445 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33446 fi
33447 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
33448 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
33449 if test $ac_cv_func__vsnprintf = yes; then
33450   ac_cv_func_vsnprintf=yes
33451
33452 cat >>confdefs.h <<\_ACEOF
33453 #define vsnprintf _vsnprintf
33454 _ACEOF
33455
33456
33457 fi
33458
33459
33460
33461 for ac_func in vprintf
33462 do
33463 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33464 echo "$as_me:$LINENO: checking for $ac_func" >&5
33465 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
33466 if eval "test \"\${$as_ac_var+set}\" = set"; then
33467   echo $ECHO_N "(cached) $ECHO_C" >&6
33468 else
33469   cat >conftest.$ac_ext <<_ACEOF
33470 #line $LINENO "configure"
33471 /* confdefs.h.  */
33472 _ACEOF
33473 cat confdefs.h >>conftest.$ac_ext
33474 cat >>conftest.$ac_ext <<_ACEOF
33475 /* end confdefs.h.  */
33476 /* System header to define __stub macros and hopefully few prototypes,
33477     which can conflict with char $ac_func (); below.
33478     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33479     <limits.h> exists even on freestanding compilers.  */
33480 #ifdef __STDC__
33481 # include <limits.h>
33482 #else
33483 # include <assert.h>
33484 #endif
33485 /* Override any gcc2 internal prototype to avoid an error.  */
33486 #ifdef __cplusplus
33487 extern "C"
33488 {
33489 #endif
33490 /* We use char because int might match the return type of a gcc2
33491    builtin and then its argument prototype would still apply.  */
33492 char $ac_func ();
33493 /* The GNU C library defines this for functions which it implements
33494     to always fail with ENOSYS.  Some functions are actually named
33495     something starting with __ and the normal name is an alias.  */
33496 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
33497 choke me
33498 #else
33499 char (*f) () = $ac_func;
33500 #endif
33501 #ifdef __cplusplus
33502 }
33503 #endif
33504
33505 int
33506 main ()
33507 {
33508 return f != $ac_func;
33509   ;
33510   return 0;
33511 }
33512 _ACEOF
33513 rm -f conftest.$ac_objext conftest$ac_exeext
33514 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33515   (eval $ac_link) 2>&5
33516   ac_status=$?
33517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33518   (exit $ac_status); } &&
33519          { ac_try='test -s conftest$ac_exeext'
33520   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33521   (eval $ac_try) 2>&5
33522   ac_status=$?
33523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33524   (exit $ac_status); }; }; then
33525   eval "$as_ac_var=yes"
33526 else
33527   echo "$as_me: failed program was:" >&5
33528 sed 's/^/| /' conftest.$ac_ext >&5
33529
33530 eval "$as_ac_var=no"
33531 fi
33532 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33533 fi
33534 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
33535 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
33536 if test `eval echo '${'$as_ac_var'}'` = yes; then
33537   cat >>confdefs.h <<_ACEOF
33538 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33539 _ACEOF
33540
33541 echo "$as_me:$LINENO: checking for _doprnt" >&5
33542 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
33543 if test "${ac_cv_func__doprnt+set}" = set; then
33544   echo $ECHO_N "(cached) $ECHO_C" >&6
33545 else
33546   cat >conftest.$ac_ext <<_ACEOF
33547 #line $LINENO "configure"
33548 /* confdefs.h.  */
33549 _ACEOF
33550 cat confdefs.h >>conftest.$ac_ext
33551 cat >>conftest.$ac_ext <<_ACEOF
33552 /* end confdefs.h.  */
33553 /* System header to define __stub macros and hopefully few prototypes,
33554     which can conflict with char _doprnt (); below.
33555     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33556     <limits.h> exists even on freestanding compilers.  */
33557 #ifdef __STDC__
33558 # include <limits.h>
33559 #else
33560 # include <assert.h>
33561 #endif
33562 /* Override any gcc2 internal prototype to avoid an error.  */
33563 #ifdef __cplusplus
33564 extern "C"
33565 {
33566 #endif
33567 /* We use char because int might match the return type of a gcc2
33568    builtin and then its argument prototype would still apply.  */
33569 char _doprnt ();
33570 /* The GNU C library defines this for functions which it implements
33571     to always fail with ENOSYS.  Some functions are actually named
33572     something starting with __ and the normal name is an alias.  */
33573 #if defined (__stub__doprnt) || defined (__stub____doprnt)
33574 choke me
33575 #else
33576 char (*f) () = _doprnt;
33577 #endif
33578 #ifdef __cplusplus
33579 }
33580 #endif
33581
33582 int
33583 main ()
33584 {
33585 return f != _doprnt;
33586   ;
33587   return 0;
33588 }
33589 _ACEOF
33590 rm -f conftest.$ac_objext conftest$ac_exeext
33591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33592   (eval $ac_link) 2>&5
33593   ac_status=$?
33594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33595   (exit $ac_status); } &&
33596          { ac_try='test -s conftest$ac_exeext'
33597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33598   (eval $ac_try) 2>&5
33599   ac_status=$?
33600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33601   (exit $ac_status); }; }; then
33602   ac_cv_func__doprnt=yes
33603 else
33604   echo "$as_me: failed program was:" >&5
33605 sed 's/^/| /' conftest.$ac_ext >&5
33606
33607 ac_cv_func__doprnt=no
33608 fi
33609 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33610 fi
33611 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
33612 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
33613 if test $ac_cv_func__doprnt = yes; then
33614
33615 cat >>confdefs.h <<\_ACEOF
33616 #define HAVE_DOPRNT 1
33617 _ACEOF
33618
33619 fi
33620
33621 fi
33622 done
33623
33624
33625
33626 if test $ac_cv_func_vprintf = yes ; then
33627
33628
33629 for ac_func in snprintf vsnprintf
33630 do
33631 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33632 echo "$as_me:$LINENO: checking for $ac_func" >&5
33633 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
33634 if eval "test \"\${$as_ac_var+set}\" = set"; then
33635   echo $ECHO_N "(cached) $ECHO_C" >&6
33636 else
33637   cat >conftest.$ac_ext <<_ACEOF
33638 #line $LINENO "configure"
33639 /* confdefs.h.  */
33640 _ACEOF
33641 cat confdefs.h >>conftest.$ac_ext
33642 cat >>conftest.$ac_ext <<_ACEOF
33643 /* end confdefs.h.  */
33644 /* System header to define __stub macros and hopefully few prototypes,
33645     which can conflict with char $ac_func (); below.
33646     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33647     <limits.h> exists even on freestanding compilers.  */
33648 #ifdef __STDC__
33649 # include <limits.h>
33650 #else
33651 # include <assert.h>
33652 #endif
33653 /* Override any gcc2 internal prototype to avoid an error.  */
33654 #ifdef __cplusplus
33655 extern "C"
33656 {
33657 #endif
33658 /* We use char because int might match the return type of a gcc2
33659    builtin and then its argument prototype would still apply.  */
33660 char $ac_func ();
33661 /* The GNU C library defines this for functions which it implements
33662     to always fail with ENOSYS.  Some functions are actually named
33663     something starting with __ and the normal name is an alias.  */
33664 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
33665 choke me
33666 #else
33667 char (*f) () = $ac_func;
33668 #endif
33669 #ifdef __cplusplus
33670 }
33671 #endif
33672
33673 int
33674 main ()
33675 {
33676 return f != $ac_func;
33677   ;
33678   return 0;
33679 }
33680 _ACEOF
33681 rm -f conftest.$ac_objext conftest$ac_exeext
33682 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33683   (eval $ac_link) 2>&5
33684   ac_status=$?
33685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33686   (exit $ac_status); } &&
33687          { ac_try='test -s conftest$ac_exeext'
33688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33689   (eval $ac_try) 2>&5
33690   ac_status=$?
33691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33692   (exit $ac_status); }; }; then
33693   eval "$as_ac_var=yes"
33694 else
33695   echo "$as_me: failed program was:" >&5
33696 sed 's/^/| /' conftest.$ac_ext >&5
33697
33698 eval "$as_ac_var=no"
33699 fi
33700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33701 fi
33702 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
33703 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
33704 if test `eval echo '${'$as_ac_var'}'` = yes; then
33705   cat >>confdefs.h <<_ACEOF
33706 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33707 _ACEOF
33708
33709 fi
33710 done
33711
33712 fi
33713
33714
33715
33716
33717
33718
33719
33720
33721
33722
33723
33724
33725
33726
33727
33728
33729
33730
33731
33732
33733
33734
33735
33736
33737
33738
33739
33740
33741
33742
33743
33744
33745
33746
33747
33748
33749
33750
33751
33752
33753
33754
33755
33756
33757
33758
33759
33760
33761
33762
33763
33764
33765
33766
33767 for ac_func in \
33768         bcopy                   \
33769         closesocket             \
33770         chroot                  \
33771         endgrent                \
33772         endpwent                \
33773         fcntl                   \
33774         flock                   \
33775         fstat                   \
33776         getdtablesize   \
33777         getgrgid                \
33778         gethostname             \
33779         getpass                 \
33780         getpassphrase   \
33781         getpwuid                \
33782         getpwnam                \
33783         getspnam                \
33784         gettimeofday    \
33785         initgroups              \
33786         lockf                   \
33787         memcpy                  \
33788         memmove                 \
33789         mkstemp                 \
33790         mktemp                  \
33791         pipe                    \
33792         read                    \
33793         recv                    \
33794         recvfrom                \
33795         setpwfile               \
33796         setgid                  \
33797         setegid                 \
33798         setsid                  \
33799         setuid                  \
33800         seteuid                 \
33801         sigaction               \
33802         signal                  \
33803         sigset                  \
33804         strdup                  \
33805         strerror                \
33806         strpbrk                 \
33807         strrchr                 \
33808         strsep                  \
33809         strstr                  \
33810         strtol                  \
33811         strtoul                 \
33812         strspn                  \
33813         sysconf                 \
33814         usleep                  \
33815         waitpid                 \
33816         wait4                   \
33817         write                   \
33818         send                    \
33819         sendmsg                 \
33820         sendto                  \
33821
33822 do
33823 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33824 echo "$as_me:$LINENO: checking for $ac_func" >&5
33825 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
33826 if eval "test \"\${$as_ac_var+set}\" = set"; then
33827   echo $ECHO_N "(cached) $ECHO_C" >&6
33828 else
33829   cat >conftest.$ac_ext <<_ACEOF
33830 #line $LINENO "configure"
33831 /* confdefs.h.  */
33832 _ACEOF
33833 cat confdefs.h >>conftest.$ac_ext
33834 cat >>conftest.$ac_ext <<_ACEOF
33835 /* end confdefs.h.  */
33836 /* System header to define __stub macros and hopefully few prototypes,
33837     which can conflict with char $ac_func (); below.
33838     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33839     <limits.h> exists even on freestanding compilers.  */
33840 #ifdef __STDC__
33841 # include <limits.h>
33842 #else
33843 # include <assert.h>
33844 #endif
33845 /* Override any gcc2 internal prototype to avoid an error.  */
33846 #ifdef __cplusplus
33847 extern "C"
33848 {
33849 #endif
33850 /* We use char because int might match the return type of a gcc2
33851    builtin and then its argument prototype would still apply.  */
33852 char $ac_func ();
33853 /* The GNU C library defines this for functions which it implements
33854     to always fail with ENOSYS.  Some functions are actually named
33855     something starting with __ and the normal name is an alias.  */
33856 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
33857 choke me
33858 #else
33859 char (*f) () = $ac_func;
33860 #endif
33861 #ifdef __cplusplus
33862 }
33863 #endif
33864
33865 int
33866 main ()
33867 {
33868 return f != $ac_func;
33869   ;
33870   return 0;
33871 }
33872 _ACEOF
33873 rm -f conftest.$ac_objext conftest$ac_exeext
33874 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33875   (eval $ac_link) 2>&5
33876   ac_status=$?
33877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33878   (exit $ac_status); } &&
33879          { ac_try='test -s conftest$ac_exeext'
33880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33881   (eval $ac_try) 2>&5
33882   ac_status=$?
33883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33884   (exit $ac_status); }; }; then
33885   eval "$as_ac_var=yes"
33886 else
33887   echo "$as_me: failed program was:" >&5
33888 sed 's/^/| /' conftest.$ac_ext >&5
33889
33890 eval "$as_ac_var=no"
33891 fi
33892 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33893 fi
33894 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
33895 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
33896 if test `eval echo '${'$as_ac_var'}'` = yes; then
33897   cat >>confdefs.h <<_ACEOF
33898 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33899 _ACEOF
33900
33901 fi
33902 done
33903
33904
33905
33906
33907 for ac_func in getopt getpeereid
33908 do
33909 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33910 echo "$as_me:$LINENO: checking for $ac_func" >&5
33911 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
33912 if eval "test \"\${$as_ac_var+set}\" = set"; then
33913   echo $ECHO_N "(cached) $ECHO_C" >&6
33914 else
33915   cat >conftest.$ac_ext <<_ACEOF
33916 #line $LINENO "configure"
33917 /* confdefs.h.  */
33918 _ACEOF
33919 cat confdefs.h >>conftest.$ac_ext
33920 cat >>conftest.$ac_ext <<_ACEOF
33921 /* end confdefs.h.  */
33922 /* System header to define __stub macros and hopefully few prototypes,
33923     which can conflict with char $ac_func (); below.
33924     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33925     <limits.h> exists even on freestanding compilers.  */
33926 #ifdef __STDC__
33927 # include <limits.h>
33928 #else
33929 # include <assert.h>
33930 #endif
33931 /* Override any gcc2 internal prototype to avoid an error.  */
33932 #ifdef __cplusplus
33933 extern "C"
33934 {
33935 #endif
33936 /* We use char because int might match the return type of a gcc2
33937    builtin and then its argument prototype would still apply.  */
33938 char $ac_func ();
33939 /* The GNU C library defines this for functions which it implements
33940     to always fail with ENOSYS.  Some functions are actually named
33941     something starting with __ and the normal name is an alias.  */
33942 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
33943 choke me
33944 #else
33945 char (*f) () = $ac_func;
33946 #endif
33947 #ifdef __cplusplus
33948 }
33949 #endif
33950
33951 int
33952 main ()
33953 {
33954 return f != $ac_func;
33955   ;
33956   return 0;
33957 }
33958 _ACEOF
33959 rm -f conftest.$ac_objext conftest$ac_exeext
33960 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33961   (eval $ac_link) 2>&5
33962   ac_status=$?
33963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33964   (exit $ac_status); } &&
33965          { ac_try='test -s conftest$ac_exeext'
33966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33967   (eval $ac_try) 2>&5
33968   ac_status=$?
33969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33970   (exit $ac_status); }; }; then
33971   eval "$as_ac_var=yes"
33972 else
33973   echo "$as_me: failed program was:" >&5
33974 sed 's/^/| /' conftest.$ac_ext >&5
33975
33976 eval "$as_ac_var=no"
33977 fi
33978 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
33979 fi
33980 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
33981 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
33982 if test `eval echo '${'$as_ac_var'}'` = yes; then
33983   cat >>confdefs.h <<_ACEOF
33984 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33985 _ACEOF
33986
33987 else
33988   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
33989 fi
33990 done
33991
33992
33993
33994 if test "$ac_cv_func_getopt" != yes; then
33995         LIBSRCS="$LIBSRCS getopt.c"
33996 fi
33997 if test "$ac_cv_func_getpeereid" != yes; then
33998         echo "$as_me:$LINENO: checking for msg_accrights in msghdr" >&5
33999 echo $ECHO_N "checking for msg_accrights in msghdr... $ECHO_C" >&6
34000 if test "${ol_cv_msghdr_msg_accrights+set}" = set; then
34001   echo $ECHO_N "(cached) $ECHO_C" >&6
34002 else
34003   cat >conftest.$ac_ext <<_ACEOF
34004 #line $LINENO "configure"
34005 /* confdefs.h.  */
34006 _ACEOF
34007 cat confdefs.h >>conftest.$ac_ext
34008 cat >>conftest.$ac_ext <<_ACEOF
34009 /* end confdefs.h.  */
34010 #include <sys/socket.h>
34011 int
34012 main ()
34013 {
34014 struct msghdr m; m.msg_accrightslen=0
34015   ;
34016   return 0;
34017 }
34018 _ACEOF
34019 rm -f conftest.$ac_objext
34020 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34021   (eval $ac_compile) 2>&5
34022   ac_status=$?
34023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34024   (exit $ac_status); } &&
34025          { ac_try='test -s conftest.$ac_objext'
34026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34027   (eval $ac_try) 2>&5
34028   ac_status=$?
34029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34030   (exit $ac_status); }; }; then
34031   ol_cv_msghdr_msg_accrights=yes
34032 else
34033   echo "$as_me: failed program was:" >&5
34034 sed 's/^/| /' conftest.$ac_ext >&5
34035
34036 ol_cv_msghdr_msg_accrights=no
34037 fi
34038 rm -f conftest.$ac_objext conftest.$ac_ext
34039
34040 fi
34041 echo "$as_me:$LINENO: result: $ol_cv_msghdr_msg_accrights" >&5
34042 echo "${ECHO_T}$ol_cv_msghdr_msg_accrights" >&6
34043   if test $ol_cv_msghdr_msg_accrights = "yes" ; then
34044
34045 cat >>confdefs.h <<\_ACEOF
34046 #define HAVE_MSGHDR_MSG_ACCRIGHTS 1
34047 _ACEOF
34048
34049   fi
34050
34051         LIBSRCS="$LIBSRCS getpeereid.c"
34052 fi
34053 if test "$ac_cv_func_snprintf" != yes -o "$ac_cv_func_vsnprintf" != yes; then
34054         if test "$ac_cv_func_snprintf" != yes; then
34055
34056 cat >>confdefs.h <<\_ACEOF
34057 #define snprintf ber_pvt_snprintf
34058 _ACEOF
34059
34060         fi
34061         if test "$ac_cv_func_vsnprintf" != yes; then
34062
34063 cat >>confdefs.h <<\_ACEOF
34064 #define vsnprintf ber_pvt_vsnprintf
34065 _ACEOF
34066
34067         fi
34068 fi
34069
34070 # Check Configuration
34071 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
34072 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
34073 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
34074   echo $ECHO_N "(cached) $ECHO_C" >&6
34075 else
34076
34077         cat >conftest.$ac_ext <<_ACEOF
34078 #line $LINENO "configure"
34079 /* confdefs.h.  */
34080 _ACEOF
34081 cat confdefs.h >>conftest.$ac_ext
34082 cat >>conftest.$ac_ext <<_ACEOF
34083 /* end confdefs.h.  */
34084
34085 #include <stdio.h>
34086 #include <sys/types.h>
34087 #include <errno.h>
34088 #ifdef WINNT
34089 #include <stdlib.h>
34090 #endif
34091 int
34092 main ()
34093 {
34094 char *c = (char *) *sys_errlist
34095   ;
34096   return 0;
34097 }
34098 _ACEOF
34099 rm -f conftest.$ac_objext
34100 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34101   (eval $ac_compile) 2>&5
34102   ac_status=$?
34103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34104   (exit $ac_status); } &&
34105          { ac_try='test -s conftest.$ac_objext'
34106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34107   (eval $ac_try) 2>&5
34108   ac_status=$?
34109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34110   (exit $ac_status); }; }; then
34111   ol_cv_dcl_sys_errlist=yes
34112         ol_cv_have_sys_errlist=yes
34113 else
34114   echo "$as_me: failed program was:" >&5
34115 sed 's/^/| /' conftest.$ac_ext >&5
34116
34117 ol_cv_dcl_sys_errlist=no
34118 fi
34119 rm -f conftest.$ac_objext conftest.$ac_ext
34120 fi
34121 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
34122 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
34123 #
34124 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
34125 if test $ol_cv_dcl_sys_errlist = no ; then
34126
34127 cat >>confdefs.h <<\_ACEOF
34128 #define DECL_SYS_ERRLIST 1
34129 _ACEOF
34130
34131
34132         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
34133 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
34134 if test "${ol_cv_have_sys_errlist+set}" = set; then
34135   echo $ECHO_N "(cached) $ECHO_C" >&6
34136 else
34137
34138                 cat >conftest.$ac_ext <<_ACEOF
34139 #line $LINENO "configure"
34140 /* confdefs.h.  */
34141 _ACEOF
34142 cat confdefs.h >>conftest.$ac_ext
34143 cat >>conftest.$ac_ext <<_ACEOF
34144 /* end confdefs.h.  */
34145 #include <errno.h>
34146 int
34147 main ()
34148 {
34149 char *c = (char *) *sys_errlist
34150   ;
34151   return 0;
34152 }
34153 _ACEOF
34154 rm -f conftest.$ac_objext conftest$ac_exeext
34155 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34156   (eval $ac_link) 2>&5
34157   ac_status=$?
34158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34159   (exit $ac_status); } &&
34160          { ac_try='test -s conftest$ac_exeext'
34161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34162   (eval $ac_try) 2>&5
34163   ac_status=$?
34164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34165   (exit $ac_status); }; }; then
34166   ol_cv_have_sys_errlist=yes
34167 else
34168   echo "$as_me: failed program was:" >&5
34169 sed 's/^/| /' conftest.$ac_ext >&5
34170
34171 ol_cv_have_sys_errlist=no
34172 fi
34173 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
34174 fi
34175 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
34176 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
34177 fi
34178 if test $ol_cv_have_sys_errlist = yes ; then
34179
34180 cat >>confdefs.h <<\_ACEOF
34181 #define HAVE_SYS_ERRLIST 1
34182 _ACEOF
34183
34184 fi
34185
34186
34187
34188 if test "$ol_enable_slapi" != no ; then
34189
34190 for ac_header in ltdl.h
34191 do
34192 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
34193 if eval "test \"\${$as_ac_Header+set}\" = set"; then
34194   echo "$as_me:$LINENO: checking for $ac_header" >&5
34195 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
34196 if eval "test \"\${$as_ac_Header+set}\" = set"; then
34197   echo $ECHO_N "(cached) $ECHO_C" >&6
34198 fi
34199 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
34200 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
34201 else
34202   # Is the header compilable?
34203 echo "$as_me:$LINENO: checking $ac_header usability" >&5
34204 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
34205 cat >conftest.$ac_ext <<_ACEOF
34206 #line $LINENO "configure"
34207 /* confdefs.h.  */
34208 _ACEOF
34209 cat confdefs.h >>conftest.$ac_ext
34210 cat >>conftest.$ac_ext <<_ACEOF
34211 /* end confdefs.h.  */
34212 $ac_includes_default
34213 #include <$ac_header>
34214 _ACEOF
34215 rm -f conftest.$ac_objext
34216 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34217   (eval $ac_compile) 2>&5
34218   ac_status=$?
34219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34220   (exit $ac_status); } &&
34221          { ac_try='test -s conftest.$ac_objext'
34222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34223   (eval $ac_try) 2>&5
34224   ac_status=$?
34225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34226   (exit $ac_status); }; }; then
34227   ac_header_compiler=yes
34228 else
34229   echo "$as_me: failed program was:" >&5
34230 sed 's/^/| /' conftest.$ac_ext >&5
34231
34232 ac_header_compiler=no
34233 fi
34234 rm -f conftest.$ac_objext conftest.$ac_ext
34235 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
34236 echo "${ECHO_T}$ac_header_compiler" >&6
34237
34238 # Is the header present?
34239 echo "$as_me:$LINENO: checking $ac_header presence" >&5
34240 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
34241 cat >conftest.$ac_ext <<_ACEOF
34242 #line $LINENO "configure"
34243 /* confdefs.h.  */
34244 _ACEOF
34245 cat confdefs.h >>conftest.$ac_ext
34246 cat >>conftest.$ac_ext <<_ACEOF
34247 /* end confdefs.h.  */
34248 #include <$ac_header>
34249 _ACEOF
34250 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
34251   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
34252   ac_status=$?
34253   grep -v '^ *+' conftest.er1 >conftest.err
34254   rm -f conftest.er1
34255   cat conftest.err >&5
34256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34257   (exit $ac_status); } >/dev/null; then
34258   if test -s conftest.err; then
34259     ac_cpp_err=$ac_c_preproc_warn_flag
34260   else
34261     ac_cpp_err=
34262   fi
34263 else
34264   ac_cpp_err=yes
34265 fi
34266 if test -z "$ac_cpp_err"; then
34267   ac_header_preproc=yes
34268 else
34269   echo "$as_me: failed program was:" >&5
34270 sed 's/^/| /' conftest.$ac_ext >&5
34271
34272   ac_header_preproc=no
34273 fi
34274 rm -f conftest.err conftest.$ac_ext
34275 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
34276 echo "${ECHO_T}$ac_header_preproc" >&6
34277
34278 # So?  What about this header?
34279 case $ac_header_compiler:$ac_header_preproc in
34280   yes:no )
34281     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
34282 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
34283     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
34284 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
34285     (
34286       cat <<\_ASBOX
34287 ## ------------------------------------ ##
34288 ## Report this to bug-autoconf@gnu.org. ##
34289 ## ------------------------------------ ##
34290 _ASBOX
34291     ) |
34292       sed "s/^/$as_me: WARNING:     /" >&2
34293     ;;
34294   no:yes )
34295     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
34296 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
34297     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
34298 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
34299     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
34300 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
34301     (
34302       cat <<\_ASBOX
34303 ## ------------------------------------ ##
34304 ## Report this to bug-autoconf@gnu.org. ##
34305 ## ------------------------------------ ##
34306 _ASBOX
34307     ) |
34308       sed "s/^/$as_me: WARNING:     /" >&2
34309     ;;
34310 esac
34311 echo "$as_me:$LINENO: checking for $ac_header" >&5
34312 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
34313 if eval "test \"\${$as_ac_Header+set}\" = set"; then
34314   echo $ECHO_N "(cached) $ECHO_C" >&6
34315 else
34316   eval "$as_ac_Header=$ac_header_preproc"
34317 fi
34318 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
34319 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
34320
34321 fi
34322 if test `eval echo '${'$as_ac_Header'}'` = yes; then
34323   cat >>confdefs.h <<_ACEOF
34324 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
34325 _ACEOF
34326
34327 fi
34328
34329 done
34330
34331
34332         if test $ac_cv_header_ltdl_h != yes ; then
34333                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
34334 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
34335    { (exit 1); exit 1; }; }
34336         fi
34337         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
34338 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
34339 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
34340   echo $ECHO_N "(cached) $ECHO_C" >&6
34341 else
34342   ac_check_lib_save_LIBS=$LIBS
34343 LIBS="-lltdl  $LIBS"
34344 cat >conftest.$ac_ext <<_ACEOF
34345 #line $LINENO "configure"
34346 /* confdefs.h.  */
34347 _ACEOF
34348 cat confdefs.h >>conftest.$ac_ext
34349 cat >>conftest.$ac_ext <<_ACEOF
34350 /* end confdefs.h.  */
34351
34352 /* Override any gcc2 internal prototype to avoid an error.  */
34353 #ifdef __cplusplus
34354 extern "C"
34355 #endif
34356 /* We use char because int might match the return type of a gcc2
34357    builtin and then its argument prototype would still apply.  */
34358 char lt_dlinit ();
34359 int
34360 main ()
34361 {
34362 lt_dlinit ();
34363   ;
34364   return 0;
34365 }
34366 _ACEOF
34367 rm -f conftest.$ac_objext conftest$ac_exeext
34368 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34369   (eval $ac_link) 2>&5
34370   ac_status=$?
34371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34372   (exit $ac_status); } &&
34373          { ac_try='test -s conftest$ac_exeext'
34374   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34375   (eval $ac_try) 2>&5
34376   ac_status=$?
34377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34378   (exit $ac_status); }; }; then
34379   ac_cv_lib_ltdl_lt_dlinit=yes
34380 else
34381   echo "$as_me: failed program was:" >&5
34382 sed 's/^/| /' conftest.$ac_ext >&5
34383
34384 ac_cv_lib_ltdl_lt_dlinit=no
34385 fi
34386 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
34387 LIBS=$ac_check_lib_save_LIBS
34388 fi
34389 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
34390 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
34391 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
34392
34393                 SLAPI_LIBS=-lltdl
34394                 LIBSLAPI=./libslapi.a
34395                 LIBSLAPITOOLS=../libslapi.a
34396
34397 cat >>confdefs.h <<\_ACEOF
34398 #define HAVE_LIBLTDL 1
34399 _ACEOF
34400
34401
34402 else
34403   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
34404 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
34405    { (exit 1); exit 1; }; }
34406 fi
34407
34408
34409
34410 cat >>confdefs.h <<\_ACEOF
34411 #define LDAP_SLAPI 1
34412 _ACEOF
34413
34414 fi
34415
34416 if test "$ol_enable_debug" != no ; then
34417
34418 cat >>confdefs.h <<\_ACEOF
34419 #define LDAP_DEBUG 1
34420 _ACEOF
34421
34422 fi
34423 if test "$ol_enable_syslog" = yes ; then
34424
34425 cat >>confdefs.h <<\_ACEOF
34426 #define LDAP_SYSLOG 1
34427 _ACEOF
34428
34429 fi
34430 if test "$ol_link_kbind" != no ; then
34431         cat >>confdefs.h <<\_ACEOF
34432 #define LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND LDAP_VENDOR_VERSION
34433 _ACEOF
34434
34435 fi
34436 if test "$ol_enable_proctitle" != no ; then
34437
34438 cat >>confdefs.h <<\_ACEOF
34439 #define LDAP_PROCTITLE 1
34440 _ACEOF
34441
34442 fi
34443 if test "$ol_enable_referrals" != no ; then
34444         cat >>confdefs.h <<\_ACEOF
34445 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
34446 _ACEOF
34447
34448 fi
34449 if test "$ol_enable_local" != no; then
34450
34451 cat >>confdefs.h <<\_ACEOF
34452 #define LDAP_PF_LOCAL 1
34453 _ACEOF
34454
34455 fi
34456 if test "$ol_link_ipv6" != no; then
34457
34458 cat >>confdefs.h <<\_ACEOF
34459 #define LDAP_PF_INET6 1
34460 _ACEOF
34461
34462 fi
34463 if test "$ol_enable_cleartext" != no ; then
34464
34465 cat >>confdefs.h <<\_ACEOF
34466 #define SLAPD_CLEARTEXT 1
34467 _ACEOF
34468
34469 fi
34470 if test "$ol_enable_crypt" != no ; then
34471
34472 cat >>confdefs.h <<\_ACEOF
34473 #define SLAPD_CRYPT 1
34474 _ACEOF
34475
34476 fi
34477 if test "$ol_link_kpasswd" != no ; then
34478
34479 cat >>confdefs.h <<\_ACEOF
34480 #define SLAPD_KPASSWD 1
34481 _ACEOF
34482
34483 fi
34484 if test "$ol_link_spasswd" != no ; then
34485
34486 cat >>confdefs.h <<\_ACEOF
34487 #define SLAPD_SPASSWD 1
34488 _ACEOF
34489
34490 fi
34491 if test "$ol_enable_multimaster" != no ; then
34492
34493 cat >>confdefs.h <<\_ACEOF
34494 #define SLAPD_MULTIMASTER 1
34495 _ACEOF
34496
34497 fi
34498 if test "$ol_enable_phonetic" != no ; then
34499
34500 cat >>confdefs.h <<\_ACEOF
34501 #define SLAPD_PHONETIC 1
34502 _ACEOF
34503
34504 fi
34505 if test "$ol_enable_rlookups" != no ; then
34506
34507 cat >>confdefs.h <<\_ACEOF
34508 #define SLAPD_RLOOKUPS 1
34509 _ACEOF
34510
34511 fi
34512 if test "$ol_enable_aci" != no ; then
34513
34514 cat >>confdefs.h <<\_ACEOF
34515 #define SLAPD_ACI_ENABLED 1
34516 _ACEOF
34517
34518 fi
34519
34520 if test "$ol_link_modules" != no ; then
34521
34522 cat >>confdefs.h <<\_ACEOF
34523 #define SLAPD_MODULES 1
34524 _ACEOF
34525
34526         BUILD_SLAPD=yes
34527         SLAPD_MODULES_LDFLAGS="-dlopen self"
34528 fi
34529
34530 if test "$ol_enable_bdb" != no ; then
34531
34532 cat >>confdefs.h <<\_ACEOF
34533 #define SLAPD_BDB 1
34534 _ACEOF
34535
34536         BUILD_SLAPD=yes
34537         BUILD_BDB=yes
34538         if test "$ol_with_bdb_module" != static ; then
34539
34540 cat >>confdefs.h <<\_ACEOF
34541 #define SLAPD_BDB_DYNAMIC 1
34542 _ACEOF
34543
34544                 BUILD_BDB=mod
34545                 BUILD_BDB_DYNAMIC=shared
34546                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
34547         else
34548                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
34549         fi
34550 fi
34551
34552 if test "$ol_link_dnssrv" != no ; then
34553
34554 cat >>confdefs.h <<\_ACEOF
34555 #define SLAPD_DNSSRV 1
34556 _ACEOF
34557
34558         BUILD_SLAPD=yes
34559         BUILD_DNSSRV=yes
34560         if test "$ol_with_dnssrv_module" != static ; then
34561
34562 cat >>confdefs.h <<\_ACEOF
34563 #define SLAPD_DNSSRV_DYNAMIC 1
34564 _ACEOF
34565
34566                 BUILD_DNSSRV=mod
34567                 BUILD_DNSSRV_DYNAMIC=shared
34568                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
34569         else
34570                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
34571         fi
34572 fi
34573
34574 if test "$ol_enable_ldap" != no ; then
34575
34576 cat >>confdefs.h <<\_ACEOF
34577 #define SLAPD_LDAP 1
34578 _ACEOF
34579
34580         BUILD_SLAPD=yes
34581         BUILD_LDAP=yes
34582         if test "$ol_with_ldap_module" != static ; then
34583
34584 cat >>confdefs.h <<\_ACEOF
34585 #define SLAPD_LDAP_DYNAMIC 1
34586 _ACEOF
34587
34588                 BUILD_LDAP=mod
34589                 BUILD_LDAP_DYNAMIC=shared
34590                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
34591         else
34592                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
34593         fi
34594 fi
34595
34596 if test "$ol_link_ldbm" != no -a $ol_enable_ldbm != no; then
34597
34598 cat >>confdefs.h <<\_ACEOF
34599 #define SLAPD_LDBM 1
34600 _ACEOF
34601
34602         BUILD_SLAPD=yes
34603         BUILD_LDBM=yes
34604         if test "$ol_with_ldbm_module" != static ; then
34605
34606 cat >>confdefs.h <<\_ACEOF
34607 #define SLAPD_LDBM_DYNAMIC 1
34608 _ACEOF
34609
34610                 BUILD_LDBM=mod
34611                 BUILD_LDBM_DYNAMIC=shared
34612                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldbm"
34613         else
34614                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldbm"
34615         fi
34616 fi
34617
34618 if test "$ol_enable_meta" != no ; then
34619         if test "$ol_enable_ldap" = no ; then
34620                 { { echo "$as_me:$LINENO: error: need --enable-ldap to use --enable-meta" >&5
34621 echo "$as_me: error: need --enable-ldap to use --enable-meta" >&2;}
34622    { (exit 1); exit 1; }; }
34623         fi
34624         if test "$ol_enable_rewrite" = no ; then
34625                 { { echo "$as_me:$LINENO: error: need --enable-rewrite to use --enable-meta" >&5
34626 echo "$as_me: error: need --enable-rewrite to use --enable-meta" >&2;}
34627    { (exit 1); exit 1; }; }
34628         fi
34629
34630 cat >>confdefs.h <<\_ACEOF
34631 #define SLAPD_META 1
34632 _ACEOF
34633
34634         BUILD_SLAPD=yes
34635         BUILD_META=yes
34636         BUILD_LDAP=yes
34637         BUILD_REWRITE=yes
34638         if test "$ol_with_meta_module" != static ; then
34639
34640 cat >>confdefs.h <<\_ACEOF
34641 #define SLAPD_META_DYNAMIC 1
34642 _ACEOF
34643
34644                 BUILD_META=mod
34645                 BUILD_META_DYNAMIC=shared
34646                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
34647         else
34648                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
34649         fi
34650 fi
34651
34652 if test "$ol_enable_monitor" != no ; then
34653
34654 cat >>confdefs.h <<\_ACEOF
34655 #define SLAPD_MONITOR 1
34656 _ACEOF
34657
34658         BUILD_SLAPD=yes
34659         BUILD_MONITOR=yes
34660         if test "$ol_with_monitor_module" != static ; then
34661
34662 cat >>confdefs.h <<\_ACEOF
34663 #define SLAPD_MONITOR_DYNAMIC 1
34664 _ACEOF
34665
34666                 BUILD_MONITOR=mod
34667                 BUILD_MONITOR_DYNAMIC=shared
34668                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
34669         else
34670                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
34671         fi
34672 fi
34673
34674 if test "$ol_enable_null" != no ; then
34675
34676 cat >>confdefs.h <<\_ACEOF
34677 #define SLAPD_NULL 1
34678 _ACEOF
34679
34680         BUILD_SLAPD=yes
34681         BUILD_NULL=yes
34682         if test "$ol_with_null_module" != static ; then
34683
34684 cat >>confdefs.h <<\_ACEOF
34685 #define SLAPD_NULL_DYNAMIC 1
34686 _ACEOF
34687
34688                 BUILD_NULL=mod
34689                 BUILD_NULL_DYNAMIC=shared
34690                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
34691         else
34692                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
34693         fi
34694 fi
34695
34696 if test "$ol_enable_passwd" != no ; then
34697
34698 cat >>confdefs.h <<\_ACEOF
34699 #define SLAPD_PASSWD 1
34700 _ACEOF
34701
34702         BUILD_SLAPD=yes
34703         BUILD_PASSWD=yes
34704         if test "$ol_with_passwd_module" != static ; then
34705
34706 cat >>confdefs.h <<\_ACEOF
34707 #define SLAPD_PASSWD_DYNAMIC 1
34708 _ACEOF
34709
34710                 BUILD_PASSWD=mod
34711                 BUILD_PASSWD_DYNAMIC=shared
34712                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
34713         else
34714                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
34715         fi
34716 fi
34717
34718 if test "$ol_link_perl" != no ; then
34719
34720 cat >>confdefs.h <<\_ACEOF
34721 #define SLAPD_PERL 1
34722 _ACEOF
34723
34724         BUILD_SLAPD=yes
34725         BUILD_PERL=yes
34726         if test "$ol_with_perl_module" != static ; then
34727
34728 cat >>confdefs.h <<\_ACEOF
34729 #define SLAPD_PERL_DYNAMIC 1
34730 _ACEOF
34731
34732                 BUILD_PERL=mod
34733                 BUILD_PERL_DYNAMIC=shared
34734                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
34735         else
34736                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
34737         fi
34738 fi
34739
34740 if test "$ol_enable_shell" != no ; then
34741         if test "$ol_link_thread" != no ; then
34742                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
34743 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
34744         fi
34745
34746 cat >>confdefs.h <<\_ACEOF
34747 #define SLAPD_SHELL 1
34748 _ACEOF
34749
34750         BUILD_SLAPD=yes
34751         BUILD_SHELL=yes
34752         if test "$ol_with_shell_module" != static ; then
34753
34754 cat >>confdefs.h <<\_ACEOF
34755 #define SLAPD_SHELL_DYNAMIC 1
34756 _ACEOF
34757
34758                 BUILD_SHELL=mod
34759                 BUILD_SHELL_DYNAMIC=shared
34760                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
34761         else
34762                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
34763         fi
34764 fi
34765
34766 if test "$ol_enable_tcl" != no ; then
34767
34768 cat >>confdefs.h <<\_ACEOF
34769 #define SLAPD_TCL 1
34770 _ACEOF
34771
34772         BUILD_SLAPD=yes
34773         BUILD_TCL=yes
34774         if test "$ol_with_tcl_module" != static; then
34775
34776 cat >>confdefs.h <<\_ACEOF
34777 #define SLAPD_TCL_DYNAMIC 1
34778 _ACEOF
34779
34780                 BUILD_TCL=mod
34781                 BUILD_TCL_DYNAMIC=shared
34782                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-tcl"
34783         else
34784                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-tcl"
34785         fi
34786 fi
34787
34788 if test "$ol_link_sql" != no ; then
34789
34790 cat >>confdefs.h <<\_ACEOF
34791 #define SLAPD_SQL 1
34792 _ACEOF
34793
34794         BUILD_SLAPD=yes
34795         BUILD_SQL=yes
34796         if test "$ol_with_sql_module" != static; then
34797
34798 cat >>confdefs.h <<\_ACEOF
34799 #define SLAPD_SQL_DYNAMIC 1
34800 _ACEOF
34801
34802                 BUILD_SQL=mod
34803                 BUILD_SQL_DYNAMIC=shared
34804                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
34805         else
34806                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
34807         fi
34808 fi
34809
34810 if test "$ol_enable_slurpd" != no -a "$ol_link_threads" != no -a \
34811         $BUILD_SLAPD = yes ; then
34812         BUILD_SLURPD=yes
34813 fi
34814
34815 if test "$ol_enable_rewrite" != no ; then
34816
34817 cat >>confdefs.h <<\_ACEOF
34818 #define ENABLE_REWRITE 1
34819 _ACEOF
34820
34821         BUILD_REWRITE=yes
34822 fi
34823
34824 if test "$ol_enable_slapi" != no ; then
34825
34826 cat >>confdefs.h <<\_ACEOF
34827 #define ENABLE_SLAPI 1
34828 _ACEOF
34829
34830         BUILD_SLAPI=yes
34831         SLAPD_SLAPI_DEPEND=libslapi.a
34832 fi
34833
34834
34835
34836 if test "$ac_cv_mingw32" = yes ; then
34837         PLAT=NT
34838         SLAPD_MODULES_LDFLAGS=
34839 else
34840         PLAT=UNIX
34841 fi
34842
34843 if test -z "$SLAPD_STATIC_BACKENDS"; then
34844         SLAPD_NO_STATIC='#'
34845 else
34846         SLAPD_NO_STATIC=
34847 fi
34848
34849
34850
34851
34852
34853
34854
34855
34856
34857
34858
34859
34860
34861
34862
34863
34864
34865
34866
34867
34868
34869
34870
34871
34872
34873
34874
34875
34876
34877
34878
34879
34880
34881
34882
34883
34884
34885
34886
34887
34888
34889
34890
34891
34892
34893
34894
34895
34896
34897
34898
34899
34900
34901
34902
34903
34904
34905
34906
34907
34908
34909
34910
34911
34912
34913
34914
34915
34916
34917
34918
34919
34920
34921
34922 # Check whether --with-xxinstall or --without-xxinstall was given.
34923 if test "${with_xxinstall+set}" = set; then
34924   withval="$with_xxinstall"
34925
34926 fi;
34927
34928           ac_config_files="$ac_config_files Makefile:build/top.mk:Makefile.in:build/dir.mk"
34929
34930           ac_config_files="$ac_config_files doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk"
34931
34932           ac_config_files="$ac_config_files doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk"
34933
34934           ac_config_files="$ac_config_files doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk"
34935
34936           ac_config_files="$ac_config_files doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk"
34937
34938           ac_config_files="$ac_config_files doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk"
34939
34940           ac_config_files="$ac_config_files doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk"
34941
34942           ac_config_files="$ac_config_files clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk"
34943
34944           ac_config_files="$ac_config_files clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk"
34945
34946           ac_config_files="$ac_config_files include/Makefile:build/top.mk:include/Makefile.in"
34947
34948           ac_config_files="$ac_config_files libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk"
34949
34950           ac_config_files="$ac_config_files libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk"
34951
34952           ac_config_files="$ac_config_files libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk"
34953
34954           ac_config_files="$ac_config_files libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk"
34955
34956           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"
34957
34958           ac_config_files="$ac_config_files libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk"
34959
34960           ac_config_files="$ac_config_files libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk"
34961
34962           ac_config_files="$ac_config_files libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk"
34963
34964           ac_config_files="$ac_config_files libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk"
34965
34966           ac_config_files="$ac_config_files libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk"
34967
34968           ac_config_files="$ac_config_files servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk"
34969
34970           ac_config_files="$ac_config_files servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk"
34971
34972           ac_config_files="$ac_config_files servers/slapd/back-bdb/Makefile:build/top.mk:servers/slapd/back-bdb/Makefile.in:build/mod.mk"
34973
34974           ac_config_files="$ac_config_files servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk"
34975
34976           ac_config_files="$ac_config_files servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk"
34977
34978           ac_config_files="$ac_config_files servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk"
34979
34980           ac_config_files="$ac_config_files servers/slapd/back-meta/Makefile:build/top.mk:servers/slapd/back-meta/Makefile.in:build/mod.mk"
34981
34982           ac_config_files="$ac_config_files servers/slapd/back-monitor/Makefile:build/top.mk:servers/slapd/back-monitor/Makefile.in:build/mod.mk"
34983
34984           ac_config_files="$ac_config_files servers/slapd/back-null/Makefile:build/top.mk:servers/slapd/back-null/Makefile.in:build/mod.mk"
34985
34986           ac_config_files="$ac_config_files servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk"
34987
34988           ac_config_files="$ac_config_files servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk"
34989
34990           ac_config_files="$ac_config_files servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk"
34991
34992           ac_config_files="$ac_config_files servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk"
34993
34994           ac_config_files="$ac_config_files servers/slapd/back-tcl/Makefile:build/top.mk:servers/slapd/back-tcl/Makefile.in:build/mod.mk"
34995
34996           ac_config_files="$ac_config_files servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk"
34997
34998           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"
34999
35000           ac_config_files="$ac_config_files servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in"
35001
35002           ac_config_files="$ac_config_files servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk"
35003
35004           ac_config_files="$ac_config_files tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk"
35005
35006           ac_config_files="$ac_config_files tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk"
35007
35008
35009           ac_config_commands="$ac_config_commands time-stamp"
35010
35011 cat >confcache <<\_ACEOF
35012 # This file is a shell script that caches the results of configure
35013 # tests run on this system so they can be shared between configure
35014 # scripts and configure runs, see configure's option --config-cache.
35015 # It is not useful on other systems.  If it contains results you don't
35016 # want to keep, you may remove or edit it.
35017 #
35018 # config.status only pays attention to the cache file if you give it
35019 # the --recheck option to rerun configure.
35020 #
35021 # `ac_cv_env_foo' variables (set or unset) will be overridden when
35022 # loading this file, other *unset* `ac_cv_foo' will be assigned the
35023 # following values.
35024
35025 _ACEOF
35026
35027 # The following way of writing the cache mishandles newlines in values,
35028 # but we know of no workaround that is simple, portable, and efficient.
35029 # So, don't put newlines in cache variables' values.
35030 # Ultrix sh set writes to stderr and can't be redirected directly,
35031 # and sets the high bit in the cache file unless we assign to the vars.
35032 {
35033   (set) 2>&1 |
35034     case `(ac_space=' '; set | grep ac_space) 2>&1` in
35035     *ac_space=\ *)
35036       # `set' does not quote correctly, so add quotes (double-quote
35037       # substitution turns \\\\ into \\, and sed turns \\ into \).
35038       sed -n \
35039         "s/'/'\\\\''/g;
35040           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
35041       ;;
35042     *)
35043       # `set' quotes correctly as required by POSIX, so do not add quotes.
35044       sed -n \
35045         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
35046       ;;
35047     esac;
35048 } |
35049   sed '
35050      t clear
35051      : clear
35052      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
35053      t end
35054      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
35055      : end' >>confcache
35056 if diff $cache_file confcache >/dev/null 2>&1; then :; else
35057   if test -w $cache_file; then
35058     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
35059     cat confcache >$cache_file
35060   else
35061     echo "not updating unwritable cache $cache_file"
35062   fi
35063 fi
35064 rm -f confcache
35065
35066 test "x$prefix" = xNONE && prefix=$ac_default_prefix
35067 # Let make expand exec_prefix.
35068 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
35069
35070 # VPATH may cause trouble with some makes, so we remove $(srcdir),
35071 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
35072 # trailing colons and then remove the whole line if VPATH becomes empty
35073 # (actually we leave an empty line to preserve line numbers).
35074 if test "x$srcdir" = x.; then
35075   ac_vpsub='/^[         ]*VPATH[        ]*=/{
35076 s/:*\$(srcdir):*/:/;
35077 s/:*\${srcdir}:*/:/;
35078 s/:*@srcdir@:*/:/;
35079 s/^\([^=]*=[    ]*\):*/\1/;
35080 s/:*$//;
35081 s/^[^=]*=[      ]*$//;
35082 }'
35083 fi
35084
35085 DEFS=-DHAVE_CONFIG_H
35086
35087 ac_libobjs=
35088 ac_ltlibobjs=
35089 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
35090   # 1. Remove the extension, and $U if already installed.
35091   ac_i=`echo "$ac_i" |
35092          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
35093   # 2. Add them.
35094   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
35095   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
35096 done
35097 LIBOBJS=$ac_libobjs
35098
35099 LTLIBOBJS=$ac_ltlibobjs
35100
35101
35102
35103 : ${CONFIG_STATUS=./config.status}
35104 ac_clean_files_save=$ac_clean_files
35105 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
35106 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
35107 echo "$as_me: creating $CONFIG_STATUS" >&6;}
35108 cat >$CONFIG_STATUS <<_ACEOF
35109 #! $SHELL
35110 # Generated by $as_me.
35111 # Run this file to recreate the current configuration.
35112 # Compiler output produced by configure, useful for debugging
35113 # configure, is in config.log if it exists.
35114
35115 debug=false
35116 ac_cs_recheck=false
35117 ac_cs_silent=false
35118 SHELL=\${CONFIG_SHELL-$SHELL}
35119 _ACEOF
35120
35121 cat >>$CONFIG_STATUS <<\_ACEOF
35122 ## --------------------- ##
35123 ## M4sh Initialization.  ##
35124 ## --------------------- ##
35125
35126 # Be Bourne compatible
35127 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
35128   emulate sh
35129   NULLCMD=:
35130   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
35131   # is contrary to our usage.  Disable this feature.
35132   alias -g '${1+"$@"}'='"$@"'
35133 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
35134   set -o posix
35135 fi
35136
35137 # Support unset when possible.
35138 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
35139   as_unset=unset
35140 else
35141   as_unset=false
35142 fi
35143
35144
35145 # Work around bugs in pre-3.0 UWIN ksh.
35146 $as_unset ENV MAIL MAILPATH
35147 PS1='$ '
35148 PS2='> '
35149 PS4='+ '
35150
35151 # NLS nuisances.
35152 for as_var in \
35153   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
35154   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
35155   LC_TELEPHONE LC_TIME
35156 do
35157   if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
35158     eval $as_var=C; export $as_var
35159   else
35160     $as_unset $as_var
35161   fi
35162 done
35163
35164 # Required to use basename.
35165 if expr a : '\(a\)' >/dev/null 2>&1; then
35166   as_expr=expr
35167 else
35168   as_expr=false
35169 fi
35170
35171 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
35172   as_basename=basename
35173 else
35174   as_basename=false
35175 fi
35176
35177
35178 # Name of the executable.
35179 as_me=`$as_basename "$0" ||
35180 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
35181          X"$0" : 'X\(//\)$' \| \
35182          X"$0" : 'X\(/\)$' \| \
35183          .     : '\(.\)' 2>/dev/null ||
35184 echo X/"$0" |
35185     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
35186           /^X\/\(\/\/\)$/{ s//\1/; q; }
35187           /^X\/\(\/\).*/{ s//\1/; q; }
35188           s/.*/./; q'`
35189
35190
35191 # PATH needs CR, and LINENO needs CR and PATH.
35192 # Avoid depending upon Character Ranges.
35193 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
35194 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
35195 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
35196 as_cr_digits='0123456789'
35197 as_cr_alnum=$as_cr_Letters$as_cr_digits
35198
35199 # The user is always right.
35200 if test "${PATH_SEPARATOR+set}" != set; then
35201   echo "#! /bin/sh" >conf$$.sh
35202   echo  "exit 0"   >>conf$$.sh
35203   chmod +x conf$$.sh
35204   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
35205     PATH_SEPARATOR=';'
35206   else
35207     PATH_SEPARATOR=:
35208   fi
35209   rm -f conf$$.sh
35210 fi
35211
35212
35213   as_lineno_1=$LINENO
35214   as_lineno_2=$LINENO
35215   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
35216   test "x$as_lineno_1" != "x$as_lineno_2" &&
35217   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
35218   # Find who we are.  Look in the path if we contain no path at all
35219   # relative or not.
35220   case $0 in
35221     *[\\/]* ) as_myself=$0 ;;
35222     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35223 for as_dir in $PATH
35224 do
35225   IFS=$as_save_IFS
35226   test -z "$as_dir" && as_dir=.
35227   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
35228 done
35229
35230        ;;
35231   esac
35232   # We did not find ourselves, most probably we were run as `sh COMMAND'
35233   # in which case we are not to be found in the path.
35234   if test "x$as_myself" = x; then
35235     as_myself=$0
35236   fi
35237   if test ! -f "$as_myself"; then
35238     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
35239 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
35240    { (exit 1); exit 1; }; }
35241   fi
35242   case $CONFIG_SHELL in
35243   '')
35244     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35245 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
35246 do
35247   IFS=$as_save_IFS
35248   test -z "$as_dir" && as_dir=.
35249   for as_base in sh bash ksh sh5; do
35250          case $as_dir in
35251          /*)
35252            if ("$as_dir/$as_base" -c '
35253   as_lineno_1=$LINENO
35254   as_lineno_2=$LINENO
35255   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
35256   test "x$as_lineno_1" != "x$as_lineno_2" &&
35257   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
35258              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
35259              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
35260              CONFIG_SHELL=$as_dir/$as_base
35261              export CONFIG_SHELL
35262              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
35263            fi;;
35264          esac
35265        done
35266 done
35267 ;;
35268   esac
35269
35270   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
35271   # uniformly replaced by the line number.  The first 'sed' inserts a
35272   # line-number line before each line; the second 'sed' does the real
35273   # work.  The second script uses 'N' to pair each line-number line
35274   # with the numbered line, and appends trailing '-' during
35275   # substitution so that $LINENO is not a special case at line end.
35276   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
35277   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
35278   sed '=' <$as_myself |
35279     sed '
35280       N
35281       s,$,-,
35282       : loop
35283       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
35284       t loop
35285       s,-$,,
35286       s,^['$as_cr_digits']*\n,,
35287     ' >$as_me.lineno &&
35288   chmod +x $as_me.lineno ||
35289     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
35290 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
35291    { (exit 1); exit 1; }; }
35292
35293   # Don't try to exec as it changes $[0], causing all sort of problems
35294   # (the dirname of $[0] is not the place where we might find the
35295   # original and so on.  Autoconf is especially sensible to this).
35296   . ./$as_me.lineno
35297   # Exit status is that of the last command.
35298   exit
35299 }
35300
35301
35302 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
35303   *c*,-n*) ECHO_N= ECHO_C='
35304 ' ECHO_T='      ' ;;
35305   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
35306   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
35307 esac
35308
35309 if expr a : '\(a\)' >/dev/null 2>&1; then
35310   as_expr=expr
35311 else
35312   as_expr=false
35313 fi
35314
35315 rm -f conf$$ conf$$.exe conf$$.file
35316 echo >conf$$.file
35317 if ln -s conf$$.file conf$$ 2>/dev/null; then
35318   # We could just check for DJGPP; but this test a) works b) is more generic
35319   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
35320   if test -f conf$$.exe; then
35321     # Don't use ln at all; we don't have any links
35322     as_ln_s='cp -p'
35323   else
35324     as_ln_s='ln -s'
35325   fi
35326 elif ln conf$$.file conf$$ 2>/dev/null; then
35327   as_ln_s=ln
35328 else
35329   as_ln_s='cp -p'
35330 fi
35331 rm -f conf$$ conf$$.exe conf$$.file
35332
35333 if mkdir -p . 2>/dev/null; then
35334   as_mkdir_p=:
35335 else
35336   as_mkdir_p=false
35337 fi
35338
35339 as_executable_p="test -f"
35340
35341 # Sed expression to map a string onto a valid CPP name.
35342 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
35343
35344 # Sed expression to map a string onto a valid variable name.
35345 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
35346
35347
35348 # IFS
35349 # We need space, tab and new line, in precisely that order.
35350 as_nl='
35351 '
35352 IFS="   $as_nl"
35353
35354 # CDPATH.
35355 $as_unset CDPATH
35356
35357 exec 6>&1
35358
35359 # Open the log real soon, to keep \$[0] and so on meaningful, and to
35360 # report actual input values of CONFIG_FILES etc. instead of their
35361 # values after options handling.  Logging --version etc. is OK.
35362 exec 5>>config.log
35363 {
35364   echo
35365   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
35366 ## Running $as_me. ##
35367 _ASBOX
35368 } >&5
35369 cat >&5 <<_CSEOF
35370
35371 This file was extended by $as_me, which was
35372 generated by GNU Autoconf 2.57.  Invocation command line was
35373
35374   CONFIG_FILES    = $CONFIG_FILES
35375   CONFIG_HEADERS  = $CONFIG_HEADERS
35376   CONFIG_LINKS    = $CONFIG_LINKS
35377   CONFIG_COMMANDS = $CONFIG_COMMANDS
35378   $ $0 $@
35379
35380 _CSEOF
35381 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
35382 echo >&5
35383 _ACEOF
35384
35385 # Files that config.status was made for.
35386 if test -n "$ac_config_files"; then
35387   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
35388 fi
35389
35390 if test -n "$ac_config_headers"; then
35391   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
35392 fi
35393
35394 if test -n "$ac_config_links"; then
35395   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
35396 fi
35397
35398 if test -n "$ac_config_commands"; then
35399   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
35400 fi
35401
35402 cat >>$CONFIG_STATUS <<\_ACEOF
35403
35404 ac_cs_usage="\
35405 \`$as_me' instantiates files from templates according to the
35406 current configuration.
35407
35408 Usage: $0 [OPTIONS] [FILE]...
35409
35410   -h, --help       print this help, then exit
35411   -V, --version    print version number, then exit
35412   -q, --quiet      do not print progress messages
35413   -d, --debug      don't remove temporary files
35414       --recheck    update $as_me by reconfiguring in the same conditions
35415   --file=FILE[:TEMPLATE]
35416                    instantiate the configuration file FILE
35417   --header=FILE[:TEMPLATE]
35418                    instantiate the configuration header FILE
35419
35420 Configuration files:
35421 $config_files
35422
35423 Configuration headers:
35424 $config_headers
35425
35426 Configuration commands:
35427 $config_commands
35428
35429 Report bugs to <bug-autoconf@gnu.org>."
35430 _ACEOF
35431
35432 cat >>$CONFIG_STATUS <<_ACEOF
35433 ac_cs_version="\\
35434 config.status
35435 configured by $0, generated by GNU Autoconf 2.57,
35436   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
35437
35438 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
35439 Free Software Foundation, Inc.
35440 This config.status script is free software; the Free Software Foundation
35441 gives unlimited permission to copy, distribute and modify it."
35442 srcdir=$srcdir
35443 INSTALL="$INSTALL"
35444 _ACEOF
35445
35446 cat >>$CONFIG_STATUS <<\_ACEOF
35447 # If no file are specified by the user, then we need to provide default
35448 # value.  By we need to know if files were specified by the user.
35449 ac_need_defaults=:
35450 while test $# != 0
35451 do
35452   case $1 in
35453   --*=*)
35454     ac_option=`expr "x$1" : 'x\([^=]*\)='`
35455     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
35456     ac_shift=:
35457     ;;
35458   -*)
35459     ac_option=$1
35460     ac_optarg=$2
35461     ac_shift=shift
35462     ;;
35463   *) # This is not an option, so the user has probably given explicit
35464      # arguments.
35465      ac_option=$1
35466      ac_need_defaults=false;;
35467   esac
35468
35469   case $ac_option in
35470   # Handling of the options.
35471 _ACEOF
35472 cat >>$CONFIG_STATUS <<\_ACEOF
35473   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
35474     ac_cs_recheck=: ;;
35475   --version | --vers* | -V )
35476     echo "$ac_cs_version"; exit 0 ;;
35477   --he | --h)
35478     # Conflict between --help and --header
35479     { { echo "$as_me:$LINENO: error: ambiguous option: $1
35480 Try \`$0 --help' for more information." >&5
35481 echo "$as_me: error: ambiguous option: $1
35482 Try \`$0 --help' for more information." >&2;}
35483    { (exit 1); exit 1; }; };;
35484   --help | --hel | -h )
35485     echo "$ac_cs_usage"; exit 0 ;;
35486   --debug | --d* | -d )
35487     debug=: ;;
35488   --file | --fil | --fi | --f )
35489     $ac_shift
35490     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
35491     ac_need_defaults=false;;
35492   --header | --heade | --head | --hea )
35493     $ac_shift
35494     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
35495     ac_need_defaults=false;;
35496   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
35497   | -silent | --silent | --silen | --sile | --sil | --si | --s)
35498     ac_cs_silent=: ;;
35499
35500   # This is an error.
35501   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
35502 Try \`$0 --help' for more information." >&5
35503 echo "$as_me: error: unrecognized option: $1
35504 Try \`$0 --help' for more information." >&2;}
35505    { (exit 1); exit 1; }; } ;;
35506
35507   *) ac_config_targets="$ac_config_targets $1" ;;
35508
35509   esac
35510   shift
35511 done
35512
35513 ac_configure_extra_args=
35514
35515 if $ac_cs_silent; then
35516   exec 6>/dev/null
35517   ac_configure_extra_args="$ac_configure_extra_args --silent"
35518 fi
35519
35520 _ACEOF
35521 cat >>$CONFIG_STATUS <<_ACEOF
35522 if \$ac_cs_recheck; then
35523   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
35524   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
35525 fi
35526
35527 _ACEOF
35528
35529 cat >>$CONFIG_STATUS <<_ACEOF
35530 #
35531 # INIT-COMMANDS section.
35532 #
35533
35534 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
35535     # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
35536     # from automake.
35537     eval 'ALL_LINGUAS''="$ALL_LINGUAS"'
35538     # Capture the value of LINGUAS because we need it to compute CATALOGS.
35539     LINGUAS="${LINGUAS-%UNSET%}"
35540
35541
35542 _ACEOF
35543
35544
35545
35546 cat >>$CONFIG_STATUS <<\_ACEOF
35547 for ac_config_target in $ac_config_targets
35548 do
35549   case "$ac_config_target" in
35550   # Handling of arguments.
35551   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
35552   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
35553   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
35554   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
35555   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
35556   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
35557   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
35558   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
35559   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
35560   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
35561   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
35562   "libraries/libavl/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35563   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
35564   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
35565   "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" ;;
35566   "libraries/libldbm/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35567   "libraries/libldif/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35568   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35569   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35570   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
35571   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
35572   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
35573   "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" ;;
35574   "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" ;;
35575   "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" ;;
35576   "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" ;;
35577   "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" ;;
35578   "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" ;;
35579   "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" ;;
35580   "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" ;;
35581   "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" ;;
35582   "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" ;;
35583   "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" ;;
35584   "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" ;;
35585   "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" ;;
35586   "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" ;;
35587   "servers/slapd/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in" ;;
35588   "servers/slurpd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk" ;;
35589   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
35590   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
35591   "default-1" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
35592   "time-stamp" ) CONFIG_COMMANDS="$CONFIG_COMMANDS time-stamp" ;;
35593   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h" ;;
35594   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h" ;;
35595   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h" ;;
35596   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
35597 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
35598    { (exit 1); exit 1; }; };;
35599   esac
35600 done
35601
35602 # If the user did not use the arguments to specify the items to instantiate,
35603 # then the envvar interface is used.  Set only those that are not.
35604 # We use the long form for the default assignment because of an extremely
35605 # bizarre bug on SunOS 4.1.3.
35606 if $ac_need_defaults; then
35607   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
35608   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
35609   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
35610 fi
35611
35612 # Have a temporary directory for convenience.  Make it in the build tree
35613 # simply because there is no reason to put it here, and in addition,
35614 # creating and moving files from /tmp can sometimes cause problems.
35615 # Create a temporary directory, and hook for its removal unless debugging.
35616 $debug ||
35617 {
35618   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
35619   trap '{ (exit 1); exit 1; }' 1 2 13 15
35620 }
35621
35622 # Create a (secure) tmp directory for tmp files.
35623
35624 {
35625   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
35626   test -n "$tmp" && test -d "$tmp"
35627 }  ||
35628 {
35629   tmp=./confstat$$-$RANDOM
35630   (umask 077 && mkdir $tmp)
35631 } ||
35632 {
35633    echo "$me: cannot create a temporary directory in ." >&2
35634    { (exit 1); exit 1; }
35635 }
35636
35637 _ACEOF
35638
35639 cat >>$CONFIG_STATUS <<_ACEOF
35640
35641 #
35642 # CONFIG_FILES section.
35643 #
35644
35645 # No need to generate the scripts if there are no CONFIG_FILES.
35646 # This happens for instance when ./config.status config.h
35647 if test -n "\$CONFIG_FILES"; then
35648   # Protect against being on the right side of a sed subst in config.status.
35649   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
35650    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
35651 s,@SHELL@,$SHELL,;t t
35652 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
35653 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
35654 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
35655 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
35656 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
35657 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
35658 s,@exec_prefix@,$exec_prefix,;t t
35659 s,@prefix@,$prefix,;t t
35660 s,@program_transform_name@,$program_transform_name,;t t
35661 s,@bindir@,$bindir,;t t
35662 s,@sbindir@,$sbindir,;t t
35663 s,@libexecdir@,$libexecdir,;t t
35664 s,@datadir@,$datadir,;t t
35665 s,@sysconfdir@,$sysconfdir,;t t
35666 s,@sharedstatedir@,$sharedstatedir,;t t
35667 s,@localstatedir@,$localstatedir,;t t
35668 s,@libdir@,$libdir,;t t
35669 s,@includedir@,$includedir,;t t
35670 s,@oldincludedir@,$oldincludedir,;t t
35671 s,@infodir@,$infodir,;t t
35672 s,@mandir@,$mandir,;t t
35673 s,@build_alias@,$build_alias,;t t
35674 s,@host_alias@,$host_alias,;t t
35675 s,@target_alias@,$target_alias,;t t
35676 s,@DEFS@,$DEFS,;t t
35677 s,@ECHO_C@,$ECHO_C,;t t
35678 s,@ECHO_N@,$ECHO_N,;t t
35679 s,@ECHO_T@,$ECHO_T,;t t
35680 s,@LIBS@,$LIBS,;t t
35681 s,@build@,$build,;t t
35682 s,@build_cpu@,$build_cpu,;t t
35683 s,@build_vendor@,$build_vendor,;t t
35684 s,@build_os@,$build_os,;t t
35685 s,@host@,$host,;t t
35686 s,@host_cpu@,$host_cpu,;t t
35687 s,@host_vendor@,$host_vendor,;t t
35688 s,@host_os@,$host_os,;t t
35689 s,@target@,$target,;t t
35690 s,@target_cpu@,$target_cpu,;t t
35691 s,@target_vendor@,$target_vendor,;t t
35692 s,@target_os@,$target_os,;t t
35693 s,@OPENLDAP_PACKAGE@,$OPENLDAP_PACKAGE,;t t
35694 s,@OPENLDAP_VERSION@,$OPENLDAP_VERSION,;t t
35695 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
35696 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
35697 s,@top_builddir@,$top_builddir,;t t
35698 s,@ldap_subdir@,$ldap_subdir,;t t
35699 s,@SET_MAKE@,$SET_MAKE,;t t
35700 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
35701 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
35702 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
35703 s,@MKINSTALLDIRS@,$MKINSTALLDIRS,;t t
35704 s,@MSGFMT@,$MSGFMT,;t t
35705 s,@GMSGFMT@,$GMSGFMT,;t t
35706 s,@XGETTEXT@,$XGETTEXT,;t t
35707 s,@MSGMERGE@,$MSGMERGE,;t t
35708 s,@CC@,$CC,;t t
35709 s,@CFLAGS@,$CFLAGS,;t t
35710 s,@LDFLAGS@,$LDFLAGS,;t t
35711 s,@CPPFLAGS@,$CPPFLAGS,;t t
35712 s,@ac_ct_CC@,$ac_ct_CC,;t t
35713 s,@EXEEXT@,$EXEEXT,;t t
35714 s,@OBJEXT@,$OBJEXT,;t t
35715 s,@USE_NLS@,$USE_NLS,;t t
35716 s,@LIBICONV@,$LIBICONV,;t t
35717 s,@LTLIBICONV@,$LTLIBICONV,;t t
35718 s,@INTLLIBS@,$INTLLIBS,;t t
35719 s,@LIBINTL@,$LIBINTL,;t t
35720 s,@LTLIBINTL@,$LTLIBINTL,;t t
35721 s,@POSUB@,$POSUB,;t t
35722 s,@AR@,$AR,;t t
35723 s,@LN_S@,$LN_S,;t t
35724 s,@ECHO@,$ECHO,;t t
35725 s,@RANLIB@,$RANLIB,;t t
35726 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
35727 s,@STRIP@,$STRIP,;t t
35728 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
35729 s,@CPP@,$CPP,;t t
35730 s,@EGREP@,$EGREP,;t t
35731 s,@LIBTOOL@,$LIBTOOL,;t t
35732 s,@LN_H@,$LN_H,;t t
35733 s,@PERLBIN@,$PERLBIN,;t t
35734 s,@OL_MKDEP@,$OL_MKDEP,;t t
35735 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
35736 s,@LTSTATIC@,$LTSTATIC,;t t
35737 s,@LIBOBJS@,$LIBOBJS,;t t
35738 s,@LIBSRCS@,$LIBSRCS,;t t
35739 s,@PLAT@,$PLAT,;t t
35740 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
35741 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
35742 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
35743 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
35744 s,@BUILD_BDB@,$BUILD_BDB,;t t
35745 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
35746 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
35747 s,@BUILD_LDBM@,$BUILD_LDBM,;t t
35748 s,@BUILD_META@,$BUILD_META,;t t
35749 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
35750 s,@BUILD_NULL@,$BUILD_NULL,;t t
35751 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
35752 s,@BUILD_PERL@,$BUILD_PERL,;t t
35753 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
35754 s,@BUILD_SQL@,$BUILD_SQL,;t t
35755 s,@BUILD_TCL@,$BUILD_TCL,;t t
35756 s,@BUILD_BDB_DYNAMIC@,$BUILD_BDB_DYNAMIC,;t t
35757 s,@BUILD_DNSSRV_DYNAMIC@,$BUILD_DNSSRV_DYNAMIC,;t t
35758 s,@BUILD_LDAP_DYNAMIC@,$BUILD_LDAP_DYNAMIC,;t t
35759 s,@BUILD_LDBM_DYNAMIC@,$BUILD_LDBM_DYNAMIC,;t t
35760 s,@BUILD_META_DYNAMIC@,$BUILD_META_DYNAMIC,;t t
35761 s,@BUILD_MONITOR_DYNAMIC@,$BUILD_MONITOR_DYNAMIC,;t t
35762 s,@BUILD_NULL_DYNAMIC@,$BUILD_NULL_DYNAMIC,;t t
35763 s,@BUILD_PASSWD_DYNAMIC@,$BUILD_PASSWD_DYNAMIC,;t t
35764 s,@BUILD_PERL_DYNAMIC@,$BUILD_PERL_DYNAMIC,;t t
35765 s,@BUILD_SHELL_DYNAMIC@,$BUILD_SHELL_DYNAMIC,;t t
35766 s,@BUILD_SQL_DYNAMIC@,$BUILD_SQL_DYNAMIC,;t t
35767 s,@BUILD_TCL_DYNAMIC@,$BUILD_TCL_DYNAMIC,;t t
35768 s,@BUILD_SLURPD@,$BUILD_SLURPD,;t t
35769 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
35770 s,@LDIF_LIBS@,$LDIF_LIBS,;t t
35771 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
35772 s,@SLURPD_LIBS@,$SLURPD_LIBS,;t t
35773 s,@LDBM_LIBS@,$LDBM_LIBS,;t t
35774 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
35775 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
35776 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
35777 s,@MOD_TCL_LIB@,$MOD_TCL_LIB,;t t
35778 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
35779 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
35780 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
35781 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
35782 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
35783 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
35784 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
35785 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
35786 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
35787 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
35788 s,@READLINE_LIBS@,$READLINE_LIBS,;t t
35789 s,@SASL_LIBS@,$SASL_LIBS,;t t
35790 s,@TERMCAP_LIBS@,$TERMCAP_LIBS,;t t
35791 s,@TLS_LIBS@,$TLS_LIBS,;t t
35792 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
35793 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
35794 s,@LIBSLAPI@,$LIBSLAPI,;t t
35795 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
35796 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
35797 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
35798 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
35799 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
35800 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
35801 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
35802 CEOF
35803
35804 _ACEOF
35805
35806   cat >>$CONFIG_STATUS <<\_ACEOF
35807   # Split the substitutions into bite-sized pieces for seds with
35808   # small command number limits, like on Digital OSF/1 and HP-UX.
35809   ac_max_sed_lines=48
35810   ac_sed_frag=1 # Number of current file.
35811   ac_beg=1 # First line for current file.
35812   ac_end=$ac_max_sed_lines # Line after last line for current file.
35813   ac_more_lines=:
35814   ac_sed_cmds=
35815   while $ac_more_lines; do
35816     if test $ac_beg -gt 1; then
35817       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
35818     else
35819       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
35820     fi
35821     if test ! -s $tmp/subs.frag; then
35822       ac_more_lines=false
35823     else
35824       # The purpose of the label and of the branching condition is to
35825       # speed up the sed processing (if there are no `@' at all, there
35826       # is no need to browse any of the substitutions).
35827       # These are the two extra sed commands mentioned above.
35828       (echo ':t
35829   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
35830       if test -z "$ac_sed_cmds"; then
35831         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
35832       else
35833         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
35834       fi
35835       ac_sed_frag=`expr $ac_sed_frag + 1`
35836       ac_beg=$ac_end
35837       ac_end=`expr $ac_end + $ac_max_sed_lines`
35838     fi
35839   done
35840   if test -z "$ac_sed_cmds"; then
35841     ac_sed_cmds=cat
35842   fi
35843 fi # test -n "$CONFIG_FILES"
35844
35845 _ACEOF
35846 cat >>$CONFIG_STATUS <<\_ACEOF
35847 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
35848   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
35849   case $ac_file in
35850   - | *:- | *:-:* ) # input from stdin
35851         cat >$tmp/stdin
35852         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35853         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
35854   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35855         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
35856   * )   ac_file_in=$ac_file.in ;;
35857   esac
35858
35859   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
35860   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
35861 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35862          X"$ac_file" : 'X\(//\)[^/]' \| \
35863          X"$ac_file" : 'X\(//\)$' \| \
35864          X"$ac_file" : 'X\(/\)' \| \
35865          .     : '\(.\)' 2>/dev/null ||
35866 echo X"$ac_file" |
35867     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
35868           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
35869           /^X\(\/\/\)$/{ s//\1/; q; }
35870           /^X\(\/\).*/{ s//\1/; q; }
35871           s/.*/./; q'`
35872   { if $as_mkdir_p; then
35873     mkdir -p "$ac_dir"
35874   else
35875     as_dir="$ac_dir"
35876     as_dirs=
35877     while test ! -d "$as_dir"; do
35878       as_dirs="$as_dir $as_dirs"
35879       as_dir=`(dirname "$as_dir") 2>/dev/null ||
35880 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35881          X"$as_dir" : 'X\(//\)[^/]' \| \
35882          X"$as_dir" : 'X\(//\)$' \| \
35883          X"$as_dir" : 'X\(/\)' \| \
35884          .     : '\(.\)' 2>/dev/null ||
35885 echo X"$as_dir" |
35886     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
35887           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
35888           /^X\(\/\/\)$/{ s//\1/; q; }
35889           /^X\(\/\).*/{ s//\1/; q; }
35890           s/.*/./; q'`
35891     done
35892     test ! -n "$as_dirs" || mkdir $as_dirs
35893   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
35894 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
35895    { (exit 1); exit 1; }; }; }
35896
35897   ac_builddir=.
35898
35899 if test "$ac_dir" != .; then
35900   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
35901   # A "../" for each directory in $ac_dir_suffix.
35902   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
35903 else
35904   ac_dir_suffix= ac_top_builddir=
35905 fi
35906
35907 case $srcdir in
35908   .)  # No --srcdir option.  We are building in place.
35909     ac_srcdir=.
35910     if test -z "$ac_top_builddir"; then
35911        ac_top_srcdir=.
35912     else
35913        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
35914     fi ;;
35915   [\\/]* | ?:[\\/]* )  # Absolute path.
35916     ac_srcdir=$srcdir$ac_dir_suffix;
35917     ac_top_srcdir=$srcdir ;;
35918   *) # Relative path.
35919     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
35920     ac_top_srcdir=$ac_top_builddir$srcdir ;;
35921 esac
35922 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
35923 # absolute.
35924 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
35925 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
35926 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
35927 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
35928
35929
35930   case $INSTALL in
35931   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
35932   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
35933   esac
35934
35935   if test x"$ac_file" != x-; then
35936     { echo "$as_me:$LINENO: creating $ac_file" >&5
35937 echo "$as_me: creating $ac_file" >&6;}
35938     rm -f "$ac_file"
35939   fi
35940   # Let's still pretend it is `configure' which instantiates (i.e., don't
35941   # use $as_me), people would be surprised to read:
35942   #    /* config.h.  Generated by config.status.  */
35943   if test x"$ac_file" = x-; then
35944     configure_input=
35945   else
35946     configure_input="$ac_file.  "
35947   fi
35948   configure_input=$configure_input"Generated from `echo $ac_file_in |
35949                                      sed 's,.*/,,'` by configure."
35950
35951   # First look for the input files in the build tree, otherwise in the
35952   # src tree.
35953   ac_file_inputs=`IFS=:
35954     for f in $ac_file_in; do
35955       case $f in
35956       -) echo $tmp/stdin ;;
35957       [\\/$]*)
35958          # Absolute (can't be DOS-style, as IFS=:)
35959          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
35960 echo "$as_me: error: cannot find input file: $f" >&2;}
35961    { (exit 1); exit 1; }; }
35962          echo $f;;
35963       *) # Relative
35964          if test -f "$f"; then
35965            # Build tree
35966            echo $f
35967          elif test -f "$srcdir/$f"; then
35968            # Source tree
35969            echo $srcdir/$f
35970          else
35971            # /dev/null tree
35972            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
35973 echo "$as_me: error: cannot find input file: $f" >&2;}
35974    { (exit 1); exit 1; }; }
35975          fi;;
35976       esac
35977     done` || { (exit 1); exit 1; }
35978 _ACEOF
35979 cat >>$CONFIG_STATUS <<_ACEOF
35980   sed "$ac_vpsub
35981 $extrasub
35982 _ACEOF
35983 cat >>$CONFIG_STATUS <<\_ACEOF
35984 :t
35985 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
35986 s,@configure_input@,$configure_input,;t t
35987 s,@srcdir@,$ac_srcdir,;t t
35988 s,@abs_srcdir@,$ac_abs_srcdir,;t t
35989 s,@top_srcdir@,$ac_top_srcdir,;t t
35990 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
35991 s,@builddir@,$ac_builddir,;t t
35992 s,@abs_builddir@,$ac_abs_builddir,;t t
35993 s,@top_builddir@,$ac_top_builddir,;t t
35994 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
35995 s,@INSTALL@,$ac_INSTALL,;t t
35996 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
35997   rm -f $tmp/stdin
35998   if test x"$ac_file" != x-; then
35999     mv $tmp/out $ac_file
36000   else
36001     cat $tmp/out
36002     rm -f $tmp/out
36003   fi
36004
36005 done
36006 _ACEOF
36007 cat >>$CONFIG_STATUS <<\_ACEOF
36008
36009 #
36010 # CONFIG_HEADER section.
36011 #
36012
36013 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
36014 # NAME is the cpp macro being defined and VALUE is the value it is being given.
36015 #
36016 # ac_d sets the value in "#define NAME VALUE" lines.
36017 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
36018 ac_dB='[        ].*$,\1#\2'
36019 ac_dC=' '
36020 ac_dD=',;t'
36021 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
36022 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
36023 ac_uB='$,\1#\2define\3'
36024 ac_uC=' '
36025 ac_uD=',;t'
36026
36027 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
36028   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
36029   case $ac_file in
36030   - | *:- | *:-:* ) # input from stdin
36031         cat >$tmp/stdin
36032         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
36033         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
36034   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
36035         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
36036   * )   ac_file_in=$ac_file.in ;;
36037   esac
36038
36039   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
36040 echo "$as_me: creating $ac_file" >&6;}
36041
36042   # First look for the input files in the build tree, otherwise in the
36043   # src tree.
36044   ac_file_inputs=`IFS=:
36045     for f in $ac_file_in; do
36046       case $f in
36047       -) echo $tmp/stdin ;;
36048       [\\/$]*)
36049          # Absolute (can't be DOS-style, as IFS=:)
36050          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
36051 echo "$as_me: error: cannot find input file: $f" >&2;}
36052    { (exit 1); exit 1; }; }
36053          echo $f;;
36054       *) # Relative
36055          if test -f "$f"; then
36056            # Build tree
36057            echo $f
36058          elif test -f "$srcdir/$f"; then
36059            # Source tree
36060            echo $srcdir/$f
36061          else
36062            # /dev/null tree
36063            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
36064 echo "$as_me: error: cannot find input file: $f" >&2;}
36065    { (exit 1); exit 1; }; }
36066          fi;;
36067       esac
36068     done` || { (exit 1); exit 1; }
36069   # Remove the trailing spaces.
36070   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
36071
36072 _ACEOF
36073
36074 # Transform confdefs.h into two sed scripts, `conftest.defines' and
36075 # `conftest.undefs', that substitutes the proper values into
36076 # config.h.in to produce config.h.  The first handles `#define'
36077 # templates, and the second `#undef' templates.
36078 # And first: Protect against being on the right side of a sed subst in
36079 # config.status.  Protect against being in an unquoted here document
36080 # in config.status.
36081 rm -f conftest.defines conftest.undefs
36082 # Using a here document instead of a string reduces the quoting nightmare.
36083 # Putting comments in sed scripts is not portable.
36084 #
36085 # `end' is used to avoid that the second main sed command (meant for
36086 # 0-ary CPP macros) applies to n-ary macro definitions.
36087 # See the Autoconf documentation for `clear'.
36088 cat >confdef2sed.sed <<\_ACEOF
36089 s/[\\&,]/\\&/g
36090 s,[\\$`],\\&,g
36091 t clear
36092 : clear
36093 s,^[    ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
36094 t end
36095 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
36096 : end
36097 _ACEOF
36098 # If some macros were called several times there might be several times
36099 # the same #defines, which is useless.  Nevertheless, we may not want to
36100 # sort them, since we want the *last* AC-DEFINE to be honored.
36101 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
36102 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
36103 rm -f confdef2sed.sed
36104
36105 # This sed command replaces #undef with comments.  This is necessary, for
36106 # example, in the case of _POSIX_SOURCE, which is predefined and required
36107 # on some systems where configure will not decide to define it.
36108 cat >>conftest.undefs <<\_ACEOF
36109 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
36110 _ACEOF
36111
36112 # Break up conftest.defines because some shells have a limit on the size
36113 # of here documents, and old seds have small limits too (100 cmds).
36114 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
36115 echo '  if grep "^[     ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
36116 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
36117 echo '  :' >>$CONFIG_STATUS
36118 rm -f conftest.tail
36119 while grep . conftest.defines >/dev/null
36120 do
36121   # Write a limited-size here document to $tmp/defines.sed.
36122   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
36123   # Speed up: don't consider the non `#define' lines.
36124   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
36125   # Work around the forget-to-reset-the-flag bug.
36126   echo 't clr' >>$CONFIG_STATUS
36127   echo ': clr' >>$CONFIG_STATUS
36128   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
36129   echo 'CEOF
36130   sed -f $tmp/defines.sed $tmp/in >$tmp/out
36131   rm -f $tmp/in
36132   mv $tmp/out $tmp/in
36133 ' >>$CONFIG_STATUS
36134   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
36135   rm -f conftest.defines
36136   mv conftest.tail conftest.defines
36137 done
36138 rm -f conftest.defines
36139 echo '  fi # grep' >>$CONFIG_STATUS
36140 echo >>$CONFIG_STATUS
36141
36142 # Break up conftest.undefs because some shells have a limit on the size
36143 # of here documents, and old seds have small limits too (100 cmds).
36144 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
36145 rm -f conftest.tail
36146 while grep . conftest.undefs >/dev/null
36147 do
36148   # Write a limited-size here document to $tmp/undefs.sed.
36149   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
36150   # Speed up: don't consider the non `#undef'
36151   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
36152   # Work around the forget-to-reset-the-flag bug.
36153   echo 't clr' >>$CONFIG_STATUS
36154   echo ': clr' >>$CONFIG_STATUS
36155   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
36156   echo 'CEOF
36157   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
36158   rm -f $tmp/in
36159   mv $tmp/out $tmp/in
36160 ' >>$CONFIG_STATUS
36161   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
36162   rm -f conftest.undefs
36163   mv conftest.tail conftest.undefs
36164 done
36165 rm -f conftest.undefs
36166
36167 cat >>$CONFIG_STATUS <<\_ACEOF
36168   # Let's still pretend it is `configure' which instantiates (i.e., don't
36169   # use $as_me), people would be surprised to read:
36170   #    /* config.h.  Generated by config.status.  */
36171   if test x"$ac_file" = x-; then
36172     echo "/* Generated by configure.  */" >$tmp/config.h
36173   else
36174     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
36175   fi
36176   cat $tmp/in >>$tmp/config.h
36177   rm -f $tmp/in
36178   if test x"$ac_file" != x-; then
36179     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
36180       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
36181 echo "$as_me: $ac_file is unchanged" >&6;}
36182     else
36183       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
36184 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36185          X"$ac_file" : 'X\(//\)[^/]' \| \
36186          X"$ac_file" : 'X\(//\)$' \| \
36187          X"$ac_file" : 'X\(/\)' \| \
36188          .     : '\(.\)' 2>/dev/null ||
36189 echo X"$ac_file" |
36190     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
36191           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
36192           /^X\(\/\/\)$/{ s//\1/; q; }
36193           /^X\(\/\).*/{ s//\1/; q; }
36194           s/.*/./; q'`
36195       { if $as_mkdir_p; then
36196     mkdir -p "$ac_dir"
36197   else
36198     as_dir="$ac_dir"
36199     as_dirs=
36200     while test ! -d "$as_dir"; do
36201       as_dirs="$as_dir $as_dirs"
36202       as_dir=`(dirname "$as_dir") 2>/dev/null ||
36203 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36204          X"$as_dir" : 'X\(//\)[^/]' \| \
36205          X"$as_dir" : 'X\(//\)$' \| \
36206          X"$as_dir" : 'X\(/\)' \| \
36207          .     : '\(.\)' 2>/dev/null ||
36208 echo X"$as_dir" |
36209     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
36210           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
36211           /^X\(\/\/\)$/{ s//\1/; q; }
36212           /^X\(\/\).*/{ s//\1/; q; }
36213           s/.*/./; q'`
36214     done
36215     test ! -n "$as_dirs" || mkdir $as_dirs
36216   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
36217 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
36218    { (exit 1); exit 1; }; }; }
36219
36220       rm -f $ac_file
36221       mv $tmp/config.h $ac_file
36222     fi
36223   else
36224     cat $tmp/config.h
36225     rm -f $tmp/config.h
36226   fi
36227 done
36228 _ACEOF
36229 cat >>$CONFIG_STATUS <<\_ACEOF
36230
36231 #
36232 # CONFIG_COMMANDS section.
36233 #
36234 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
36235   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
36236   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
36237   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
36238 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36239          X"$ac_dest" : 'X\(//\)[^/]' \| \
36240          X"$ac_dest" : 'X\(//\)$' \| \
36241          X"$ac_dest" : 'X\(/\)' \| \
36242          .     : '\(.\)' 2>/dev/null ||
36243 echo X"$ac_dest" |
36244     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
36245           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
36246           /^X\(\/\/\)$/{ s//\1/; q; }
36247           /^X\(\/\).*/{ s//\1/; q; }
36248           s/.*/./; q'`
36249   ac_builddir=.
36250
36251 if test "$ac_dir" != .; then
36252   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
36253   # A "../" for each directory in $ac_dir_suffix.
36254   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
36255 else
36256   ac_dir_suffix= ac_top_builddir=
36257 fi
36258
36259 case $srcdir in
36260   .)  # No --srcdir option.  We are building in place.
36261     ac_srcdir=.
36262     if test -z "$ac_top_builddir"; then
36263        ac_top_srcdir=.
36264     else
36265        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
36266     fi ;;
36267   [\\/]* | ?:[\\/]* )  # Absolute path.
36268     ac_srcdir=$srcdir$ac_dir_suffix;
36269     ac_top_srcdir=$srcdir ;;
36270   *) # Relative path.
36271     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
36272     ac_top_srcdir=$ac_top_builddir$srcdir ;;
36273 esac
36274 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
36275 # absolute.
36276 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
36277 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
36278 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
36279 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
36280
36281
36282   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
36283 echo "$as_me: executing $ac_dest commands" >&6;}
36284   case $ac_dest in
36285     default-1 )
36286     for ac_file in $CONFIG_FILES; do
36287       # Support "outfile[:infile[:infile...]]"
36288       case "$ac_file" in
36289         *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
36290       esac
36291       # PO directories have a Makefile.in generated from Makefile.in.in.
36292       case "$ac_file" in */Makefile.in)
36293         # Adjust a relative srcdir.
36294         ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
36295         ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
36296         ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
36297         # In autoconf-2.13 it is called $ac_given_srcdir.
36298         # In autoconf-2.50 it is called $srcdir.
36299         test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
36300         case "$ac_given_srcdir" in
36301           .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
36302           /*) top_srcdir="$ac_given_srcdir" ;;
36303           *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
36304         esac
36305         if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
36306           rm -f "$ac_dir/POTFILES"
36307           test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
36308           cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[   ]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
36309           # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
36310           # on $ac_dir but don't depend on user-specified configuration
36311           # parameters.
36312           if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
36313             # The LINGUAS file contains the set of available languages.
36314             if test -n "$ALL_LINGUAS"; then
36315               test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
36316             fi
36317             ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
36318             # Hide the ALL_LINGUAS assigment from automake.
36319             eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
36320           fi
36321           case "$ac_given_srcdir" in
36322             .) srcdirpre= ;;
36323             *) srcdirpre='$(srcdir)/' ;;
36324           esac
36325           POFILES=
36326           GMOFILES=
36327           UPDATEPOFILES=
36328           DUMMYPOFILES=
36329           for lang in $ALL_LINGUAS; do
36330             POFILES="$POFILES $srcdirpre$lang.po"
36331             GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
36332             UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
36333             DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
36334           done
36335           # CATALOGS depends on both $ac_dir and the user's LINGUAS
36336           # environment variable.
36337           INST_LINGUAS=
36338           if test -n "$ALL_LINGUAS"; then
36339             for presentlang in $ALL_LINGUAS; do
36340               useit=no
36341               if test "%UNSET%" != "$LINGUAS"; then
36342                 desiredlanguages="$LINGUAS"
36343               else
36344                 desiredlanguages="$ALL_LINGUAS"
36345               fi
36346               for desiredlang in $desiredlanguages; do
36347                 # Use the presentlang catalog if desiredlang is
36348                 #   a. equal to presentlang, or
36349                 #   b. a variant of presentlang (because in this case,
36350                 #      presentlang can be used as a fallback for messages
36351                 #      which are not translated in the desiredlang catalog).
36352                 case "$desiredlang" in
36353                   "$presentlang"*) useit=yes;;
36354                 esac
36355               done
36356               if test $useit = yes; then
36357                 INST_LINGUAS="$INST_LINGUAS $presentlang"
36358               fi
36359             done
36360           fi
36361           CATALOGS=
36362           if test -n "$INST_LINGUAS"; then
36363             for lang in $INST_LINGUAS; do
36364               CATALOGS="$CATALOGS $lang.gmo"
36365             done
36366           fi
36367           test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
36368           sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
36369           for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
36370             if test -f "$f"; then
36371               case "$f" in
36372                 *.orig | *.bak | *~) ;;
36373                 *) cat "$f" >> "$ac_dir/Makefile" ;;
36374               esac
36375             fi
36376           done
36377         fi
36378         ;;
36379       esac
36380     done ;;
36381     time-stamp ) date >stamp-h
36382 echo Please run \"make depend\" to build dependencies ;;
36383   esac
36384 done
36385 _ACEOF
36386
36387 cat >>$CONFIG_STATUS <<\_ACEOF
36388
36389 { (exit 0); exit 0; }
36390 _ACEOF
36391 chmod +x $CONFIG_STATUS
36392 ac_clean_files=$ac_clean_files_save
36393
36394
36395 # configure is writing to config.log, and then calls config.status.
36396 # config.status does its own redirection, appending to config.log.
36397 # Unfortunately, on DOS this fails, as config.log is still kept open
36398 # by configure, so config.status won't be able to write to it; its
36399 # output is simply discarded.  So we exec the FD to /dev/null,
36400 # effectively closing config.log, so it can be properly (re)opened and
36401 # appended to by config.status.  When coming back to configure, we
36402 # need to make the FD available again.
36403 if test "$no_create" != yes; then
36404   ac_cs_success=:
36405   ac_config_status_args=
36406   test "$silent" = yes &&
36407     ac_config_status_args="$ac_config_status_args --quiet"
36408   exec 5>/dev/null
36409   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
36410   exec 5>>config.log
36411   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
36412   # would make configure fail if this is the last instruction.
36413   $ac_cs_success || { (exit 1); exit 1; }
36414 fi
36415