3 # from OpenLDAP: pkg/ldap/configure.in,v 1.310 2000/06/08 22:32:03 kurt Exp
5 # Copyright 1998-2000 The OpenLDAP Foundation. All Rights Reserved.
7 # Redistribution and use in source and binary forms are permitted only
8 # as authorized by the OpenLDAP Public License. A copy of this
9 # license is available at http://www.OpenLDAP.org/license.html or
10 # in file LICENSE in the top-level directory of the distribution.
12 echo "Copyright 1998-2000 The OpenLDAP Foundation, All Rights Reserved."
13 echo "Copying restrictions apply, see COPYRIGHT file."
18 # Guess values for system-dependent variables and create Makefiles.
19 # Generated automatically using autoconf version 2.13.1
20 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
22 # This configure script is free software; the Free Software Foundation
23 # gives unlimited permission to copy, distribute and modify it.
27 ac_default_prefix=/usr/local
28 # Any additions from configure.in:
29 ac_default_prefix=/usr/local
31 --with-subdir=DIR change default subdirectory used for installs"
33 --enable-debug enable debugging (yes)"
35 --enable-syslog enable syslog support (auto)"
37 --enable-proctitle enable proctitle support (yes)"
39 --enable-cache enable caching (yes)"
41 --enable-referrals enable V2 Referrals extension (yes)"
43 --enable-kbind enable V2 Kerberos IV bind (auto)"
45 --enable-cldap enable connectionless ldap (no)"
47 --enable-ldapi enable domain socket (PF_LOCAL) ldap (no)"
49 --enable-x-compile enable cross compiling (no)"
51 --with-cyrus-sasl with Cyrus SASL support (auto)"
53 --with-fetch with fetch URL support (auto)"
55 --with-kerberos with support (auto)"
57 --with-readline with readline support (auto)"
59 --with-threads use threads (auto)"
61 --with-tls with TLS/SSL support (auto)"
63 --with-yielding-select with implicitly yielding select (auto)"
65 SLAPD (Standalone LDAP Daemon) Options:"
67 --enable-slapd enable building slapd (yes)"
69 --enable-cleartext enable cleartext passwords (yes)"
71 --enable-crypt enable crypt(3) passwords (auto)"
73 --enable-kpasswd enable kerberos password verification (no)"
75 --enable-spasswd enable (Cyrus) SASL password verification (no)"
77 --enable-modules enable dynamic module support (no)"
79 --enable-multimaster enable multimaster replication (no)"
81 --enable-phonetic enable phonetic/soundex (no)"
83 --enable-quipu build quipu migration tools (no)"
85 --enable-rlookups enable reverse lookups (auto)"
87 --enable-aci enable per-object ACIs (no)"
89 --enable-wrappers enable tcp wrapper support (no)"
91 --enable-dynamic enable linking built binaries with dynamic libs (no)"
93 --enable-dnssrv enable dnssrv backend (no)"
95 --with-dnssrv-module module type (static)"
97 --enable-ldap enable ldap backend (no)"
99 --with-ldap-module module type (static)"
101 --enable-ldbm enable ldbm backend (yes)"
103 --with-ldbm-api use LDBM API (auto)"
105 --with-ldbm-module module type (static)"
107 --with-ldbm-type use LDBM type (auto)"
109 --enable-passwd enable passwd backend (no)"
111 --with-passwd-module module type (static)"
113 --enable-perl enable perl backend (no)"
115 --with-perl-module module type (static)"
117 --enable-shell enable shell backend (no)"
119 --with-shell-module module type (static)"
121 --enable-sql enable sql backend (no)"
123 --with-sql-module module type (static)"
125 --enable-tcl enable tcl backend (no)"
127 --with-tcl-module module type (static)"
129 SLURPD (Replication Daemon) Options:"
131 --enable-slurpd enable building slurpd (auto)"
133 Library Generation & Linking Options"
135 --enable-static[=PKGS] build static libraries [default=yes]"
137 --enable-shared[=PKGS] build shared libraries [default=yes]"
139 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
141 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
143 --disable-libtool-lock avoid locking (might break parallel builds)"
145 # Initialize some variables set by options.
146 # The variables have the same names as the options, with
147 # dashes changed to underlines.
149 cache_file=./config.cache
158 program_transform_name=s,x,x,
166 bindir='${exec_prefix}/bin'
167 sbindir='${exec_prefix}/sbin'
168 libexecdir='${exec_prefix}/libexec'
169 datadir='${prefix}/share'
170 sysconfdir='${prefix}/etc'
171 sharedstatedir='${prefix}/com'
172 localstatedir='${prefix}/var'
173 libdir='${exec_prefix}/lib'
174 includedir='${prefix}/include'
175 oldincludedir='/usr/include'
176 infodir='${prefix}/info'
177 mandir='${prefix}/man'
179 # Initialize some other variables.
182 SHELL=${CONFIG_SHELL-/bin/sh}
183 # Maximum number of lines to put in a shell here document.
190 # If the previous option needs an argument, assign it.
191 if test -n "$ac_prev"; then
192 eval "$ac_prev=\$ac_option"
198 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
202 # Accept the important Cygnus configure options, so we can diagnose typos.
206 -bindir | --bindir | --bindi | --bind | --bin | --bi)
208 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
209 bindir="$ac_optarg" ;;
211 -build | --build | --buil | --bui | --bu)
213 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
214 build="$ac_optarg" ;;
216 -cache-file | --cache-file | --cache-fil | --cache-fi \
217 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
218 ac_prev=cache_file ;;
219 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
220 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
221 cache_file="$ac_optarg" ;;
223 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
225 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
227 datadir="$ac_optarg" ;;
229 -disable-* | --disable-*)
230 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
231 # Reject names that are not valid shell variable names.
232 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
233 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
235 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
236 eval "enable_${ac_feature}=no" ;;
238 -enable-* | --enable-*)
239 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
240 # Reject names that are not valid shell variable names.
241 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
242 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
244 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
249 eval "enable_${ac_feature}='$ac_optarg'" ;;
251 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
252 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
253 | --exec | --exe | --ex)
254 ac_prev=exec_prefix ;;
255 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
256 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
257 | --exec=* | --exe=* | --ex=*)
258 exec_prefix="$ac_optarg" ;;
260 -gas | --gas | --ga | --g)
261 # Obsolete; use --with-gas.
264 -help | --help | --hel | --he)
265 # Omit some internal or obsolete options to make the list less imposing.
266 # This message is too long to be a string in the A/UX 3.1 sh.
268 Usage: configure [options] [host]
269 Options: [defaults in brackets after descriptions]
271 --cache-file=FILE cache test results in FILE
272 --help print this message
273 --no-create do not create output files
274 --quiet, --silent do not print \`checking...' messages
275 --version print the version of autoconf that created configure
276 Directory and file names:
277 --prefix=PREFIX install architecture-independent files in PREFIX
279 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
281 --bindir=DIR user executables in DIR [EPREFIX/bin]
282 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
283 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
284 --datadir=DIR read-only architecture-independent data in DIR
286 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
287 --sharedstatedir=DIR modifiable architecture-independent data in DIR
289 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
290 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
291 --includedir=DIR C header files in DIR [PREFIX/include]
292 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
293 --infodir=DIR info documentation in DIR [PREFIX/info]
294 --mandir=DIR man documentation in DIR [PREFIX/man]
295 --srcdir=DIR find the sources in DIR [configure dir or ..]
296 --program-prefix=PREFIX prepend PREFIX to installed program names
297 --program-suffix=SUFFIX append SUFFIX to installed program names
298 --program-transform-name=PROGRAM
299 run sed PROGRAM on installed program names
303 --build=BUILD configure for building on BUILD [BUILD=HOST]
304 --host=HOST configure for HOST [guessed]
305 --target=TARGET configure for TARGET [TARGET=HOST]
306 Features and packages:
307 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
308 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
309 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
310 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
311 --x-includes=DIR X include files are in DIR
312 --x-libraries=DIR X library files are in DIR
314 if test -n "$ac_help"; then
315 echo "--enable and --with options recognized:$ac_help"
319 -host | --host | --hos | --ho)
321 -host=* | --host=* | --hos=* | --ho=*)
324 -includedir | --includedir | --includedi | --included | --include \
325 | --includ | --inclu | --incl | --inc)
326 ac_prev=includedir ;;
327 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
328 | --includ=* | --inclu=* | --incl=* | --inc=*)
329 includedir="$ac_optarg" ;;
331 -infodir | --infodir | --infodi | --infod | --info | --inf)
333 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
334 infodir="$ac_optarg" ;;
336 -libdir | --libdir | --libdi | --libd)
338 -libdir=* | --libdir=* | --libdi=* | --libd=*)
339 libdir="$ac_optarg" ;;
341 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
342 | --libexe | --libex | --libe)
343 ac_prev=libexecdir ;;
344 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
345 | --libexe=* | --libex=* | --libe=*)
346 libexecdir="$ac_optarg" ;;
348 -localstatedir | --localstatedir | --localstatedi | --localstated \
349 | --localstate | --localstat | --localsta | --localst \
350 | --locals | --local | --loca | --loc | --lo)
351 ac_prev=localstatedir ;;
352 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
353 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
354 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
355 localstatedir="$ac_optarg" ;;
357 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
359 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
360 mandir="$ac_optarg" ;;
363 # Obsolete; use --without-fp.
366 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
370 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
371 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
374 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
375 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
376 | --oldin | --oldi | --old | --ol | --o)
377 ac_prev=oldincludedir ;;
378 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
379 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
380 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
381 oldincludedir="$ac_optarg" ;;
383 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
385 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
386 prefix="$ac_optarg" ;;
388 -program-prefix | --program-prefix | --program-prefi | --program-pref \
389 | --program-pre | --program-pr | --program-p)
390 ac_prev=program_prefix ;;
391 -program-prefix=* | --program-prefix=* | --program-prefi=* \
392 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
393 program_prefix="$ac_optarg" ;;
395 -program-suffix | --program-suffix | --program-suffi | --program-suff \
396 | --program-suf | --program-su | --program-s)
397 ac_prev=program_suffix ;;
398 -program-suffix=* | --program-suffix=* | --program-suffi=* \
399 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
400 program_suffix="$ac_optarg" ;;
402 -program-transform-name | --program-transform-name \
403 | --program-transform-nam | --program-transform-na \
404 | --program-transform-n | --program-transform- \
405 | --program-transform | --program-transfor \
406 | --program-transfo | --program-transf \
407 | --program-trans | --program-tran \
408 | --progr-tra | --program-tr | --program-t)
409 ac_prev=program_transform_name ;;
410 -program-transform-name=* | --program-transform-name=* \
411 | --program-transform-nam=* | --program-transform-na=* \
412 | --program-transform-n=* | --program-transform-=* \
413 | --program-transform=* | --program-transfor=* \
414 | --program-transfo=* | --program-transf=* \
415 | --program-trans=* | --program-tran=* \
416 | --progr-tra=* | --program-tr=* | --program-t=*)
417 program_transform_name="$ac_optarg" ;;
419 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
420 | -silent | --silent | --silen | --sile | --sil)
423 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
425 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
427 sbindir="$ac_optarg" ;;
429 -sharedstatedir | --sharedstatedir | --sharedstatedi \
430 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
431 | --sharedst | --shareds | --shared | --share | --shar \
433 ac_prev=sharedstatedir ;;
434 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
435 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
436 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
438 sharedstatedir="$ac_optarg" ;;
440 -site | --site | --sit)
442 -site=* | --site=* | --sit=*)
445 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
447 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
448 srcdir="$ac_optarg" ;;
450 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
451 | --syscon | --sysco | --sysc | --sys | --sy)
452 ac_prev=sysconfdir ;;
453 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
454 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
455 sysconfdir="$ac_optarg" ;;
457 -target | --target | --targe | --targ | --tar | --ta | --t)
459 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
460 target="$ac_optarg" ;;
462 -v | -verbose | --verbose | --verbos | --verbo | --verb)
465 -version | --version | --versio | --versi | --vers)
466 echo "configure generated by autoconf version 2.13.1"
470 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
471 # Reject names that are not valid shell variable names.
472 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
473 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
475 ac_package=`echo $ac_package| sed 's/-/_/g'`
480 eval "with_${ac_package}='$ac_optarg'" ;;
482 -without-* | --without-*)
483 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
484 # Reject names that are not valid shell variable names.
485 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
486 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
488 ac_package=`echo $ac_package| sed 's/-/_/g'`
489 eval "with_${ac_package}=no" ;;
492 # Obsolete; use --with-x.
495 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
496 | --x-incl | --x-inc | --x-in | --x-i)
497 ac_prev=x_includes ;;
498 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
499 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
500 x_includes="$ac_optarg" ;;
502 -x-libraries | --x-libraries | --x-librarie | --x-librari \
503 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
504 ac_prev=x_libraries ;;
505 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
506 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
507 x_libraries="$ac_optarg" ;;
509 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
513 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
514 echo "configure: warning: $ac_option: invalid host type" 1>&2
516 if test "x$nonopt" != xNONE; then
517 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
525 if test -n "$ac_prev"; then
526 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
529 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
531 # File descriptor usage:
534 # 2 errors and warnings
535 # 3 some systems may open it to /dev/tty
536 # 4 used on the Kubota Titan
537 # 6 checking for... messages and results
538 # 5 compiler messages saved in config.log
539 if test "$silent" = yes; then
547 This file contains any messages produced by compilers while
548 running configure, to aid debugging if configure makes a mistake.
551 # Strip out --no-create and --no-recursion so they do not pile up.
552 # Also quote any args containing shell metacharacters.
557 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
558 | --no-cr | --no-c) ;;
559 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
560 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
561 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
562 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
563 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
568 # Only set these to C if already set. These must not be set unconditionally
569 # because not all systems understand e.g. LANG=C (notably SCO).
570 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
571 # Non-C LC_CTYPE values break the ctype check.
572 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
573 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
574 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
575 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
577 # confdefs.h avoids OS command line length limits that DEFS can exceed.
578 rm -rf conftest* confdefs.h
579 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
582 # A filename unique to this package, relative to the directory that
583 # configure is in, which we can look for to find out if srcdir is correct.
584 ac_unique_file=build/version
586 # Find the source files, if location was not specified.
587 if test -z "$srcdir"; then
588 ac_srcdir_defaulted=yes
589 # Try the directory containing this script, then its parent.
591 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
592 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
594 if test ! -r $srcdir/$ac_unique_file; then
598 ac_srcdir_defaulted=no
600 if test ! -r $srcdir/$ac_unique_file; then
601 if test "$ac_srcdir_defaulted" = yes; then
602 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
604 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
607 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
609 # Prefer explicitly selected file to automatically selected ones.
610 if test -z "$CONFIG_SITE"; then
611 if test "x$prefix" != xNONE; then
612 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
614 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
617 for ac_site_file in $CONFIG_SITE; do
618 if test -r "$ac_site_file"; then
619 echo "loading site script $ac_site_file"
626 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
627 ac_cpp='$CPP $CPPFLAGS'
628 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
629 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
630 cross_compiling=$ac_cv_prog_cc_cross
634 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
635 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
636 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
643 ac_n= ac_c='\c' ac_t=
647 for ac_dir in build $srcdir/build; do
648 if test -f $ac_dir/install-sh; then
650 ac_install_sh="$ac_aux_dir/install-sh -c"
652 elif test -f $ac_dir/install.sh; then
654 ac_install_sh="$ac_aux_dir/install.sh -c"
656 elif test -f $ac_dir/shtool; then
658 ac_install_sh="$ac_aux_dir/shtool install -c"
662 if test -z "$ac_aux_dir"; then
663 { echo "configure: error: can not find install-sh or install.sh in build $srcdir/build" 1>&2; exit 1; }
665 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
666 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
667 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
669 OL_VERSION=`cat $ac_aux_dir/version`
670 if test -z "$OL_VERSION"; then
671 { echo "configure: error: could not determine version" 1>&2; exit 1; }
674 echo "Configuring OpenLDAP $OL_VERSION ..."
677 echo $ac_n "checking host system type""... $ac_c" 1>&6
678 echo "configure:679: checking host system type" >&5
679 if test "x$ac_cv_host" = "x" || (test "x$host" != "xNONE" && test "x$host" != "x$ac_cv_host_alias"); then
681 # Make sure we can run config.sub.
682 if $ac_config_sub sun4 >/dev/null 2>&1; then :
683 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
686 ac_cv_host_alias=$host
687 case "$ac_cv_host_alias" in
691 if ac_cv_host_alias=`$ac_config_guess`; then :
692 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
694 *) ac_cv_host_alias=$nonopt ;;
698 ac_cv_host=`$ac_config_sub $ac_cv_host_alias`
699 ac_cv_host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
700 ac_cv_host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
701 ac_cv_host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
703 echo $ac_n "(cached) $ac_c" 1>&6
706 echo "$ac_t""$ac_cv_host" 1>&6
709 host_alias=$ac_cv_host_alias
710 host_cpu=$ac_cv_host_cpu
711 host_vendor=$ac_cv_host_vendor
712 host_os=$ac_cv_host_os
718 echo $ac_n "checking target system type""... $ac_c" 1>&6
719 echo "configure:720: checking target system type" >&5
720 if test "x$ac_cv_target" = "x" || (test "x$target" != "xNONE" && test "x$target" != "x$ac_cv_target_alias"); then
722 # Make sure we can run config.sub.
723 if $ac_config_sub sun4 >/dev/null 2>&1; then :
724 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
727 ac_cv_target_alias=$target
728 case "$ac_cv_target_alias" in
732 ac_cv_target_alias=$host_alias ;;
734 *) ac_cv_target_alias=$nonopt ;;
738 ac_cv_target=`$ac_config_sub $ac_cv_target_alias`
739 ac_cv_target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
740 ac_cv_target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
741 ac_cv_target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
743 echo $ac_n "(cached) $ac_c" 1>&6
746 echo "$ac_t""$ac_cv_target" 1>&6
749 target_alias=$ac_cv_target_alias
750 target_cpu=$ac_cv_target_cpu
751 target_vendor=$ac_cv_target_vendor
752 target_os=$ac_cv_target_os
758 echo $ac_n "checking build system type""... $ac_c" 1>&6
759 echo "configure:760: checking build system type" >&5
760 if test "x$ac_cv_build" = "x" || (test "x$build" != "xNONE" && test "x$build" != "x$ac_cv_build_alias"); then
762 # Make sure we can run config.sub.
763 if $ac_config_sub sun4 >/dev/null 2>&1; then :
764 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
767 ac_cv_build_alias=$build
768 case "$ac_cv_build_alias" in
772 ac_cv_build_alias=$host_alias ;;
774 *) ac_cv_build_alias=$nonopt ;;
778 ac_cv_build=`$ac_config_sub $ac_cv_build_alias`
779 ac_cv_build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
780 ac_cv_build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
781 ac_cv_build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
783 echo $ac_n "(cached) $ac_c" 1>&6
786 echo "$ac_t""$ac_cv_build" 1>&6
789 build_alias=$ac_cv_build_alias
790 build_cpu=$ac_cv_build_cpu
791 build_vendor=$ac_cv_build_vendor
792 build_os=$ac_cv_build_os
798 # Do some error checking and defaulting for the host and target type.
800 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
803 # 1. You are not allowed to specify --host, --target, and nonopt at the
805 # 2. Host defaults to nonopt.
806 # 3. If nonopt is not specified, then host defaults to the current host,
807 # as determined by config.guess.
808 # 4. Target and build default to nonopt.
809 # 5. If nonopt is not specified, then target and build default to host.
811 # The aliases save the names the user supplied, while $host etc.
812 # will get canonicalized.
813 case $host---$target---$nonopt in
814 NONE---*---* | *---NONE---* | *---*---NONE) ;;
815 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
818 test "$host_alias" != "$target_alias" &&
819 test "$program_prefix$program_suffix$program_transform_name" = \
821 program_prefix=${target_alias}-
824 # Find a good install program. We prefer a C program (faster),
825 # so one script is as good as another. But avoid the broken or
826 # incompatible versions:
827 # SysV /etc/install, /usr/sbin/install
828 # SunOS /usr/etc/install
831 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
832 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
833 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
834 # ./install, which can be erroneously created by make from ./install.sh.
835 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
836 echo "configure:837: checking for a BSD compatible install" >&5
837 if test -z "$INSTALL"; then
838 if eval "test \"\${ac_cv_path_install+set}\" = set"; then
839 echo $ac_n "(cached) $ac_c" 1>&6
841 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
842 for ac_dir in $PATH; do
843 # Account for people who put trailing slashes in PATH elements.
845 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
847 # OSF1 and SCO ODT 3.0 have their own names for install.
848 # Don't use installbsd from OSF since it installs stuff as root
850 for ac_prog in ginstall scoinst install; do
851 if test -f $ac_dir/$ac_prog; then
852 if test $ac_prog = install &&
853 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
854 # AIX install. It has an incompatible calling convention.
856 elif test $ac_prog = install &&
857 grep pwplus $ac_dir/$ac_prog >/dev/null 2>&1; then
858 # program-specific install script used by HP pwplus--don't use.
861 ac_cv_path_install="$ac_dir/$ac_prog -c"
872 if test "${ac_cv_path_install+set}" = set; then
873 INSTALL="$ac_cv_path_install"
875 # As a last resort, use the slow shell script. We don't cache a
876 # path for INSTALL within a source directory, because that will
877 # break other packages using the cache if that directory is
878 # removed, or if the path is relative.
879 INSTALL="$ac_install_sh"
882 echo "$ac_t""$INSTALL" 1>&6
884 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
885 # It thinks the first close brace ends the variable substitution.
886 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
888 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
890 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
892 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
893 echo "configure:894: checking whether build environment is sane" >&5
896 echo timestamp > conftestfile
897 # Do `set' in a subshell so we don't clobber the current shell's
898 # arguments. Must try -L first in case configure is actually a
899 # symlink; some systems play weird games with the mod time of symlinks
900 # (eg FreeBSD returns the mod time of the symlink's containing
903 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
904 if test "$*" = "X"; then
906 set X `ls -t $srcdir/configure conftestfile`
908 if test "$*" != "X $srcdir/configure conftestfile" \
909 && test "$*" != "X conftestfile $srcdir/configure"; then
911 # If neither matched, then we have a broken ls. This can happen
912 # if, for instance, CONFIG_SHELL is bash and it inherits a
913 # broken ls alias from the environment. This has actually
914 # happened. Such a system could not be considered "sane".
915 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
916 alias in your environment" 1>&2; exit 1; }
919 test "$2" = conftestfile
925 { echo "configure: error: newly created file is older than distributed files!
926 Check your system clock" 1>&2; exit 1; }
929 echo "$ac_t""yes" 1>&6
930 if test "$program_transform_name" = s,x,x,; then
931 program_transform_name=
933 # Double any \ or $. echo might interpret backslashes.
934 cat <<\EOF_SED > conftestsed
935 s,\\,\\\\,g; s,\$,$$,g
937 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
940 test "$program_prefix" != NONE &&
941 program_transform_name="s,^,${program_prefix},;$program_transform_name"
942 # Use a double $ so make ignores it.
943 test "$program_suffix" != NONE &&
944 program_transform_name="s,\$\$,${program_suffix},;$program_transform_name"
946 # sed with no file args requires a program.
947 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
949 for ac_prog in mawk gawk nawk awk
951 # Extract the first word of "$ac_prog", so it can be a program name with args.
952 set dummy $ac_prog; ac_word=$2
953 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
954 echo "configure:955: checking for $ac_word" >&5
955 if eval "test \"\${ac_cv_prog_AWK+set}\" = set"; then
956 echo $ac_n "(cached) $ac_c" 1>&6
958 if test -n "$AWK"; then
959 ac_cv_prog_AWK="$AWK" # Let the user override the test.
961 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
963 for ac_dir in $ac_dummy; do
964 test -z "$ac_dir" && ac_dir=.
965 if test -f $ac_dir/$ac_word; then
966 ac_cv_prog_AWK="$ac_prog"
973 AWK="$ac_cv_prog_AWK"
974 if test -n "$AWK"; then
975 echo "$ac_t""$AWK" 1>&6
977 echo "$ac_t""no" 1>&6
980 test -n "$AWK" && break
983 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
984 echo "configure:985: checking whether ${MAKE-make} sets \${MAKE}" >&5
985 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
986 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
987 echo $ac_n "(cached) $ac_c" 1>&6
989 cat > conftestmake <<\EOF
991 @echo 'ac_maketemp="${MAKE}"'
993 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
994 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
995 if test -n "$ac_maketemp"; then
996 eval ac_cv_prog_make_${ac_make}_set=yes
998 eval ac_cv_prog_make_${ac_make}_set=no
1002 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1003 echo "$ac_t""yes" 1>&6
1006 echo "$ac_t""no" 1>&6
1007 SET_MAKE="MAKE=${MAKE-make}"
1016 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1017 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1022 missing_dir=`cd $ac_aux_dir && pwd`
1023 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
1024 echo "configure:1025: checking for working aclocal" >&5
1025 # Run test in a subshell; some versions of sh will print an error if
1026 # an executable is not found, even if stderr is redirected.
1027 # Redirect stdin to placate older versions of autoconf. Sigh.
1028 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1030 echo "$ac_t""found" 1>&6
1032 ACLOCAL="$missing_dir/missing aclocal"
1033 echo "$ac_t""missing" 1>&6
1036 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
1037 echo "configure:1038: checking for working autoconf" >&5
1038 # Run test in a subshell; some versions of sh will print an error if
1039 # an executable is not found, even if stderr is redirected.
1040 # Redirect stdin to placate older versions of autoconf. Sigh.
1041 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1043 echo "$ac_t""found" 1>&6
1045 AUTOCONF="$missing_dir/missing autoconf"
1046 echo "$ac_t""missing" 1>&6
1049 echo $ac_n "checking for working automake""... $ac_c" 1>&6
1050 echo "configure:1051: checking for working automake" >&5
1051 # Run test in a subshell; some versions of sh will print an error if
1052 # an executable is not found, even if stderr is redirected.
1053 # Redirect stdin to placate older versions of autoconf. Sigh.
1054 if (automake --version) < /dev/null > /dev/null 2>&1; then
1056 echo "$ac_t""found" 1>&6
1058 AUTOMAKE="$missing_dir/missing automake"
1059 echo "$ac_t""missing" 1>&6
1062 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
1063 echo "configure:1064: checking for working autoheader" >&5
1064 # Run test in a subshell; some versions of sh will print an error if
1065 # an executable is not found, even if stderr is redirected.
1066 # Redirect stdin to placate older versions of autoconf. Sigh.
1067 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1068 AUTOHEADER=autoheader
1069 echo "$ac_t""found" 1>&6
1071 AUTOHEADER="$missing_dir/missing autoheader"
1072 echo "$ac_t""missing" 1>&6
1075 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
1076 echo "configure:1077: checking for working makeinfo" >&5
1077 # Run test in a subshell; some versions of sh will print an error if
1078 # an executable is not found, even if stderr is redirected.
1079 # Redirect stdin to placate older versions of autoconf. Sigh.
1080 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1082 echo "$ac_t""found" 1>&6
1084 MAKEINFO="$missing_dir/missing makeinfo"
1085 echo "$ac_t""missing" 1>&6
1088 install_sh="$missing_dir/install-sh"
1089 test -f "$install_sh" || install_sh="$missing_dir/install.sh"
1091 for ac_prog in gnutar gtar tar
1093 # Extract the first word of "$ac_prog", so it can be a program name with args.
1094 set dummy $ac_prog; ac_word=$2
1095 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1096 echo "configure:1097: checking for $ac_word" >&5
1097 if eval "test \"\${ac_cv_prog_AMTAR+set}\" = set"; then
1098 echo $ac_n "(cached) $ac_c" 1>&6
1100 if test -n "$AMTAR"; then
1101 ac_cv_prog_AMTAR="$AMTAR" # Let the user override the test.
1103 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1105 for ac_dir in $ac_dummy; do
1106 test -z "$ac_dir" && ac_dir=.
1107 if test -f $ac_dir/$ac_word; then
1108 ac_cv_prog_AMTAR="$ac_prog"
1115 AMTAR="$ac_cv_prog_AMTAR"
1116 if test -n "$AMTAR"; then
1117 echo "$ac_t""$AMTAR" 1>&6
1119 echo "$ac_t""no" 1>&6
1122 test -n "$AMTAR" && break
1127 if test -n "$AMTAR"; then
1128 if $SHELL -c "$AMTAR --version" > /dev/null 2>&1; then
1135 cat >> confdefs.h <<EOF
1136 #define OPENLDAP_PACKAGE "$PACKAGE"
1139 cat >> confdefs.h <<EOF
1140 #define OPENLDAP_VERSION "$VERSION"
1146 echo $ac_n "checking configure arguments""... $ac_c" 1>&6
1147 echo "configure:1148: checking configure arguments" >&5
1152 ldap_subdir="/openldap"
1154 # Check whether --with-subdir or --without-subdir was given.
1155 if test "${with_subdir+set}" = set; then
1156 withval="$with_subdir"
1163 ldap_subdir="$withval"
1166 ldap_subdir="/$withval"
1173 # OpenLDAP --enable-debug
1174 # Check whether --enable-debug or --disable-debug was given.
1175 if test "${enable_debug+set}" = set; then
1176 enableval="$enable_debug"
1179 for ol_val in auto yes no ; do
1180 if test "$enableval" = "$ol_val" ; then
1184 if test "$ol_arg" = "invalid" ; then
1185 { echo "configure: error: bad value $enableval for --enable-debug" 1>&2; exit 1; }
1187 ol_enable_debug="$ol_arg"
1190 ol_enable_debug="yes"
1192 # end --enable-debug
1193 # OpenLDAP --enable-syslog
1194 # Check whether --enable-syslog or --disable-syslog was given.
1195 if test "${enable_syslog+set}" = set; then
1196 enableval="$enable_syslog"
1199 for ol_val in auto yes no ; do
1200 if test "$enableval" = "$ol_val" ; then
1204 if test "$ol_arg" = "invalid" ; then
1205 { echo "configure: error: bad value $enableval for --enable-syslog" 1>&2; exit 1; }
1207 ol_enable_syslog="$ol_arg"
1210 ol_enable_syslog="auto"
1212 # end --enable-syslog
1213 # OpenLDAP --enable-proctitle
1214 # Check whether --enable-proctitle or --disable-proctitle was given.
1215 if test "${enable_proctitle+set}" = set; then
1216 enableval="$enable_proctitle"
1219 for ol_val in auto yes no ; do
1220 if test "$enableval" = "$ol_val" ; then
1224 if test "$ol_arg" = "invalid" ; then
1225 { echo "configure: error: bad value $enableval for --enable-proctitle" 1>&2; exit 1; }
1227 ol_enable_proctitle="$ol_arg"
1230 ol_enable_proctitle="yes"
1232 # end --enable-proctitle
1233 # OpenLDAP --enable-cache
1234 # Check whether --enable-cache or --disable-cache was given.
1235 if test "${enable_cache+set}" = set; then
1236 enableval="$enable_cache"
1239 for ol_val in auto yes no ; do
1240 if test "$enableval" = "$ol_val" ; then
1244 if test "$ol_arg" = "invalid" ; then
1245 { echo "configure: error: bad value $enableval for --enable-cache" 1>&2; exit 1; }
1247 ol_enable_cache="$ol_arg"
1250 ol_enable_cache="yes"
1252 # end --enable-cache
1253 # OpenLDAP --enable-referrals
1254 # Check whether --enable-referrals or --disable-referrals was given.
1255 if test "${enable_referrals+set}" = set; then
1256 enableval="$enable_referrals"
1259 for ol_val in auto yes no ; do
1260 if test "$enableval" = "$ol_val" ; then
1264 if test "$ol_arg" = "invalid" ; then
1265 { echo "configure: error: bad value $enableval for --enable-referrals" 1>&2; exit 1; }
1267 ol_enable_referrals="$ol_arg"
1270 ol_enable_referrals="yes"
1272 # end --enable-referrals
1273 # OpenLDAP --enable-kbind
1274 # Check whether --enable-kbind or --disable-kbind was given.
1275 if test "${enable_kbind+set}" = set; then
1276 enableval="$enable_kbind"
1279 for ol_val in auto yes no ; do
1280 if test "$enableval" = "$ol_val" ; then
1284 if test "$ol_arg" = "invalid" ; then
1285 { echo "configure: error: bad value $enableval for --enable-kbind" 1>&2; exit 1; }
1287 ol_enable_kbind="$ol_arg"
1290 ol_enable_kbind="auto"
1292 # end --enable-kbind
1293 # OpenLDAP --enable-cldap
1294 # Check whether --enable-cldap or --disable-cldap was given.
1295 if test "${enable_cldap+set}" = set; then
1296 enableval="$enable_cldap"
1299 for ol_val in auto yes no ; do
1300 if test "$enableval" = "$ol_val" ; then
1304 if test "$ol_arg" = "invalid" ; then
1305 { echo "configure: error: bad value $enableval for --enable-cldap" 1>&2; exit 1; }
1307 ol_enable_cldap="$ol_arg"
1310 ol_enable_cldap="no"
1312 # end --enable-cldap
1313 # OpenLDAP --enable-ldapi
1314 # Check whether --enable-ldapi or --disable-ldapi was given.
1315 if test "${enable_ldapi+set}" = set; then
1316 enableval="$enable_ldapi"
1319 for ol_val in auto yes no ; do
1320 if test "$enableval" = "$ol_val" ; then
1324 if test "$ol_arg" = "invalid" ; then
1325 { echo "configure: error: bad value $enableval for --enable-ldapi" 1>&2; exit 1; }
1327 ol_enable_ldapi="$ol_arg"
1330 ol_enable_ldapi="no"
1332 # end --enable-ldapi
1333 # OpenLDAP --enable-x_compile
1334 # Check whether --enable-x_compile or --disable-x_compile was given.
1335 if test "${enable_x_compile+set}" = set; then
1336 enableval="$enable_x_compile"
1339 for ol_val in yes no ; do
1340 if test "$enableval" = "$ol_val" ; then
1344 if test "$ol_arg" = "invalid" ; then
1345 { echo "configure: error: bad value $enableval for --enable-x_compile" 1>&2; exit 1; }
1347 ol_enable_x_compile="$ol_arg"
1350 ol_enable_x_compile="no"
1352 # end --enable-x_compile
1355 # OpenLDAP --with-cyrus_sasl
1356 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
1357 if test "${with_cyrus_sasl+set}" = set; then
1358 withval="$with_cyrus_sasl"
1361 for ol_val in auto yes no ; do
1362 if test "$withval" = "$ol_val" ; then
1366 if test "$ol_arg" = "invalid" ; then
1367 { echo "configure: error: bad value $withval for --with-cyrus_sasl" 1>&2; exit 1; }
1369 ol_with_cyrus_sasl="$ol_arg"
1372 ol_with_cyrus_sasl="auto"
1374 # end --with-cyrus_sasl
1376 # OpenLDAP --with-fetch
1377 # Check whether --with-fetch or --without-fetch was given.
1378 if test "${with_fetch+set}" = set; then
1379 withval="$with_fetch"
1382 for ol_val in auto yes no ; do
1383 if test "$withval" = "$ol_val" ; then
1387 if test "$ol_arg" = "invalid" ; then
1388 { echo "configure: error: bad value $withval for --with-fetch" 1>&2; exit 1; }
1390 ol_with_fetch="$ol_arg"
1393 ol_with_fetch="auto"
1397 # OpenLDAP --with-kerberos
1398 # Check whether --with-kerberos or --without-kerberos was given.
1399 if test "${with_kerberos+set}" = set; then
1400 withval="$with_kerberos"
1403 for ol_val in auto k5 k5only k425 kth k4 afs yes no ; do
1404 if test "$withval" = "$ol_val" ; then
1408 if test "$ol_arg" = "invalid" ; then
1409 { echo "configure: error: bad value $withval for --with-kerberos" 1>&2; exit 1; }
1411 ol_with_kerberos="$ol_arg"
1414 ol_with_kerberos="auto"
1416 # end --with-kerberos
1418 # OpenLDAP --with-readline
1419 # Check whether --with-readline or --without-readline was given.
1420 if test "${with_readline+set}" = set; then
1421 withval="$with_readline"
1424 for ol_val in auto yes no ; do
1425 if test "$withval" = "$ol_val" ; then
1429 if test "$ol_arg" = "invalid" ; then
1430 { echo "configure: error: bad value $withval for --with-readline" 1>&2; exit 1; }
1432 ol_with_readline="$ol_arg"
1435 ol_with_readline="auto"
1437 # end --with-readline
1439 # OpenLDAP --with-threads
1440 # Check whether --with-threads or --without-threads was given.
1441 if test "${with_threads+set}" = set; then
1442 withval="$with_threads"
1445 for ol_val in auto nt posix mach pth lwp yes no manual ; do
1446 if test "$withval" = "$ol_val" ; then
1450 if test "$ol_arg" = "invalid" ; then
1451 { echo "configure: error: bad value $withval for --with-threads" 1>&2; exit 1; }
1453 ol_with_threads="$ol_arg"
1456 ol_with_threads="auto"
1458 # end --with-threads
1460 # OpenLDAP --with-tls
1461 # Check whether --with-tls or --without-tls was given.
1462 if test "${with_tls+set}" = set; then
1466 for ol_val in auto ssleay openssl yes no ; do
1467 if test "$withval" = "$ol_val" ; then
1471 if test "$ol_arg" = "invalid" ; then
1472 { echo "configure: error: bad value $withval for --with-tls" 1>&2; exit 1; }
1474 ol_with_tls="$ol_arg"
1481 # OpenLDAP --with-yielding_select
1482 # Check whether --with-yielding_select or --without-yielding_select was given.
1483 if test "${with_yielding_select+set}" = set; then
1484 withval="$with_yielding_select"
1487 for ol_val in auto yes no manual ; do
1488 if test "$withval" = "$ol_val" ; then
1492 if test "$ol_arg" = "invalid" ; then
1493 { echo "configure: error: bad value $withval for --with-yielding_select" 1>&2; exit 1; }
1495 ol_with_yielding_select="$ol_arg"
1498 ol_with_yielding_select="auto"
1500 # end --with-yielding_select
1504 # Check whether --with-xxslapdoptions or --without-xxslapdoptions was given.
1505 if test "${with_xxslapdoptions+set}" = set; then
1506 withval="$with_xxslapdoptions"
1510 # OpenLDAP --enable-slapd
1511 # Check whether --enable-slapd or --disable-slapd was given.
1512 if test "${enable_slapd+set}" = set; then
1513 enableval="$enable_slapd"
1516 for ol_val in auto yes no ; do
1517 if test "$enableval" = "$ol_val" ; then
1521 if test "$ol_arg" = "invalid" ; then
1522 { echo "configure: error: bad value $enableval for --enable-slapd" 1>&2; exit 1; }
1524 ol_enable_slapd="$ol_arg"
1527 ol_enable_slapd="yes"
1529 # end --enable-slapd
1530 # OpenLDAP --enable-cleartext
1531 # Check whether --enable-cleartext or --disable-cleartext was given.
1532 if test "${enable_cleartext+set}" = set; then
1533 enableval="$enable_cleartext"
1536 for ol_val in auto yes no ; do
1537 if test "$enableval" = "$ol_val" ; then
1541 if test "$ol_arg" = "invalid" ; then
1542 { echo "configure: error: bad value $enableval for --enable-cleartext" 1>&2; exit 1; }
1544 ol_enable_cleartext="$ol_arg"
1547 ol_enable_cleartext="yes"
1549 # end --enable-cleartext
1550 # OpenLDAP --enable-crypt
1551 # Check whether --enable-crypt or --disable-crypt was given.
1552 if test "${enable_crypt+set}" = set; then
1553 enableval="$enable_crypt"
1556 for ol_val in auto yes no ; do
1557 if test "$enableval" = "$ol_val" ; then
1561 if test "$ol_arg" = "invalid" ; then
1562 { echo "configure: error: bad value $enableval for --enable-crypt" 1>&2; exit 1; }
1564 ol_enable_crypt="$ol_arg"
1567 ol_enable_crypt="auto"
1569 # end --enable-crypt
1570 # OpenLDAP --enable-kpasswd
1571 # Check whether --enable-kpasswd or --disable-kpasswd was given.
1572 if test "${enable_kpasswd+set}" = set; then
1573 enableval="$enable_kpasswd"
1576 for ol_val in auto yes no ; do
1577 if test "$enableval" = "$ol_val" ; then
1581 if test "$ol_arg" = "invalid" ; then
1582 { echo "configure: error: bad value $enableval for --enable-kpasswd" 1>&2; exit 1; }
1584 ol_enable_kpasswd="$ol_arg"
1587 ol_enable_kpasswd="no"
1589 # end --enable-kpasswd
1590 # OpenLDAP --enable-spasswd
1591 # Check whether --enable-spasswd or --disable-spasswd was given.
1592 if test "${enable_spasswd+set}" = set; then
1593 enableval="$enable_spasswd"
1596 for ol_val in auto yes no ; do
1597 if test "$enableval" = "$ol_val" ; then
1601 if test "$ol_arg" = "invalid" ; then
1602 { echo "configure: error: bad value $enableval for --enable-spasswd" 1>&2; exit 1; }
1604 ol_enable_spasswd="$ol_arg"
1607 ol_enable_spasswd="no"
1609 # end --enable-spasswd
1610 # OpenLDAP --enable-modules
1611 # Check whether --enable-modules or --disable-modules was given.
1612 if test "${enable_modules+set}" = set; then
1613 enableval="$enable_modules"
1616 for ol_val in auto yes no ; do
1617 if test "$enableval" = "$ol_val" ; then
1621 if test "$ol_arg" = "invalid" ; then
1622 { echo "configure: error: bad value $enableval for --enable-modules" 1>&2; exit 1; }
1624 ol_enable_modules="$ol_arg"
1627 ol_enable_modules="no"
1629 # end --enable-modules
1630 # OpenLDAP --enable-multimaster
1631 # Check whether --enable-multimaster or --disable-multimaster was given.
1632 if test "${enable_multimaster+set}" = set; then
1633 enableval="$enable_multimaster"
1636 for ol_val in auto yes no ; do
1637 if test "$enableval" = "$ol_val" ; then
1641 if test "$ol_arg" = "invalid" ; then
1642 { echo "configure: error: bad value $enableval for --enable-multimaster" 1>&2; exit 1; }
1644 ol_enable_multimaster="$ol_arg"
1647 ol_enable_multimaster="no"
1649 # end --enable-multimaster
1650 # OpenLDAP --enable-phonetic
1651 # Check whether --enable-phonetic or --disable-phonetic was given.
1652 if test "${enable_phonetic+set}" = set; then
1653 enableval="$enable_phonetic"
1656 for ol_val in auto yes no ; do
1657 if test "$enableval" = "$ol_val" ; then
1661 if test "$ol_arg" = "invalid" ; then
1662 { echo "configure: error: bad value $enableval for --enable-phonetic" 1>&2; exit 1; }
1664 ol_enable_phonetic="$ol_arg"
1667 ol_enable_phonetic="no"
1669 # end --enable-phonetic
1670 # OpenLDAP --enable-quipu
1671 # Check whether --enable-quipu or --disable-quipu was given.
1672 if test "${enable_quipu+set}" = set; then
1673 enableval="$enable_quipu"
1676 for ol_val in auto yes no ; do
1677 if test "$enableval" = "$ol_val" ; then
1681 if test "$ol_arg" = "invalid" ; then
1682 { echo "configure: error: bad value $enableval for --enable-quipu" 1>&2; exit 1; }
1684 ol_enable_quipu="$ol_arg"
1687 ol_enable_quipu="no"
1689 # end --enable-quipu
1690 # OpenLDAP --enable-rlookups
1691 # Check whether --enable-rlookups or --disable-rlookups was given.
1692 if test "${enable_rlookups+set}" = set; then
1693 enableval="$enable_rlookups"
1696 for ol_val in auto yes no ; do
1697 if test "$enableval" = "$ol_val" ; then
1701 if test "$ol_arg" = "invalid" ; then
1702 { echo "configure: error: bad value $enableval for --enable-rlookups" 1>&2; exit 1; }
1704 ol_enable_rlookups="$ol_arg"
1707 ol_enable_rlookups="auto"
1709 # end --enable-rlookups
1710 # OpenLDAP --enable-aci
1711 # Check whether --enable-aci or --disable-aci was given.
1712 if test "${enable_aci+set}" = set; then
1713 enableval="$enable_aci"
1716 for ol_val in auto yes no ; do
1717 if test "$enableval" = "$ol_val" ; then
1721 if test "$ol_arg" = "invalid" ; then
1722 { echo "configure: error: bad value $enableval for --enable-aci" 1>&2; exit 1; }
1724 ol_enable_aci="$ol_arg"
1730 # OpenLDAP --enable-wrappers
1731 # Check whether --enable-wrappers or --disable-wrappers was given.
1732 if test "${enable_wrappers+set}" = set; then
1733 enableval="$enable_wrappers"
1736 for ol_val in auto yes no ; do
1737 if test "$enableval" = "$ol_val" ; then
1741 if test "$ol_arg" = "invalid" ; then
1742 { echo "configure: error: bad value $enableval for --enable-wrappers" 1>&2; exit 1; }
1744 ol_enable_wrappers="$ol_arg"
1747 ol_enable_wrappers="no"
1749 # end --enable-wrappers
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"
1756 for ol_val in auto yes no ; do
1757 if test "$enableval" = "$ol_val" ; then
1761 if test "$ol_arg" = "invalid" ; then
1762 { echo "configure: error: bad value $enableval for --enable-dynamic" 1>&2; exit 1; }
1764 ol_enable_dynamic="$ol_arg"
1767 ol_enable_dynamic="no"
1769 # end --enable-dynamic
1771 # OpenLDAP --enable-dnssrv
1772 # Check whether --enable-dnssrv or --disable-dnssrv was given.
1773 if test "${enable_dnssrv+set}" = set; then
1774 enableval="$enable_dnssrv"
1777 for ol_val in auto yes no ; do
1778 if test "$enableval" = "$ol_val" ; then
1782 if test "$ol_arg" = "invalid" ; then
1783 { echo "configure: error: bad value $enableval for --enable-dnssrv" 1>&2; exit 1; }
1785 ol_enable_dnssrv="$ol_arg"
1788 ol_enable_dnssrv="no"
1790 # end --enable-dnssrv
1791 # OpenLDAP --with-dnssrv_module
1792 # Check whether --with-dnssrv_module or --without-dnssrv_module was given.
1793 if test "${with_dnssrv_module+set}" = set; then
1794 withval="$with_dnssrv_module"
1797 for ol_val in static dynamic ; do
1798 if test "$withval" = "$ol_val" ; then
1802 if test "$ol_arg" = "invalid" ; then
1803 { echo "configure: error: bad value $withval for --with-dnssrv_module" 1>&2; exit 1; }
1805 ol_with_dnssrv_module="$ol_arg"
1808 ol_with_dnssrv_module="static"
1810 # end --with-dnssrv_module
1812 # OpenLDAP --enable-ldap
1813 # Check whether --enable-ldap or --disable-ldap was given.
1814 if test "${enable_ldap+set}" = set; then
1815 enableval="$enable_ldap"
1818 for ol_val in auto yes no ; do
1819 if test "$enableval" = "$ol_val" ; then
1823 if test "$ol_arg" = "invalid" ; then
1824 { echo "configure: error: bad value $enableval for --enable-ldap" 1>&2; exit 1; }
1826 ol_enable_ldap="$ol_arg"
1832 # OpenLDAP --with-ldap_module
1833 # Check whether --with-ldap_module or --without-ldap_module was given.
1834 if test "${with_ldap_module+set}" = set; then
1835 withval="$with_ldap_module"
1838 for ol_val in static dynamic ; do
1839 if test "$withval" = "$ol_val" ; then
1843 if test "$ol_arg" = "invalid" ; then
1844 { echo "configure: error: bad value $withval for --with-ldap_module" 1>&2; exit 1; }
1846 ol_with_ldap_module="$ol_arg"
1849 ol_with_ldap_module="static"
1851 # end --with-ldap_module
1853 # OpenLDAP --enable-ldbm
1854 # Check whether --enable-ldbm or --disable-ldbm was given.
1855 if test "${enable_ldbm+set}" = set; then
1856 enableval="$enable_ldbm"
1859 for ol_val in auto yes no ; do
1860 if test "$enableval" = "$ol_val" ; then
1864 if test "$ol_arg" = "invalid" ; then
1865 { echo "configure: error: bad value $enableval for --enable-ldbm" 1>&2; exit 1; }
1867 ol_enable_ldbm="$ol_arg"
1870 ol_enable_ldbm="yes"
1873 # OpenLDAP --with-ldbm_api
1874 # Check whether --with-ldbm_api or --without-ldbm_api was given.
1875 if test "${with_ldbm_api+set}" = set; then
1876 withval="$with_ldbm_api"
1879 for ol_val in auto berkeley bcompat mdbm gdbm ; do
1880 if test "$withval" = "$ol_val" ; then
1884 if test "$ol_arg" = "invalid" ; then
1885 { echo "configure: error: bad value $withval for --with-ldbm_api" 1>&2; exit 1; }
1887 ol_with_ldbm_api="$ol_arg"
1890 ol_with_ldbm_api="auto"
1892 # end --with-ldbm_api
1894 # OpenLDAP --with-ldbm_module
1895 # Check whether --with-ldbm_module or --without-ldbm_module was given.
1896 if test "${with_ldbm_module+set}" = set; then
1897 withval="$with_ldbm_module"
1900 for ol_val in static dynamic ; do
1901 if test "$withval" = "$ol_val" ; then
1905 if test "$ol_arg" = "invalid" ; then
1906 { echo "configure: error: bad value $withval for --with-ldbm_module" 1>&2; exit 1; }
1908 ol_with_ldbm_module="$ol_arg"
1911 ol_with_ldbm_module="static"
1913 # end --with-ldbm_module
1915 # OpenLDAP --with-ldbm_type
1916 # Check whether --with-ldbm_type or --without-ldbm_type was given.
1917 if test "${with_ldbm_type+set}" = set; then
1918 withval="$with_ldbm_type"
1921 for ol_val in auto btree hash ; do
1922 if test "$withval" = "$ol_val" ; then
1926 if test "$ol_arg" = "invalid" ; then
1927 { echo "configure: error: bad value $withval for --with-ldbm_type" 1>&2; exit 1; }
1929 ol_with_ldbm_type="$ol_arg"
1932 ol_with_ldbm_type="auto"
1934 # end --with-ldbm_type
1936 # OpenLDAP --enable-passwd
1937 # Check whether --enable-passwd or --disable-passwd was given.
1938 if test "${enable_passwd+set}" = set; then
1939 enableval="$enable_passwd"
1942 for ol_val in auto yes no ; do
1943 if test "$enableval" = "$ol_val" ; then
1947 if test "$ol_arg" = "invalid" ; then
1948 { echo "configure: error: bad value $enableval for --enable-passwd" 1>&2; exit 1; }
1950 ol_enable_passwd="$ol_arg"
1953 ol_enable_passwd="no"
1955 # end --enable-passwd
1956 # OpenLDAP --with-passwd_module
1957 # Check whether --with-passwd_module or --without-passwd_module was given.
1958 if test "${with_passwd_module+set}" = set; then
1959 withval="$with_passwd_module"
1962 for ol_val in static dynamic ; do
1963 if test "$withval" = "$ol_val" ; then
1967 if test "$ol_arg" = "invalid" ; then
1968 { echo "configure: error: bad value $withval for --with-passwd_module" 1>&2; exit 1; }
1970 ol_with_passwd_module="$ol_arg"
1973 ol_with_passwd_module="static"
1975 # end --with-passwd_module
1977 # OpenLDAP --enable-perl
1978 # Check whether --enable-perl or --disable-perl was given.
1979 if test "${enable_perl+set}" = set; then
1980 enableval="$enable_perl"
1983 for ol_val in auto yes no ; do
1984 if test "$enableval" = "$ol_val" ; then
1988 if test "$ol_arg" = "invalid" ; then
1989 { echo "configure: error: bad value $enableval for --enable-perl" 1>&2; exit 1; }
1991 ol_enable_perl="$ol_arg"
1997 # OpenLDAP --with-perl_module
1998 # Check whether --with-perl_module or --without-perl_module was given.
1999 if test "${with_perl_module+set}" = set; then
2000 withval="$with_perl_module"
2003 for ol_val in static dynamic ; do
2004 if test "$withval" = "$ol_val" ; then
2008 if test "$ol_arg" = "invalid" ; then
2009 { echo "configure: error: bad value $withval for --with-perl_module" 1>&2; exit 1; }
2011 ol_with_perl_module="$ol_arg"
2014 ol_with_perl_module="static"
2016 # end --with-perl_module
2018 # OpenLDAP --enable-shell
2019 # Check whether --enable-shell or --disable-shell was given.
2020 if test "${enable_shell+set}" = set; then
2021 enableval="$enable_shell"
2024 for ol_val in auto yes no ; do
2025 if test "$enableval" = "$ol_val" ; then
2029 if test "$ol_arg" = "invalid" ; then
2030 { echo "configure: error: bad value $enableval for --enable-shell" 1>&2; exit 1; }
2032 ol_enable_shell="$ol_arg"
2035 ol_enable_shell="no"
2037 # end --enable-shell
2038 # OpenLDAP --with-shell_module
2039 # Check whether --with-shell_module or --without-shell_module was given.
2040 if test "${with_shell_module+set}" = set; then
2041 withval="$with_shell_module"
2044 for ol_val in static dynamic ; do
2045 if test "$withval" = "$ol_val" ; then
2049 if test "$ol_arg" = "invalid" ; then
2050 { echo "configure: error: bad value $withval for --with-shell_module" 1>&2; exit 1; }
2052 ol_with_shell_module="$ol_arg"
2055 ol_with_shell_module="static"
2057 # end --with-shell_module
2059 # OpenLDAP --enable-sql
2060 # Check whether --enable-sql or --disable-sql was given.
2061 if test "${enable_sql+set}" = set; then
2062 enableval="$enable_sql"
2065 for ol_val in auto yes no ; do
2066 if test "$enableval" = "$ol_val" ; then
2070 if test "$ol_arg" = "invalid" ; then
2071 { echo "configure: error: bad value $enableval for --enable-sql" 1>&2; exit 1; }
2073 ol_enable_sql="$ol_arg"
2079 # OpenLDAP --with-sql_module
2080 # Check whether --with-sql_module or --without-sql_module was given.
2081 if test "${with_sql_module+set}" = set; then
2082 withval="$with_sql_module"
2085 for ol_val in static dynamic ; do
2086 if test "$withval" = "$ol_val" ; then
2090 if test "$ol_arg" = "invalid" ; then
2091 { echo "configure: error: bad value $withval for --with-sql_module" 1>&2; exit 1; }
2093 ol_with_sql_module="$ol_arg"
2096 ol_with_sql_module="static"
2098 # end --with-sql_module
2100 # OpenLDAP --enable-tcl
2101 # Check whether --enable-tcl or --disable-tcl was given.
2102 if test "${enable_tcl+set}" = set; then
2103 enableval="$enable_tcl"
2106 for ol_val in auto yes no ; do
2107 if test "$enableval" = "$ol_val" ; then
2111 if test "$ol_arg" = "invalid" ; then
2112 { echo "configure: error: bad value $enableval for --enable-tcl" 1>&2; exit 1; }
2114 ol_enable_tcl="$ol_arg"
2120 # OpenLDAP --with-tcl_module
2121 # Check whether --with-tcl_module or --without-tcl_module was given.
2122 if test "${with_tcl_module+set}" = set; then
2123 withval="$with_tcl_module"
2126 for ol_val in static dynamic ; do
2127 if test "$withval" = "$ol_val" ; then
2131 if test "$ol_arg" = "invalid" ; then
2132 { echo "configure: error: bad value $withval for --with-tcl_module" 1>&2; exit 1; }
2134 ol_with_tcl_module="$ol_arg"
2137 ol_with_tcl_module="static"
2139 # end --with-tcl_module
2142 # Check whether --with-xxslurpdoptions or --without-xxslurpdoptions was given.
2143 if test "${with_xxslurpdoptions+set}" = set; then
2144 withval="$with_xxslurpdoptions"
2148 # OpenLDAP --enable-slurpd
2149 # Check whether --enable-slurpd or --disable-slurpd was given.
2150 if test "${enable_slurpd+set}" = set; then
2151 enableval="$enable_slurpd"
2154 for ol_val in auto yes no ; do
2155 if test "$enableval" = "$ol_val" ; then
2159 if test "$ol_arg" = "invalid" ; then
2160 { echo "configure: error: bad value $enableval for --enable-slurpd" 1>&2; exit 1; }
2162 ol_enable_slurpd="$ol_arg"
2165 ol_enable_slurpd="auto"
2167 # end --enable-slurpd
2169 # Check whether --with-xxliboptions or --without-xxliboptions was given.
2170 if test "${with_xxliboptions+set}" = set; then
2171 withval="$with_xxliboptions"
2175 # Check whether --enable-static or --disable-static was given.
2176 if test "${enable_static+set}" = set; then
2177 enableval="$enable_static"
2178 p=${PACKAGE-default}
2179 case "$enableval" in
2180 yes) enable_static=yes ;;
2181 no) enable_static=no ;;
2184 # Look at the argument we got. We use all the common list separators.
2185 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2186 for pkg in $enableval; do
2187 if test "X$pkg" = "X$p"; then
2198 # Check whether --enable-shared or --disable-shared was given.
2199 if test "${enable_shared+set}" = set; then
2200 enableval="$enable_shared"
2201 p=${PACKAGE-default}
2202 case "$enableval" in
2203 yes) enable_shared=yes ;;
2204 no) enable_shared=no ;;
2207 # Look at the argument we got. We use all the common list separators.
2208 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2209 for pkg in $enableval; do
2210 if test "X$pkg" = "X$p"; then
2224 if test $ol_enable_slapd = no ; then
2225 if test $ol_enable_dnssrv = yes ; then
2226 echo "configure: warning: slapd disabled, ignoring --enable-dnssrv argument" 1>&2
2228 if test $ol_enable_ldap = yes ; then
2229 echo "configure: warning: slapd disabled, ignoring --enable-ldap argument" 1>&2
2231 if test $ol_enable_ldbm = yes ; then
2232 echo "configure: warning: slapd disabled, ignoring --enable-ldbm argument" 1>&2
2234 if test $ol_enable_passwd = yes ; then
2235 echo "configure: warning: slapd disabled, ignoring --enable-passwd argument" 1>&2
2237 if test $ol_enable_perl = yes ; then
2238 echo "configure: warning: slapd disabled, ignoring --enable-perl argument" 1>&2
2240 if test $ol_enable_shell = yes ; then
2241 echo "configure: warning: slapd disabled, ignoring --enable-shell argument" 1>&2
2243 if test $ol_enable_tcl = yes ; then
2244 echo "configure: warning: slapd disabled, ignoring --enable-tcl argument" 1>&2
2246 if test $ol_enable_sql = yes ; then
2247 echo "configure: warning: slapd disabled, ignoring --enable-sql argument" 1>&2
2249 if test $ol_enable_modules = yes ; then
2250 echo "configure: warning: slapd disabled, ignoring --enable-modules argument" 1>&2
2252 if test $ol_enable_multimaster = yes ; then
2253 echo "configure: warning: slapd disabled, ignoring --enable-multimaster argument" 1>&2
2255 if test $ol_enable_wrappers = yes ; then
2256 echo "configure: warning: slapd disabled, ignoring --enable-wrappers argument" 1>&2
2258 if test $ol_enable_phonetic = yes ; then
2259 echo "configure: warning: slapd disabled, ignoring --enable-phonetic argument" 1>&2
2261 if test $ol_enable_quipu = yes ; then
2262 echo "configure: warning: slapd disabled, ignoring --enable-quipu argument" 1>&2
2264 if test $ol_enable_rlookups = yes ; then
2265 echo "configure: warning: slapd disabled, ignoring --enable-rlookups argument" 1>&2
2267 if test $ol_enable_aci = yes ; then
2268 echo "configure: warning: slapd disabled, ignoring --enable-aci argument" 1>&2
2270 if test $ol_with_ldbm_api != auto ; then
2271 echo "configure: warning: slapd disabled, ignoring --with-ldbm-api argument" 1>&2
2273 if test $ol_with_ldbm_type != auto ; then
2274 echo "configure: warning: slapd disabled, ignoring --with-ldbm-type argument" 1>&2
2276 if test $ol_with_dnssrv_module != static ; then
2277 echo "configure: warning: slapd disabled, ignoring --with-dnssrv-module argument" 1>&2
2279 if test $ol_with_ldap_module != static ; then
2280 echo "configure: warning: slapd disabled, ignoring --with-ldap-module argument" 1>&2
2282 if test $ol_with_ldbm_module != static ; then
2283 echo "configure: warning: slapd disabled, ignoring --with-ldbm-module argument" 1>&2
2285 if test $ol_with_passwd_module != static ; then
2286 echo "configure: warning: slapd disabled, ignoring --with-passwd-module argument" 1>&2
2288 if test $ol_with_perl_module != static ; then
2289 echo "configure: warning: slapd disabled, ignoring --with-perl-module argument" 1>&2
2291 if test $ol_with_shell_module != static ; then
2292 echo "configure: warning: slapd disabled, ignoring --with-shell-module argument" 1>&2
2294 if test $ol_with_tcl_module != static ; then
2295 echo "configure: warning: slapd disabled, ignoring --with-tcl-module argument" 1>&2
2297 if test $ol_with_sql_module != static ; then
2298 echo "configure: warning: slapd disabled, ignoring --with-sql-module argument" 1>&2
2300 if test $ol_enable_slurpd = yes ; then
2301 { echo "configure: error: slurpd requires slapd" 1>&2; exit 1; }
2304 # force settings to no
2314 ol_enable_modules=no
2315 ol_enable_multimaster=no
2316 ol_enable_phonetic=no
2318 ol_enable_rlookups=no
2320 ol_enable_wrappers=no
2321 ol_enable_dynamic=no
2324 ol_with_ldbm_type=no
2326 ol_with_dnssrv_module=static
2327 ol_with_ldap_module=static
2328 ol_with_ldbm_module=static
2329 ol_with_passwd_module=static
2330 ol_with_perl_module=static
2331 ol_with_shell_module=static
2332 ol_with_tcl_module=static
2333 ol_with_sql_module=static
2337 elif test $ol_enable_ldbm = no ; then
2339 if test $ol_with_ldbm_api != auto ; then
2340 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-api argument" 1>&2
2343 if test $ol_with_ldbm_type != auto ; then
2344 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-type argument" 1>&2
2347 if test $ol_with_ldbm_module != static ; then
2348 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-module argument" 1>&2
2351 if test $ol_enable_modules != yes -a \
2352 $ol_enable_dnssrv = no -a \
2353 $ol_enable_ldap = no -a \
2354 $ol_enable_passwd = no -a \
2355 $ol_enable_perl = no -a \
2356 $ol_enable_shell = no -a \
2357 $ol_enable_sql = no -a \
2358 $ol_enable_tcl = no ; then
2359 { echo "configure: error: slapd requires a backend" 1>&2; exit 1; }
2363 ol_with_ldbm_type=no
2364 ol_with_ldbm_module=static
2367 if test $ol_with_ldbm_api = gdbm -a \
2368 $ol_with_ldbm_type = btree ; then
2369 { echo "configure: error: GDBM only supports LDBM type hash" 1>&2; exit 1; }
2371 if test $ol_with_ldbm_api = mdbm -a \
2372 $ol_with_ldbm_type = btree ; then
2373 { echo "configure: error: MDBM only supports LDBM type hash" 1>&2; exit 1; }
2375 if test $ol_with_ldbm_api = ndbm -a \
2376 $ol_with_ldbm_type = btree ; then
2377 { echo "configure: error: NDBM only supports LDBM type hash" 1>&2; exit 1; }
2381 if test $ol_enable_slurpd = yes ; then
2382 if test $ol_with_threads = no ; then
2383 { echo "configure: error: slurpd requires threads" 1>&2; exit 1; }
2387 if test $ol_enable_kbind = yes -o $ol_enable_kpasswd = yes ; then
2388 if test $ol_with_kerberos = no ; then
2389 { echo "configure: error: options require --with-kerberos" 1>&2; exit 1; }
2391 elif test $ol_enable_kbind = no -o $ol_enable_kpasswd = no ; then
2392 if test $ol_with_kerberos != auto ; then
2393 echo "configure: warning: Kerberos detection enabled unnecessarily" 1>&2;
2399 if test $ol_enable_spasswd = yes ; then
2400 if test $ol_with_cyrus_sasl = no ; then
2401 { echo "configure: error: options require --with-cyrus-sasl" 1>&2; exit 1; }
2406 echo "$ac_t""done" 1>&6
2433 BUILD_DNSSRV_DYNAMIC=static
2434 BUILD_LDAP_DYNAMIC=static
2435 BUILD_LDBM_DYNAMIC=static
2436 BUILD_PASSWD_DYNAMIC=static
2437 BUILD_PERL_DYNAMIC=static
2438 BUILD_SHELL_DYNAMIC=static
2439 BUILD_TCL_DYNAMIC=static
2440 BUILD_SQL_DYNAMIC=static
2442 SLAPD_MODULES_LDFLAGS=
2443 SLAPD_MODULES_CPPFLAGS=
2466 cat >> confdefs.h <<\EOF
2467 #define HAVE_MKVERSION 1
2475 *-*-aix*) if test -z "$CC" ; then
2476 case "$ol_with_threads" in
2477 auto | yes | posix) ol_aix_threads=yes ;;
2483 if test $ol_aix_threads = yes ; then
2484 if test -z "${CC}" ; then
2485 for ac_prog in cc_r xlc_r cc
2487 # Extract the first word of "$ac_prog", so it can be a program name with args.
2488 set dummy $ac_prog; ac_word=$2
2489 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2490 echo "configure:2491: checking for $ac_word" >&5
2491 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2492 echo $ac_n "(cached) $ac_c" 1>&6
2494 if test -n "$CC"; then
2495 ac_cv_prog_CC="$CC" # Let the user override the test.
2497 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2499 for ac_dir in $ac_dummy; do
2500 test -z "$ac_dir" && ac_dir=.
2501 if test -f $ac_dir/$ac_word; then
2502 ac_cv_prog_CC="$ac_prog"
2510 if test -n "$CC"; then
2511 echo "$ac_t""$CC" 1>&6
2513 echo "$ac_t""no" 1>&6
2516 test -n "$CC" && break
2520 if test "$CC" = cc ; then
2521 if test $ol_with_threads != auto ; then
2522 { echo "configure: error: --with-threads requires cc_r (or other suitable compiler) on AIX" 1>&2; exit 1; }
2524 echo "configure: warning: disabling threads, no cc_r on AIX" 1>&2
2530 if test "${CC}" = "cc_r" -o "${CC}" = "xlc_r" ; then
2531 ol_with_threads=posix
2532 ol_cv_pthread_create=yes
2536 if test -z "${CC}"; then
2539 # Extract the first word of "$ac_prog", so it can be a program name with args.
2540 set dummy $ac_prog; ac_word=$2
2541 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2542 echo "configure:2543: checking for $ac_word" >&5
2543 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2544 echo $ac_n "(cached) $ac_c" 1>&6
2546 if test -n "$CC"; then
2547 ac_cv_prog_CC="$CC" # Let the user override the test.
2549 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2551 for ac_dir in $ac_dummy; do
2552 test -z "$ac_dir" && ac_dir=.
2553 if test -f $ac_dir/$ac_word; then
2554 ac_cv_prog_CC="$ac_prog"
2562 if test -n "$CC"; then
2563 echo "$ac_t""$CC" 1>&6
2565 echo "$ac_t""no" 1>&6
2568 test -n "$CC" && break
2576 # Check whether --enable-fast-install or --disable-fast-install was given.
2577 if test "${enable_fast_install+set}" = set; then
2578 enableval="$enable_fast_install"
2579 p=${PACKAGE-default}
2580 case "$enableval" in
2581 yes) enable_fast_install=yes ;;
2582 no) enable_fast_install=no ;;
2584 enable_fast_install=no
2585 # Look at the argument we got. We use all the common list separators.
2586 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2587 for pkg in $enableval; do
2588 if test "X$pkg" = "X$p"; then
2589 enable_fast_install=yes
2596 enable_fast_install=yes
2599 # Extract the first word of "ranlib", so it can be a program name with args.
2600 set dummy ranlib; ac_word=$2
2601 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2602 echo "configure:2603: checking for $ac_word" >&5
2603 if eval "test \"\${ac_cv_prog_RANLIB+set}\" = set"; then
2604 echo $ac_n "(cached) $ac_c" 1>&6
2606 if test -n "$RANLIB"; then
2607 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2609 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2611 for ac_dir in $ac_dummy; do
2612 test -z "$ac_dir" && ac_dir=.
2613 if test -f $ac_dir/$ac_word; then
2614 ac_cv_prog_RANLIB="ranlib"
2619 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2622 RANLIB="$ac_cv_prog_RANLIB"
2623 if test -n "$RANLIB"; then
2624 echo "$ac_t""$RANLIB" 1>&6
2626 echo "$ac_t""no" 1>&6
2629 # Extract the first word of "gcc", so it can be a program name with args.
2630 set dummy gcc; ac_word=$2
2631 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2632 echo "configure:2633: checking for $ac_word" >&5
2633 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2634 echo $ac_n "(cached) $ac_c" 1>&6
2636 if test -n "$CC"; then
2637 ac_cv_prog_CC="$CC" # Let the user override the test.
2639 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2641 for ac_dir in $ac_dummy; do
2642 test -z "$ac_dir" && ac_dir=.
2643 if test -f $ac_dir/$ac_word; then
2652 if test -n "$CC"; then
2653 echo "$ac_t""$CC" 1>&6
2655 echo "$ac_t""no" 1>&6
2658 if test -z "$CC"; then
2659 # Extract the first word of "cc", so it can be a program name with args.
2660 set dummy cc; ac_word=$2
2661 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2662 echo "configure:2663: checking for $ac_word" >&5
2663 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2664 echo $ac_n "(cached) $ac_c" 1>&6
2666 if test -n "$CC"; then
2667 ac_cv_prog_CC="$CC" # Let the user override the test.
2669 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2672 for ac_dir in $ac_dummy; do
2673 test -z "$ac_dir" && ac_dir=.
2674 if test -f $ac_dir/$ac_word; then
2675 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2676 ac_prog_rejected=yes
2684 if test $ac_prog_rejected = yes; then
2685 # We found a bogon in the path, so make sure we never use it.
2686 set dummy $ac_cv_prog_CC
2688 if test $# -gt 0; then
2689 # We chose a different compiler from the bogus one.
2690 # However, it has the same basename, so the bogon will be chosen
2691 # first if we set CC to just the basename; use the full file name.
2693 set dummy "$ac_dir/$ac_word" "$@"
2701 if test -n "$CC"; then
2702 echo "$ac_t""$CC" 1>&6
2704 echo "$ac_t""no" 1>&6
2707 if test -z "$CC"; then
2708 case "`uname -s`" in
2709 *win32* | *WIN32* | *CYGWIN*)
2710 # Extract the first word of "cl", so it can be a program name with args.
2711 set dummy cl; ac_word=$2
2712 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2713 echo "configure:2714: checking for $ac_word" >&5
2714 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2715 echo $ac_n "(cached) $ac_c" 1>&6
2717 if test -n "$CC"; then
2718 ac_cv_prog_CC="$CC" # Let the user override the test.
2720 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2722 for ac_dir in $ac_dummy; do
2723 test -z "$ac_dir" && ac_dir=.
2724 if test -f $ac_dir/$ac_word; then
2733 if test -n "$CC"; then
2734 echo "$ac_t""$CC" 1>&6
2736 echo "$ac_t""no" 1>&6
2741 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2744 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2745 echo "configure:2746: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works" >&5
2748 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2749 ac_cpp='$CPP $CPPFLAGS'
2750 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2751 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2752 cross_compiling=$ac_cv_prog_cc_cross
2754 cat > conftest.$ac_ext << EOF
2756 #line 2757 "configure"
2757 #include "confdefs.h"
2761 if { (eval echo configure:2762: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2762 ac_cv_prog_cc_works=yes
2763 # If we can't run a trivial program, we are probably using a cross compiler.
2764 if (./conftest; exit) 2>/dev/null; then
2765 ac_cv_prog_cc_cross=no
2767 ac_cv_prog_cc_cross=yes
2770 echo "configure: failed program was:" >&5
2771 cat conftest.$ac_ext >&5
2772 ac_cv_prog_cc_works=no
2776 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2777 ac_cpp='$CPP $CPPFLAGS'
2778 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2779 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2780 cross_compiling=$ac_cv_prog_cc_cross
2782 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2783 if test $ac_cv_prog_cc_works = no; then
2784 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2786 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2787 echo "configure:2788: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler" >&5
2788 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2789 cross_compiling=$ac_cv_prog_cc_cross
2791 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2792 echo "configure:2793: checking whether we are using GNU C" >&5
2793 if eval "test \"\${ac_cv_prog_gcc+set}\" = set"; then
2794 echo $ac_n "(cached) $ac_c" 1>&6
2796 cat > conftest.c <<EOF
2801 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2802: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2808 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2810 if test $ac_cv_prog_gcc = yes; then
2816 ac_test_CFLAGS="${CFLAGS+set}"
2817 ac_save_CFLAGS="$CFLAGS"
2819 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
2820 echo "configure:2821: checking whether ${CC-cc} accepts -g" >&5
2821 if eval "test \"\${ac_cv_prog_cc_g+set}\" = set"; then
2822 echo $ac_n "(cached) $ac_c" 1>&6
2824 echo 'void f(){}' > conftest.c
2825 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2834 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2835 if test "$ac_test_CFLAGS" = set; then
2836 CFLAGS="$ac_save_CFLAGS"
2837 elif test $ac_cv_prog_cc_g = yes; then
2838 if test "$GCC" = yes; then
2844 if test "$GCC" = yes; then
2851 # Check whether --with-gnu-ld or --without-gnu-ld was given.
2852 if test "${with_gnu_ld+set}" = set; then
2853 withval="$with_gnu_ld"
2854 test "$withval" = no || with_gnu_ld=yes
2860 if test "$ac_cv_prog_gcc" = yes; then
2861 # Check if gcc -print-prog-name=ld gives a path.
2862 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
2863 echo "configure:2864: checking for ld used by GCC" >&5
2864 ac_prog=`($CC -print-prog-name=ld) 2>&5`
2866 # Accept absolute paths.
2867 [\\/]* | [A-Za-z]:[\\/]*)
2868 re_direlt='/[^/][^/]*/\.\./'
2869 # Canonicalize the path of ld
2870 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
2871 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2872 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
2874 test -z "$LD" && LD="$ac_prog"
2877 # If it fails, then pretend we aren't using GCC.
2881 # If it is relative, then search for the first ld in PATH.
2885 elif test "$with_gnu_ld" = yes; then
2886 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
2887 echo "configure:2888: checking for GNU ld" >&5
2889 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
2890 echo "configure:2891: checking for non-GNU ld" >&5
2892 if eval "test \"\${ac_cv_path_LD+set}\" = set"; then
2893 echo $ac_n "(cached) $ac_c" 1>&6
2895 if test -z "$LD"; then
2896 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2897 for ac_dir in $PATH; do
2898 test -z "$ac_dir" && ac_dir=.
2899 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2900 ac_cv_path_LD="$ac_dir/$ac_prog"
2901 # Check to see if the program is GNU ld. I'd rather use --version,
2902 # but apparently some GNU ld's only accept -v.
2903 # Break only if it was the GNU/non-GNU ld that we prefer.
2904 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
2905 test "$with_gnu_ld" != no && break
2907 test "$with_gnu_ld" != yes && break
2913 ac_cv_path_LD="$LD" # Let the user override the test with a path.
2918 if test -n "$LD"; then
2919 echo "$ac_t""$LD" 1>&6
2921 echo "$ac_t""no" 1>&6
2923 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
2924 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
2925 echo "configure:2926: checking if the linker ($LD) is GNU ld" >&5
2926 if eval "test \"\${ac_cv_prog_gnu_ld+set}\" = set"; then
2927 echo $ac_n "(cached) $ac_c" 1>&6
2929 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
2930 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
2931 ac_cv_prog_gnu_ld=yes
2933 ac_cv_prog_gnu_ld=no
2937 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
2940 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
2941 echo "configure:2942: checking for BSD-compatible nm" >&5
2942 if eval "test \"\${ac_cv_path_NM+set}\" = set"; then
2943 echo $ac_n "(cached) $ac_c" 1>&6
2945 if test -n "$NM"; then
2946 # Let the user override the test.
2949 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2950 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2951 test -z "$ac_dir" && ac_dir=.
2952 if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
2953 # Check to see if the nm accepts a BSD-compat flag.
2954 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2955 # nm: unknown option "B" ignored
2956 if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2957 ac_cv_path_NM="$ac_dir/nm -B"
2959 elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2960 ac_cv_path_NM="$ac_dir/nm -p"
2963 ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
2964 continue # so that we can try to find one that supports BSD flags
2969 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
2974 echo "$ac_t""$NM" 1>&6
2976 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
2977 echo "configure:2978: checking whether ln -s works" >&5
2978 if eval "test \"\${ac_cv_prog_LN_S+set}\" = set"; then
2979 echo $ac_n "(cached) $ac_c" 1>&6
2982 if ln -s X conftestdata 2>/dev/null
2985 ac_cv_prog_LN_S="ln -s"
2990 LN_S="$ac_cv_prog_LN_S"
2991 if test "$ac_cv_prog_LN_S" = "ln -s"; then
2992 echo "$ac_t""yes" 1>&6
2994 echo "$ac_t""no" 1>&6
2997 if test $host != $build; then
2998 ac_tool_prefix=${host_alias}-
3005 NONE) lt_target="$host" ;;
3006 *) lt_target="$target" ;;
3009 # Check for any special flags to pass to ltconfig.
3010 libtool_flags="--cache-file=$cache_file"
3011 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
3012 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
3013 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
3014 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
3015 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
3016 libtool_flags="$libtool_flags --enable-dlopen"
3017 libtool_flags="$libtool_flags --enable-win32-dll"
3018 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
3019 if test "${enable_libtool_lock+set}" = set; then
3020 enableval="$enable_libtool_lock"
3024 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
3025 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
3027 # Some flags need to be propagated to the compiler or linker for good
3029 case "$lt_target" in
3031 # Find out which ABI we are using.
3032 echo '#line 3033 "configure"' > conftest.$ac_ext
3033 if { (eval echo configure:3034: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3034 case "`/usr/bin/file conftest.o`" in
3050 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
3051 SAVE_CFLAGS="$CFLAGS"
3052 CFLAGS="$CFLAGS -belf"
3053 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
3054 echo "configure:3055: checking whether the C compiler needs -belf" >&5
3055 if eval "test \"\${lt_cv_cc_needs_belf+set}\" = set"; then
3056 echo $ac_n "(cached) $ac_c" 1>&6
3058 cat > conftest.$ac_ext <<EOF
3059 #line 3060 "configure"
3060 #include "confdefs.h"
3066 if { (eval echo configure:3067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3068 lt_cv_cc_needs_belf=yes
3070 echo "configure: failed program was:" >&5
3071 cat conftest.$ac_ext >&5
3073 lt_cv_cc_needs_belf=no
3078 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
3079 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
3080 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
3081 CFLAGS="$SAVE_CFLAGS"
3085 *-*-cygwin* | *-*-mingw*)
3086 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
3087 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
3088 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3089 echo "configure:3090: checking for $ac_word" >&5
3090 if eval "test \"\${ac_cv_prog_DLLTOOL+set}\" = set"; then
3091 echo $ac_n "(cached) $ac_c" 1>&6
3093 if test -n "$DLLTOOL"; then
3094 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
3096 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3098 for ac_dir in $ac_dummy; do
3099 test -z "$ac_dir" && ac_dir=.
3100 if test -f $ac_dir/$ac_word; then
3101 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
3108 DLLTOOL="$ac_cv_prog_DLLTOOL"
3109 if test -n "$DLLTOOL"; then
3110 echo "$ac_t""$DLLTOOL" 1>&6
3112 echo "$ac_t""no" 1>&6
3116 if test -z "$ac_cv_prog_DLLTOOL"; then
3117 if test -n "$ac_tool_prefix"; then
3118 # Extract the first word of "dlltool", so it can be a program name with args.
3119 set dummy dlltool; ac_word=$2
3120 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3121 echo "configure:3122: checking for $ac_word" >&5
3122 if eval "test \"\${ac_cv_prog_DLLTOOL+set}\" = set"; then
3123 echo $ac_n "(cached) $ac_c" 1>&6
3125 if test -n "$DLLTOOL"; then
3126 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
3128 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3130 for ac_dir in $ac_dummy; do
3131 test -z "$ac_dir" && ac_dir=.
3132 if test -f $ac_dir/$ac_word; then
3133 ac_cv_prog_DLLTOOL="dlltool"
3138 test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="false"
3141 DLLTOOL="$ac_cv_prog_DLLTOOL"
3142 if test -n "$DLLTOOL"; then
3143 echo "$ac_t""$DLLTOOL" 1>&6
3145 echo "$ac_t""no" 1>&6
3153 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
3154 set dummy ${ac_tool_prefix}as; ac_word=$2
3155 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3156 echo "configure:3157: checking for $ac_word" >&5
3157 if eval "test \"\${ac_cv_prog_AS+set}\" = set"; then
3158 echo $ac_n "(cached) $ac_c" 1>&6
3160 if test -n "$AS"; then
3161 ac_cv_prog_AS="$AS" # Let the user override the test.
3163 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3165 for ac_dir in $ac_dummy; do
3166 test -z "$ac_dir" && ac_dir=.
3167 if test -f $ac_dir/$ac_word; then
3168 ac_cv_prog_AS="${ac_tool_prefix}as"
3176 if test -n "$AS"; then
3177 echo "$ac_t""$AS" 1>&6
3179 echo "$ac_t""no" 1>&6
3183 if test -z "$ac_cv_prog_AS"; then
3184 if test -n "$ac_tool_prefix"; then
3185 # Extract the first word of "as", so it can be a program name with args.
3186 set dummy as; ac_word=$2
3187 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3188 echo "configure:3189: checking for $ac_word" >&5
3189 if eval "test \"\${ac_cv_prog_AS+set}\" = set"; then
3190 echo $ac_n "(cached) $ac_c" 1>&6
3192 if test -n "$AS"; then
3193 ac_cv_prog_AS="$AS" # Let the user override the test.
3195 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3197 for ac_dir in $ac_dummy; do
3198 test -z "$ac_dir" && ac_dir=.
3199 if test -f $ac_dir/$ac_word; then
3205 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="false"
3209 if test -n "$AS"; then
3210 echo "$ac_t""$AS" 1>&6
3212 echo "$ac_t""no" 1>&6
3220 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
3221 set dummy ${ac_tool_prefix}objdump; ac_word=$2
3222 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3223 echo "configure:3224: checking for $ac_word" >&5
3224 if eval "test \"\${ac_cv_prog_OBJDUMP+set}\" = set"; then
3225 echo $ac_n "(cached) $ac_c" 1>&6
3227 if test -n "$OBJDUMP"; then
3228 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
3230 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3232 for ac_dir in $ac_dummy; do
3233 test -z "$ac_dir" && ac_dir=.
3234 if test -f $ac_dir/$ac_word; then
3235 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
3242 OBJDUMP="$ac_cv_prog_OBJDUMP"
3243 if test -n "$OBJDUMP"; then
3244 echo "$ac_t""$OBJDUMP" 1>&6
3246 echo "$ac_t""no" 1>&6
3250 if test -z "$ac_cv_prog_OBJDUMP"; then
3251 if test -n "$ac_tool_prefix"; then
3252 # Extract the first word of "objdump", so it can be a program name with args.
3253 set dummy objdump; ac_word=$2
3254 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3255 echo "configure:3256: checking for $ac_word" >&5
3256 if eval "test \"\${ac_cv_prog_OBJDUMP+set}\" = set"; then
3257 echo $ac_n "(cached) $ac_c" 1>&6
3259 if test -n "$OBJDUMP"; then
3260 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
3262 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3264 for ac_dir in $ac_dummy; do
3265 test -z "$ac_dir" && ac_dir=.
3266 if test -f $ac_dir/$ac_word; then
3267 ac_cv_prog_OBJDUMP="objdump"
3272 test -z "$ac_cv_prog_OBJDUMP" && ac_cv_prog_OBJDUMP="false"
3275 OBJDUMP="$ac_cv_prog_OBJDUMP"
3276 if test -n "$OBJDUMP"; then
3277 echo "$ac_t""$OBJDUMP" 1>&6
3279 echo "$ac_t""no" 1>&6
3292 # Save cache, so that ltconfig can load it
3295 # Actually configure libtool. ac_aux_dir is where install-sh is found.
3296 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
3297 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3298 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
3299 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
3300 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
3301 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
3302 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
3304 # Reload cache, that may have been modified by ltconfig
3307 # This can be used to rebuild libtool when needed
3308 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
3310 # Always use our own libtool.
3311 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
3313 # Redirect the config.log output again, so that the ltconfig log is not
3314 # clobbered by the next message.
3315 exec 5>>./config.log
3318 for ac_prog in mawk gawk nawk awk
3320 # Extract the first word of "$ac_prog", so it can be a program name with args.
3321 set dummy $ac_prog; ac_word=$2
3322 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3323 echo "configure:3324: checking for $ac_word" >&5
3324 if eval "test \"\${ac_cv_prog_AWK+set}\" = set"; then
3325 echo $ac_n "(cached) $ac_c" 1>&6
3327 if test -n "$AWK"; then
3328 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3330 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3332 for ac_dir in $ac_dummy; do
3333 test -z "$ac_dir" && ac_dir=.
3334 if test -f $ac_dir/$ac_word; then
3335 ac_cv_prog_AWK="$ac_prog"
3342 AWK="$ac_cv_prog_AWK"
3343 if test -n "$AWK"; then
3344 echo "$ac_t""$AWK" 1>&6
3346 echo "$ac_t""no" 1>&6
3349 test -n "$AWK" && break
3352 # test for ln hardlink support
3353 echo $ac_n "checking whether ln works""... $ac_c" 1>&6
3354 echo "configure:3355: checking whether ln works" >&5
3355 if eval "test \"\${ol_cv_prog_LN_H+set}\" = set"; then
3356 echo $ac_n "(cached) $ac_c" 1>&6
3358 rm -f conftest.src conftest.dst
3359 echo "conftest" > conftest.src
3360 if ln conftest.src conftest.dst 2>/dev/null
3362 ol_cv_prog_LN_H="ln"
3364 ol_cv_prog_LN_H="cp"
3366 rm -f conftest.src conftest.dst
3369 LN_H="$ol_cv_prog_LN_H"
3370 if test "$ol_cv_prog_LN_H" = "ln"; then
3371 echo "$ac_t""yes" 1>&6
3373 echo "$ac_t""no" 1>&6
3376 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
3377 echo "configure:3378: checking whether ln -s works" >&5
3378 if eval "test \"\${ac_cv_prog_LN_S+set}\" = set"; then
3379 echo $ac_n "(cached) $ac_c" 1>&6
3382 if ln -s X conftestdata 2>/dev/null
3385 ac_cv_prog_LN_S="ln -s"
3390 LN_S="$ac_cv_prog_LN_S"
3391 if test "$ac_cv_prog_LN_S" = "ln -s"; then
3392 echo "$ac_t""yes" 1>&6
3394 echo "$ac_t""no" 1>&6
3398 if test "$LN_H" = "cp" -a "$LN_S" = "ln"; then
3402 # Extract the first word of "sendmail", so it can be a program name with args.
3403 set dummy sendmail; ac_word=$2
3404 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3405 echo "configure:3406: checking for $ac_word" >&5
3406 if eval "test \"\${ac_cv_path_SENDMAIL+set}\" = set"; then
3407 echo $ac_n "(cached) $ac_c" 1>&6
3411 ac_cv_path_SENDMAIL="$SENDMAIL" # Let the user override the test with a path.
3414 ac_cv_path_SENDMAIL="$SENDMAIL" # Let the user override the test with a dos path.
3417 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3418 ac_dummy="$PATH:/usr/libexec:/usr/lib:/usr/sbin:/usr/etc:/etc"
3419 for ac_dir in $ac_dummy; do
3420 test -z "$ac_dir" && ac_dir=.
3421 if test -f $ac_dir/$ac_word; then
3422 ac_cv_path_SENDMAIL="$ac_dir/$ac_word"
3427 test -z "$ac_cv_path_SENDMAIL" && ac_cv_path_SENDMAIL="/usr/lib/sendmail"
3431 SENDMAIL="$ac_cv_path_SENDMAIL"
3432 if test -n "$SENDMAIL"; then
3433 echo "$ac_t""$SENDMAIL" 1>&6
3435 echo "$ac_t""no" 1>&6
3438 # Extract the first word of "vi", so it can be a program name with args.
3439 set dummy vi; ac_word=$2
3440 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3441 echo "configure:3442: checking for $ac_word" >&5
3442 if eval "test \"\${ac_cv_path_EDITOR+set}\" = set"; then
3443 echo $ac_n "(cached) $ac_c" 1>&6
3447 ac_cv_path_EDITOR="$EDITOR" # Let the user override the test with a path.
3450 ac_cv_path_EDITOR="$EDITOR" # Let the user override the test with a dos path.
3453 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3454 ac_dummy="$PATH:/usr/ucb"
3455 for ac_dir in $ac_dummy; do
3456 test -z "$ac_dir" && ac_dir=.
3457 if test -f $ac_dir/$ac_word; then
3458 ac_cv_path_EDITOR="$ac_dir/$ac_word"
3463 test -z "$ac_cv_path_EDITOR" && ac_cv_path_EDITOR="/usr/ucb/vi"
3467 EDITOR="$ac_cv_path_EDITOR"
3468 if test -n "$EDITOR"; then
3469 echo "$ac_t""$EDITOR" 1>&6
3471 echo "$ac_t""no" 1>&6
3474 # Extract the first word of "finger", so it can be a program name with args.
3475 set dummy finger; ac_word=$2
3476 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3477 echo "configure:3478: checking for $ac_word" >&5
3478 if eval "test \"\${ac_cv_path_FINGER+set}\" = set"; then
3479 echo $ac_n "(cached) $ac_c" 1>&6
3483 ac_cv_path_FINGER="$FINGER" # Let the user override the test with a path.
3486 ac_cv_path_FINGER="$FINGER" # Let the user override the test with a dos path.
3489 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3490 ac_dummy="$PATH:/usr/ucb"
3491 for ac_dir in $ac_dummy; do
3492 test -z "$ac_dir" && ac_dir=.
3493 if test -f $ac_dir/$ac_word; then
3494 ac_cv_path_FINGER="$ac_dir/$ac_word"
3499 test -z "$ac_cv_path_FINGER" && ac_cv_path_FINGER="/usr/ucb/finger"
3503 FINGER="$ac_cv_path_FINGER"
3504 if test -n "$FINGER"; then
3505 echo "$ac_t""$FINGER" 1>&6
3507 echo "$ac_t""no" 1>&6
3512 if test $ol_enable_perl != no ; then
3513 # Extract the first word of "perl", so it can be a program name with args.
3514 set dummy perl; ac_word=$2
3515 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3516 echo "configure:3517: checking for $ac_word" >&5
3517 if eval "test \"\${ac_cv_path_PERLBIN+set}\" = set"; then
3518 echo $ac_n "(cached) $ac_c" 1>&6
3522 ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
3525 ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a dos path.
3528 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3530 for ac_dir in $ac_dummy; do
3531 test -z "$ac_dir" && ac_dir=.
3532 if test -f $ac_dir/$ac_word; then
3533 ac_cv_path_PERLBIN="$ac_dir/$ac_word"
3538 test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
3542 PERLBIN="$ac_cv_path_PERLBIN"
3543 if test -n "$PERLBIN"; then
3544 echo "$ac_t""$PERLBIN" 1>&6
3546 echo "$ac_t""no" 1>&6
3550 if test "no$PERLBIN" = "no" ; then
3551 if test $ol_enable_perl = yes ; then
3552 { echo "configure: error: could not locate perl" 1>&2; exit 1; }
3556 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
3557 if test x"$ol_with_perl_module" = "xstatic" ; then
3558 SLAPD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
3560 MOD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
3566 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
3567 echo "configure:3568: checking how to run the C preprocessor" >&5
3568 # On Suns, sometimes $CPP names a directory.
3569 if test -n "$CPP" && test -d "$CPP"; then
3572 if test -z "$CPP"; then
3573 if eval "test \"\${ac_cv_prog_CPP+set}\" = set"; then
3574 echo $ac_n "(cached) $ac_c" 1>&6
3576 # This must be in double quotes, not single quotes, because CPP may get
3577 # substituted into the Makefile and "${CC-cc}" will confuse make.
3579 # On the NeXT, cc -E runs the code through the compiler's parser,
3580 # not just through cpp.
3581 cat > conftest.$ac_ext <<EOF
3582 #line 3583 "configure"
3583 #include "confdefs.h"
3587 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3588 { (eval echo configure:3589: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3589 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3590 if test -z "$ac_err"; then
3594 echo "configure: failed program was:" >&5
3595 cat conftest.$ac_ext >&5
3597 CPP="${CC-cc} -E -traditional-cpp"
3598 cat > conftest.$ac_ext <<EOF
3599 #line 3600 "configure"
3600 #include "confdefs.h"
3604 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3605 { (eval echo configure:3606: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3606 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3607 if test -z "$ac_err"; then
3611 echo "configure: failed program was:" >&5
3612 cat conftest.$ac_ext >&5
3614 CPP="${CC-cc} -nologo -E"
3615 cat > conftest.$ac_ext <<EOF
3616 #line 3617 "configure"
3617 #include "confdefs.h"
3621 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3622 { (eval echo configure:3623: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3623 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3624 if test -z "$ac_err"; then
3628 echo "configure: failed program was:" >&5
3629 cat conftest.$ac_ext >&5
3638 ac_cv_prog_CPP="$CPP"
3640 CPP="$ac_cv_prog_CPP"
3642 ac_cv_prog_CPP="$CPP"
3644 echo "$ac_t""$CPP" 1>&6
3647 if test $cross_compiling = yes -a $ol_enable_x_compile = yes; then
3648 echo "configure: warning: cross compiling.... some functionality will be removed." 1>&2
3650 elif test $cross_compiling = no -a $ol_enable_x_compile = yes; then
3651 echo "configure: warning: programs compiled here do run here..." 1>&2
3652 { echo "configure: error: if not cross compiling, use --disable-x-compile." 1>&2; exit 1; }
3654 elif test $cross_compiling = yes -a $ol_enable_x_compile = no; then
3655 echo "configure: warning: programs compiled here do not run here..." 1>&2
3656 { echo "configure: error: if cross compiling, add --enable-x-compile." 1>&2; exit 1; }
3659 echo $ac_n "checking for AIX""... $ac_c" 1>&6
3660 echo "configure:3661: checking for AIX" >&5
3661 cat > conftest.$ac_ext <<EOF
3662 #line 3663 "configure"
3663 #include "confdefs.h"
3669 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3670 egrep "yes" >/dev/null 2>&1; then
3672 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
3673 #define _ALL_SOURCE 1
3678 echo "$ac_t""no" 1>&6
3683 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
3684 echo "configure:3685: checking for POSIXized ISC" >&5
3685 if test -d /etc/conf/kconfig.d &&
3686 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
3688 echo "$ac_t""yes" 1>&6
3689 ISC=yes # If later tests want to check for ISC.
3690 cat >> confdefs.h <<\EOF
3691 #define _POSIX_SOURCE 1
3694 if test "$GCC" = yes; then
3700 echo "$ac_t""no" 1>&6
3704 ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
3705 echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
3706 echo "configure:3707: checking for minix/config.h" >&5
3707 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
3708 echo $ac_n "(cached) $ac_c" 1>&6
3710 cat > conftest.$ac_ext <<EOF
3711 #line 3712 "configure"
3712 #include "confdefs.h"
3713 #include <minix/config.h>
3715 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3716 { (eval echo configure:3717: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3717 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3718 if test -z "$ac_err"; then
3720 eval "ac_cv_header_$ac_safe=yes"
3723 echo "configure: failed program was:" >&5
3724 cat conftest.$ac_ext >&5
3726 eval "ac_cv_header_$ac_safe=no"
3730 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3731 echo "$ac_t""yes" 1>&6
3734 echo "$ac_t""no" 1>&6
3738 if test "$MINIX" = yes; then
3739 cat >> confdefs.h <<\EOF
3740 #define _POSIX_SOURCE 1
3743 cat >> confdefs.h <<\EOF
3744 #define _POSIX_1_SOURCE 2
3747 cat >> confdefs.h <<\EOF
3754 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
3755 echo "configure:3756: checking for Cygwin environment" >&5
3756 if eval "test \"\${ac_cv_cygwin+set}\" = set"; then
3757 echo $ac_n "(cached) $ac_c" 1>&6
3759 cat > conftest.$ac_ext <<EOF
3760 #line 3761 "configure"
3761 #include "confdefs.h"
3766 #define __CYGWIN__ __CYGWIN32__
3771 if { (eval echo configure:3772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3775 echo "configure: failed program was:" >&5
3776 cat conftest.$ac_ext >&5
3783 echo "$ac_t""$ac_cv_cygwin" 1>&6
3785 test "$ac_cv_cygwin" = yes && CYGWIN=yes
3786 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
3787 echo "configure:3788: checking for mingw32 environment" >&5
3788 if eval "test \"\${ac_cv_mingw32+set}\" = set"; then
3789 echo $ac_n "(cached) $ac_c" 1>&6
3791 cat > conftest.$ac_ext <<EOF
3792 #line 3793 "configure"
3793 #include "confdefs.h"
3799 if { (eval echo configure:3800: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3803 echo "configure: failed program was:" >&5
3804 cat conftest.$ac_ext >&5
3811 echo "$ac_t""$ac_cv_mingw32" 1>&6
3813 test "$ac_cv_mingw32" = yes && MINGW32=yes
3814 echo $ac_n "checking for EMX OS/2 environment""... $ac_c" 1>&6
3815 echo "configure:3816: checking for EMX OS/2 environment" >&5
3816 if eval "test \"\${ac_cv_emxos2+set}\" = set"; then
3817 echo $ac_n "(cached) $ac_c" 1>&6
3819 cat > conftest.$ac_ext <<EOF
3820 #line 3821 "configure"
3821 #include "confdefs.h"
3827 if { (eval echo configure:3828: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3831 echo "configure: failed program was:" >&5
3832 cat conftest.$ac_ext >&5
3839 echo "$ac_t""$ac_cv_emxos2" 1>&6
3841 test "$ac_cv_emxos2" = yes && EMXOS2=yes
3845 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
3846 echo "configure:3847: checking for executable suffix" >&5
3847 if eval "test \"\${ac_cv_exeext+set}\" = set"; then
3848 echo $ac_n "(cached) $ac_c" 1>&6
3850 if test "$CYGWIN" = yes || test "$MINGW32" = yes || test "$EMXOS2" = yes; then
3854 echo 'int main () { return 0; }' > conftest.$ac_ext
3856 if { (eval echo configure:3857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
3857 for file in conftest.*; do
3859 *.c | *.C | *.o | *.obj | *.xcoff) ;;
3860 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
3864 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
3867 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
3872 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
3873 echo "$ac_t""${ac_cv_exeext}" 1>&6
3876 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
3877 echo "configure:3878: checking for object suffix" >&5
3878 if eval "test \"\${ac_cv_objext+set}\" = set"; then
3879 echo $ac_n "(cached) $ac_c" 1>&6
3882 echo 'int i = 1;' > conftest.$ac_ext
3883 if { (eval echo configure:3884: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3884 for ac_file in conftest.*; do
3887 *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
3891 { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
3896 echo "$ac_t""$ac_cv_objext" 1>&6
3897 OBJEXT=$ac_cv_objext
3898 ac_objext=$ac_cv_objext
3901 cat >> confdefs.h <<EOF
3902 #define EXEEXT "${EXEEXT}"
3906 echo $ac_n "checking for be_app in -lbe""... $ac_c" 1>&6
3907 echo "configure:3908: checking for be_app in -lbe" >&5
3908 ac_lib_var=`echo be'_'be_app | sed 'y%./+-:%__p__%'`
3909 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
3910 echo $ac_n "(cached) $ac_c" 1>&6
3912 ac_save_LIBS="$LIBS"
3913 LIBS="-lbe -lroot -lnet $LIBS"
3914 cat > conftest.$ac_ext <<EOF
3915 #line 3916 "configure"
3916 #include "confdefs.h"
3917 /* Override any gcc2 internal prototype to avoid an error. */
3918 /* We use char because int might match the return type of a gcc2
3919 builtin and then its argument prototype would still apply. */
3926 if { (eval echo configure:3927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3928 eval "ac_cv_lib_$ac_lib_var=yes"
3930 echo "configure: failed program was:" >&5
3931 cat conftest.$ac_ext >&5
3933 eval "ac_cv_lib_$ac_lib_var=no"
3936 LIBS="$ac_save_LIBS"
3939 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3940 echo "$ac_t""yes" 1>&6
3941 LIBS="$LIBS -lbe -lroot -lnet"
3943 echo "$ac_t""no" 1>&6
3951 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
3952 echo "configure:3953: checking for ${CC-cc} option to accept ANSI C" >&5
3953 if eval "test \"\${am_cv_prog_cc_stdc+set}\" = set"; then
3954 echo $ac_n "(cached) $ac_c" 1>&6
3956 am_cv_prog_cc_stdc=no
3958 # Don't try gcc -ansi; that turns off useful extensions and
3959 # breaks some systems' header files.
3960 # AIX -qlanglvl=ansi
3961 # Ultrix and OSF/1 -std1
3962 # HP-UX 10.20 and later -Ae
3963 # HP-UX older versions -Aa -D_HPUX_SOURCE
3964 # SVR4 -Xc -D__EXTENSIONS__
3965 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3967 CC="$ac_save_CC $ac_arg"
3968 cat > conftest.$ac_ext <<EOF
3969 #line 3970 "configure"
3970 #include "confdefs.h"
3973 #include <sys/types.h>
3974 #include <sys/stat.h>
3975 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3976 struct buf { int x; };
3977 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3978 static char *e (p, i)
3984 static char *f (char * (*g) (char **, int), char **p, ...)
3989 s = g (p, va_arg (v,int));
3993 int test (int i, double x);
3994 struct s1 {int (*f) (int a);};
3995 struct s2 {int (*f) (double a);};
3996 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4002 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4006 if { (eval echo configure:4007: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4008 am_cv_prog_cc_stdc="$ac_arg"; break
4010 echo "configure: failed program was:" >&5
4011 cat conftest.$ac_ext >&5
4019 if test -z "$am_cv_prog_cc_stdc"; then
4020 echo "$ac_t""none needed" 1>&6
4022 echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
4024 case "x$am_cv_prog_cc_stdc" in
4026 *) CC="$CC $am_cv_prog_cc_stdc" ;;
4029 if test "X${am_cv_prog_cc_stdc}" = "Xno" ; then
4030 { echo "configure: error: OpenLDAP requires compiler to support STDC constructs." 1>&2; exit 1; }
4033 # test for make depend flag
4036 if test -z "${MKDEP}"; then
4038 if test -z "${MKDEP_FLAGS}"; then
4039 echo $ac_n "checking for ${OL_MKDEP} depend flag""... $ac_c" 1>&6
4040 echo "configure:4041: checking for ${OL_MKDEP} depend flag" >&5
4041 if eval "test \"\${ol_cv_mkdep+set}\" = set"; then
4042 echo $ac_n "(cached) $ac_c" 1>&6
4046 for flag in "-M" "-xM"; do
4047 cat > conftest.c <<EOF
4050 if { ac_try='$OL_MKDEP $flag conftest.c'; { (eval echo configure:4051: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
4051 | egrep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
4053 if test ! -f conftest."${ac_object}" ; then
4055 OL_MKDEP_FLAGS="$flag"
4064 echo "$ac_t""$ol_cv_mkdep" 1>&6
4067 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
4072 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
4077 if test "${ol_cv_mkdep}" = no ; then
4078 # this will soon become an error
4079 echo "configure: warning: do not know how to generate dependencies" 1>&2
4082 echo $ac_n "checking for afopen in -ls""... $ac_c" 1>&6
4083 echo "configure:4084: checking for afopen in -ls" >&5
4084 ac_lib_var=`echo s'_'afopen | sed 'y%./+-:%__p__%'`
4085 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4086 echo $ac_n "(cached) $ac_c" 1>&6
4088 ac_save_LIBS="$LIBS"
4090 cat > conftest.$ac_ext <<EOF
4091 #line 4092 "configure"
4092 #include "confdefs.h"
4093 /* Override any gcc2 internal prototype to avoid an error. */
4094 /* We use char because int might match the return type of a gcc2
4095 builtin and then its argument prototype would still apply. */
4102 if { (eval echo configure:4103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4104 eval "ac_cv_lib_$ac_lib_var=yes"
4106 echo "configure: failed program was:" >&5
4107 cat conftest.$ac_ext >&5
4109 eval "ac_cv_lib_$ac_lib_var=no"
4112 LIBS="$ac_save_LIBS"
4115 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4116 echo "$ac_t""yes" 1>&6
4119 cat >> confdefs.h <<\EOF
4120 #define HAVE_AIX_SECURITY 1
4125 echo "$ac_t""no" 1>&6
4130 if test $ol_enable_modules != no ; then
4131 for ac_hdr in ltdl.h
4133 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4134 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4135 echo "configure:4136: checking for $ac_hdr" >&5
4136 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
4137 echo $ac_n "(cached) $ac_c" 1>&6
4139 cat > conftest.$ac_ext <<EOF
4140 #line 4141 "configure"
4141 #include "confdefs.h"
4144 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4145 { (eval echo configure:4146: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4146 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4147 if test -z "$ac_err"; then
4149 eval "ac_cv_header_$ac_safe=yes"
4152 echo "configure: failed program was:" >&5
4153 cat conftest.$ac_ext >&5
4155 eval "ac_cv_header_$ac_safe=no"
4159 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4160 echo "$ac_t""yes" 1>&6
4161 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4162 cat >> confdefs.h <<EOF
4163 #define $ac_tr_hdr 1
4167 echo "$ac_t""no" 1>&6
4172 if test $ac_cv_header_ltdl_h = no ; then
4173 { echo "configure: error: could not locate libtool ltdl.h" 1>&2; exit 1; }
4176 echo $ac_n "checking for lt_dlinit in -lltdl""... $ac_c" 1>&6
4177 echo "configure:4178: checking for lt_dlinit in -lltdl" >&5
4178 ac_lib_var=`echo ltdl'_'lt_dlinit | sed 'y%./+-:%__p__%'`
4179 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4180 echo $ac_n "(cached) $ac_c" 1>&6
4182 ac_save_LIBS="$LIBS"
4184 cat > conftest.$ac_ext <<EOF
4185 #line 4186 "configure"
4186 #include "confdefs.h"
4187 /* Override any gcc2 internal prototype to avoid an error. */
4188 /* We use char because int might match the return type of a gcc2
4189 builtin and then its argument prototype would still apply. */
4196 if { (eval echo configure:4197: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4198 eval "ac_cv_lib_$ac_lib_var=yes"
4200 echo "configure: failed program was:" >&5
4201 cat conftest.$ac_ext >&5
4203 eval "ac_cv_lib_$ac_lib_var=no"
4206 LIBS="$ac_save_LIBS"
4209 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4210 echo "$ac_t""yes" 1>&6
4213 cat >> confdefs.h <<\EOF
4214 #define HAVE_LIBLTDL 1
4219 echo "$ac_t""no" 1>&6
4223 if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
4224 { echo "configure: error: could not locate libtool -lltdl" 1>&2; exit 1; }
4228 ol_with_dnssrv_module=static
4229 ol_with_ldap_module=static
4230 ol_with_ldbm_module=static
4231 ol_with_passwd_module=static
4232 ol_with_perl_module=static
4233 ol_with_shell_module=static
4234 ol_with_tcl_module=static
4235 ol_with_sql_module=static
4239 echo $ac_n "checking for EBCDIC""... $ac_c" 1>&6
4240 echo "configure:4241: checking for EBCDIC" >&5
4241 if eval "test \"\${ol_cv_cpp_ebcdic+set}\" = set"; then
4242 echo $ac_n "(cached) $ac_c" 1>&6
4245 cat > conftest.$ac_ext <<EOF
4246 #line 4247 "configure"
4247 #include "confdefs.h"
4250 #include <__ASCII__/generate_error.h>
4254 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4255 { (eval echo configure:4256: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4256 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4257 if test -z "$ac_err"; then
4259 ol_cv_cpp_ebcdic=yes
4262 echo "configure: failed program was:" >&5
4263 cat conftest.$ac_ext >&5
4270 echo "$ac_t""$ol_cv_cpp_ebcdic" 1>&6
4271 if test $ol_cv_cpp_ebcdic = yes ; then
4272 cat >> confdefs.h <<\EOF
4273 #define HAVE_EBCDIC 1
4278 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
4279 echo "configure:4280: checking for ANSI C header files" >&5
4280 if eval "test \"\${ol_cv_header_stdc+set}\" = set"; then
4281 echo $ac_n "(cached) $ac_c" 1>&6
4283 cat > conftest.$ac_ext <<EOF
4284 #line 4285 "configure"
4285 #include "confdefs.h"
4291 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4292 { (eval echo configure:4293: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4293 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4294 if test -z "$ac_err"; then
4296 ol_cv_header_stdc=yes
4299 echo "configure: failed program was:" >&5
4300 cat conftest.$ac_ext >&5
4302 ol_cv_header_stdc=no
4306 if test $ol_cv_header_stdc = yes; then
4307 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4308 cat > conftest.$ac_ext <<EOF
4309 #line 4310 "configure"
4310 #include "confdefs.h"
4313 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4314 egrep "memchr" >/dev/null 2>&1; then
4318 ol_cv_header_stdc=no
4324 if test $ol_cv_header_stdc = yes; then
4325 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4326 cat > conftest.$ac_ext <<EOF
4327 #line 4328 "configure"
4328 #include "confdefs.h"
4331 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4332 egrep "free" >/dev/null 2>&1; then
4336 ol_cv_header_stdc=no
4342 if test $ol_cv_header_stdc = yes; then
4343 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4344 if test "$cross_compiling" = yes; then
4347 cat > conftest.$ac_ext <<EOF
4348 #line 4349 "configure"
4349 #include "confdefs.h"
4352 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4353 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4355 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
4356 || ('j' <= (c) && (c) <= 'r') \
4357 || ('s' <= (c) && (c) <= 'z'))
4358 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4360 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4361 int main () { int i; for (i = 0; i < 256; i++)
4362 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
4366 if { (eval echo configure:4367: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4370 echo "configure: failed program was:" >&5
4371 cat conftest.$ac_ext >&5
4373 ol_cv_header_stdc=no
4381 echo "$ac_t""$ol_cv_header_stdc" 1>&6
4382 if test $ol_cv_header_stdc = yes; then
4383 cat >> confdefs.h <<\EOF
4384 #define STDC_HEADERS 1
4388 ac_cv_header_stdc=disable
4391 if test $ol_cv_header_stdc != yes; then
4392 echo "configure: warning: could not locate Standard C compliant headers" 1>&2
4396 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
4398 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4399 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
4400 echo "configure:4401: checking for $ac_hdr that defines DIR" >&5
4401 if eval "test \"\${ac_cv_header_dirent_$ac_safe+set}\" = set"; then
4402 echo $ac_n "(cached) $ac_c" 1>&6
4404 cat > conftest.$ac_ext <<EOF
4405 #line 4406 "configure"
4406 #include "confdefs.h"
4407 #include <sys/types.h>
4413 if { (eval echo configure:4414: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4415 eval "ac_cv_header_dirent_$ac_safe=yes"
4417 echo "configure: failed program was:" >&5
4418 cat conftest.$ac_ext >&5
4420 eval "ac_cv_header_dirent_$ac_safe=no"
4424 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
4425 echo "$ac_t""yes" 1>&6
4426 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4427 cat >> confdefs.h <<EOF
4428 #define $ac_tr_hdr 1
4430 ac_header_dirent=$ac_hdr; break
4432 echo "$ac_t""no" 1>&6
4435 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4436 if test $ac_header_dirent = dirent.h; then
4437 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
4438 echo "configure:4439: checking for opendir in -ldir" >&5
4439 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-:%__p__%'`
4440 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4441 echo $ac_n "(cached) $ac_c" 1>&6
4443 ac_save_LIBS="$LIBS"
4445 cat > conftest.$ac_ext <<EOF
4446 #line 4447 "configure"
4447 #include "confdefs.h"
4448 /* Override any gcc2 internal prototype to avoid an error. */
4449 /* We use char because int might match the return type of a gcc2
4450 builtin and then its argument prototype would still apply. */
4457 if { (eval echo configure:4458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4459 eval "ac_cv_lib_$ac_lib_var=yes"
4461 echo "configure: failed program was:" >&5
4462 cat conftest.$ac_ext >&5
4464 eval "ac_cv_lib_$ac_lib_var=no"
4467 LIBS="$ac_save_LIBS"
4470 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4471 echo "$ac_t""yes" 1>&6
4474 echo "$ac_t""no" 1>&6
4478 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
4479 echo "configure:4480: checking for opendir in -lx" >&5
4480 ac_lib_var=`echo x'_'opendir | sed 'y%./+-:%__p__%'`
4481 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4482 echo $ac_n "(cached) $ac_c" 1>&6
4484 ac_save_LIBS="$LIBS"
4486 cat > conftest.$ac_ext <<EOF
4487 #line 4488 "configure"
4488 #include "confdefs.h"
4489 /* Override any gcc2 internal prototype to avoid an error. */
4490 /* We use char because int might match the return type of a gcc2
4491 builtin and then its argument prototype would still apply. */
4498 if { (eval echo configure:4499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4500 eval "ac_cv_lib_$ac_lib_var=yes"
4502 echo "configure: failed program was:" >&5
4503 cat conftest.$ac_ext >&5
4505 eval "ac_cv_lib_$ac_lib_var=no"
4508 LIBS="$ac_save_LIBS"
4511 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4512 echo "$ac_t""yes" 1>&6
4515 echo "$ac_t""no" 1>&6
4520 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
4521 echo "configure:4522: checking for sys/wait.h that is POSIX.1 compatible" >&5
4522 if eval "test \"\${ac_cv_header_sys_wait_h+set}\" = set"; then
4523 echo $ac_n "(cached) $ac_c" 1>&6
4525 cat > conftest.$ac_ext <<EOF
4526 #line 4527 "configure"
4527 #include "confdefs.h"
4528 #include <sys/types.h>
4529 #include <sys/wait.h>
4531 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
4534 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
4539 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
4542 if { (eval echo configure:4543: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4544 ac_cv_header_sys_wait_h=yes
4546 echo "configure: failed program was:" >&5
4547 cat conftest.$ac_ext >&5
4549 ac_cv_header_sys_wait_h=no
4554 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
4555 if test $ac_cv_header_sys_wait_h = yes; then
4556 cat >> confdefs.h <<\EOF
4557 #define HAVE_SYS_WAIT_H 1
4562 echo $ac_n "checking POSIX termios""... $ac_c" 1>&6
4563 echo "configure:4564: checking POSIX termios" >&5
4564 if eval "test \"\${am_cv_sys_posix_termios+set}\" = set"; then
4565 echo $ac_n "(cached) $ac_c" 1>&6
4567 cat > conftest.$ac_ext <<EOF
4568 #line 4569 "configure"
4569 #include "confdefs.h"
4570 #include <sys/types.h>
4572 #include <termios.h>
4574 /* SunOS 4.0.3 has termios.h but not the library calls. */
4578 if { (eval echo configure:4579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4580 am_cv_sys_posix_termios=yes
4582 echo "configure: failed program was:" >&5
4583 cat conftest.$ac_ext >&5
4585 am_cv_sys_posix_termios=no
4590 echo "$ac_t""$am_cv_sys_posix_termios" 1>&6
4593 echo $ac_n "checking whether use of TIOCGWINSZ requires sys/ioctl.h""... $ac_c" 1>&6
4594 echo "configure:4595: checking whether use of TIOCGWINSZ requires sys/ioctl.h" >&5
4595 if eval "test \"\${am_cv_sys_tiocgwinsz_needs_sys_ioctl_h+set}\" = set"; then
4596 echo $ac_n "(cached) $ac_c" 1>&6
4598 am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=no
4600 gwinsz_in_termios_h=no
4601 if test $am_cv_sys_posix_termios = yes; then
4602 cat > conftest.$ac_ext <<EOF
4603 #line 4604 "configure"
4604 #include "confdefs.h"
4605 #include <sys/types.h>
4606 # include <termios.h>
4612 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4613 egrep "yes" >/dev/null 2>&1; then
4615 gwinsz_in_termios_h=yes
4621 if test $gwinsz_in_termios_h = no; then
4622 cat > conftest.$ac_ext <<EOF
4623 #line 4624 "configure"
4624 #include "confdefs.h"
4625 #include <sys/types.h>
4626 # include <sys/ioctl.h>
4632 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4633 egrep "yes" >/dev/null 2>&1; then
4635 am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=yes
4643 echo "$ac_t""$am_cv_sys_tiocgwinsz_needs_sys_ioctl_h" 1>&6
4644 if test $am_cv_sys_tiocgwinsz_needs_sys_ioctl_h = yes; then
4645 cat >> confdefs.h <<\EOF
4646 #define GWINSZ_IN_SYS_IOCTL 1
4651 if test $am_cv_sys_posix_termios = yes ; then
4652 cat >> confdefs.h <<\EOF
4653 #define HAVE_POSIX_TERMIOS 1
4704 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4705 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4706 echo "configure:4707: checking for $ac_hdr" >&5
4707 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
4708 echo $ac_n "(cached) $ac_c" 1>&6
4710 cat > conftest.$ac_ext <<EOF
4711 #line 4712 "configure"
4712 #include "confdefs.h"
4715 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4716 { (eval echo configure:4717: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4717 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4718 if test -z "$ac_err"; then
4720 eval "ac_cv_header_$ac_safe=yes"
4723 echo "configure: failed program was:" >&5
4724 cat conftest.$ac_ext >&5
4726 eval "ac_cv_header_$ac_safe=no"
4730 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4731 echo "$ac_t""yes" 1>&6
4732 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4733 cat >> confdefs.h <<EOF
4734 #define $ac_tr_hdr 1
4738 echo "$ac_t""no" 1>&6
4745 echo $ac_n "checking for sigset in -lV3""... $ac_c" 1>&6
4746 echo "configure:4747: checking for sigset in -lV3" >&5
4747 ac_lib_var=`echo V3'_'sigset | sed 'y%./+-:%__p__%'`
4748 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4749 echo $ac_n "(cached) $ac_c" 1>&6
4751 ac_save_LIBS="$LIBS"
4753 cat > conftest.$ac_ext <<EOF
4754 #line 4755 "configure"
4755 #include "confdefs.h"
4756 /* Override any gcc2 internal prototype to avoid an error. */
4757 /* We use char because int might match the return type of a gcc2
4758 builtin and then its argument prototype would still apply. */
4765 if { (eval echo configure:4766: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4767 eval "ac_cv_lib_$ac_lib_var=yes"
4769 echo "configure: failed program was:" >&5
4770 cat conftest.$ac_ext >&5
4772 eval "ac_cv_lib_$ac_lib_var=no"
4775 LIBS="$ac_save_LIBS"
4778 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4779 echo "$ac_t""yes" 1>&6
4780 ac_tr_lib=HAVE_LIB`echo V3 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4781 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4782 cat >> confdefs.h <<EOF
4783 #define $ac_tr_lib 1
4789 echo "$ac_t""no" 1>&6
4793 if test $ac_cv_header_winsock_h = yes; then
4794 echo $ac_n "checking for winsock""... $ac_c" 1>&6
4795 echo "configure:4796: checking for winsock" >&5
4796 if eval "test \"\${ol_cv_winsock+set}\" = set"; then
4797 echo $ac_n "(cached) $ac_c" 1>&6
4799 cat > conftest.$ac_ext <<EOF
4800 #line 4801 "configure"
4801 #include "confdefs.h"
4802 #include <winsock.h>
4806 select(0,NULL,NULL,NULL,NULL);
4808 gethostname(NULL,0);
4812 if { (eval echo configure:4813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4816 echo "configure: failed program was:" >&5
4817 cat conftest.$ac_ext >&5
4824 echo "$ac_t""$ol_cv_winsock" 1>&6
4826 if test $ol_cv_winsock = yes ; then
4827 cat >> confdefs.h <<\EOF
4828 #define HAVE_WINSOCK 1
4831 ac_cv_func_socket=yes
4832 ac_cv_func_select=yes
4833 ac_cv_func_closesocket=yes
4834 ac_cv_func_gethostname=yes
4839 echo $ac_n "checking for socket""... $ac_c" 1>&6
4840 echo "configure:4841: checking for socket" >&5
4841 if eval "test \"\${ac_cv_func_socket+set}\" = set"; then
4842 echo $ac_n "(cached) $ac_c" 1>&6
4844 cat > conftest.$ac_ext <<EOF
4845 #line 4846 "configure"
4846 #include "confdefs.h"
4847 /* System header to define __stub macros and hopefully few prototypes,
4848 which can conflict with char socket(); below. */
4850 /* Override any gcc2 internal prototype to avoid an error. */
4851 /* We use char because int might match the return type of a gcc2
4852 builtin and then its argument prototype would still apply. */
4858 /* The GNU C library defines this for functions which it implements
4859 to always fail with ENOSYS. Some functions are actually named
4860 something starting with __ and the normal name is an alias. */
4861 #if defined (__stub_socket) || defined (__stub___socket)
4869 if { (eval echo configure:4870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4871 eval "ac_cv_func_socket=yes"
4873 echo "configure: failed program was:" >&5
4874 cat conftest.$ac_ext >&5
4876 eval "ac_cv_func_socket=no"
4881 if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
4882 echo "$ac_t""yes" 1>&6
4885 echo "$ac_t""no" 1>&6
4887 echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6
4888 echo "configure:4889: checking for main in -lsocket" >&5
4889 ac_lib_var=`echo socket'_'main | sed 'y%./+-:%__p__%'`
4890 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4891 echo $ac_n "(cached) $ac_c" 1>&6
4893 ac_save_LIBS="$LIBS"
4894 LIBS="-lsocket $LIBS"
4895 cat > conftest.$ac_ext <<EOF
4896 #line 4897 "configure"
4897 #include "confdefs.h"
4903 if { (eval echo configure:4904: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4905 eval "ac_cv_lib_$ac_lib_var=yes"
4907 echo "configure: failed program was:" >&5
4908 cat conftest.$ac_ext >&5
4910 eval "ac_cv_lib_$ac_lib_var=no"
4913 LIBS="$ac_save_LIBS"
4916 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4917 echo "$ac_t""yes" 1>&6
4918 ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4919 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4920 cat >> confdefs.h <<EOF
4921 #define $ac_tr_lib 1
4924 LIBS="-lsocket $LIBS"
4927 echo "$ac_t""no" 1>&6
4930 echo $ac_n "checking for main in -lnet""... $ac_c" 1>&6
4931 echo "configure:4932: checking for main in -lnet" >&5
4932 ac_lib_var=`echo net'_'main | sed 'y%./+-:%__p__%'`
4933 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4934 echo $ac_n "(cached) $ac_c" 1>&6
4936 ac_save_LIBS="$LIBS"
4938 cat > conftest.$ac_ext <<EOF
4939 #line 4940 "configure"
4940 #include "confdefs.h"
4946 if { (eval echo configure:4947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4948 eval "ac_cv_lib_$ac_lib_var=yes"
4950 echo "configure: failed program was:" >&5
4951 cat conftest.$ac_ext >&5
4953 eval "ac_cv_lib_$ac_lib_var=no"
4956 LIBS="$ac_save_LIBS"
4959 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4960 echo "$ac_t""yes" 1>&6
4961 ac_tr_lib=HAVE_LIB`echo net | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4962 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4963 cat >> confdefs.h <<EOF
4964 #define $ac_tr_lib 1
4970 echo "$ac_t""no" 1>&6
4973 echo $ac_n "checking for main in -lnsl_s""... $ac_c" 1>&6
4974 echo "configure:4975: checking for main in -lnsl_s" >&5
4975 ac_lib_var=`echo nsl_s'_'main | sed 'y%./+-:%__p__%'`
4976 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4977 echo $ac_n "(cached) $ac_c" 1>&6
4979 ac_save_LIBS="$LIBS"
4980 LIBS="-lnsl_s $LIBS"
4981 cat > conftest.$ac_ext <<EOF
4982 #line 4983 "configure"
4983 #include "confdefs.h"
4989 if { (eval echo configure:4990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4991 eval "ac_cv_lib_$ac_lib_var=yes"
4993 echo "configure: failed program was:" >&5
4994 cat conftest.$ac_ext >&5
4996 eval "ac_cv_lib_$ac_lib_var=no"
4999 LIBS="$ac_save_LIBS"
5002 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5003 echo "$ac_t""yes" 1>&6
5004 ac_tr_lib=HAVE_LIB`echo nsl_s | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5005 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5006 cat >> confdefs.h <<EOF
5007 #define $ac_tr_lib 1
5010 LIBS="-lnsl_s $LIBS"
5013 echo "$ac_t""no" 1>&6
5016 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
5017 echo "configure:5018: checking for main in -lnsl" >&5
5018 ac_lib_var=`echo nsl'_'main | sed 'y%./+-:%__p__%'`
5019 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5020 echo $ac_n "(cached) $ac_c" 1>&6
5022 ac_save_LIBS="$LIBS"
5024 cat > conftest.$ac_ext <<EOF
5025 #line 5026 "configure"
5026 #include "confdefs.h"
5032 if { (eval echo configure:5033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5034 eval "ac_cv_lib_$ac_lib_var=yes"
5036 echo "configure: failed program was:" >&5
5037 cat conftest.$ac_ext >&5
5039 eval "ac_cv_lib_$ac_lib_var=no"
5042 LIBS="$ac_save_LIBS"
5045 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5046 echo "$ac_t""yes" 1>&6
5047 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5048 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5049 cat >> confdefs.h <<EOF
5050 #define $ac_tr_lib 1
5056 echo "$ac_t""no" 1>&6
5059 echo $ac_n "checking for socket in -linet""... $ac_c" 1>&6
5060 echo "configure:5061: checking for socket in -linet" >&5
5061 ac_lib_var=`echo inet'_'socket | sed 'y%./+-:%__p__%'`
5062 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5063 echo $ac_n "(cached) $ac_c" 1>&6
5065 ac_save_LIBS="$LIBS"
5067 cat > conftest.$ac_ext <<EOF
5068 #line 5069 "configure"
5069 #include "confdefs.h"
5070 /* Override any gcc2 internal prototype to avoid an error. */
5071 /* We use char because int might match the return type of a gcc2
5072 builtin and then its argument prototype would still apply. */
5079 if { (eval echo configure:5080: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5081 eval "ac_cv_lib_$ac_lib_var=yes"
5083 echo "configure: failed program was:" >&5
5084 cat conftest.$ac_ext >&5
5086 eval "ac_cv_lib_$ac_lib_var=no"
5089 LIBS="$ac_save_LIBS"
5092 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5093 echo "$ac_t""yes" 1>&6
5094 ac_tr_lib=HAVE_LIB`echo inet | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5095 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5096 cat >> confdefs.h <<EOF
5097 #define $ac_tr_lib 1
5103 echo "$ac_t""no" 1>&6
5106 echo $ac_n "checking for main in -lgen""... $ac_c" 1>&6
5107 echo "configure:5108: checking for main in -lgen" >&5
5108 ac_lib_var=`echo gen'_'main | sed 'y%./+-:%__p__%'`
5109 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5110 echo $ac_n "(cached) $ac_c" 1>&6
5112 ac_save_LIBS="$LIBS"
5114 cat > conftest.$ac_ext <<EOF
5115 #line 5116 "configure"
5116 #include "confdefs.h"
5122 if { (eval echo configure:5123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5124 eval "ac_cv_lib_$ac_lib_var=yes"
5126 echo "configure: failed program was:" >&5
5127 cat conftest.$ac_ext >&5
5129 eval "ac_cv_lib_$ac_lib_var=no"
5132 LIBS="$ac_save_LIBS"
5135 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5136 echo "$ac_t""yes" 1>&6
5137 ac_tr_lib=HAVE_LIB`echo gen | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5138 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5139 cat >> confdefs.h <<EOF
5140 #define $ac_tr_lib 1
5146 echo "$ac_t""no" 1>&6
5153 echo $ac_n "checking for select""... $ac_c" 1>&6
5154 echo "configure:5155: checking for select" >&5
5155 if eval "test \"\${ac_cv_func_select+set}\" = set"; then
5156 echo $ac_n "(cached) $ac_c" 1>&6
5158 cat > conftest.$ac_ext <<EOF
5159 #line 5160 "configure"
5160 #include "confdefs.h"
5161 /* System header to define __stub macros and hopefully few prototypes,
5162 which can conflict with char select(); below. */
5164 /* Override any gcc2 internal prototype to avoid an error. */
5165 /* We use char because int might match the return type of a gcc2
5166 builtin and then its argument prototype would still apply. */
5172 /* The GNU C library defines this for functions which it implements
5173 to always fail with ENOSYS. Some functions are actually named
5174 something starting with __ and the normal name is an alias. */
5175 #if defined (__stub_select) || defined (__stub___select)
5183 if { (eval echo configure:5184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5185 eval "ac_cv_func_select=yes"
5187 echo "configure: failed program was:" >&5
5188 cat conftest.$ac_ext >&5
5190 eval "ac_cv_func_select=no"
5195 if eval "test \"`echo '$ac_cv_func_'select`\" = yes"; then
5196 echo "$ac_t""yes" 1>&6
5199 echo "$ac_t""no" 1>&6
5200 { echo "configure: error: select() required." 1>&2; exit 1; }
5204 if test "${ac_cv_header_winsock_h}" != yes; then
5205 echo $ac_n "checking types of arguments for select()""... $ac_c" 1>&6
5206 echo "configure:5207: checking types of arguments for select()" >&5
5207 if eval "test \"\${ac_cv_func_select_arg234+set}\" = set"; then
5208 echo $ac_n "(cached) $ac_c" 1>&6
5210 if eval "test \"\${ac_cv_func_select_arg1+set}\" = set"; then
5211 echo $ac_n "(cached) $ac_c" 1>&6
5213 if eval "test \"\${ac_cv_func_select_arg5+set}\" = set"; then
5214 echo $ac_n "(cached) $ac_c" 1>&6
5216 for ac_cv_func_select_arg234 in 'fd_set *' 'int *' 'void *'; do
5217 for ac_cv_func_select_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
5218 for ac_cv_func_select_arg5 in 'struct timeval *' 'const struct timeval *'; do
5219 cat > conftest.$ac_ext <<EOF
5220 #line 5221 "configure"
5221 #include "confdefs.h"
5222 #ifdef HAVE_SYS_TYPES_H
5223 #include <sys/types.h>
5225 #ifdef HAVE_SYS_TIME_H
5226 #include <sys/time.h>
5228 #ifdef HAVE_SYS_SELECT_H
5229 #include <sys/select.h>
5231 #ifdef HAVE_SYS_SOCKET_H
5232 #include <sys/socket.h>
5234 extern select ($ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5);
5239 if { (eval echo configure:5240: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5241 ac_not_found=no ; break 3
5243 echo "configure: failed program was:" >&5
5244 cat conftest.$ac_ext >&5
5258 if test "$ac_not_found" = yes; then
5259 ac_cv_func_select_arg1=int
5260 ac_cv_func_select_arg234='int *'
5261 ac_cv_func_select_arg5='struct timeval *'
5263 echo "$ac_t""$ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5" 1>&6
5264 cat >> confdefs.h <<EOF
5265 #define SELECT_TYPE_ARG1 $ac_cv_func_select_arg1
5268 cat >> confdefs.h <<EOF
5269 #define SELECT_TYPE_ARG234 ($ac_cv_func_select_arg234)
5272 cat >> confdefs.h <<EOF
5273 #define SELECT_TYPE_ARG5 ($ac_cv_func_select_arg5)
5280 for ac_hdr in regex.h
5282 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5283 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5284 echo "configure:5285: checking for $ac_hdr" >&5
5285 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5286 echo $ac_n "(cached) $ac_c" 1>&6
5288 cat > conftest.$ac_ext <<EOF
5289 #line 5290 "configure"
5290 #include "confdefs.h"
5293 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5294 { (eval echo configure:5295: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5295 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5296 if test -z "$ac_err"; then
5298 eval "ac_cv_header_$ac_safe=yes"
5301 echo "configure: failed program was:" >&5
5302 cat conftest.$ac_ext >&5
5304 eval "ac_cv_header_$ac_safe=no"
5308 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5309 echo "$ac_t""yes" 1>&6
5310 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5311 cat >> confdefs.h <<EOF
5312 #define $ac_tr_hdr 1
5316 echo "$ac_t""no" 1>&6
5320 if test "$ac_cv_header_regex_h" != yes ; then
5321 { echo "configure: error: POSIX regex.h required." 1>&2; exit 1; }
5323 echo $ac_n "checking for regfree""... $ac_c" 1>&6
5324 echo "configure:5325: checking for regfree" >&5
5325 if eval "test \"\${ac_cv_func_regfree+set}\" = set"; then
5326 echo $ac_n "(cached) $ac_c" 1>&6
5328 cat > conftest.$ac_ext <<EOF
5329 #line 5330 "configure"
5330 #include "confdefs.h"
5331 /* System header to define __stub macros and hopefully few prototypes,
5332 which can conflict with char regfree(); below. */
5334 /* Override any gcc2 internal prototype to avoid an error. */
5335 /* We use char because int might match the return type of a gcc2
5336 builtin and then its argument prototype would still apply. */
5342 /* The GNU C library defines this for functions which it implements
5343 to always fail with ENOSYS. Some functions are actually named
5344 something starting with __ and the normal name is an alias. */
5345 #if defined (__stub_regfree) || defined (__stub___regfree)
5353 if { (eval echo configure:5354: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5355 eval "ac_cv_func_regfree=yes"
5357 echo "configure: failed program was:" >&5
5358 cat conftest.$ac_ext >&5
5360 eval "ac_cv_func_regfree=no"
5365 if eval "test \"`echo '$ac_cv_func_'regfree`\" = yes"; then
5366 echo "$ac_t""yes" 1>&6
5369 echo "$ac_t""no" 1>&6
5370 { echo "configure: error: POSIX regex required." 1>&2; exit 1; }
5375 echo $ac_n "checking for compatible POSIX regex""... $ac_c" 1>&6
5376 echo "configure:5377: checking for compatible POSIX regex" >&5
5377 if eval "test \"\${ol_cv_c_posix_regex+set}\" = set"; then
5378 echo $ac_n "(cached) $ac_c" 1>&6
5381 if test "$cross_compiling" = yes; then
5382 ol_cv_c_posix_regex=cross
5384 cat > conftest.$ac_ext <<EOF
5385 #line 5386 "configure"
5386 #include "confdefs.h"
5388 #include <sys/types.h>
5390 static char *pattern, *string;
5398 if(regcomp(&re, pattern, 0)) {
5402 string = "ALL MATCH";
5404 rc = regexec(&re, string, 0, (void*)0, 0);
5411 if { (eval echo configure:5412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5413 ol_cv_c_posix_regex=yes
5415 echo "configure: failed program was:" >&5
5416 cat conftest.$ac_ext >&5
5418 ol_cv_c_posix_regex=no
5425 echo "$ac_t""$ol_cv_c_posix_regex" 1>&6
5427 if test "$ol_cv_c_posix_regex" = no ; then
5428 { echo "configure: error: broken POSIX regex!" 1>&2; exit 1; }
5432 echo $ac_n "checking for res_query""... $ac_c" 1>&6
5433 echo "configure:5434: checking for res_query" >&5
5434 if eval "test \"\${ac_cv_func_res_query+set}\" = set"; then
5435 echo $ac_n "(cached) $ac_c" 1>&6
5437 cat > conftest.$ac_ext <<EOF
5438 #line 5439 "configure"
5439 #include "confdefs.h"
5440 /* System header to define __stub macros and hopefully few prototypes,
5441 which can conflict with char res_query(); below. */
5443 /* Override any gcc2 internal prototype to avoid an error. */
5444 /* We use char because int might match the return type of a gcc2
5445 builtin and then its argument prototype would still apply. */
5451 /* The GNU C library defines this for functions which it implements
5452 to always fail with ENOSYS. Some functions are actually named
5453 something starting with __ and the normal name is an alias. */
5454 #if defined (__stub_res_query) || defined (__stub___res_query)
5462 if { (eval echo configure:5463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5464 eval "ac_cv_func_res_query=yes"
5466 echo "configure: failed program was:" >&5
5467 cat conftest.$ac_ext >&5
5469 eval "ac_cv_func_res_query=no"
5474 if eval "test \"`echo '$ac_cv_func_'res_query`\" = yes"; then
5475 echo "$ac_t""yes" 1>&6
5478 echo "$ac_t""no" 1>&6
5481 if test $ac_cv_func_res_query = no ; then
5482 echo $ac_n "checking for res_query in -lbind""... $ac_c" 1>&6
5483 echo "configure:5484: checking for res_query in -lbind" >&5
5484 ac_lib_var=`echo bind'_'res_query | sed 'y%./+-:%__p__%'`
5485 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5486 echo $ac_n "(cached) $ac_c" 1>&6
5488 ac_save_LIBS="$LIBS"
5490 cat > conftest.$ac_ext <<EOF
5491 #line 5492 "configure"
5492 #include "confdefs.h"
5493 /* Override any gcc2 internal prototype to avoid an error. */
5494 /* We use char because int might match the return type of a gcc2
5495 builtin and then its argument prototype would still apply. */
5502 if { (eval echo configure:5503: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5504 eval "ac_cv_lib_$ac_lib_var=yes"
5506 echo "configure: failed program was:" >&5
5507 cat conftest.$ac_ext >&5
5509 eval "ac_cv_lib_$ac_lib_var=no"
5512 LIBS="$ac_save_LIBS"
5515 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5516 echo "$ac_t""yes" 1>&6
5517 ac_tr_lib=HAVE_LIB`echo bind | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5518 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5519 cat >> confdefs.h <<EOF
5520 #define $ac_tr_lib 1
5526 echo "$ac_t""no" 1>&6
5529 ac_cv_func_res_query=$ac_cv_lib_bind_res_query
5532 if test $ac_cv_func_res_query = no ; then
5533 echo $ac_n "checking for __res_query in -lbind""... $ac_c" 1>&6
5534 echo "configure:5535: checking for __res_query in -lbind" >&5
5535 ac_lib_var=`echo bind'_'__res_query | sed 'y%./+-:%__p__%'`
5536 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5537 echo $ac_n "(cached) $ac_c" 1>&6
5539 ac_save_LIBS="$LIBS"
5541 cat > conftest.$ac_ext <<EOF
5542 #line 5543 "configure"
5543 #include "confdefs.h"
5544 /* Override any gcc2 internal prototype to avoid an error. */
5545 /* We use char because int might match the return type of a gcc2
5546 builtin and then its argument prototype would still apply. */
5553 if { (eval echo configure:5554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5555 eval "ac_cv_lib_$ac_lib_var=yes"
5557 echo "configure: failed program was:" >&5
5558 cat conftest.$ac_ext >&5
5560 eval "ac_cv_lib_$ac_lib_var=no"
5563 LIBS="$ac_save_LIBS"
5566 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5567 echo "$ac_t""yes" 1>&6
5568 ac_tr_lib=HAVE_LIB`echo bind | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5569 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5570 cat >> confdefs.h <<EOF
5571 #define $ac_tr_lib 1
5577 echo "$ac_t""no" 1>&6
5580 ac_cv_func_res_query=$ac_cv_lib_bind___res_query
5583 if test $ac_cv_func_res_query = no ; then
5584 echo $ac_n "checking for res_query in -lresolv""... $ac_c" 1>&6
5585 echo "configure:5586: checking for res_query in -lresolv" >&5
5586 ac_lib_var=`echo resolv'_'res_query | sed 'y%./+-:%__p__%'`
5587 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5588 echo $ac_n "(cached) $ac_c" 1>&6
5590 ac_save_LIBS="$LIBS"
5591 LIBS="-lresolv $LIBS"
5592 cat > conftest.$ac_ext <<EOF
5593 #line 5594 "configure"
5594 #include "confdefs.h"
5595 /* Override any gcc2 internal prototype to avoid an error. */
5596 /* We use char because int might match the return type of a gcc2
5597 builtin and then its argument prototype would still apply. */
5604 if { (eval echo configure:5605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5606 eval "ac_cv_lib_$ac_lib_var=yes"
5608 echo "configure: failed program was:" >&5
5609 cat conftest.$ac_ext >&5
5611 eval "ac_cv_lib_$ac_lib_var=no"
5614 LIBS="$ac_save_LIBS"
5617 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5618 echo "$ac_t""yes" 1>&6
5619 ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5620 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5621 cat >> confdefs.h <<EOF
5622 #define $ac_tr_lib 1
5625 LIBS="-lresolv $LIBS"
5628 echo "$ac_t""no" 1>&6
5631 ac_cv_func_res_query=$ac_cv_lib_resolv_res_query
5634 if test "$ac_cv_func_res_query" = yes ; then
5635 cat >> confdefs.h <<\EOF
5636 #define HAVE_RES_QUERY 1
5640 if test $ol_enable_dnssrv != no ; then
5645 if test "$ol_enable_dnssrv" = yes -a "$ol_link_dnssrv" = no ; then
5646 { echo "configure: error: DNSSRV requires res_query()" 1>&2; exit 1; }
5649 if test $ol_enable_quipu != no ; then
5650 for ac_hdr in quipu/commonarg.h
5652 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5653 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5654 echo "configure:5655: checking for $ac_hdr" >&5
5655 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5656 echo $ac_n "(cached) $ac_c" 1>&6
5658 cat > conftest.$ac_ext <<EOF
5659 #line 5660 "configure"
5660 #include "confdefs.h"
5663 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5664 { (eval echo configure:5665: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5665 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5666 if test -z "$ac_err"; then
5668 eval "ac_cv_header_$ac_safe=yes"
5671 echo "configure: failed program was:" >&5
5672 cat conftest.$ac_ext >&5
5674 eval "ac_cv_header_$ac_safe=no"
5678 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5679 echo "$ac_t""yes" 1>&6
5680 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5681 cat >> confdefs.h <<EOF
5682 #define $ac_tr_hdr 1
5686 echo "$ac_t""no" 1>&6
5691 if test $ac_cv_header_quipu_commonarg_h = yes ; then
5693 elif test $ol_enable_quipu = auto ; then
5694 echo "configure: warning: no quipu for --enable-quipu=auto, disabling" 1>&2
5696 { echo "configure: error: no quipu for --enable-quipu=$ol_enable_quipu" 1>&2; exit 1; }
5705 if test $ol_with_kerberos = auto -o $ol_with_kerberos = k5 \
5706 -o $ol_with_kerberos = k5only -o $ol_with_kerberos = k425 ; then
5708 for ac_hdr in krb5.h
5710 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5711 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5712 echo "configure:5713: checking for $ac_hdr" >&5
5713 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5714 echo $ac_n "(cached) $ac_c" 1>&6
5716 cat > conftest.$ac_ext <<EOF
5717 #line 5718 "configure"
5718 #include "confdefs.h"
5721 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5722 { (eval echo configure:5723: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5723 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5724 if test -z "$ac_err"; then
5726 eval "ac_cv_header_$ac_safe=yes"
5729 echo "configure: failed program was:" >&5
5730 cat conftest.$ac_ext >&5
5732 eval "ac_cv_header_$ac_safe=no"
5736 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5737 echo "$ac_t""yes" 1>&6
5738 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5739 cat >> confdefs.h <<EOF
5740 #define $ac_tr_hdr 1
5744 echo "$ac_t""no" 1>&6
5749 if test $ac_cv_header_krb5_h = yes ; then
5750 for ac_hdr in heim_err.h
5752 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5753 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5754 echo "configure:5755: checking for $ac_hdr" >&5
5755 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5756 echo $ac_n "(cached) $ac_c" 1>&6
5758 cat > conftest.$ac_ext <<EOF
5759 #line 5760 "configure"
5760 #include "confdefs.h"
5763 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5764 { (eval echo configure:5765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5765 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5766 if test -z "$ac_err"; then
5768 eval "ac_cv_header_$ac_safe=yes"
5771 echo "configure: failed program was:" >&5
5772 cat conftest.$ac_ext >&5
5774 eval "ac_cv_header_$ac_safe=no"
5778 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5779 echo "$ac_t""yes" 1>&6
5780 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5781 cat >> confdefs.h <<EOF
5782 #define $ac_tr_hdr 1
5786 echo "$ac_t""no" 1>&6
5790 if test $ac_cv_header_heim_err_h = yes ; then
5796 if test $krb5_impl = mit; then
5797 echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6
5798 echo "configure:5799: checking for main in -lkrb5" >&5
5799 ac_lib_var=`echo krb5'_'main | sed 'y%./+-:%__p__%'`
5800 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5801 echo $ac_n "(cached) $ac_c" 1>&6
5803 ac_save_LIBS="$LIBS"
5804 LIBS="-lkrb5 -lcrypto -lcom_err $LIBS"
5805 cat > conftest.$ac_ext <<EOF
5806 #line 5807 "configure"
5807 #include "confdefs.h"
5813 if { (eval echo configure:5814: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5815 eval "ac_cv_lib_$ac_lib_var=yes"
5817 echo "configure: failed program was:" >&5
5818 cat conftest.$ac_ext >&5
5820 eval "ac_cv_lib_$ac_lib_var=no"
5823 LIBS="$ac_save_LIBS"
5826 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5827 echo "$ac_t""yes" 1>&6
5829 KRB5_LIBS="-lkrb5 -lcrypto -lcom_err"
5831 echo "$ac_t""no" 1>&6
5836 elif test $krb5_impl = heimdal; then
5837 echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6
5838 echo "configure:5839: checking for main in -lkrb5" >&5
5839 ac_lib_var=`echo krb5'_'main | sed 'y%./+-:%__p__%'`
5840 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5841 echo $ac_n "(cached) $ac_c" 1>&6
5843 ac_save_LIBS="$LIBS"
5844 LIBS="-lkrb5 -ldes -lasn1 -lroken -lcom_err $LIBS"
5845 cat > conftest.$ac_ext <<EOF
5846 #line 5847 "configure"
5847 #include "confdefs.h"
5853 if { (eval echo configure:5854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5855 eval "ac_cv_lib_$ac_lib_var=yes"
5857 echo "configure: failed program was:" >&5
5858 cat conftest.$ac_ext >&5
5860 eval "ac_cv_lib_$ac_lib_var=no"
5863 LIBS="$ac_save_LIBS"
5866 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5867 echo "$ac_t""yes" 1>&6
5869 KRB5_LIBS="-lkrb5 -ldes -lasn1 -lroken -lcom_err"
5871 echo "$ac_t""no" 1>&6
5876 cat >> confdefs.h <<\EOF
5877 #define HAVE_HEIMDAL_KERBEROS 1
5882 echo "configure: warning: Unrecongized Kerberos5 Implementation" 1>&2
5885 if test $have_krb5 = yes ; then
5888 cat >> confdefs.h <<\EOF
5893 if test $ol_enable_kpasswd != no ; then
5894 ol_link_kpasswd=yes;
5897 if test $ol_with_kerberos = k5only ; then
5898 ol_with_kerberos=found
5901 elif test $ol_with_kerberos != auto ; then
5902 { echo "configure: error: Required Kerberos 5 support not available" 1>&2; exit 1; }
5908 if test $ol_link_krb5 = yes -a \
5909 \( $ol_with_kerberos = auto -o $ol_with_kerberos = k425 \) ; then
5911 for ac_hdr in kerberosIV/krb.h kerberosIV/des.h
5913 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5914 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5915 echo "configure:5916: checking for $ac_hdr" >&5
5916 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5917 echo $ac_n "(cached) $ac_c" 1>&6
5919 cat > conftest.$ac_ext <<EOF
5920 #line 5921 "configure"
5921 #include "confdefs.h"
5924 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5925 { (eval echo configure:5926: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5926 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5927 if test -z "$ac_err"; then
5929 eval "ac_cv_header_$ac_safe=yes"
5932 echo "configure: failed program was:" >&5
5933 cat conftest.$ac_ext >&5
5935 eval "ac_cv_header_$ac_safe=no"
5939 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5940 echo "$ac_t""yes" 1>&6
5941 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5942 cat >> confdefs.h <<EOF
5943 #define $ac_tr_hdr 1
5947 echo "$ac_t""no" 1>&6
5952 if test $ac_cv_header_kerberosIV_krb_h = yes ; then
5953 if test $krb5_impl = mit; then
5954 echo $ac_n "checking for main in -lkrb4""... $ac_c" 1>&6
5955 echo "configure:5956: checking for main in -lkrb4" >&5
5956 ac_lib_var=`echo krb4'_'main | sed 'y%./+-:%__p__%'`
5957 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5958 echo $ac_n "(cached) $ac_c" 1>&6
5960 ac_save_LIBS="$LIBS"
5961 LIBS="-lkrb4 -ldes425 -lkrb5 -lcrypto -lcom_err $LIBS"
5962 cat > conftest.$ac_ext <<EOF
5963 #line 5964 "configure"
5964 #include "confdefs.h"
5970 if { (eval echo configure:5971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5972 eval "ac_cv_lib_$ac_lib_var=yes"
5974 echo "configure: failed program was:" >&5
5975 cat conftest.$ac_ext >&5
5977 eval "ac_cv_lib_$ac_lib_var=no"
5980 LIBS="$ac_save_LIBS"
5983 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5984 echo "$ac_t""yes" 1>&6
5986 KRB4_LIBS="-lkrb4 -ldes425"
5988 echo "$ac_t""no" 1>&6
5993 elif test $krb5_impl = heimdal; then
5994 echo $ac_n "checking for main in -lkrb4""... $ac_c" 1>&6
5995 echo "configure:5996: checking for main in -lkrb4" >&5
5996 ac_lib_var=`echo krb4'_'main | sed 'y%./+-:%__p__%'`
5997 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5998 echo $ac_n "(cached) $ac_c" 1>&6
6000 ac_save_LIBS="$LIBS"
6001 LIBS="-lkrb4 -lkrb5 -ldes -lasn1 -lroken -lcom_err $LIBS"
6002 cat > conftest.$ac_ext <<EOF
6003 #line 6004 "configure"
6004 #include "confdefs.h"
6010 if { (eval echo configure:6011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6012 eval "ac_cv_lib_$ac_lib_var=yes"
6014 echo "configure: failed program was:" >&5
6015 cat conftest.$ac_ext >&5
6017 eval "ac_cv_lib_$ac_lib_var=no"
6020 LIBS="$ac_save_LIBS"
6023 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6024 echo "$ac_t""yes" 1>&6
6028 echo "$ac_t""no" 1>&6
6035 echo "configure: warning: Unrecongized Kerberos5 Implementation" 1>&2
6038 if test $have_k425 = yes ; then
6039 ol_with_kerberos=found
6042 cat >> confdefs.h <<\EOF
6043 #define HAVE_KRB425 1
6046 cat >> confdefs.h <<\EOF
6051 echo $ac_n "checking for des_debug in Kerberos libraries""... $ac_c" 1>&6
6052 echo "configure:6053: checking for des_debug in Kerberos libraries" >&5
6053 if eval "test \"\${ol_cv_var_des_debug+set}\" = set"; then
6054 echo $ac_n "(cached) $ac_c" 1>&6
6058 LIBS="$KRB4_LIBS $KRB5_LIBS $LIBS"
6059 cat > conftest.$ac_ext <<EOF
6060 #line 6061 "configure"
6061 #include "confdefs.h"
6063 #include <kerberosIV/krb.h>
6064 #include <kerberosIV/des.h>
6065 extern int des_debug;
6073 if { (eval echo configure:6074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6075 ol_cv_var_des_debug=yes
6077 echo "configure: failed program was:" >&5
6078 cat conftest.$ac_ext >&5
6080 ol_cv_var_des_debug=no
6087 echo "$ac_t""$ol_cv_var_des_debug" 1>&6
6089 if test $ol_cv_var_des_debug = yes ; then
6090 cat >> confdefs.h <<\EOF
6091 #define HAVE_DES_DEBUG 1
6101 if test $ol_link_krb5 = yes ; then
6102 ol_with_kerberos=found
6105 if test $ol_with_kerberos = auto -o $ol_with_kerberos = k4 \
6106 -o $ol_with_kerberos = kth ; then
6108 for ac_hdr in krb.h des.h krb-archaeology.h
6110 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6111 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6112 echo "configure:6113: checking for $ac_hdr" >&5
6113 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6114 echo $ac_n "(cached) $ac_c" 1>&6
6116 cat > conftest.$ac_ext <<EOF
6117 #line 6118 "configure"
6118 #include "confdefs.h"
6121 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6122 { (eval echo configure:6123: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6123 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6124 if test -z "$ac_err"; then
6126 eval "ac_cv_header_$ac_safe=yes"
6129 echo "configure: failed program was:" >&5
6130 cat conftest.$ac_ext >&5
6132 eval "ac_cv_header_$ac_safe=no"
6136 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6137 echo "$ac_t""yes" 1>&6
6138 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6139 cat >> confdefs.h <<EOF
6140 #define $ac_tr_hdr 1
6144 echo "$ac_t""no" 1>&6
6149 if test $ac_cv_header_krb_h = yes ; then
6150 echo $ac_n "checking for main in -lkrb""... $ac_c" 1>&6
6151 echo "configure:6152: checking for main in -lkrb" >&5
6152 ac_lib_var=`echo krb'_'main | sed 'y%./+-:%__p__%'`
6153 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6154 echo $ac_n "(cached) $ac_c" 1>&6
6156 ac_save_LIBS="$LIBS"
6157 LIBS="-lkrb -ldes $LIBS"
6158 cat > conftest.$ac_ext <<EOF
6159 #line 6160 "configure"
6160 #include "confdefs.h"
6166 if { (eval echo configure:6167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6168 eval "ac_cv_lib_$ac_lib_var=yes"
6170 echo "configure: failed program was:" >&5
6171 cat conftest.$ac_ext >&5
6173 eval "ac_cv_lib_$ac_lib_var=no"
6176 LIBS="$ac_save_LIBS"
6179 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6180 echo "$ac_t""yes" 1>&6
6183 echo "$ac_t""no" 1>&6
6188 if test $have_k4 = yes ; then
6189 ol_with_kerberos=found
6192 cat >> confdefs.h <<\EOF
6197 KRB4_LIBS="-lkrb -ldes"
6199 if test $ac_cv_header_krb_archaeology_h = yes ; then
6200 cat >> confdefs.h <<\EOF
6201 #define HAVE_KTH_KERBEROS 1
6209 if test $ol_link_krb4 = yes -a $ol_enable_kpasswd != no ; then
6210 ol_link_kpasswd=yes;
6213 if test $ol_link_krb4 = yes -o $ol_link_krb5 = yes ; then
6214 cat >> confdefs.h <<\EOF
6215 #define HAVE_KERBEROS 1
6219 elif test $ol_with_kerberos != auto -a $ol_with_kerberos != no ; then
6220 { echo "configure: error: Kerberos detection failed." 1>&2; exit 1; }
6224 if test $ol_with_tls != no ; then
6226 for ac_hdr in openssl/ssl.h ssl.h
6228 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6229 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6230 echo "configure:6231: checking for $ac_hdr" >&5
6231 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6232 echo $ac_n "(cached) $ac_c" 1>&6
6234 cat > conftest.$ac_ext <<EOF
6235 #line 6236 "configure"
6236 #include "confdefs.h"
6239 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6240 { (eval echo configure:6241: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6241 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6242 if test -z "$ac_err"; then
6244 eval "ac_cv_header_$ac_safe=yes"
6247 echo "configure: failed program was:" >&5
6248 cat conftest.$ac_ext >&5
6250 eval "ac_cv_header_$ac_safe=no"
6254 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6255 echo "$ac_t""yes" 1>&6
6256 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6257 cat >> confdefs.h <<EOF
6258 #define $ac_tr_hdr 1
6262 echo "$ac_t""no" 1>&6
6267 if test $ac_cv_header_openssl_ssl_h = yes -o $ac_cv_header_ssl_h = yes ; then
6268 echo $ac_n "checking for SSLeay_add_ssl_algorithms in -lssl""... $ac_c" 1>&6
6269 echo "configure:6270: checking for SSLeay_add_ssl_algorithms in -lssl" >&5
6270 ac_lib_var=`echo ssl'_'SSLeay_add_ssl_algorithms | sed 'y%./+-:%__p__%'`
6271 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6272 echo $ac_n "(cached) $ac_c" 1>&6
6274 ac_save_LIBS="$LIBS"
6275 LIBS="-lssl -lcrypto $LIBS"
6276 cat > conftest.$ac_ext <<EOF
6277 #line 6278 "configure"
6278 #include "confdefs.h"
6279 /* Override any gcc2 internal prototype to avoid an error. */
6280 /* We use char because int might match the return type of a gcc2
6281 builtin and then its argument prototype would still apply. */
6282 char SSLeay_add_ssl_algorithms();
6285 SSLeay_add_ssl_algorithms()
6288 if { (eval echo configure:6289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6290 eval "ac_cv_lib_$ac_lib_var=yes"
6292 echo "configure: failed program was:" >&5
6293 cat conftest.$ac_ext >&5
6295 eval "ac_cv_lib_$ac_lib_var=no"
6298 LIBS="$ac_save_LIBS"
6301 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6302 echo "$ac_t""yes" 1>&6
6306 echo "$ac_t""no" 1>&6
6311 if test $have_ssleay = no ; then
6312 echo $ac_n "checking for SSL_library_init in -lssl""... $ac_c" 1>&6
6313 echo "configure:6314: checking for SSL_library_init in -lssl" >&5
6314 ac_lib_var=`echo ssl'_'SSL_library_init | sed 'y%./+-:%__p__%'`
6315 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6316 echo $ac_n "(cached) $ac_c" 1>&6
6318 ac_save_LIBS="$LIBS"
6319 LIBS="-lssl -lcrypto $LIBS"
6320 cat > conftest.$ac_ext <<EOF
6321 #line 6322 "configure"
6322 #include "confdefs.h"
6323 /* Override any gcc2 internal prototype to avoid an error. */
6324 /* We use char because int might match the return type of a gcc2
6325 builtin and then its argument prototype would still apply. */
6326 char SSL_library_init();
6332 if { (eval echo configure:6333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6334 eval "ac_cv_lib_$ac_lib_var=yes"
6336 echo "configure: failed program was:" >&5
6337 cat conftest.$ac_ext >&5
6339 eval "ac_cv_lib_$ac_lib_var=no"
6342 LIBS="$ac_save_LIBS"
6345 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6346 echo "$ac_t""yes" 1>&6
6350 echo "$ac_t""no" 1>&6
6356 if test $have_ssleay = no ; then
6357 echo $ac_n "checking for ssl3_accept in -lssl""... $ac_c" 1>&6
6358 echo "configure:6359: checking for ssl3_accept in -lssl" >&5
6359 ac_lib_var=`echo ssl'_'ssl3_accept | sed 'y%./+-:%__p__%'`
6360 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6361 echo $ac_n "(cached) $ac_c" 1>&6
6363 ac_save_LIBS="$LIBS"
6364 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
6365 cat > conftest.$ac_ext <<EOF
6366 #line 6367 "configure"
6367 #include "confdefs.h"
6368 /* Override any gcc2 internal prototype to avoid an error. */
6369 /* We use char because int might match the return type of a gcc2
6370 builtin and then its argument prototype would still apply. */
6377 if { (eval echo configure:6378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6379 eval "ac_cv_lib_$ac_lib_var=yes"
6381 echo "configure: failed program was:" >&5
6382 cat conftest.$ac_ext >&5
6384 eval "ac_cv_lib_$ac_lib_var=no"
6387 LIBS="$ac_save_LIBS"
6390 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6391 echo "$ac_t""yes" 1>&6
6395 echo "$ac_t""no" 1>&6
6401 if test $have_ssleay = yes ; then
6405 cat >> confdefs.h <<\EOF
6406 #define HAVE_SSLEAY 1
6410 if test $need_rsaref = yes; then
6411 cat >> confdefs.h <<\EOF
6412 #define HAVE_RSAREF 1
6416 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
6418 TLS_LIBS="-lssl -lcrypto"
6424 if test $ol_link_tls = yes ; then
6425 cat >> confdefs.h <<\EOF
6433 gethostbyname_r gethostbyaddr_r \
6436 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6437 echo "configure:6438: checking for $ac_func" >&5
6438 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
6439 echo $ac_n "(cached) $ac_c" 1>&6
6441 cat > conftest.$ac_ext <<EOF
6442 #line 6443 "configure"
6443 #include "confdefs.h"
6444 /* System header to define __stub macros and hopefully few prototypes,
6445 which can conflict with char $ac_func(); below. */
6447 /* Override any gcc2 internal prototype to avoid an error. */
6448 /* We use char because int might match the return type of a gcc2
6449 builtin and then its argument prototype would still apply. */
6455 /* The GNU C library defines this for functions which it implements
6456 to always fail with ENOSYS. Some functions are actually named
6457 something starting with __ and the normal name is an alias. */
6458 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6466 if { (eval echo configure:6467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6468 eval "ac_cv_func_$ac_func=yes"
6470 echo "configure: failed program was:" >&5
6471 cat conftest.$ac_ext >&5
6473 eval "ac_cv_func_$ac_func=no"
6478 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6479 echo "$ac_t""yes" 1>&6
6480 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6481 cat >> confdefs.h <<EOF
6482 #define $ac_tr_func 1
6486 echo "$ac_t""no" 1>&6
6491 if test "$ac_cv_func_ctime_r" = no ; then
6492 ol_cv_func_ctime_r_nargs=0
6494 echo $ac_n "checking number of arguments of ctime_r""... $ac_c" 1>&6
6495 echo "configure:6496: checking number of arguments of ctime_r" >&5
6496 if eval "test \"\${ol_cv_func_ctime_r_nargs+set}\" = set"; then
6497 echo $ac_n "(cached) $ac_c" 1>&6
6499 cat > conftest.$ac_ext <<EOF
6500 #line 6501 "configure"
6501 #include "confdefs.h"
6504 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
6507 if { (eval echo configure:6508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6509 ol_cv_func_ctime_r_nargs3=yes
6511 echo "configure: failed program was:" >&5
6512 cat conftest.$ac_ext >&5
6514 ol_cv_func_ctime_r_nargs3=no
6518 cat > conftest.$ac_ext <<EOF
6519 #line 6520 "configure"
6520 #include "confdefs.h"
6523 time_t ti; char *buffer; ctime_r(&ti,buffer);
6526 if { (eval echo configure:6527: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6528 ol_cv_func_ctime_r_nargs2=yes
6530 echo "configure: failed program was:" >&5
6531 cat conftest.$ac_ext >&5
6533 ol_cv_func_ctime_r_nargs2=no
6537 if test $ol_cv_func_ctime_r_nargs3 = yes -a \
6538 $ol_cv_func_ctime_r_nargs2 = no ; then
6540 ol_cv_func_ctime_r_nargs=3
6542 elif test $ol_cv_func_ctime_r_nargs3 = no -a \
6543 $ol_cv_func_ctime_r_nargs2 = yes ; then
6545 ol_cv_func_ctime_r_nargs=2
6548 ol_cv_func_ctime_r_nargs=0
6553 echo "$ac_t""$ol_cv_func_ctime_r_nargs" 1>&6
6555 if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
6556 cat >> confdefs.h <<EOF
6557 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
6564 if test "$ac_cv_func_gethostbyname_r" = yes ; then
6565 echo $ac_n "checking number of arguments of gethostbyname_r""... $ac_c" 1>&6
6566 echo "configure:6567: checking number of arguments of gethostbyname_r" >&5
6567 if eval "test \"\${ol_cv_func_gethostbyname_r_nargs+set}\" = set"; then
6568 echo $ac_n "(cached) $ac_c" 1>&6
6570 cat > conftest.$ac_ext <<EOF
6571 #line 6572 "configure"
6572 #include "confdefs.h"
6573 #include <sys/types.h>
6574 #include <sys/socket.h>
6575 #include <netinet/in.h>
6577 #define BUFSIZE (sizeof(struct hostent)+10)
6579 struct hostent hent; char buffer[BUFSIZE];
6580 int bufsize=BUFSIZE;int h_errno;
6581 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
6582 buffer, bufsize, &h_errno);
6585 if { (eval echo configure:6586: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6587 ol_cv_func_gethostbyname_r_nargs5=yes
6589 echo "configure: failed program was:" >&5
6590 cat conftest.$ac_ext >&5
6592 ol_cv_func_gethostbyname_r_nargs5=no
6596 cat > conftest.$ac_ext <<EOF
6597 #line 6598 "configure"
6598 #include "confdefs.h"
6599 #include <sys/types.h>
6600 #include <sys/socket.h>
6601 #include <netinet/in.h>
6603 #define BUFSIZE (sizeof(struct hostent)+10)
6605 struct hostent hent;struct hostent *rhent;
6606 char buffer[BUFSIZE];
6607 int bufsize=BUFSIZE;int h_errno;
6608 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
6612 if { (eval echo configure:6613: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6614 ol_cv_func_gethostbyname_r_nargs6=yes
6616 echo "configure: failed program was:" >&5
6617 cat conftest.$ac_ext >&5
6619 ol_cv_func_gethostbyname_r_nargs6=no
6623 if test $ol_cv_func_gethostbyname_r_nargs5 = yes -a \
6624 $ol_cv_func_gethostbyname_r_nargs6 = no ; then
6626 ol_cv_func_gethostbyname_r_nargs=5
6628 elif test $ol_cv_func_gethostbyname_r_nargs5 = no -a \
6629 $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
6631 ol_cv_func_gethostbyname_r_nargs=6
6634 ol_cv_func_gethostbyname_r_nargs=0
6639 echo "$ac_t""$ol_cv_func_gethostbyname_r_nargs" 1>&6
6640 if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
6641 cat >> confdefs.h <<EOF
6642 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
6648 ol_cv_func_gethostbyname_r_nargs=0
6651 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
6652 echo $ac_n "checking number of arguments of gethostbyaddr_r""... $ac_c" 1>&6
6653 echo "configure:6654: checking number of arguments of gethostbyaddr_r" >&5
6654 if eval "test \"\${ol_cv_func_gethostbyaddr_r_nargs+set}\" = set"; then
6655 echo $ac_n "(cached) $ac_c" 1>&6
6657 cat > conftest.$ac_ext <<EOF
6658 #line 6659 "configure"
6659 #include "confdefs.h"
6660 #include <sys/types.h>
6661 #include <sys/socket.h>
6662 #include <netinet/in.h>
6664 #define BUFSIZE (sizeof(struct hostent)+10)
6666 struct hostent hent; char buffer[BUFSIZE];
6668 size_t alen=sizeof(struct in_addr);
6669 int bufsize=BUFSIZE;int h_errno;
6670 (void)gethostbyaddr_r( (void *)&(add.s_addr),
6671 alen, AF_INET, &hent, buffer, bufsize, &h_errno);
6674 if { (eval echo configure:6675: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6676 ol_cv_func_gethostbyaddr_r_nargs7=yes
6678 echo "configure: failed program was:" >&5
6679 cat conftest.$ac_ext >&5
6681 ol_cv_func_gethostbyaddr_r_nargs7=no
6685 cat > conftest.$ac_ext <<EOF
6686 #line 6687 "configure"
6687 #include "confdefs.h"
6688 #include <sys/types.h>
6689 #include <sys/socket.h>
6690 #include <netinet/in.h>
6692 #define BUFSIZE (sizeof(struct hostent)+10)
6694 struct hostent hent;
6695 struct hostent *rhent; char buffer[BUFSIZE];
6697 size_t alen=sizeof(struct in_addr);
6698 int bufsize=BUFSIZE;int h_errno;
6699 (void)gethostbyaddr_r( (void *)&(add.s_addr),
6700 alen, AF_INET, &hent, buffer, bufsize,
6704 if { (eval echo configure:6705: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6706 ol_cv_func_gethostbyaddr_r_nargs8=yes
6708 echo "configure: failed program was:" >&5
6709 cat conftest.$ac_ext >&5
6711 ol_cv_func_gethostbyaddr_r_nargs8=no
6715 if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes -a \
6716 $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
6718 ol_cv_func_gethostbyaddr_r_nargs=7
6720 elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no -a \
6721 $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
6723 ol_cv_func_gethostbyaddr_r_nargs=8
6726 ol_cv_func_gethostbyaddr_r_nargs=0
6731 echo "$ac_t""$ol_cv_func_gethostbyaddr_r_nargs" 1>&6
6732 if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
6733 cat >> confdefs.h <<EOF
6734 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
6740 ol_cv_func_gethostbyaddr_r_nargs=0
6743 if test "$ac_cv_func_ctime_r" = yes \
6744 -a "$ol_cv_func_ctime_r_nargs" -ge 2 \
6745 -a "$ol_cv_func_ctime_r_nargs" -le 3 \
6746 -a "$ac_cv_func_gethostbyname_r" = yes \
6747 -a "$ol_cv_func_gethostbyname_r_nargs" -ge 5 \
6748 -a "$ol_cv_func_gethostbyname_r_nargs" -le 6 \
6749 -a "$ac_cv_func_gethostbyaddr_r" = yes \
6750 -a "$ol_cv_func_gethostbyaddr_r_nargs" -ge 5 \
6751 -a "$ol_cv_func_gethostbyaddr_r_nargs" -le 6 \
6754 cat >> confdefs.h <<\EOF
6755 #define LDAP_API_FEATURE_X_OPENLDAP_REENTRANT 1
6762 if test $ol_with_threads = auto -o $ol_with_threads = yes \
6763 -o $ol_with_threads = nt ; then
6766 echo $ac_n "checking for NT Threads""... $ac_c" 1>&6
6767 echo "configure:6768: checking for NT Threads" >&5
6768 if eval "test \"\${ol_cv_nt_threads+set}\" = set"; then
6769 echo $ac_n "(cached) $ac_c" 1>&6
6772 echo $ac_n "checking for _beginthread""... $ac_c" 1>&6
6773 echo "configure:6774: checking for _beginthread" >&5
6774 if eval "test \"\${ac_cv_func__beginthread+set}\" = set"; then
6775 echo $ac_n "(cached) $ac_c" 1>&6
6777 cat > conftest.$ac_ext <<EOF
6778 #line 6779 "configure"
6779 #include "confdefs.h"
6780 /* System header to define __stub macros and hopefully few prototypes,
6781 which can conflict with char _beginthread(); below. */
6783 /* Override any gcc2 internal prototype to avoid an error. */
6784 /* We use char because int might match the return type of a gcc2
6785 builtin and then its argument prototype would still apply. */
6786 char _beginthread();
6791 /* The GNU C library defines this for functions which it implements
6792 to always fail with ENOSYS. Some functions are actually named
6793 something starting with __ and the normal name is an alias. */
6794 #if defined (__stub__beginthread) || defined (__stub____beginthread)
6802 if { (eval echo configure:6803: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6804 eval "ac_cv_func__beginthread=yes"
6806 echo "configure: failed program was:" >&5
6807 cat conftest.$ac_ext >&5
6809 eval "ac_cv_func__beginthread=no"
6814 if eval "test \"`echo '$ac_cv_func_'_beginthread`\" = yes"; then
6815 echo "$ac_t""yes" 1>&6
6816 ol_cv_nt_threads=yes
6818 echo "$ac_t""no" 1>&6
6825 echo "$ac_t""$ol_cv_nt_threads" 1>&6
6827 if test $ol_cv_nt_threads = yes ; then
6828 cat >> confdefs.h <<\EOF
6829 #define HAVE_NT_THREADS 1
6835 if test "$ol_cv_nt_threads" = yes ; then
6837 ol_with_threads=found
6838 ol_with_yielding_select=yes
6840 cat >> confdefs.h <<\EOF
6841 #define HAVE_NT_SERVICE_MANAGER 1
6844 cat >> confdefs.h <<\EOF
6845 #define HAVE_NT_EVENT_LOG 1
6850 if test $ol_with_threads = nt ; then
6851 { echo "configure: error: could not locate NT Threads" 1>&2; exit 1; }
6855 if test $ol_with_threads = auto -o $ol_with_threads = yes \
6856 -o $ol_with_threads = posix ; then
6858 for ac_hdr in pthread.h
6860 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6861 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6862 echo "configure:6863: checking for $ac_hdr" >&5
6863 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6864 echo $ac_n "(cached) $ac_c" 1>&6
6866 cat > conftest.$ac_ext <<EOF
6867 #line 6868 "configure"
6868 #include "confdefs.h"
6871 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6872 { (eval echo configure:6873: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6873 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6874 if test -z "$ac_err"; then
6876 eval "ac_cv_header_$ac_safe=yes"
6879 echo "configure: failed program was:" >&5
6880 cat conftest.$ac_ext >&5
6882 eval "ac_cv_header_$ac_safe=no"
6886 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6887 echo "$ac_t""yes" 1>&6
6888 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6889 cat >> confdefs.h <<EOF
6890 #define $ac_tr_hdr 1
6894 echo "$ac_t""no" 1>&6
6899 if test $ac_cv_header_pthread_h = yes ; then
6900 echo $ac_n "checking POSIX thread version""... $ac_c" 1>&6
6901 echo "configure:6902: checking POSIX thread version" >&5
6902 if eval "test \"\${ol_cv_pthread_version+set}\" = set"; then
6903 echo $ac_n "(cached) $ac_c" 1>&6
6906 cat > conftest.$ac_ext <<EOF
6907 #line 6908 "configure"
6908 #include "confdefs.h"
6910 # include <pthread.h>
6911 /* this check could be improved */
6912 # ifdef PTHREAD_ONCE_INIT
6913 pthread_version_final;
6917 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6918 egrep "pthread_version_final" >/dev/null 2>&1; then
6920 ol_pthread_final=yes
6928 cat > conftest.$ac_ext <<EOF
6929 #line 6930 "configure"
6930 #include "confdefs.h"
6932 # include <pthread.h>
6933 /* this check could be improved */
6934 # ifdef pthread_once_init
6935 pthread_version_draft4;
6939 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6940 egrep "pthread_version_draft4" >/dev/null 2>&1; then
6942 ol_pthread_draft4=yes
6945 ol_pthread_draft4=no
6950 if test $ol_pthread_final = yes -a $ol_pthread_draft4 = no; then
6951 ol_cv_pthread_version=final
6952 elif test $ol_pthread_final = no -a $ol_pthread_draft4 = yes; then
6953 ol_cv_pthread_version=draft4
6955 ol_cv_pthread_version=unknown
6960 echo "$ac_t""$ol_cv_pthread_version" 1>&6
6963 if test $ol_cv_pthread_version = final ; then
6964 cat >> confdefs.h <<\EOF
6965 #define HAVE_PTHREADS_FINAL 1
6968 elif test $ol_cv_pthread_version = draft4 ; then
6969 cat >> confdefs.h <<\EOF
6970 #define HAVE_PTHREADS_D4 1
6974 { echo "configure: error: unknown pthread version" 1>&2; exit 1; }
6977 # consider threads found
6978 ol_with_threads=found
6981 echo $ac_n "checking for LinuxThreads pthread.h""... $ac_c" 1>&6
6982 echo "configure:6983: checking for LinuxThreads pthread.h" >&5
6983 if eval "test \"\${ol_cv_header_linux_threads+set}\" = set"; then
6984 echo $ac_n "(cached) $ac_c" 1>&6
6986 cat > conftest.$ac_ext <<EOF
6987 #line 6988 "configure"
6988 #include "confdefs.h"
6989 #include <pthread.h>
6991 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6992 egrep "pthread_kill_other_threads_np" >/dev/null 2>&1; then
6994 ol_cv_header_linux_threads=yes
6997 ol_cv_header_linux_threads=no
7004 echo "$ac_t""$ol_cv_header_linux_threads" 1>&6
7005 if test $ol_cv_header_linux_threads = yes; then
7006 cat >> confdefs.h <<\EOF
7007 #define HAVE_LINUX_THREADS 1
7013 echo $ac_n "checking for GNU Pth pthread.h""... $ac_c" 1>&6
7014 echo "configure:7015: checking for GNU Pth pthread.h" >&5
7015 if eval "test \"\${ol_cv_header_gnu_pth_pthread_h+set}\" = set"; then
7016 echo $ac_n "(cached) $ac_c" 1>&6
7018 cat > conftest.$ac_ext <<EOF
7019 #line 7020 "configure"
7020 #include "confdefs.h"
7021 #include <pthread.h>
7022 #ifdef _POSIX_THREAD_IS_GNU_PTH
7027 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7028 egrep "__gnu_pth__" >/dev/null 2>&1; then
7030 ol_cv_header_gnu_pth_pthread_h=yes
7033 ol_cv_header_gnu_pth_pthread_h=no
7040 echo "$ac_t""$ol_cv_header_gnu_pth_pthread_h" 1>&6
7043 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
7044 for ac_hdr in sched.h
7046 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7047 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7048 echo "configure:7049: checking for $ac_hdr" >&5
7049 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
7050 echo $ac_n "(cached) $ac_c" 1>&6
7052 cat > conftest.$ac_ext <<EOF
7053 #line 7054 "configure"
7054 #include "confdefs.h"
7057 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7058 { (eval echo configure:7059: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7059 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7060 if test -z "$ac_err"; then
7062 eval "ac_cv_header_$ac_safe=yes"
7065 echo "configure: failed program was:" >&5
7066 cat conftest.$ac_ext >&5
7068 eval "ac_cv_header_$ac_safe=no"
7072 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7073 echo "$ac_t""yes" 1>&6
7074 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7075 cat >> confdefs.h <<EOF
7076 #define $ac_tr_hdr 1
7080 echo "$ac_t""no" 1>&6
7087 echo $ac_n "checking for pthread_create in default libraries""... $ac_c" 1>&6
7088 echo "configure:7089: checking for pthread_create in default libraries" >&5
7089 if eval "test \"\${ol_cv_pthread_create+set}\" = set"; then
7090 echo $ac_n "(cached) $ac_c" 1>&6
7093 if test "$cross_compiling" = yes; then
7094 cat > conftest.$ac_ext <<EOF
7095 #line 7096 "configure"
7096 #include "confdefs.h"
7097 /* pthread test headers */
7098 #include <pthread.h>
7100 #define NULL (void*)0
7103 static void *task(p)
7106 return (void *) (p == NULL);
7111 /* pthread test function */
7114 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7115 /* This system (e.g. AIX) defaults detached; must override */
7116 pthread_attr_t attr;
7118 status = pthread_attr_init(&attr);
7119 if( status ) exit( status );
7121 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7122 if( status ) exit( status );
7126 #if HAVE_PTHREADS_D4
7127 #define ATTR pthread_attr_default
7132 /* make sure pthread_create() isn't just a stub */
7133 status = pthread_create(&t, ATTR, task, NULL);
7134 if( status ) exit( status );
7136 /* make sure pthread_detach() isn't just a stub */
7137 #if HAVE_PTHREADS_D4
7138 status = pthread_detach( &t );
7140 status = pthread_detach( t );
7143 #ifdef HAVE_LINUX_THREADS
7144 pthread_kill_other_threads_np();
7151 if { (eval echo configure:7152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7153 ol_cv_pthread_create=yes
7155 echo "configure: failed program was:" >&5
7156 cat conftest.$ac_ext >&5
7158 ol_cv_pthread_create=no
7162 cat > conftest.$ac_ext <<EOF
7163 #line 7164 "configure"
7164 #include "confdefs.h"
7165 /* pthread test headers */
7166 #include <pthread.h>
7168 #define NULL (void*)0
7171 static void *task(p)
7174 return (void *) (p == NULL);
7178 int main(argc, argv)
7183 /* pthread test function */
7186 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7187 /* This system (e.g. AIX) defaults detached; must override */
7188 pthread_attr_t attr;
7190 status = pthread_attr_init(&attr);
7191 if( status ) exit( status );
7193 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7194 if( status ) exit( status );
7198 #if HAVE_PTHREADS_D4
7199 #define ATTR pthread_attr_default
7204 /* make sure pthread_create() isn't just a stub */
7205 status = pthread_create(&t, ATTR, task, NULL);
7206 if( status ) exit( status );
7208 /* make sure pthread_detach() isn't just a stub */
7209 #if HAVE_PTHREADS_D4
7210 status = pthread_detach( &t );
7212 status = pthread_detach( t );
7215 #ifdef HAVE_LINUX_THREADS
7216 pthread_kill_other_threads_np();
7224 if { (eval echo configure:7225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7226 ol_cv_pthread_create=yes
7228 echo "configure: failed program was:" >&5
7229 cat conftest.$ac_ext >&5
7231 ol_cv_pthread_create=no
7238 echo "$ac_t""$ol_cv_pthread_create" 1>&6
7240 if test $ol_cv_pthread_create != no ; then
7241 ol_link_threads=posix
7245 # Pthread try link: -kthread (ol_cv_pthread_kthread)
7246 if test "$ol_link_threads" = no ; then
7248 echo $ac_n "checking for pthread link with -kthread""... $ac_c" 1>&6
7249 echo "configure:7250: checking for pthread link with -kthread" >&5
7250 if eval "test \"\${ol_cv_pthread_kthread+set}\" = set"; then
7251 echo $ac_n "(cached) $ac_c" 1>&6
7256 LIBS="-kthread $LIBS"
7258 if test "$cross_compiling" = yes; then
7259 cat > conftest.$ac_ext <<EOF
7260 #line 7261 "configure"
7261 #include "confdefs.h"
7262 /* pthread test headers */
7263 #include <pthread.h>
7265 #define NULL (void*)0
7268 static void *task(p)
7271 return (void *) (p == NULL);
7276 /* pthread test function */
7279 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7280 /* This system (e.g. AIX) defaults detached; must override */
7281 pthread_attr_t attr;
7283 status = pthread_attr_init(&attr);
7284 if( status ) exit( status );
7286 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7287 if( status ) exit( status );
7291 #if HAVE_PTHREADS_D4
7292 #define ATTR pthread_attr_default
7297 /* make sure pthread_create() isn't just a stub */
7298 status = pthread_create(&t, ATTR, task, NULL);
7299 if( status ) exit( status );
7301 /* make sure pthread_detach() isn't just a stub */
7302 #if HAVE_PTHREADS_D4
7303 status = pthread_detach( &t );
7305 status = pthread_detach( t );
7308 #ifdef HAVE_LINUX_THREADS
7309 pthread_kill_other_threads_np();
7316 if { (eval echo configure:7317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7318 ol_cv_pthread_kthread=yes
7320 echo "configure: failed program was:" >&5
7321 cat conftest.$ac_ext >&5
7323 ol_cv_pthread_kthread=no
7327 cat > conftest.$ac_ext <<EOF
7328 #line 7329 "configure"
7329 #include "confdefs.h"
7330 /* pthread test headers */
7331 #include <pthread.h>
7333 #define NULL (void*)0
7336 static void *task(p)
7339 return (void *) (p == NULL);
7343 int main(argc, argv)
7348 /* pthread test function */
7351 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7352 /* This system (e.g. AIX) defaults detached; must override */
7353 pthread_attr_t attr;
7355 status = pthread_attr_init(&attr);
7356 if( status ) exit( status );
7358 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7359 if( status ) exit( status );
7363 #if HAVE_PTHREADS_D4
7364 #define ATTR pthread_attr_default
7369 /* make sure pthread_create() isn't just a stub */
7370 status = pthread_create(&t, ATTR, task, NULL);
7371 if( status ) exit( status );
7373 /* make sure pthread_detach() isn't just a stub */
7374 #if HAVE_PTHREADS_D4
7375 status = pthread_detach( &t );
7377 status = pthread_detach( t );
7380 #ifdef HAVE_LINUX_THREADS
7381 pthread_kill_other_threads_np();
7389 if { (eval echo configure:7390: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7391 ol_cv_pthread_kthread=yes
7393 echo "configure: failed program was:" >&5
7394 cat conftest.$ac_ext >&5
7396 ol_cv_pthread_kthread=no
7407 echo "$ac_t""$ol_cv_pthread_kthread" 1>&6
7409 if test $ol_cv_pthread_kthread = yes ; then
7410 ol_link_pthreads="-kthread"
7411 ol_link_threads=posix
7415 # Pthread try link: -pthread (ol_cv_pthread_pthread)
7416 if test "$ol_link_threads" = no ; then
7418 echo $ac_n "checking for pthread link with -pthread""... $ac_c" 1>&6
7419 echo "configure:7420: checking for pthread link with -pthread" >&5
7420 if eval "test \"\${ol_cv_pthread_pthread+set}\" = set"; then
7421 echo $ac_n "(cached) $ac_c" 1>&6
7426 LIBS="-pthread $LIBS"
7428 if test "$cross_compiling" = yes; then
7429 cat > conftest.$ac_ext <<EOF
7430 #line 7431 "configure"
7431 #include "confdefs.h"
7432 /* pthread test headers */
7433 #include <pthread.h>
7435 #define NULL (void*)0
7438 static void *task(p)
7441 return (void *) (p == NULL);
7446 /* pthread test function */
7449 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7450 /* This system (e.g. AIX) defaults detached; must override */
7451 pthread_attr_t attr;
7453 status = pthread_attr_init(&attr);
7454 if( status ) exit( status );
7456 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7457 if( status ) exit( status );
7461 #if HAVE_PTHREADS_D4
7462 #define ATTR pthread_attr_default
7467 /* make sure pthread_create() isn't just a stub */
7468 status = pthread_create(&t, ATTR, task, NULL);
7469 if( status ) exit( status );
7471 /* make sure pthread_detach() isn't just a stub */
7472 #if HAVE_PTHREADS_D4
7473 status = pthread_detach( &t );
7475 status = pthread_detach( t );
7478 #ifdef HAVE_LINUX_THREADS
7479 pthread_kill_other_threads_np();
7486 if { (eval echo configure:7487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7488 ol_cv_pthread_pthread=yes
7490 echo "configure: failed program was:" >&5
7491 cat conftest.$ac_ext >&5
7493 ol_cv_pthread_pthread=no
7497 cat > conftest.$ac_ext <<EOF
7498 #line 7499 "configure"
7499 #include "confdefs.h"
7500 /* pthread test headers */
7501 #include <pthread.h>
7503 #define NULL (void*)0
7506 static void *task(p)
7509 return (void *) (p == NULL);
7513 int main(argc, argv)
7518 /* pthread test function */
7521 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7522 /* This system (e.g. AIX) defaults detached; must override */
7523 pthread_attr_t attr;
7525 status = pthread_attr_init(&attr);
7526 if( status ) exit( status );
7528 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7529 if( status ) exit( status );
7533 #if HAVE_PTHREADS_D4
7534 #define ATTR pthread_attr_default
7539 /* make sure pthread_create() isn't just a stub */
7540 status = pthread_create(&t, ATTR, task, NULL);
7541 if( status ) exit( status );
7543 /* make sure pthread_detach() isn't just a stub */
7544 #if HAVE_PTHREADS_D4
7545 status = pthread_detach( &t );
7547 status = pthread_detach( t );
7550 #ifdef HAVE_LINUX_THREADS
7551 pthread_kill_other_threads_np();
7559 if { (eval echo configure:7560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7561 ol_cv_pthread_pthread=yes
7563 echo "configure: failed program was:" >&5
7564 cat conftest.$ac_ext >&5
7566 ol_cv_pthread_pthread=no
7577 echo "$ac_t""$ol_cv_pthread_pthread" 1>&6
7579 if test $ol_cv_pthread_pthread = yes ; then
7580 ol_link_pthreads="-pthread"
7581 ol_link_threads=posix
7585 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
7586 if test "$ol_link_threads" = no ; then
7588 echo $ac_n "checking for pthread link with -pthreads""... $ac_c" 1>&6
7589 echo "configure:7590: checking for pthread link with -pthreads" >&5
7590 if eval "test \"\${ol_cv_pthread_pthreads+set}\" = set"; then
7591 echo $ac_n "(cached) $ac_c" 1>&6
7596 LIBS="-pthreads $LIBS"
7598 if test "$cross_compiling" = yes; then
7599 cat > conftest.$ac_ext <<EOF
7600 #line 7601 "configure"
7601 #include "confdefs.h"
7602 /* pthread test headers */
7603 #include <pthread.h>
7605 #define NULL (void*)0
7608 static void *task(p)
7611 return (void *) (p == NULL);
7616 /* pthread test function */
7619 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7620 /* This system (e.g. AIX) defaults detached; must override */
7621 pthread_attr_t attr;
7623 status = pthread_attr_init(&attr);
7624 if( status ) exit( status );
7626 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7627 if( status ) exit( status );
7631 #if HAVE_PTHREADS_D4
7632 #define ATTR pthread_attr_default
7637 /* make sure pthread_create() isn't just a stub */
7638 status = pthread_create(&t, ATTR, task, NULL);
7639 if( status ) exit( status );
7641 /* make sure pthread_detach() isn't just a stub */
7642 #if HAVE_PTHREADS_D4
7643 status = pthread_detach( &t );
7645 status = pthread_detach( t );
7648 #ifdef HAVE_LINUX_THREADS
7649 pthread_kill_other_threads_np();
7656 if { (eval echo configure:7657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7658 ol_cv_pthread_pthreads=yes
7660 echo "configure: failed program was:" >&5
7661 cat conftest.$ac_ext >&5
7663 ol_cv_pthread_pthreads=no
7667 cat > conftest.$ac_ext <<EOF
7668 #line 7669 "configure"
7669 #include "confdefs.h"
7670 /* pthread test headers */
7671 #include <pthread.h>
7673 #define NULL (void*)0
7676 static void *task(p)
7679 return (void *) (p == NULL);
7683 int main(argc, argv)
7688 /* pthread test function */
7691 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7692 /* This system (e.g. AIX) defaults detached; must override */
7693 pthread_attr_t attr;
7695 status = pthread_attr_init(&attr);
7696 if( status ) exit( status );
7698 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7699 if( status ) exit( status );
7703 #if HAVE_PTHREADS_D4
7704 #define ATTR pthread_attr_default
7709 /* make sure pthread_create() isn't just a stub */
7710 status = pthread_create(&t, ATTR, task, NULL);
7711 if( status ) exit( status );
7713 /* make sure pthread_detach() isn't just a stub */
7714 #if HAVE_PTHREADS_D4
7715 status = pthread_detach( &t );
7717 status = pthread_detach( t );
7720 #ifdef HAVE_LINUX_THREADS
7721 pthread_kill_other_threads_np();
7729 if { (eval echo configure:7730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7731 ol_cv_pthread_pthreads=yes
7733 echo "configure: failed program was:" >&5
7734 cat conftest.$ac_ext >&5
7736 ol_cv_pthread_pthreads=no
7747 echo "$ac_t""$ol_cv_pthread_pthreads" 1>&6
7749 if test $ol_cv_pthread_pthreads = yes ; then
7750 ol_link_pthreads="-pthreads"
7751 ol_link_threads=posix
7755 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
7756 if test "$ol_link_threads" = no ; then
7758 echo $ac_n "checking for pthread link with -mthreads""... $ac_c" 1>&6
7759 echo "configure:7760: checking for pthread link with -mthreads" >&5
7760 if eval "test \"\${ol_cv_pthread_mthreads+set}\" = set"; then
7761 echo $ac_n "(cached) $ac_c" 1>&6
7766 LIBS="-mthreads $LIBS"
7768 if test "$cross_compiling" = yes; then
7769 cat > conftest.$ac_ext <<EOF
7770 #line 7771 "configure"
7771 #include "confdefs.h"
7772 /* pthread test headers */
7773 #include <pthread.h>
7775 #define NULL (void*)0
7778 static void *task(p)
7781 return (void *) (p == NULL);
7786 /* pthread test function */
7789 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7790 /* This system (e.g. AIX) defaults detached; must override */
7791 pthread_attr_t attr;
7793 status = pthread_attr_init(&attr);
7794 if( status ) exit( status );
7796 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7797 if( status ) exit( status );
7801 #if HAVE_PTHREADS_D4
7802 #define ATTR pthread_attr_default
7807 /* make sure pthread_create() isn't just a stub */
7808 status = pthread_create(&t, ATTR, task, NULL);
7809 if( status ) exit( status );
7811 /* make sure pthread_detach() isn't just a stub */
7812 #if HAVE_PTHREADS_D4
7813 status = pthread_detach( &t );
7815 status = pthread_detach( t );
7818 #ifdef HAVE_LINUX_THREADS
7819 pthread_kill_other_threads_np();
7826 if { (eval echo configure:7827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7828 ol_cv_pthread_mthreads=yes
7830 echo "configure: failed program was:" >&5
7831 cat conftest.$ac_ext >&5
7833 ol_cv_pthread_mthreads=no
7837 cat > conftest.$ac_ext <<EOF
7838 #line 7839 "configure"
7839 #include "confdefs.h"
7840 /* pthread test headers */
7841 #include <pthread.h>
7843 #define NULL (void*)0
7846 static void *task(p)
7849 return (void *) (p == NULL);
7853 int main(argc, argv)
7858 /* pthread test function */
7861 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7862 /* This system (e.g. AIX) defaults detached; must override */
7863 pthread_attr_t attr;
7865 status = pthread_attr_init(&attr);
7866 if( status ) exit( status );
7868 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7869 if( status ) exit( status );
7873 #if HAVE_PTHREADS_D4
7874 #define ATTR pthread_attr_default
7879 /* make sure pthread_create() isn't just a stub */
7880 status = pthread_create(&t, ATTR, task, NULL);
7881 if( status ) exit( status );
7883 /* make sure pthread_detach() isn't just a stub */
7884 #if HAVE_PTHREADS_D4
7885 status = pthread_detach( &t );
7887 status = pthread_detach( t );
7890 #ifdef HAVE_LINUX_THREADS
7891 pthread_kill_other_threads_np();
7899 if { (eval echo configure:7900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7901 ol_cv_pthread_mthreads=yes
7903 echo "configure: failed program was:" >&5
7904 cat conftest.$ac_ext >&5
7906 ol_cv_pthread_mthreads=no
7917 echo "$ac_t""$ol_cv_pthread_mthreads" 1>&6
7919 if test $ol_cv_pthread_mthreads = yes ; then
7920 ol_link_pthreads="-mthreads"
7921 ol_link_threads=posix
7925 # Pthread try link: -thread (ol_cv_pthread_thread)
7926 if test "$ol_link_threads" = no ; then
7928 echo $ac_n "checking for pthread link with -thread""... $ac_c" 1>&6
7929 echo "configure:7930: checking for pthread link with -thread" >&5
7930 if eval "test \"\${ol_cv_pthread_thread+set}\" = set"; then
7931 echo $ac_n "(cached) $ac_c" 1>&6
7936 LIBS="-thread $LIBS"
7938 if test "$cross_compiling" = yes; then
7939 cat > conftest.$ac_ext <<EOF
7940 #line 7941 "configure"
7941 #include "confdefs.h"
7942 /* pthread test headers */
7943 #include <pthread.h>
7945 #define NULL (void*)0
7948 static void *task(p)
7951 return (void *) (p == NULL);
7956 /* pthread test function */
7959 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7960 /* This system (e.g. AIX) defaults detached; must override */
7961 pthread_attr_t attr;
7963 status = pthread_attr_init(&attr);
7964 if( status ) exit( status );
7966 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7967 if( status ) exit( status );
7971 #if HAVE_PTHREADS_D4
7972 #define ATTR pthread_attr_default
7977 /* make sure pthread_create() isn't just a stub */
7978 status = pthread_create(&t, ATTR, task, NULL);
7979 if( status ) exit( status );
7981 /* make sure pthread_detach() isn't just a stub */
7982 #if HAVE_PTHREADS_D4
7983 status = pthread_detach( &t );
7985 status = pthread_detach( t );
7988 #ifdef HAVE_LINUX_THREADS
7989 pthread_kill_other_threads_np();
7996 if { (eval echo configure:7997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7998 ol_cv_pthread_thread=yes
8000 echo "configure: failed program was:" >&5
8001 cat conftest.$ac_ext >&5
8003 ol_cv_pthread_thread=no
8007 cat > conftest.$ac_ext <<EOF
8008 #line 8009 "configure"
8009 #include "confdefs.h"
8010 /* pthread test headers */
8011 #include <pthread.h>
8013 #define NULL (void*)0
8016 static void *task(p)
8019 return (void *) (p == NULL);
8023 int main(argc, argv)
8028 /* pthread test function */
8031 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8032 /* This system (e.g. AIX) defaults detached; must override */
8033 pthread_attr_t attr;
8035 status = pthread_attr_init(&attr);
8036 if( status ) exit( status );
8038 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8039 if( status ) exit( status );
8043 #if HAVE_PTHREADS_D4
8044 #define ATTR pthread_attr_default
8049 /* make sure pthread_create() isn't just a stub */
8050 status = pthread_create(&t, ATTR, task, NULL);
8051 if( status ) exit( status );
8053 /* make sure pthread_detach() isn't just a stub */
8054 #if HAVE_PTHREADS_D4
8055 status = pthread_detach( &t );
8057 status = pthread_detach( t );
8060 #ifdef HAVE_LINUX_THREADS
8061 pthread_kill_other_threads_np();
8069 if { (eval echo configure:8070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8071 ol_cv_pthread_thread=yes
8073 echo "configure: failed program was:" >&5
8074 cat conftest.$ac_ext >&5
8076 ol_cv_pthread_thread=no
8087 echo "$ac_t""$ol_cv_pthread_thread" 1>&6
8089 if test $ol_cv_pthread_thread = yes ; then
8090 ol_link_pthreads="-thread"
8091 ol_link_threads=posix
8096 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
8097 if test "$ol_link_threads" = no ; then
8098 # try -lpthread -lmach -lexc -lc_r
8099 echo $ac_n "checking for pthread link with -lpthread -lmach -lexc -lc_r""... $ac_c" 1>&6
8100 echo "configure:8101: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
8101 if eval "test \"\${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}\" = set"; then
8102 echo $ac_n "(cached) $ac_c" 1>&6
8107 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
8109 if test "$cross_compiling" = yes; then
8110 cat > conftest.$ac_ext <<EOF
8111 #line 8112 "configure"
8112 #include "confdefs.h"
8113 /* pthread test headers */
8114 #include <pthread.h>
8116 #define NULL (void*)0
8119 static void *task(p)
8122 return (void *) (p == NULL);
8127 /* pthread test function */
8130 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8131 /* This system (e.g. AIX) defaults detached; must override */
8132 pthread_attr_t attr;
8134 status = pthread_attr_init(&attr);
8135 if( status ) exit( status );
8137 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8138 if( status ) exit( status );
8142 #if HAVE_PTHREADS_D4
8143 #define ATTR pthread_attr_default
8148 /* make sure pthread_create() isn't just a stub */
8149 status = pthread_create(&t, ATTR, task, NULL);
8150 if( status ) exit( status );
8152 /* make sure pthread_detach() isn't just a stub */
8153 #if HAVE_PTHREADS_D4
8154 status = pthread_detach( &t );
8156 status = pthread_detach( t );
8159 #ifdef HAVE_LINUX_THREADS
8160 pthread_kill_other_threads_np();
8167 if { (eval echo configure:8168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8169 ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
8171 echo "configure: failed program was:" >&5
8172 cat conftest.$ac_ext >&5
8174 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
8178 cat > conftest.$ac_ext <<EOF
8179 #line 8180 "configure"
8180 #include "confdefs.h"
8181 /* pthread test headers */
8182 #include <pthread.h>
8184 #define NULL (void*)0
8187 static void *task(p)
8190 return (void *) (p == NULL);
8194 int main(argc, argv)
8199 /* pthread test function */
8202 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8203 /* This system (e.g. AIX) defaults detached; must override */
8204 pthread_attr_t attr;
8206 status = pthread_attr_init(&attr);
8207 if( status ) exit( status );
8209 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8210 if( status ) exit( status );
8214 #if HAVE_PTHREADS_D4
8215 #define ATTR pthread_attr_default
8220 /* make sure pthread_create() isn't just a stub */
8221 status = pthread_create(&t, ATTR, task, NULL);
8222 if( status ) exit( status );
8224 /* make sure pthread_detach() isn't just a stub */
8225 #if HAVE_PTHREADS_D4
8226 status = pthread_detach( &t );
8228 status = pthread_detach( t );
8231 #ifdef HAVE_LINUX_THREADS
8232 pthread_kill_other_threads_np();
8240 if { (eval echo configure:8241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8242 ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
8244 echo "configure: failed program was:" >&5
8245 cat conftest.$ac_ext >&5
8247 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
8258 echo "$ac_t""$ol_cv_pthread_lpthread_lmach_lexc_lc_r" 1>&6
8260 if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
8261 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
8262 ol_link_threads=posix
8266 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
8267 if test "$ol_link_threads" = no ; then
8268 # try -lpthread -lmach -lexc
8269 echo $ac_n "checking for pthread link with -lpthread -lmach -lexc""... $ac_c" 1>&6
8270 echo "configure:8271: checking for pthread link with -lpthread -lmach -lexc" >&5
8271 if eval "test \"\${ol_cv_pthread_lpthread_lmach_lexc+set}\" = set"; then
8272 echo $ac_n "(cached) $ac_c" 1>&6
8277 LIBS="-lpthread -lmach -lexc $LIBS"
8279 if test "$cross_compiling" = yes; then
8280 cat > conftest.$ac_ext <<EOF
8281 #line 8282 "configure"
8282 #include "confdefs.h"
8283 /* pthread test headers */
8284 #include <pthread.h>
8286 #define NULL (void*)0
8289 static void *task(p)
8292 return (void *) (p == NULL);
8297 /* pthread test function */
8300 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8301 /* This system (e.g. AIX) defaults detached; must override */
8302 pthread_attr_t attr;
8304 status = pthread_attr_init(&attr);
8305 if( status ) exit( status );
8307 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8308 if( status ) exit( status );
8312 #if HAVE_PTHREADS_D4
8313 #define ATTR pthread_attr_default
8318 /* make sure pthread_create() isn't just a stub */
8319 status = pthread_create(&t, ATTR, task, NULL);
8320 if( status ) exit( status );
8322 /* make sure pthread_detach() isn't just a stub */
8323 #if HAVE_PTHREADS_D4
8324 status = pthread_detach( &t );
8326 status = pthread_detach( t );
8329 #ifdef HAVE_LINUX_THREADS
8330 pthread_kill_other_threads_np();
8337 if { (eval echo configure:8338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8339 ol_cv_pthread_lpthread_lmach_lexc=yes
8341 echo "configure: failed program was:" >&5
8342 cat conftest.$ac_ext >&5
8344 ol_cv_pthread_lpthread_lmach_lexc=no
8348 cat > conftest.$ac_ext <<EOF
8349 #line 8350 "configure"
8350 #include "confdefs.h"
8351 /* pthread test headers */
8352 #include <pthread.h>
8354 #define NULL (void*)0
8357 static void *task(p)
8360 return (void *) (p == NULL);
8364 int main(argc, argv)
8369 /* pthread test function */
8372 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8373 /* This system (e.g. AIX) defaults detached; must override */
8374 pthread_attr_t attr;
8376 status = pthread_attr_init(&attr);
8377 if( status ) exit( status );
8379 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8380 if( status ) exit( status );
8384 #if HAVE_PTHREADS_D4
8385 #define ATTR pthread_attr_default
8390 /* make sure pthread_create() isn't just a stub */
8391 status = pthread_create(&t, ATTR, task, NULL);
8392 if( status ) exit( status );
8394 /* make sure pthread_detach() isn't just a stub */
8395 #if HAVE_PTHREADS_D4
8396 status = pthread_detach( &t );
8398 status = pthread_detach( t );
8401 #ifdef HAVE_LINUX_THREADS
8402 pthread_kill_other_threads_np();
8410 if { (eval echo configure:8411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8412 ol_cv_pthread_lpthread_lmach_lexc=yes
8414 echo "configure: failed program was:" >&5
8415 cat conftest.$ac_ext >&5
8417 ol_cv_pthread_lpthread_lmach_lexc=no
8428 echo "$ac_t""$ol_cv_pthread_lpthread_lmach_lexc" 1>&6
8430 if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
8431 ol_link_pthreads="-lpthread -lmach -lexc"
8432 ol_link_threads=posix
8437 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
8438 if test "$ol_link_threads" = no ; then
8439 # try -lpthread -Wl,-woff,85
8440 echo $ac_n "checking for pthread link with -lpthread -Wl,-woff,85""... $ac_c" 1>&6
8441 echo "configure:8442: checking for pthread link with -lpthread -Wl,-woff,85" >&5
8442 if eval "test \"\${ol_cv_pthread_lib_lpthread_woff+set}\" = set"; then
8443 echo $ac_n "(cached) $ac_c" 1>&6
8448 LIBS="-lpthread -Wl,-woff,85 $LIBS"
8450 if test "$cross_compiling" = yes; then
8451 cat > conftest.$ac_ext <<EOF
8452 #line 8453 "configure"
8453 #include "confdefs.h"
8454 /* pthread test headers */
8455 #include <pthread.h>
8457 #define NULL (void*)0
8460 static void *task(p)
8463 return (void *) (p == NULL);
8468 /* pthread test function */
8471 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8472 /* This system (e.g. AIX) defaults detached; must override */
8473 pthread_attr_t attr;
8475 status = pthread_attr_init(&attr);
8476 if( status ) exit( status );
8478 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8479 if( status ) exit( status );
8483 #if HAVE_PTHREADS_D4
8484 #define ATTR pthread_attr_default
8489 /* make sure pthread_create() isn't just a stub */
8490 status = pthread_create(&t, ATTR, task, NULL);
8491 if( status ) exit( status );
8493 /* make sure pthread_detach() isn't just a stub */
8494 #if HAVE_PTHREADS_D4
8495 status = pthread_detach( &t );
8497 status = pthread_detach( t );
8500 #ifdef HAVE_LINUX_THREADS
8501 pthread_kill_other_threads_np();
8508 if { (eval echo configure:8509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8510 ol_cv_pthread_lib_lpthread_woff=yes
8512 echo "configure: failed program was:" >&5
8513 cat conftest.$ac_ext >&5
8515 ol_cv_pthread_lib_lpthread_woff=no
8519 cat > conftest.$ac_ext <<EOF
8520 #line 8521 "configure"
8521 #include "confdefs.h"
8522 /* pthread test headers */
8523 #include <pthread.h>
8525 #define NULL (void*)0
8528 static void *task(p)
8531 return (void *) (p == NULL);
8535 int main(argc, argv)
8540 /* pthread test function */
8543 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8544 /* This system (e.g. AIX) defaults detached; must override */
8545 pthread_attr_t attr;
8547 status = pthread_attr_init(&attr);
8548 if( status ) exit( status );
8550 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8551 if( status ) exit( status );
8555 #if HAVE_PTHREADS_D4
8556 #define ATTR pthread_attr_default
8561 /* make sure pthread_create() isn't just a stub */
8562 status = pthread_create(&t, ATTR, task, NULL);
8563 if( status ) exit( status );
8565 /* make sure pthread_detach() isn't just a stub */
8566 #if HAVE_PTHREADS_D4
8567 status = pthread_detach( &t );
8569 status = pthread_detach( t );
8572 #ifdef HAVE_LINUX_THREADS
8573 pthread_kill_other_threads_np();
8581 if { (eval echo configure:8582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8583 ol_cv_pthread_lib_lpthread_woff=yes
8585 echo "configure: failed program was:" >&5
8586 cat conftest.$ac_ext >&5
8588 ol_cv_pthread_lib_lpthread_woff=no
8599 echo "$ac_t""$ol_cv_pthread_lib_lpthread_woff" 1>&6
8601 if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
8602 ol_link_pthreads="-lpthread -Wl,-woff,85"
8603 ol_link_threads=posix
8608 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
8609 if test "$ol_link_threads" = no ; then
8611 echo $ac_n "checking for pthread link with -lpthread""... $ac_c" 1>&6
8612 echo "configure:8613: checking for pthread link with -lpthread" >&5
8613 if eval "test \"\${ol_cv_pthread_lpthread+set}\" = set"; then
8614 echo $ac_n "(cached) $ac_c" 1>&6
8619 LIBS="-lpthread $LIBS"
8621 if test "$cross_compiling" = yes; then
8622 cat > conftest.$ac_ext <<EOF
8623 #line 8624 "configure"
8624 #include "confdefs.h"
8625 /* pthread test headers */
8626 #include <pthread.h>
8628 #define NULL (void*)0
8631 static void *task(p)
8634 return (void *) (p == NULL);
8639 /* pthread test function */
8642 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8643 /* This system (e.g. AIX) defaults detached; must override */
8644 pthread_attr_t attr;
8646 status = pthread_attr_init(&attr);
8647 if( status ) exit( status );
8649 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8650 if( status ) exit( status );
8654 #if HAVE_PTHREADS_D4
8655 #define ATTR pthread_attr_default
8660 /* make sure pthread_create() isn't just a stub */
8661 status = pthread_create(&t, ATTR, task, NULL);
8662 if( status ) exit( status );
8664 /* make sure pthread_detach() isn't just a stub */
8665 #if HAVE_PTHREADS_D4
8666 status = pthread_detach( &t );
8668 status = pthread_detach( t );
8671 #ifdef HAVE_LINUX_THREADS
8672 pthread_kill_other_threads_np();
8679 if { (eval echo configure:8680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8681 ol_cv_pthread_lpthread=yes
8683 echo "configure: failed program was:" >&5
8684 cat conftest.$ac_ext >&5
8686 ol_cv_pthread_lpthread=no
8690 cat > conftest.$ac_ext <<EOF
8691 #line 8692 "configure"
8692 #include "confdefs.h"
8693 /* pthread test headers */
8694 #include <pthread.h>
8696 #define NULL (void*)0
8699 static void *task(p)
8702 return (void *) (p == NULL);
8706 int main(argc, argv)
8711 /* pthread test function */
8714 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8715 /* This system (e.g. AIX) defaults detached; must override */
8716 pthread_attr_t attr;
8718 status = pthread_attr_init(&attr);
8719 if( status ) exit( status );
8721 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8722 if( status ) exit( status );
8726 #if HAVE_PTHREADS_D4
8727 #define ATTR pthread_attr_default
8732 /* make sure pthread_create() isn't just a stub */
8733 status = pthread_create(&t, ATTR, task, NULL);
8734 if( status ) exit( status );
8736 /* make sure pthread_detach() isn't just a stub */
8737 #if HAVE_PTHREADS_D4
8738 status = pthread_detach( &t );
8740 status = pthread_detach( t );
8743 #ifdef HAVE_LINUX_THREADS
8744 pthread_kill_other_threads_np();
8752 if { (eval echo configure:8753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8754 ol_cv_pthread_lpthread=yes
8756 echo "configure: failed program was:" >&5
8757 cat conftest.$ac_ext >&5
8759 ol_cv_pthread_lpthread=no
8770 echo "$ac_t""$ol_cv_pthread_lpthread" 1>&6
8772 if test $ol_cv_pthread_lpthread = yes ; then
8773 ol_link_pthreads="-lpthread"
8774 ol_link_threads=posix
8778 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
8779 if test "$ol_link_threads" = no ; then
8781 echo $ac_n "checking for pthread link with -lc_r""... $ac_c" 1>&6
8782 echo "configure:8783: checking for pthread link with -lc_r" >&5
8783 if eval "test \"\${ol_cv_pthread_lc_r+set}\" = set"; then
8784 echo $ac_n "(cached) $ac_c" 1>&6
8791 if test "$cross_compiling" = yes; then
8792 cat > conftest.$ac_ext <<EOF
8793 #line 8794 "configure"
8794 #include "confdefs.h"
8795 /* pthread test headers */
8796 #include <pthread.h>
8798 #define NULL (void*)0
8801 static void *task(p)
8804 return (void *) (p == NULL);
8809 /* pthread test function */
8812 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8813 /* This system (e.g. AIX) defaults detached; must override */
8814 pthread_attr_t attr;
8816 status = pthread_attr_init(&attr);
8817 if( status ) exit( status );
8819 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8820 if( status ) exit( status );
8824 #if HAVE_PTHREADS_D4
8825 #define ATTR pthread_attr_default
8830 /* make sure pthread_create() isn't just a stub */
8831 status = pthread_create(&t, ATTR, task, NULL);
8832 if( status ) exit( status );
8834 /* make sure pthread_detach() isn't just a stub */
8835 #if HAVE_PTHREADS_D4
8836 status = pthread_detach( &t );
8838 status = pthread_detach( t );
8841 #ifdef HAVE_LINUX_THREADS
8842 pthread_kill_other_threads_np();
8849 if { (eval echo configure:8850: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8851 ol_cv_pthread_lc_r=yes
8853 echo "configure: failed program was:" >&5
8854 cat conftest.$ac_ext >&5
8856 ol_cv_pthread_lc_r=no
8860 cat > conftest.$ac_ext <<EOF
8861 #line 8862 "configure"
8862 #include "confdefs.h"
8863 /* pthread test headers */
8864 #include <pthread.h>
8866 #define NULL (void*)0
8869 static void *task(p)
8872 return (void *) (p == NULL);
8876 int main(argc, argv)
8881 /* pthread test function */
8884 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8885 /* This system (e.g. AIX) defaults detached; must override */
8886 pthread_attr_t attr;
8888 status = pthread_attr_init(&attr);
8889 if( status ) exit( status );
8891 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8892 if( status ) exit( status );
8896 #if HAVE_PTHREADS_D4
8897 #define ATTR pthread_attr_default
8902 /* make sure pthread_create() isn't just a stub */
8903 status = pthread_create(&t, ATTR, task, NULL);
8904 if( status ) exit( status );
8906 /* make sure pthread_detach() isn't just a stub */
8907 #if HAVE_PTHREADS_D4
8908 status = pthread_detach( &t );
8910 status = pthread_detach( t );
8913 #ifdef HAVE_LINUX_THREADS
8914 pthread_kill_other_threads_np();
8922 if { (eval echo configure:8923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8924 ol_cv_pthread_lc_r=yes
8926 echo "configure: failed program was:" >&5
8927 cat conftest.$ac_ext >&5
8929 ol_cv_pthread_lc_r=no
8940 echo "$ac_t""$ol_cv_pthread_lc_r" 1>&6
8942 if test $ol_cv_pthread_lc_r = yes ; then
8943 ol_link_pthreads="-lc_r"
8944 ol_link_threads=posix
8949 # Pthread try link: -threads (ol_cv_pthread_threads)
8950 if test "$ol_link_threads" = no ; then
8952 echo $ac_n "checking for pthread link with -threads""... $ac_c" 1>&6
8953 echo "configure:8954: checking for pthread link with -threads" >&5
8954 if eval "test \"\${ol_cv_pthread_threads+set}\" = set"; then
8955 echo $ac_n "(cached) $ac_c" 1>&6
8960 LIBS="-threads $LIBS"
8962 if test "$cross_compiling" = yes; then
8963 cat > conftest.$ac_ext <<EOF
8964 #line 8965 "configure"
8965 #include "confdefs.h"
8966 /* pthread test headers */
8967 #include <pthread.h>
8969 #define NULL (void*)0
8972 static void *task(p)
8975 return (void *) (p == NULL);
8980 /* pthread test function */
8983 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8984 /* This system (e.g. AIX) defaults detached; must override */
8985 pthread_attr_t attr;
8987 status = pthread_attr_init(&attr);
8988 if( status ) exit( status );
8990 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8991 if( status ) exit( status );
8995 #if HAVE_PTHREADS_D4
8996 #define ATTR pthread_attr_default
9001 /* make sure pthread_create() isn't just a stub */
9002 status = pthread_create(&t, ATTR, task, NULL);
9003 if( status ) exit( status );
9005 /* make sure pthread_detach() isn't just a stub */
9006 #if HAVE_PTHREADS_D4
9007 status = pthread_detach( &t );
9009 status = pthread_detach( t );
9012 #ifdef HAVE_LINUX_THREADS
9013 pthread_kill_other_threads_np();
9020 if { (eval echo configure:9021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9022 ol_cv_pthread_threads=yes
9024 echo "configure: failed program was:" >&5
9025 cat conftest.$ac_ext >&5
9027 ol_cv_pthread_threads=no
9031 cat > conftest.$ac_ext <<EOF
9032 #line 9033 "configure"
9033 #include "confdefs.h"
9034 /* pthread test headers */
9035 #include <pthread.h>
9037 #define NULL (void*)0
9040 static void *task(p)
9043 return (void *) (p == NULL);
9047 int main(argc, argv)
9052 /* pthread test function */
9055 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9056 /* This system (e.g. AIX) defaults detached; must override */
9057 pthread_attr_t attr;
9059 status = pthread_attr_init(&attr);
9060 if( status ) exit( status );
9062 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9063 if( status ) exit( status );
9067 #if HAVE_PTHREADS_D4
9068 #define ATTR pthread_attr_default
9073 /* make sure pthread_create() isn't just a stub */
9074 status = pthread_create(&t, ATTR, task, NULL);
9075 if( status ) exit( status );
9077 /* make sure pthread_detach() isn't just a stub */
9078 #if HAVE_PTHREADS_D4
9079 status = pthread_detach( &t );
9081 status = pthread_detach( t );
9084 #ifdef HAVE_LINUX_THREADS
9085 pthread_kill_other_threads_np();
9093 if { (eval echo configure:9094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9095 ol_cv_pthread_threads=yes
9097 echo "configure: failed program was:" >&5
9098 cat conftest.$ac_ext >&5
9100 ol_cv_pthread_threads=no
9111 echo "$ac_t""$ol_cv_pthread_threads" 1>&6
9113 if test $ol_cv_pthread_threads = yes ; then
9114 ol_link_pthreads="-threads"
9115 ol_link_threads=posix
9120 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
9121 if test "$ol_link_threads" = no ; then
9122 # try -lpthreads -lmach -lexc -lc_r
9123 echo $ac_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r""... $ac_c" 1>&6
9124 echo "configure:9125: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
9125 if eval "test \"\${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}\" = set"; then
9126 echo $ac_n "(cached) $ac_c" 1>&6
9131 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
9133 if test "$cross_compiling" = yes; then
9134 cat > conftest.$ac_ext <<EOF
9135 #line 9136 "configure"
9136 #include "confdefs.h"
9137 /* pthread test headers */
9138 #include <pthread.h>
9140 #define NULL (void*)0
9143 static void *task(p)
9146 return (void *) (p == NULL);
9151 /* pthread test function */
9154 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9155 /* This system (e.g. AIX) defaults detached; must override */
9156 pthread_attr_t attr;
9158 status = pthread_attr_init(&attr);
9159 if( status ) exit( status );
9161 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9162 if( status ) exit( status );
9166 #if HAVE_PTHREADS_D4
9167 #define ATTR pthread_attr_default
9172 /* make sure pthread_create() isn't just a stub */
9173 status = pthread_create(&t, ATTR, task, NULL);
9174 if( status ) exit( status );
9176 /* make sure pthread_detach() isn't just a stub */
9177 #if HAVE_PTHREADS_D4
9178 status = pthread_detach( &t );
9180 status = pthread_detach( t );
9183 #ifdef HAVE_LINUX_THREADS
9184 pthread_kill_other_threads_np();
9191 if { (eval echo configure:9192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9193 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
9195 echo "configure: failed program was:" >&5
9196 cat conftest.$ac_ext >&5
9198 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
9202 cat > conftest.$ac_ext <<EOF
9203 #line 9204 "configure"
9204 #include "confdefs.h"
9205 /* pthread test headers */
9206 #include <pthread.h>
9208 #define NULL (void*)0
9211 static void *task(p)
9214 return (void *) (p == NULL);
9218 int main(argc, argv)
9223 /* pthread test function */
9226 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9227 /* This system (e.g. AIX) defaults detached; must override */
9228 pthread_attr_t attr;
9230 status = pthread_attr_init(&attr);
9231 if( status ) exit( status );
9233 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9234 if( status ) exit( status );
9238 #if HAVE_PTHREADS_D4
9239 #define ATTR pthread_attr_default
9244 /* make sure pthread_create() isn't just a stub */
9245 status = pthread_create(&t, ATTR, task, NULL);
9246 if( status ) exit( status );
9248 /* make sure pthread_detach() isn't just a stub */
9249 #if HAVE_PTHREADS_D4
9250 status = pthread_detach( &t );
9252 status = pthread_detach( t );
9255 #ifdef HAVE_LINUX_THREADS
9256 pthread_kill_other_threads_np();
9264 if { (eval echo configure:9265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9266 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
9268 echo "configure: failed program was:" >&5
9269 cat conftest.$ac_ext >&5
9271 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
9282 echo "$ac_t""$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" 1>&6
9284 if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
9285 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
9286 ol_link_threads=posix
9290 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
9291 if test "$ol_link_threads" = no ; then
9292 # try -lpthreads -lmach -lexc
9293 echo $ac_n "checking for pthread link with -lpthreads -lmach -lexc""... $ac_c" 1>&6
9294 echo "configure:9295: checking for pthread link with -lpthreads -lmach -lexc" >&5
9295 if eval "test \"\${ol_cv_pthread_lpthreads_lmach_lexc+set}\" = set"; then
9296 echo $ac_n "(cached) $ac_c" 1>&6
9301 LIBS="-lpthreads -lmach -lexc $LIBS"
9303 if test "$cross_compiling" = yes; then
9304 cat > conftest.$ac_ext <<EOF
9305 #line 9306 "configure"
9306 #include "confdefs.h"
9307 /* pthread test headers */
9308 #include <pthread.h>
9310 #define NULL (void*)0
9313 static void *task(p)
9316 return (void *) (p == NULL);
9321 /* pthread test function */
9324 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9325 /* This system (e.g. AIX) defaults detached; must override */
9326 pthread_attr_t attr;
9328 status = pthread_attr_init(&attr);
9329 if( status ) exit( status );
9331 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9332 if( status ) exit( status );
9336 #if HAVE_PTHREADS_D4
9337 #define ATTR pthread_attr_default
9342 /* make sure pthread_create() isn't just a stub */
9343 status = pthread_create(&t, ATTR, task, NULL);
9344 if( status ) exit( status );
9346 /* make sure pthread_detach() isn't just a stub */
9347 #if HAVE_PTHREADS_D4
9348 status = pthread_detach( &t );
9350 status = pthread_detach( t );
9353 #ifdef HAVE_LINUX_THREADS
9354 pthread_kill_other_threads_np();
9361 if { (eval echo configure:9362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9363 ol_cv_pthread_lpthreads_lmach_lexc=yes
9365 echo "configure: failed program was:" >&5
9366 cat conftest.$ac_ext >&5
9368 ol_cv_pthread_lpthreads_lmach_lexc=no
9372 cat > conftest.$ac_ext <<EOF
9373 #line 9374 "configure"
9374 #include "confdefs.h"
9375 /* pthread test headers */
9376 #include <pthread.h>
9378 #define NULL (void*)0
9381 static void *task(p)
9384 return (void *) (p == NULL);
9388 int main(argc, argv)
9393 /* pthread test function */
9396 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9397 /* This system (e.g. AIX) defaults detached; must override */
9398 pthread_attr_t attr;
9400 status = pthread_attr_init(&attr);
9401 if( status ) exit( status );
9403 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9404 if( status ) exit( status );
9408 #if HAVE_PTHREADS_D4
9409 #define ATTR pthread_attr_default
9414 /* make sure pthread_create() isn't just a stub */
9415 status = pthread_create(&t, ATTR, task, NULL);
9416 if( status ) exit( status );
9418 /* make sure pthread_detach() isn't just a stub */
9419 #if HAVE_PTHREADS_D4
9420 status = pthread_detach( &t );
9422 status = pthread_detach( t );
9425 #ifdef HAVE_LINUX_THREADS
9426 pthread_kill_other_threads_np();
9434 if { (eval echo configure:9435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9436 ol_cv_pthread_lpthreads_lmach_lexc=yes
9438 echo "configure: failed program was:" >&5
9439 cat conftest.$ac_ext >&5
9441 ol_cv_pthread_lpthreads_lmach_lexc=no
9452 echo "$ac_t""$ol_cv_pthread_lpthreads_lmach_lexc" 1>&6
9454 if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
9455 ol_link_pthreads="-lpthreads -lmach -lexc"
9456 ol_link_threads=posix
9460 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
9461 if test "$ol_link_threads" = no ; then
9462 # try -lpthreads -lexc
9463 echo $ac_n "checking for pthread link with -lpthreads -lexc""... $ac_c" 1>&6
9464 echo "configure:9465: checking for pthread link with -lpthreads -lexc" >&5
9465 if eval "test \"\${ol_cv_pthread_lpthreads_lexc+set}\" = set"; then
9466 echo $ac_n "(cached) $ac_c" 1>&6
9471 LIBS="-lpthreads -lexc $LIBS"
9473 if test "$cross_compiling" = yes; then
9474 cat > conftest.$ac_ext <<EOF
9475 #line 9476 "configure"
9476 #include "confdefs.h"
9477 /* pthread test headers */
9478 #include <pthread.h>
9480 #define NULL (void*)0
9483 static void *task(p)
9486 return (void *) (p == NULL);
9491 /* pthread test function */
9494 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9495 /* This system (e.g. AIX) defaults detached; must override */
9496 pthread_attr_t attr;
9498 status = pthread_attr_init(&attr);
9499 if( status ) exit( status );
9501 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9502 if( status ) exit( status );
9506 #if HAVE_PTHREADS_D4
9507 #define ATTR pthread_attr_default
9512 /* make sure pthread_create() isn't just a stub */
9513 status = pthread_create(&t, ATTR, task, NULL);
9514 if( status ) exit( status );
9516 /* make sure pthread_detach() isn't just a stub */
9517 #if HAVE_PTHREADS_D4
9518 status = pthread_detach( &t );
9520 status = pthread_detach( t );
9523 #ifdef HAVE_LINUX_THREADS
9524 pthread_kill_other_threads_np();
9531 if { (eval echo configure:9532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9533 ol_cv_pthread_lpthreads_lexc=yes
9535 echo "configure: failed program was:" >&5
9536 cat conftest.$ac_ext >&5
9538 ol_cv_pthread_lpthreads_lexc=no
9542 cat > conftest.$ac_ext <<EOF
9543 #line 9544 "configure"
9544 #include "confdefs.h"
9545 /* pthread test headers */
9546 #include <pthread.h>
9548 #define NULL (void*)0
9551 static void *task(p)
9554 return (void *) (p == NULL);
9558 int main(argc, argv)
9563 /* pthread test function */
9566 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9567 /* This system (e.g. AIX) defaults detached; must override */
9568 pthread_attr_t attr;
9570 status = pthread_attr_init(&attr);
9571 if( status ) exit( status );
9573 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9574 if( status ) exit( status );
9578 #if HAVE_PTHREADS_D4
9579 #define ATTR pthread_attr_default
9584 /* make sure pthread_create() isn't just a stub */
9585 status = pthread_create(&t, ATTR, task, NULL);
9586 if( status ) exit( status );
9588 /* make sure pthread_detach() isn't just a stub */
9589 #if HAVE_PTHREADS_D4
9590 status = pthread_detach( &t );
9592 status = pthread_detach( t );
9595 #ifdef HAVE_LINUX_THREADS
9596 pthread_kill_other_threads_np();
9604 if { (eval echo configure:9605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9606 ol_cv_pthread_lpthreads_lexc=yes
9608 echo "configure: failed program was:" >&5
9609 cat conftest.$ac_ext >&5
9611 ol_cv_pthread_lpthreads_lexc=no
9622 echo "$ac_t""$ol_cv_pthread_lpthreads_lexc" 1>&6
9624 if test $ol_cv_pthread_lpthreads_lexc = yes ; then
9625 ol_link_pthreads="-lpthreads -lexc"
9626 ol_link_threads=posix
9631 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
9632 if test "$ol_link_threads" = no ; then
9634 echo $ac_n "checking for pthread link with -lpthreads""... $ac_c" 1>&6
9635 echo "configure:9636: checking for pthread link with -lpthreads" >&5
9636 if eval "test \"\${ol_cv_pthread_lib_lpthreads+set}\" = set"; then
9637 echo $ac_n "(cached) $ac_c" 1>&6
9642 LIBS="-lpthreads $LIBS"
9644 if test "$cross_compiling" = yes; then
9645 cat > conftest.$ac_ext <<EOF
9646 #line 9647 "configure"
9647 #include "confdefs.h"
9648 /* pthread test headers */
9649 #include <pthread.h>
9651 #define NULL (void*)0
9654 static void *task(p)
9657 return (void *) (p == NULL);
9662 /* pthread test function */
9665 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9666 /* This system (e.g. AIX) defaults detached; must override */
9667 pthread_attr_t attr;
9669 status = pthread_attr_init(&attr);
9670 if( status ) exit( status );
9672 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9673 if( status ) exit( status );
9677 #if HAVE_PTHREADS_D4
9678 #define ATTR pthread_attr_default
9683 /* make sure pthread_create() isn't just a stub */
9684 status = pthread_create(&t, ATTR, task, NULL);
9685 if( status ) exit( status );
9687 /* make sure pthread_detach() isn't just a stub */
9688 #if HAVE_PTHREADS_D4
9689 status = pthread_detach( &t );
9691 status = pthread_detach( t );
9694 #ifdef HAVE_LINUX_THREADS
9695 pthread_kill_other_threads_np();
9702 if { (eval echo configure:9703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9704 ol_cv_pthread_lib_lpthreads=yes
9706 echo "configure: failed program was:" >&5
9707 cat conftest.$ac_ext >&5
9709 ol_cv_pthread_lib_lpthreads=no
9713 cat > conftest.$ac_ext <<EOF
9714 #line 9715 "configure"
9715 #include "confdefs.h"
9716 /* pthread test headers */
9717 #include <pthread.h>
9719 #define NULL (void*)0
9722 static void *task(p)
9725 return (void *) (p == NULL);
9729 int main(argc, argv)
9734 /* pthread test function */
9737 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9738 /* This system (e.g. AIX) defaults detached; must override */
9739 pthread_attr_t attr;
9741 status = pthread_attr_init(&attr);
9742 if( status ) exit( status );
9744 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9745 if( status ) exit( status );
9749 #if HAVE_PTHREADS_D4
9750 #define ATTR pthread_attr_default
9755 /* make sure pthread_create() isn't just a stub */
9756 status = pthread_create(&t, ATTR, task, NULL);
9757 if( status ) exit( status );
9759 /* make sure pthread_detach() isn't just a stub */
9760 #if HAVE_PTHREADS_D4
9761 status = pthread_detach( &t );
9763 status = pthread_detach( t );
9766 #ifdef HAVE_LINUX_THREADS
9767 pthread_kill_other_threads_np();
9775 if { (eval echo configure:9776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9777 ol_cv_pthread_lib_lpthreads=yes
9779 echo "configure: failed program was:" >&5
9780 cat conftest.$ac_ext >&5
9782 ol_cv_pthread_lib_lpthreads=no
9793 echo "$ac_t""$ol_cv_pthread_lib_lpthreads" 1>&6
9795 if test $ol_cv_pthread_lib_lpthreads = yes ; then
9796 ol_link_pthreads="-lpthreads"
9797 ol_link_threads=posix
9802 if test $ol_link_threads != no ; then
9803 cat >> confdefs.h <<\EOF
9804 #define HAVE_PTHREADS 1
9808 LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
9810 save_CPPFLAGS="$CPPFLAGS"
9812 LIBS="$LTHREAD_LIBS $LIBS"
9814 for ac_func in sched_yield pthread_yield
9816 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9817 echo "configure:9818: checking for $ac_func" >&5
9818 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9819 echo $ac_n "(cached) $ac_c" 1>&6
9821 cat > conftest.$ac_ext <<EOF
9822 #line 9823 "configure"
9823 #include "confdefs.h"
9824 /* System header to define __stub macros and hopefully few prototypes,
9825 which can conflict with char $ac_func(); below. */
9827 /* Override any gcc2 internal prototype to avoid an error. */
9828 /* We use char because int might match the return type of a gcc2
9829 builtin and then its argument prototype would still apply. */
9835 /* The GNU C library defines this for functions which it implements
9836 to always fail with ENOSYS. Some functions are actually named
9837 something starting with __ and the normal name is an alias. */
9838 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9846 if { (eval echo configure:9847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9848 eval "ac_cv_func_$ac_func=yes"
9850 echo "configure: failed program was:" >&5
9851 cat conftest.$ac_ext >&5
9853 eval "ac_cv_func_$ac_func=no"
9858 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
9859 echo "$ac_t""yes" 1>&6
9860 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
9861 cat >> confdefs.h <<EOF
9862 #define $ac_tr_func 1
9866 echo "$ac_t""no" 1>&6
9871 if test $ac_cv_func_sched_yield = no -a \
9872 $ac_cv_func_pthread_yield = no ; then
9873 echo $ac_n "checking for sched_yield in -lrt""... $ac_c" 1>&6
9874 echo "configure:9875: checking for sched_yield in -lrt" >&5
9875 ac_lib_var=`echo rt'_'sched_yield | sed 'y%./+-:%__p__%'`
9876 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
9877 echo $ac_n "(cached) $ac_c" 1>&6
9879 ac_save_LIBS="$LIBS"
9881 cat > conftest.$ac_ext <<EOF
9882 #line 9883 "configure"
9883 #include "confdefs.h"
9884 /* Override any gcc2 internal prototype to avoid an error. */
9885 /* We use char because int might match the return type of a gcc2
9886 builtin and then its argument prototype would still apply. */
9893 if { (eval echo configure:9894: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9895 eval "ac_cv_lib_$ac_lib_var=yes"
9897 echo "configure: failed program was:" >&5
9898 cat conftest.$ac_ext >&5
9900 eval "ac_cv_lib_$ac_lib_var=no"
9903 LIBS="$ac_save_LIBS"
9906 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
9907 echo "$ac_t""yes" 1>&6
9908 LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
9909 cat >> confdefs.h <<\EOF
9910 #define HAVE_SCHED_YIELD 1
9913 ac_cv_func_sched_yield=yes
9915 echo "$ac_t""no" 1>&6
9916 ac_cv_func_sched_yield=no
9920 if test $ac_cv_func_sched_yield = no -a \
9921 $ac_cv_func_pthread_yield = no ; then
9922 for ac_func in thr_yield
9924 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9925 echo "configure:9926: checking for $ac_func" >&5
9926 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9927 echo $ac_n "(cached) $ac_c" 1>&6
9929 cat > conftest.$ac_ext <<EOF
9930 #line 9931 "configure"
9931 #include "confdefs.h"
9932 /* System header to define __stub macros and hopefully few prototypes,
9933 which can conflict with char $ac_func(); below. */
9935 /* Override any gcc2 internal prototype to avoid an error. */
9936 /* We use char because int might match the return type of a gcc2
9937 builtin and then its argument prototype would still apply. */
9943 /* The GNU C library defines this for functions which it implements
9944 to always fail with ENOSYS. Some functions are actually named
9945 something starting with __ and the normal name is an alias. */
9946 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9954 if { (eval echo configure:9955: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9956 eval "ac_cv_func_$ac_func=yes"
9958 echo "configure: failed program was:" >&5
9959 cat conftest.$ac_ext >&5
9961 eval "ac_cv_func_$ac_func=no"
9966 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
9967 echo "$ac_t""yes" 1>&6
9968 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
9969 cat >> confdefs.h <<EOF
9970 #define $ac_tr_func 1
9974 echo "$ac_t""no" 1>&6
9979 if test $ac_cv_func_sched_yield = no -a \
9980 $ac_cv_func_pthread_yield = no -a \
9981 "$ac_cv_func_thr_yield" = no ; then
9982 echo "configure: warning: could not locate sched_yield() or pthread_yield()" 1>&2
9985 for ac_func in pthread_kill pthread_rwlock_destroy
9987 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9988 echo "configure:9989: checking for $ac_func" >&5
9989 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9990 echo $ac_n "(cached) $ac_c" 1>&6
9992 cat > conftest.$ac_ext <<EOF
9993 #line 9994 "configure"
9994 #include "confdefs.h"
9995 /* System header to define __stub macros and hopefully few prototypes,
9996 which can conflict with char $ac_func(); below. */
9998 /* Override any gcc2 internal prototype to avoid an error. */
9999 /* We use char because int might match the return type of a gcc2
10000 builtin and then its argument prototype would still apply. */
10006 /* The GNU C library defines this for functions which it implements
10007 to always fail with ENOSYS. Some functions are actually named
10008 something starting with __ and the normal name is an alias. */
10009 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10017 if { (eval echo configure:10018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10019 eval "ac_cv_func_$ac_func=yes"
10021 echo "configure: failed program was:" >&5
10022 cat conftest.$ac_ext >&5
10024 eval "ac_cv_func_$ac_func=no"
10029 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10030 echo "$ac_t""yes" 1>&6
10031 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10032 cat >> confdefs.h <<EOF
10033 #define $ac_tr_func 1
10037 echo "$ac_t""no" 1>&6
10042 echo $ac_n "checking for pthread_detach with <pthread.h>""... $ac_c" 1>&6
10043 echo "configure:10044: checking for pthread_detach with <pthread.h>" >&5
10044 if eval "test \"\${ol_cv_func_pthread_detach+set}\" = set"; then
10045 echo $ac_n "(cached) $ac_c" 1>&6
10048 cat > conftest.$ac_ext <<EOF
10049 #line 10050 "configure"
10050 #include "confdefs.h"
10052 #include <pthread.h>
10054 #define NULL (void*)0
10058 pthread_detach(NULL);
10061 if { (eval echo configure:10062: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10063 ol_cv_func_pthread_detach=yes
10065 echo "configure: failed program was:" >&5
10066 cat conftest.$ac_ext >&5
10068 ol_cv_func_pthread_detach=no
10074 echo "$ac_t""$ol_cv_func_pthread_detach" 1>&6
10076 if test $ol_cv_func_pthread_detach = no ; then
10077 { echo "configure: error: could not locate pthread_detach()" 1>&2; exit 1; }
10080 cat >> confdefs.h <<\EOF
10081 #define HAVE_PTHREAD_DETACH 1
10086 pthread_setconcurrency \
10087 pthread_getconcurrency \
10088 thr_setconcurrency \
10089 thr_getconcurrency \
10092 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
10093 echo "configure:10094: checking for $ac_func" >&5
10094 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
10095 echo $ac_n "(cached) $ac_c" 1>&6
10097 cat > conftest.$ac_ext <<EOF
10098 #line 10099 "configure"
10099 #include "confdefs.h"
10100 /* System header to define __stub macros and hopefully few prototypes,
10101 which can conflict with char $ac_func(); below. */
10102 #include <assert.h>
10103 /* Override any gcc2 internal prototype to avoid an error. */
10104 /* We use char because int might match the return type of a gcc2
10105 builtin and then its argument prototype would still apply. */
10111 /* The GNU C library defines this for functions which it implements
10112 to always fail with ENOSYS. Some functions are actually named
10113 something starting with __ and the normal name is an alias. */
10114 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10122 if { (eval echo configure:10123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10124 eval "ac_cv_func_$ac_func=yes"
10126 echo "configure: failed program was:" >&5
10127 cat conftest.$ac_ext >&5
10129 eval "ac_cv_func_$ac_func=no"
10134 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10135 echo "$ac_t""yes" 1>&6
10136 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10137 cat >> confdefs.h <<EOF
10138 #define $ac_tr_func 1
10142 echo "$ac_t""no" 1>&6
10148 echo $ac_n "checking for pthread_kill_other_threads_np""... $ac_c" 1>&6
10149 echo "configure:10150: checking for pthread_kill_other_threads_np" >&5
10150 if eval "test \"\${ac_cv_func_pthread_kill_other_threads_np+set}\" = set"; then
10151 echo $ac_n "(cached) $ac_c" 1>&6
10153 cat > conftest.$ac_ext <<EOF
10154 #line 10155 "configure"
10155 #include "confdefs.h"
10156 /* System header to define __stub macros and hopefully few prototypes,
10157 which can conflict with char pthread_kill_other_threads_np(); below. */
10158 #include <assert.h>
10159 /* Override any gcc2 internal prototype to avoid an error. */
10160 /* We use char because int might match the return type of a gcc2
10161 builtin and then its argument prototype would still apply. */
10162 char pthread_kill_other_threads_np();
10167 /* The GNU C library defines this for functions which it implements
10168 to always fail with ENOSYS. Some functions are actually named
10169 something starting with __ and the normal name is an alias. */
10170 #if defined (__stub_pthread_kill_other_threads_np) || defined (__stub___pthread_kill_other_threads_np)
10173 f = pthread_kill_other_threads_np;
10178 if { (eval echo configure:10179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10180 eval "ac_cv_func_pthread_kill_other_threads_np=yes"
10182 echo "configure: failed program was:" >&5
10183 cat conftest.$ac_ext >&5
10185 eval "ac_cv_func_pthread_kill_other_threads_np=no"
10190 if eval "test \"`echo '$ac_cv_func_'pthread_kill_other_threads_np`\" = yes"; then
10191 echo "$ac_t""yes" 1>&6
10194 echo "$ac_t""no" 1>&6
10197 echo $ac_n "checking for LinuxThreads implementation""... $ac_c" 1>&6
10198 echo "configure:10199: checking for LinuxThreads implementation" >&5
10199 if eval "test \"\${ol_cv_sys_linux_threads+set}\" = set"; then
10200 echo $ac_n "(cached) $ac_c" 1>&6
10202 ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
10205 echo "$ac_t""$ol_cv_sys_linux_threads" 1>&6
10210 echo $ac_n "checking for LinuxThreads consistency""... $ac_c" 1>&6
10211 echo "configure:10212: checking for LinuxThreads consistency" >&5
10212 if eval "test \"\${ol_cv_linux_threads+set}\" = set"; then
10213 echo $ac_n "(cached) $ac_c" 1>&6
10216 if test $ol_cv_header_linux_threads = yes -a \
10217 $ol_cv_sys_linux_threads = yes; then
10218 ol_cv_linux_threads=yes
10219 elif test $ol_cv_header_linux_threads = no -a \
10220 $ol_cv_sys_linux_threads = no; then
10221 ol_cv_linux_threads=no
10223 ol_cv_linux_threads=error
10228 echo "$ac_t""$ol_cv_linux_threads" 1>&6
10231 if test $ol_cv_linux_threads = error; then
10232 { echo "configure: error: LinuxThreads header/library mismatch" 1>&2; exit 1; };
10235 echo $ac_n "checking if pthread_create() works""... $ac_c" 1>&6
10236 echo "configure:10237: checking if pthread_create() works" >&5
10237 if eval "test \"\${ol_cv_pthread_create_works+set}\" = set"; then
10238 echo $ac_n "(cached) $ac_c" 1>&6
10241 if test "$cross_compiling" = yes; then
10242 ol_cv_pthread_create_works=yes
10244 cat > conftest.$ac_ext <<EOF
10245 #line 10246 "configure"
10246 #include "confdefs.h"
10247 /* pthread test headers */
10248 #include <pthread.h>
10250 #define NULL (void*)0
10253 static void *task(p)
10256 return (void *) (p == NULL);
10260 int main(argc, argv)
10265 /* pthread test function */
10268 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
10269 /* This system (e.g. AIX) defaults detached; must override */
10270 pthread_attr_t attr;
10272 status = pthread_attr_init(&attr);
10273 if( status ) exit( status );
10275 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
10276 if( status ) exit( status );
10280 #if HAVE_PTHREADS_D4
10281 #define ATTR pthread_attr_default
10286 /* make sure pthread_create() isn't just a stub */
10287 status = pthread_create(&t, ATTR, task, NULL);
10288 if( status ) exit( status );
10290 /* make sure pthread_detach() isn't just a stub */
10291 #if HAVE_PTHREADS_D4
10292 status = pthread_detach( &t );
10294 status = pthread_detach( t );
10297 #ifdef HAVE_LINUX_THREADS
10298 pthread_kill_other_threads_np();
10306 if { (eval echo configure:10307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
10308 ol_cv_pthread_create_works=yes
10310 echo "configure: failed program was:" >&5
10311 cat conftest.$ac_ext >&5
10313 ol_cv_pthread_create_works=no
10320 echo "$ac_t""$ol_cv_pthread_create_works" 1>&6
10322 if test $ol_cv_pthread_create_works = no ; then
10323 { echo "configure: error: pthread_create is not usable, check environment settings" 1>&2; exit 1; }
10326 if test $ol_with_yielding_select = auto ; then
10327 echo $ac_n "checking if select yields when using pthreads""... $ac_c" 1>&6
10328 echo "configure:10329: checking if select yields when using pthreads" >&5
10329 if eval "test \"\${ol_cv_pthread_select_yields+set}\" = set"; then
10330 echo $ac_n "(cached) $ac_c" 1>&6
10333 if test "$cross_compiling" = yes; then
10334 ol_cv_pthread_select_yields=cross
10336 cat > conftest.$ac_ext <<EOF
10337 #line 10338 "configure"
10338 #include "confdefs.h"
10340 #include <sys/types.h>
10341 #include <sys/time.h>
10342 #include <unistd.h>
10343 #include <pthread.h>
10345 #define NULL (void*) 0
10348 static int fildes[2];
10350 static void *task(p)
10362 FD_SET(fildes[0], &rfds);
10364 /* we're not interested in any fds */
10365 i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
10372 exit(0); /* if we exit here, the select blocked the whole process */
10375 int main(argc, argv)
10381 /* create a pipe to select */
10382 if(pipe(&fildes[0])) {
10387 #ifdef HAVE_PTHREAD_SETCONCURRENCY
10388 (void) pthread_setconcurrency(2);
10390 #ifdef HAVE_THR_SETCONCURRENCY
10391 /* Set Solaris LWP concurrency to 2 */
10392 thr_setconcurrency(2);
10396 #if HAVE_PTHREADS_D4
10397 pthread_create(&t, pthread_attr_default, task, NULL);
10399 pthread_create(&t, NULL, task, NULL);
10402 #if HAVE_SCHED_YIELD
10403 sched_yield(); /* make sure task runs first */
10405 #ifdef HAVE_PTHREAD_YIELD
10406 pthread_yield(); /* make sure task runs first */
10413 if { (eval echo configure:10414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
10415 ol_cv_pthread_select_yields=no
10417 echo "configure: failed program was:" >&5
10418 cat conftest.$ac_ext >&5
10420 ol_cv_pthread_select_yields=yes
10427 echo "$ac_t""$ol_cv_pthread_select_yields" 1>&6
10429 if test $ol_cv_pthread_select_yields = cross ; then
10430 { echo "configure: error: crossing compiling: use --with-yielding_select=yes|no|manual" 1>&2; exit 1; }
10433 if test $ol_cv_pthread_select_yields = yes ; then
10434 ol_with_yielding_select=yes
10438 CPPFLAGS="$save_CPPFLAGS"
10441 { echo "configure: error: could not link with POSIX Threads" 1>&2; exit 1; }
10445 if test $ol_with_threads = posix ; then
10446 { echo "configure: error: could not locate POSIX Threads" 1>&2; exit 1; }
10450 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10451 -o $ol_with_threads = mach ; then
10453 for ac_hdr in mach/cthreads.h
10455 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10456 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10457 echo "configure:10458: checking for $ac_hdr" >&5
10458 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10459 echo $ac_n "(cached) $ac_c" 1>&6
10461 cat > conftest.$ac_ext <<EOF
10462 #line 10463 "configure"
10463 #include "confdefs.h"
10466 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10467 { (eval echo configure:10468: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10468 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10469 if test -z "$ac_err"; then
10471 eval "ac_cv_header_$ac_safe=yes"
10474 echo "configure: failed program was:" >&5
10475 cat conftest.$ac_ext >&5
10477 eval "ac_cv_header_$ac_safe=no"
10481 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10482 echo "$ac_t""yes" 1>&6
10483 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10484 cat >> confdefs.h <<EOF
10485 #define $ac_tr_hdr 1
10489 echo "$ac_t""no" 1>&6
10493 if test $ac_cv_header_mach_cthreads_h = yes ; then
10494 ol_with_threads=found
10496 echo $ac_n "checking for cthread_fork""... $ac_c" 1>&6
10497 echo "configure:10498: checking for cthread_fork" >&5
10498 if eval "test \"\${ac_cv_func_cthread_fork+set}\" = set"; then
10499 echo $ac_n "(cached) $ac_c" 1>&6
10501 cat > conftest.$ac_ext <<EOF
10502 #line 10503 "configure"
10503 #include "confdefs.h"
10504 /* System header to define __stub macros and hopefully few prototypes,
10505 which can conflict with char cthread_fork(); below. */
10506 #include <assert.h>
10507 /* Override any gcc2 internal prototype to avoid an error. */
10508 /* We use char because int might match the return type of a gcc2
10509 builtin and then its argument prototype would still apply. */
10510 char cthread_fork();
10515 /* The GNU C library defines this for functions which it implements
10516 to always fail with ENOSYS. Some functions are actually named
10517 something starting with __ and the normal name is an alias. */
10518 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
10526 if { (eval echo configure:10527: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10528 eval "ac_cv_func_cthread_fork=yes"
10530 echo "configure: failed program was:" >&5
10531 cat conftest.$ac_ext >&5
10533 eval "ac_cv_func_cthread_fork=no"
10538 if eval "test \"`echo '$ac_cv_func_'cthread_fork`\" = yes"; then
10539 echo "$ac_t""yes" 1>&6
10540 ol_link_threads=yes
10542 echo "$ac_t""no" 1>&6
10546 if test $ol_link_threads = no ; then
10547 echo $ac_n "checking for cthread_fork with -all_load""... $ac_c" 1>&6
10548 echo "configure:10549: checking for cthread_fork with -all_load" >&5
10549 if eval "test \"\${ol_cv_cthread_all_load+set}\" = set"; then
10550 echo $ac_n "(cached) $ac_c" 1>&6
10554 LIBS="-all_load $LIBS"
10555 cat > conftest.$ac_ext <<EOF
10556 #line 10557 "configure"
10557 #include "confdefs.h"
10558 #include <mach/cthreads.h>
10561 cthread_fork((void *)0, (void *)0);
10565 if { (eval echo configure:10566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10567 ol_cv_cthread_all_load=yes
10569 echo "configure: failed program was:" >&5
10570 cat conftest.$ac_ext >&5
10572 ol_cv_cthread_all_load=no
10579 echo "$ac_t""$ol_cv_cthread_all_load" 1>&6
10581 if test $ol_cv_cthread_all_load = yes ; then
10582 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
10583 ol_link_threads=mach
10587 if test $ol_link_threads != no ; then
10588 : check for cthread specific functionality here
10589 cat >> confdefs.h <<\EOF
10590 #define HAVE_MACH_CTHREADS 1
10594 { echo "configure: error: could not link with Mach CThreads" 1>&2; exit 1; }
10598 if test $ol_with_threads = mach ; then
10599 { echo "configure: error: could not locate Mach CThreads" 1>&2; exit 1; }
10603 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10604 -o $ol_with_threads = pth ; then
10606 for ac_hdr in pth.h
10608 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10609 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10610 echo "configure:10611: checking for $ac_hdr" >&5
10611 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10612 echo $ac_n "(cached) $ac_c" 1>&6
10614 cat > conftest.$ac_ext <<EOF
10615 #line 10616 "configure"
10616 #include "confdefs.h"
10619 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10620 { (eval echo configure:10621: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10621 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10622 if test -z "$ac_err"; then
10624 eval "ac_cv_header_$ac_safe=yes"
10627 echo "configure: failed program was:" >&5
10628 cat conftest.$ac_ext >&5
10630 eval "ac_cv_header_$ac_safe=no"
10634 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10635 echo "$ac_t""yes" 1>&6
10636 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10637 cat >> confdefs.h <<EOF
10638 #define $ac_tr_hdr 1
10642 echo "$ac_t""no" 1>&6
10647 if test $ac_cv_header_pth_h = yes ; then
10648 echo $ac_n "checking for pth_version in -lpth""... $ac_c" 1>&6
10649 echo "configure:10650: checking for pth_version in -lpth" >&5
10650 ac_lib_var=`echo pth'_'pth_version | sed 'y%./+-:%__p__%'`
10651 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10652 echo $ac_n "(cached) $ac_c" 1>&6
10654 ac_save_LIBS="$LIBS"
10656 cat > conftest.$ac_ext <<EOF
10657 #line 10658 "configure"
10658 #include "confdefs.h"
10659 /* Override any gcc2 internal prototype to avoid an error. */
10660 /* We use char because int might match the return type of a gcc2
10661 builtin and then its argument prototype would still apply. */
10662 char pth_version();
10668 if { (eval echo configure:10669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10670 eval "ac_cv_lib_$ac_lib_var=yes"
10672 echo "configure: failed program was:" >&5
10673 cat conftest.$ac_ext >&5
10675 eval "ac_cv_lib_$ac_lib_var=no"
10678 LIBS="$ac_save_LIBS"
10681 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10682 echo "$ac_t""yes" 1>&6
10685 echo "$ac_t""no" 1>&6
10690 if test $have_pth = yes ; then
10691 cat >> confdefs.h <<\EOF
10692 #define HAVE_GNU_PTH 1
10695 LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
10696 ol_link_threads=pth
10698 if test $ol_with_yielding_select = auto ; then
10699 ol_with_yielding_select=yes
10705 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10706 -o $ol_with_threads = lwp ; then
10708 for ac_hdr in thread.h synch.h
10710 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10711 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10712 echo "configure:10713: checking for $ac_hdr" >&5
10713 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10714 echo $ac_n "(cached) $ac_c" 1>&6
10716 cat > conftest.$ac_ext <<EOF
10717 #line 10718 "configure"
10718 #include "confdefs.h"
10721 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10722 { (eval echo configure:10723: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10723 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10724 if test -z "$ac_err"; then
10726 eval "ac_cv_header_$ac_safe=yes"
10729 echo "configure: failed program was:" >&5
10730 cat conftest.$ac_ext >&5
10732 eval "ac_cv_header_$ac_safe=no"
10736 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10737 echo "$ac_t""yes" 1>&6
10738 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10739 cat >> confdefs.h <<EOF
10740 #define $ac_tr_hdr 1
10744 echo "$ac_t""no" 1>&6
10748 if test $ac_cv_header_thread_h = yes -a $ac_cv_header_synch_h = yes ; then
10749 echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6
10750 echo "configure:10751: checking for thr_create in -lthread" >&5
10751 ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-:%__p__%'`
10752 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10753 echo $ac_n "(cached) $ac_c" 1>&6
10755 ac_save_LIBS="$LIBS"
10756 LIBS="-lthread $LIBS"
10757 cat > conftest.$ac_ext <<EOF
10758 #line 10759 "configure"
10759 #include "confdefs.h"
10760 /* Override any gcc2 internal prototype to avoid an error. */
10761 /* We use char because int might match the return type of a gcc2
10762 builtin and then its argument prototype would still apply. */
10769 if { (eval echo configure:10770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10771 eval "ac_cv_lib_$ac_lib_var=yes"
10773 echo "configure: failed program was:" >&5
10774 cat conftest.$ac_ext >&5
10776 eval "ac_cv_lib_$ac_lib_var=no"
10779 LIBS="$ac_save_LIBS"
10782 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10783 echo "$ac_t""yes" 1>&6
10786 echo "$ac_t""no" 1>&6
10791 if test $have_thr = yes ; then
10792 cat >> confdefs.h <<\EOF
10796 LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
10797 ol_link_threads=thr
10799 if test $ol_with_yielding_select = auto ; then
10800 ol_with_yielding_select=yes
10804 thr_setconcurrency \
10805 thr_getconcurrency \
10808 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
10809 echo "configure:10810: checking for $ac_func" >&5
10810 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
10811 echo $ac_n "(cached) $ac_c" 1>&6
10813 cat > conftest.$ac_ext <<EOF
10814 #line 10815 "configure"
10815 #include "confdefs.h"
10816 /* System header to define __stub macros and hopefully few prototypes,
10817 which can conflict with char $ac_func(); below. */
10818 #include <assert.h>
10819 /* Override any gcc2 internal prototype to avoid an error. */
10820 /* We use char because int might match the return type of a gcc2
10821 builtin and then its argument prototype would still apply. */
10827 /* The GNU C library defines this for functions which it implements
10828 to always fail with ENOSYS. Some functions are actually named
10829 something starting with __ and the normal name is an alias. */
10830 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10838 if { (eval echo configure:10839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10840 eval "ac_cv_func_$ac_func=yes"
10842 echo "configure: failed program was:" >&5
10843 cat conftest.$ac_ext >&5
10845 eval "ac_cv_func_$ac_func=no"
10850 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10851 echo "$ac_t""yes" 1>&6
10852 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10853 cat >> confdefs.h <<EOF
10854 #define $ac_tr_func 1
10858 echo "$ac_t""no" 1>&6
10865 for ac_hdr in lwp/lwp.h
10867 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10868 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10869 echo "configure:10870: checking for $ac_hdr" >&5
10870 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10871 echo $ac_n "(cached) $ac_c" 1>&6
10873 cat > conftest.$ac_ext <<EOF
10874 #line 10875 "configure"
10875 #include "confdefs.h"
10878 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10879 { (eval echo configure:10880: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10880 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10881 if test -z "$ac_err"; then
10883 eval "ac_cv_header_$ac_safe=yes"
10886 echo "configure: failed program was:" >&5
10887 cat conftest.$ac_ext >&5
10889 eval "ac_cv_header_$ac_safe=no"
10893 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10894 echo "$ac_t""yes" 1>&6
10895 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10896 cat >> confdefs.h <<EOF
10897 #define $ac_tr_hdr 1
10901 echo "$ac_t""no" 1>&6
10905 if test $ac_cv_header_lwp_lwp_h = yes ; then
10906 echo $ac_n "checking for lwp_create in -llwp""... $ac_c" 1>&6
10907 echo "configure:10908: checking for lwp_create in -llwp" >&5
10908 ac_lib_var=`echo lwp'_'lwp_create | sed 'y%./+-:%__p__%'`
10909 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10910 echo $ac_n "(cached) $ac_c" 1>&6
10912 ac_save_LIBS="$LIBS"
10914 cat > conftest.$ac_ext <<EOF
10915 #line 10916 "configure"
10916 #include "confdefs.h"
10917 /* Override any gcc2 internal prototype to avoid an error. */
10918 /* We use char because int might match the return type of a gcc2
10919 builtin and then its argument prototype would still apply. */
10926 if { (eval echo configure:10927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10928 eval "ac_cv_lib_$ac_lib_var=yes"
10930 echo "configure: failed program was:" >&5
10931 cat conftest.$ac_ext >&5
10933 eval "ac_cv_lib_$ac_lib_var=no"
10936 LIBS="$ac_save_LIBS"
10939 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10940 echo "$ac_t""yes" 1>&6
10943 echo "$ac_t""no" 1>&6
10948 if test $have_lwp = yes ; then
10949 cat >> confdefs.h <<\EOF
10953 LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
10954 ol_link_threads=lwp
10956 if test $ol_with_yielding_select = auto ; then
10957 ol_with_yielding_select=no
10963 if test $ol_with_yielding_select = yes ; then
10964 cat >> confdefs.h <<\EOF
10965 #define HAVE_YIELDING_SELECT 1
10970 if test $ol_with_threads = manual ; then
10971 ol_link_threads=yes
10973 echo "configure: warning: thread defines and link options must be set manually" 1>&2
10975 for ac_hdr in pthread.h sched.h
10977 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10978 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10979 echo "configure:10980: checking for $ac_hdr" >&5
10980 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10981 echo $ac_n "(cached) $ac_c" 1>&6
10983 cat > conftest.$ac_ext <<EOF
10984 #line 10985 "configure"
10985 #include "confdefs.h"
10988 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10989 { (eval echo configure:10990: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10990 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10991 if test -z "$ac_err"; then
10993 eval "ac_cv_header_$ac_safe=yes"
10996 echo "configure: failed program was:" >&5
10997 cat conftest.$ac_ext >&5
10999 eval "ac_cv_header_$ac_safe=no"
11003 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11004 echo "$ac_t""yes" 1>&6
11005 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11006 cat >> confdefs.h <<EOF
11007 #define $ac_tr_hdr 1
11011 echo "$ac_t""no" 1>&6
11015 for ac_func in sched_yield pthread_yield
11017 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
11018 echo "configure:11019: checking for $ac_func" >&5
11019 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
11020 echo $ac_n "(cached) $ac_c" 1>&6
11022 cat > conftest.$ac_ext <<EOF
11023 #line 11024 "configure"
11024 #include "confdefs.h"
11025 /* System header to define __stub macros and hopefully few prototypes,
11026 which can conflict with char $ac_func(); below. */
11027 #include <assert.h>
11028 /* Override any gcc2 internal prototype to avoid an error. */
11029 /* We use char because int might match the return type of a gcc2
11030 builtin and then its argument prototype would still apply. */
11036 /* The GNU C library defines this for functions which it implements
11037 to always fail with ENOSYS. Some functions are actually named
11038 something starting with __ and the normal name is an alias. */
11039 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11047 if { (eval echo configure:11048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11049 eval "ac_cv_func_$ac_func=yes"
11051 echo "configure: failed program was:" >&5
11052 cat conftest.$ac_ext >&5
11054 eval "ac_cv_func_$ac_func=no"
11059 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
11060 echo "$ac_t""yes" 1>&6
11061 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
11062 cat >> confdefs.h <<EOF
11063 #define $ac_tr_func 1
11067 echo "$ac_t""no" 1>&6
11072 echo $ac_n "checking for LinuxThreads pthread.h""... $ac_c" 1>&6
11073 echo "configure:11074: checking for LinuxThreads pthread.h" >&5
11074 if eval "test \"\${ol_cv_header_linux_threads+set}\" = set"; then
11075 echo $ac_n "(cached) $ac_c" 1>&6
11077 cat > conftest.$ac_ext <<EOF
11078 #line 11079 "configure"
11079 #include "confdefs.h"
11080 #include <pthread.h>
11082 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11083 egrep "pthread_kill_other_threads_np" >/dev/null 2>&1; then
11085 ol_cv_header_linux_threads=yes
11088 ol_cv_header_linux_threads=no
11095 echo "$ac_t""$ol_cv_header_linux_threads" 1>&6
11096 if test $ol_cv_header_linux_threads = yes; then
11097 cat >> confdefs.h <<\EOF
11098 #define HAVE_LINUX_THREADS 1
11104 for ac_hdr in mach/cthreads.h
11106 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11107 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11108 echo "configure:11109: checking for $ac_hdr" >&5
11109 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11110 echo $ac_n "(cached) $ac_c" 1>&6
11112 cat > conftest.$ac_ext <<EOF
11113 #line 11114 "configure"
11114 #include "confdefs.h"
11117 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11118 { (eval echo configure:11119: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11119 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11120 if test -z "$ac_err"; then
11122 eval "ac_cv_header_$ac_safe=yes"
11125 echo "configure: failed program was:" >&5
11126 cat conftest.$ac_ext >&5
11128 eval "ac_cv_header_$ac_safe=no"
11132 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11133 echo "$ac_t""yes" 1>&6
11134 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11135 cat >> confdefs.h <<EOF
11136 #define $ac_tr_hdr 1
11140 echo "$ac_t""no" 1>&6
11144 for ac_hdr in lwp/lwp.h
11146 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11147 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11148 echo "configure:11149: checking for $ac_hdr" >&5
11149 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11150 echo $ac_n "(cached) $ac_c" 1>&6
11152 cat > conftest.$ac_ext <<EOF
11153 #line 11154 "configure"
11154 #include "confdefs.h"
11157 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11158 { (eval echo configure:11159: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11159 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11160 if test -z "$ac_err"; then
11162 eval "ac_cv_header_$ac_safe=yes"
11165 echo "configure: failed program was:" >&5
11166 cat conftest.$ac_ext >&5
11168 eval "ac_cv_header_$ac_safe=no"
11172 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11173 echo "$ac_t""yes" 1>&6
11174 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11175 cat >> confdefs.h <<EOF
11176 #define $ac_tr_hdr 1
11180 echo "$ac_t""no" 1>&6
11184 for ac_hdr in thread.h synch.h
11186 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11187 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11188 echo "configure:11189: checking for $ac_hdr" >&5
11189 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11190 echo $ac_n "(cached) $ac_c" 1>&6
11192 cat > conftest.$ac_ext <<EOF
11193 #line 11194 "configure"
11194 #include "confdefs.h"
11197 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11198 { (eval echo configure:11199: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11199 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11200 if test -z "$ac_err"; then
11202 eval "ac_cv_header_$ac_safe=yes"
11205 echo "configure: failed program was:" >&5
11206 cat conftest.$ac_ext >&5
11208 eval "ac_cv_header_$ac_safe=no"
11212 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11213 echo "$ac_t""yes" 1>&6
11214 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11215 cat >> confdefs.h <<EOF
11216 #define $ac_tr_hdr 1
11220 echo "$ac_t""no" 1>&6
11226 if test $ol_link_threads != no -a $ol_link_threads != nt ; then
11227 cat >> confdefs.h <<\EOF
11228 #define REENTRANT 1
11231 cat >> confdefs.h <<\EOF
11232 #define _REENTRANT 1
11235 cat >> confdefs.h <<\EOF
11236 #define THREAD_SAFE 1
11239 cat >> confdefs.h <<\EOF
11240 #define _THREAD_SAFE 1
11243 cat >> confdefs.h <<\EOF
11244 #define THREADSAFE 1
11247 cat >> confdefs.h <<\EOF
11248 #define _THREADSAFE 1
11251 cat >> confdefs.h <<\EOF
11252 #define _SGI_MP_SOURCE 1
11256 echo $ac_n "checking for thread specific errno""... $ac_c" 1>&6
11257 echo "configure:11258: checking for thread specific errno" >&5
11258 if eval "test \"\${ol_cv_errno_thread_specific+set}\" = set"; then
11259 echo $ac_n "(cached) $ac_c" 1>&6
11262 cat > conftest.$ac_ext <<EOF
11263 #line 11264 "configure"
11264 #include "confdefs.h"
11270 if { (eval echo configure:11271: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11272 ol_cv_errno_thread_specific=yes
11274 echo "configure: failed program was:" >&5
11275 cat conftest.$ac_ext >&5
11277 ol_cv_errno_thread_specific=no
11283 echo "$ac_t""$ol_cv_errno_thread_specific" 1>&6
11285 echo $ac_n "checking for thread specific h_errno""... $ac_c" 1>&6
11286 echo "configure:11287: checking for thread specific h_errno" >&5
11287 if eval "test \"\${ol_cv_h_errno_thread_specific+set}\" = set"; then
11288 echo $ac_n "(cached) $ac_c" 1>&6
11291 cat > conftest.$ac_ext <<EOF
11292 #line 11293 "configure"
11293 #include "confdefs.h"
11299 if { (eval echo configure:11300: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11301 ol_cv_h_errno_thread_specific=yes
11303 echo "configure: failed program was:" >&5
11304 cat conftest.$ac_ext >&5
11306 ol_cv_h_errno_thread_specific=no
11312 echo "$ac_t""$ol_cv_h_errno_thread_specific" 1>&6
11314 if test $ol_cv_errno_thread_specific != yes \
11315 -o $ol_cv_h_errno_thread_specific != yes ; then
11316 LIBS="$LTHREAD_LIBS $LIBS"
11322 if test $ol_link_threads = no ; then
11323 if test $ol_with_threads = yes ; then
11324 { echo "configure: error: no suitable thread support" 1>&2; exit 1; }
11327 if test $ol_with_threads = auto ; then
11328 echo "configure: warning: no suitable thread support, disabling threads" 1>&2
11332 cat >> confdefs.h <<\EOF
11333 #define NO_THREADS 1
11339 if test $ol_link_threads != no ; then
11340 cat >> confdefs.h <<\EOF
11341 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
11348 if test $ol_with_ldbm_api = auto \
11349 -o $ol_with_ldbm_api = berkeley \
11350 -o $ol_with_ldbm_api = bcompat ; then
11352 if test $ol_with_ldbm_api = bcompat; then \
11353 ol_cv_berkeley_db=no
11354 for ac_hdr in db_185.h db.h
11356 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11357 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11358 echo "configure:11359: checking for $ac_hdr" >&5
11359 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11360 echo $ac_n "(cached) $ac_c" 1>&6
11362 cat > conftest.$ac_ext <<EOF
11363 #line 11364 "configure"
11364 #include "confdefs.h"
11367 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11368 { (eval echo configure:11369: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11369 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11370 if test -z "$ac_err"; then
11372 eval "ac_cv_header_$ac_safe=yes"
11375 echo "configure: failed program was:" >&5
11376 cat conftest.$ac_ext >&5
11378 eval "ac_cv_header_$ac_safe=no"
11382 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11383 echo "$ac_t""yes" 1>&6
11384 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11385 cat >> confdefs.h <<EOF
11386 #define $ac_tr_hdr 1
11390 echo "$ac_t""no" 1>&6
11394 if test $ac_cv_header_db_185_h = yes -o $ac_cv_header_db_h = yes; then
11395 echo $ac_n "checking if Berkeley DB header compatibility""... $ac_c" 1>&6
11396 echo "configure:11397: checking if Berkeley DB header compatibility" >&5
11397 if eval "test \"\${ol_cv_header_db1+set}\" = set"; then
11398 echo $ac_n "(cached) $ac_c" 1>&6
11401 cat > conftest.$ac_ext <<EOF
11402 #line 11403 "configure"
11403 #include "confdefs.h"
11406 # include <db_185.h>
11411 /* this check could be improved */
11412 #ifndef DB_VERSION_MAJOR
11413 # define DB_VERSION_MAJOR 1
11416 #if DB_VERSION_MAJOR == 1
11421 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11422 egrep "__db_version_1" >/dev/null 2>&1; then
11424 ol_cv_header_db1=yes
11427 ol_cv_header_db1=no
11433 echo "$ac_t""$ol_cv_header_db1" 1>&6
11435 if test ol_cv_header_db1=yes ; then
11437 if test $ol_cv_lib_db = no ; then
11438 echo $ac_n "checking for Berkeley DB link (default)""... $ac_c" 1>&6
11439 echo "configure:11440: checking for Berkeley DB link (default)" >&5
11440 if eval "test \"\${ol_cv_db_none+set}\" = set"; then
11441 echo $ac_n "(cached) $ac_c" 1>&6
11446 LIBS="$ol_DB_LIB $LIBS"
11448 cat > conftest.$ac_ext <<EOF
11449 #line 11450 "configure"
11450 #include "confdefs.h"
11452 #ifdef HAVE_DB_185_H
11453 # include <db_185.h>
11458 #ifndef DB_VERSION_MAJOR
11459 # define DB_VERSION_MAJOR 1
11463 #define NULL ((void*)0)
11468 #if DB_VERSION_MAJOR > 2
11469 db_env_create( NULL, 0 );
11470 #elif DB_VERSION_MAJOR > 1
11471 db_appexit( NULL );
11473 (void) dbopen( NULL, 0, 0, 0, NULL);
11478 if { (eval echo configure:11479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11482 echo "configure: failed program was:" >&5
11483 cat conftest.$ac_ext >&5
11493 echo "$ac_t""$ol_cv_db_none" 1>&6
11495 if test $ol_cv_db_none = yes ; then
11500 if test $ol_cv_lib_db = no ; then
11501 echo $ac_n "checking for Berkeley DB link (-ldb)""... $ac_c" 1>&6
11502 echo "configure:11503: checking for Berkeley DB link (-ldb)" >&5
11503 if eval "test \"\${ol_cv_db_db+set}\" = set"; then
11504 echo $ac_n "(cached) $ac_c" 1>&6
11509 LIBS="$ol_DB_LIB $LIBS"
11511 cat > conftest.$ac_ext <<EOF
11512 #line 11513 "configure"
11513 #include "confdefs.h"
11515 #ifdef HAVE_DB_185_H
11516 # include <db_185.h>
11521 #ifndef DB_VERSION_MAJOR
11522 # define DB_VERSION_MAJOR 1
11526 #define NULL ((void*)0)
11531 #if DB_VERSION_MAJOR > 2
11532 db_env_create( NULL, 0 );
11533 #elif DB_VERSION_MAJOR > 1
11534 db_appexit( NULL );
11536 (void) dbopen( NULL, 0, 0, 0, NULL);
11541 if { (eval echo configure:11542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11545 echo "configure: failed program was:" >&5
11546 cat conftest.$ac_ext >&5
11556 echo "$ac_t""$ol_cv_db_db" 1>&6
11558 if test $ol_cv_db_db = yes ; then
11563 if test $ol_cv_lib_db = no ; then
11564 echo $ac_n "checking for Berkeley DB link (-ldb3)""... $ac_c" 1>&6
11565 echo "configure:11566: checking for Berkeley DB link (-ldb3)" >&5
11566 if eval "test \"\${ol_cv_db_db3+set}\" = set"; then
11567 echo $ac_n "(cached) $ac_c" 1>&6
11572 LIBS="$ol_DB_LIB $LIBS"
11574 cat > conftest.$ac_ext <<EOF
11575 #line 11576 "configure"
11576 #include "confdefs.h"
11578 #ifdef HAVE_DB_185_H
11579 # include <db_185.h>
11584 #ifndef DB_VERSION_MAJOR
11585 # define DB_VERSION_MAJOR 1
11589 #define NULL ((void*)0)
11594 #if DB_VERSION_MAJOR > 2
11595 db_env_create( NULL, 0 );
11596 #elif DB_VERSION_MAJOR > 1
11597 db_appexit( NULL );
11599 (void) dbopen( NULL, 0, 0, 0, NULL);
11604 if { (eval echo configure:11605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11608 echo "configure: failed program was:" >&5
11609 cat conftest.$ac_ext >&5
11619 echo "$ac_t""$ol_cv_db_db3" 1>&6
11621 if test $ol_cv_db_db3 = yes ; then
11626 if test $ol_cv_lib_db = no ; then
11627 echo $ac_n "checking for Berkeley DB link (-ldb2)""... $ac_c" 1>&6
11628 echo "configure:11629: checking for Berkeley DB link (-ldb2)" >&5
11629 if eval "test \"\${ol_cv_db_db2+set}\" = set"; then
11630 echo $ac_n "(cached) $ac_c" 1>&6
11635 LIBS="$ol_DB_LIB $LIBS"
11637 cat > conftest.$ac_ext <<EOF
11638 #line 11639 "configure"
11639 #include "confdefs.h"
11641 #ifdef HAVE_DB_185_H
11642 # include <db_185.h>
11647 #ifndef DB_VERSION_MAJOR
11648 # define DB_VERSION_MAJOR 1
11652 #define NULL ((void*)0)
11657 #if DB_VERSION_MAJOR > 2
11658 db_env_create( NULL, 0 );
11659 #elif DB_VERSION_MAJOR > 1
11660 db_appexit( NULL );
11662 (void) dbopen( NULL, 0, 0, 0, NULL);
11667 if { (eval echo configure:11668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11671 echo "configure: failed program was:" >&5
11672 cat conftest.$ac_ext >&5
11682 echo "$ac_t""$ol_cv_db_db2" 1>&6
11684 if test $ol_cv_db_db2 = yes ; then
11689 if test $ol_cv_lib_db = no ; then
11690 echo $ac_n "checking for Berkeley DB link (-ldb1)""... $ac_c" 1>&6
11691 echo "configure:11692: checking for Berkeley DB link (-ldb1)" >&5
11692 if eval "test \"\${ol_cv_db_db1+set}\" = set"; then
11693 echo $ac_n "(cached) $ac_c" 1>&6
11698 LIBS="$ol_DB_LIB $LIBS"
11700 cat > conftest.$ac_ext <<EOF
11701 #line 11702 "configure"
11702 #include "confdefs.h"
11704 #ifdef HAVE_DB_185_H
11705 # include <db_185.h>
11710 #ifndef DB_VERSION_MAJOR
11711 # define DB_VERSION_MAJOR 1
11715 #define NULL ((void*)0)
11720 #if DB_VERSION_MAJOR > 2
11721 db_env_create( NULL, 0 );
11722 #elif DB_VERSION_MAJOR > 1
11723 db_appexit( NULL );
11725 (void) dbopen( NULL, 0, 0, 0, NULL);
11730 if { (eval echo configure:11731: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11734 echo "configure: failed program was:" >&5
11735 cat conftest.$ac_ext >&5
11745 echo "$ac_t""$ol_cv_db_db1" 1>&6
11747 if test $ol_cv_db_db1 = yes ; then
11753 if test "$ol_cv_lib_db" != no ; then
11754 ol_cv_berkeley_db=yes
11760 ol_cv_berkeley_db=no
11763 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11764 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11765 echo "configure:11766: checking for $ac_hdr" >&5
11766 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11767 echo $ac_n "(cached) $ac_c" 1>&6
11769 cat > conftest.$ac_ext <<EOF
11770 #line 11771 "configure"
11771 #include "confdefs.h"
11774 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11775 { (eval echo configure:11776: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11776 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11777 if test -z "$ac_err"; then
11779 eval "ac_cv_header_$ac_safe=yes"
11782 echo "configure: failed program was:" >&5
11783 cat conftest.$ac_ext >&5
11785 eval "ac_cv_header_$ac_safe=no"
11789 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11790 echo "$ac_t""yes" 1>&6
11791 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11792 cat >> confdefs.h <<EOF
11793 #define $ac_tr_hdr 1
11797 echo "$ac_t""no" 1>&6
11801 if test $ac_cv_header_db_h = yes; then
11803 if test $ol_cv_lib_db = no ; then
11804 echo $ac_n "checking for Berkeley DB link (default)""... $ac_c" 1>&6
11805 echo "configure:11806: checking for Berkeley DB link (default)" >&5
11806 if eval "test \"\${ol_cv_db_none+set}\" = set"; then
11807 echo $ac_n "(cached) $ac_c" 1>&6
11812 LIBS="$ol_DB_LIB $LIBS"
11814 cat > conftest.$ac_ext <<EOF
11815 #line 11816 "configure"
11816 #include "confdefs.h"
11818 #ifdef HAVE_DB_185_H
11819 # include <db_185.h>
11824 #ifndef DB_VERSION_MAJOR
11825 # define DB_VERSION_MAJOR 1
11829 #define NULL ((void*)0)
11834 #if DB_VERSION_MAJOR > 2
11835 db_env_create( NULL, 0 );
11836 #elif DB_VERSION_MAJOR > 1
11837 db_appexit( NULL );
11839 (void) dbopen( NULL, 0, 0, 0, NULL);
11844 if { (eval echo configure:11845: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11848 echo "configure: failed program was:" >&5
11849 cat conftest.$ac_ext >&5
11859 echo "$ac_t""$ol_cv_db_none" 1>&6
11861 if test $ol_cv_db_none = yes ; then
11866 if test $ol_cv_lib_db = no ; then
11867 echo $ac_n "checking for Berkeley DB link (-ldb)""... $ac_c" 1>&6
11868 echo "configure:11869: checking for Berkeley DB link (-ldb)" >&5
11869 if eval "test \"\${ol_cv_db_db+set}\" = set"; then
11870 echo $ac_n "(cached) $ac_c" 1>&6
11875 LIBS="$ol_DB_LIB $LIBS"
11877 cat > conftest.$ac_ext <<EOF
11878 #line 11879 "configure"
11879 #include "confdefs.h"
11881 #ifdef HAVE_DB_185_H
11882 # include <db_185.h>
11887 #ifndef DB_VERSION_MAJOR
11888 # define DB_VERSION_MAJOR 1
11892 #define NULL ((void*)0)
11897 #if DB_VERSION_MAJOR > 2
11898 db_env_create( NULL, 0 );
11899 #elif DB_VERSION_MAJOR > 1
11900 db_appexit( NULL );
11902 (void) dbopen( NULL, 0, 0, 0, NULL);
11907 if { (eval echo configure:11908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11911 echo "configure: failed program was:" >&5
11912 cat conftest.$ac_ext >&5
11922 echo "$ac_t""$ol_cv_db_db" 1>&6
11924 if test $ol_cv_db_db = yes ; then
11929 if test $ol_cv_lib_db = no ; then
11930 echo $ac_n "checking for Berkeley DB link (-ldb3)""... $ac_c" 1>&6
11931 echo "configure:11932: checking for Berkeley DB link (-ldb3)" >&5
11932 if eval "test \"\${ol_cv_db_db3+set}\" = set"; then
11933 echo $ac_n "(cached) $ac_c" 1>&6
11938 LIBS="$ol_DB_LIB $LIBS"
11940 cat > conftest.$ac_ext <<EOF
11941 #line 11942 "configure"
11942 #include "confdefs.h"
11944 #ifdef HAVE_DB_185_H
11945 # include <db_185.h>
11950 #ifndef DB_VERSION_MAJOR
11951 # define DB_VERSION_MAJOR 1
11955 #define NULL ((void*)0)
11960 #if DB_VERSION_MAJOR > 2
11961 db_env_create( NULL, 0 );
11962 #elif DB_VERSION_MAJOR > 1
11963 db_appexit( NULL );
11965 (void) dbopen( NULL, 0, 0, 0, NULL);
11970 if { (eval echo configure:11971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11974 echo "configure: failed program was:" >&5
11975 cat conftest.$ac_ext >&5
11985 echo "$ac_t""$ol_cv_db_db3" 1>&6
11987 if test $ol_cv_db_db3 = yes ; then
11992 if test $ol_cv_lib_db = no ; then
11993 echo $ac_n "checking for Berkeley DB link (-ldb2)""... $ac_c" 1>&6
11994 echo "configure:11995: checking for Berkeley DB link (-ldb2)" >&5
11995 if eval "test \"\${ol_cv_db_db2+set}\" = set"; then
11996 echo $ac_n "(cached) $ac_c" 1>&6
12001 LIBS="$ol_DB_LIB $LIBS"
12003 cat > conftest.$ac_ext <<EOF
12004 #line 12005 "configure"
12005 #include "confdefs.h"
12007 #ifdef HAVE_DB_185_H
12008 # include <db_185.h>
12013 #ifndef DB_VERSION_MAJOR
12014 # define DB_VERSION_MAJOR 1
12018 #define NULL ((void*)0)
12023 #if DB_VERSION_MAJOR > 2
12024 db_env_create( NULL, 0 );
12025 #elif DB_VERSION_MAJOR > 1
12026 db_appexit( NULL );
12028 (void) dbopen( NULL, 0, 0, 0, NULL);
12033 if { (eval echo configure:12034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12037 echo "configure: failed program was:" >&5
12038 cat conftest.$ac_ext >&5
12048 echo "$ac_t""$ol_cv_db_db2" 1>&6
12050 if test $ol_cv_db_db2 = yes ; then
12055 if test $ol_cv_lib_db = no ; then
12056 echo $ac_n "checking for Berkeley DB link (-ldb1)""... $ac_c" 1>&6
12057 echo "configure:12058: checking for Berkeley DB link (-ldb1)" >&5
12058 if eval "test \"\${ol_cv_db_db1+set}\" = set"; then
12059 echo $ac_n "(cached) $ac_c" 1>&6
12064 LIBS="$ol_DB_LIB $LIBS"
12066 cat > conftest.$ac_ext <<EOF
12067 #line 12068 "configure"
12068 #include "confdefs.h"
12070 #ifdef HAVE_DB_185_H
12071 # include <db_185.h>
12076 #ifndef DB_VERSION_MAJOR
12077 # define DB_VERSION_MAJOR 1
12081 #define NULL ((void*)0)
12086 #if DB_VERSION_MAJOR > 2
12087 db_env_create( NULL, 0 );
12088 #elif DB_VERSION_MAJOR > 1
12089 db_appexit( NULL );
12091 (void) dbopen( NULL, 0, 0, 0, NULL);
12096 if { (eval echo configure:12097: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12100 echo "configure: failed program was:" >&5
12101 cat conftest.$ac_ext >&5
12111 echo "$ac_t""$ol_cv_db_db1" 1>&6
12113 if test $ol_cv_db_db1 = yes ; then
12119 if test "$ol_cv_lib_db" != no ; then
12120 ol_cv_berkeley_db=yes
12121 echo $ac_n "checking for Berkeley DB thread support""... $ac_c" 1>&6
12122 echo "configure:12123: checking for Berkeley DB thread support" >&5
12123 if eval "test \"\${ol_cv_berkeley_db_thread+set}\" = set"; then
12124 echo $ac_n "(cached) $ac_c" 1>&6
12128 if test $ol_cv_lib_db != yes ; then
12129 LIBS="$ol_cv_lib_db"
12132 if test "$cross_compiling" = yes; then
12133 ol_cv_berkeley_db_thread=cross
12135 cat > conftest.$ac_ext <<EOF
12136 #line 12137 "configure"
12137 #include "confdefs.h"
12139 #ifdef HAVE_DB_185_H
12145 #define NULL ((void *)0)
12150 u_int32_t flags = DB_CREATE | DB_THREAD;
12153 #if DB_VERSION_MAJOR > 2
12154 DB_ENV *env = NULL;
12156 rc = db_env_create( &env, 0 );
12159 rc = env->open( env, NULL, NULL, flags, 0 );
12164 memset( &env, '\0', sizeof(env) );
12166 rc = db_appinit( NULL, NULL, &env, flags );
12169 db_appexit( &env );
12176 if { (eval echo configure:12177: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
12178 ol_cv_berkeley_db_thread=yes
12180 echo "configure: failed program was:" >&5
12181 cat conftest.$ac_ext >&5
12183 ol_cv_berkeley_db_thread=no
12191 if test $ol_cv_berkeley_db_thread != no ; then
12192 cat >> confdefs.h <<\EOF
12193 #define HAVE_BERKELEY_DB_THREAD 1
12200 echo "$ac_t""$ol_cv_berkeley_db_thread" 1>&6
12206 if test $ol_cv_berkeley_db != no ; then
12207 cat >> confdefs.h <<\EOF
12208 #define HAVE_BERKELEY_DB 1
12212 ol_link_ldbm=berkeley
12213 ol_with_ldbm_api=db
12215 if test $ol_with_ldbm_type = hash ; then
12216 cat >> confdefs.h <<\EOF
12217 #define LDBM_USE_DBHASH 1
12221 cat >> confdefs.h <<\EOF
12222 #define LDBM_USE_DBBTREE 1
12227 if test $ol_cv_lib_db != yes ; then
12228 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_db"
12233 if test $ol_link_ldbm = no -a $ol_with_ldbm_type = btree ; then
12234 echo "configure: warning: Could not find LDBM with BTREE support" 1>&2
12235 ol_with_ldbm_api=none
12238 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = mdbm ; then
12239 echo $ac_n "checking for MDBM library""... $ac_c" 1>&6
12240 echo "configure:12241: checking for MDBM library" >&5
12241 if eval "test \"\${ol_cv_lib_mdbm+set}\" = set"; then
12242 echo $ac_n "(cached) $ac_c" 1>&6
12245 echo $ac_n "checking for mdbm_set_chain""... $ac_c" 1>&6
12246 echo "configure:12247: checking for mdbm_set_chain" >&5
12247 if eval "test \"\${ac_cv_func_mdbm_set_chain+set}\" = set"; then
12248 echo $ac_n "(cached) $ac_c" 1>&6
12250 cat > conftest.$ac_ext <<EOF
12251 #line 12252 "configure"
12252 #include "confdefs.h"
12253 /* System header to define __stub macros and hopefully few prototypes,
12254 which can conflict with char mdbm_set_chain(); below. */
12255 #include <assert.h>
12256 /* Override any gcc2 internal prototype to avoid an error. */
12257 /* We use char because int might match the return type of a gcc2
12258 builtin and then its argument prototype would still apply. */
12259 char mdbm_set_chain();
12264 /* The GNU C library defines this for functions which it implements
12265 to always fail with ENOSYS. Some functions are actually named
12266 something starting with __ and the normal name is an alias. */
12267 #if defined (__stub_mdbm_set_chain) || defined (__stub___mdbm_set_chain)
12270 f = mdbm_set_chain;
12275 if { (eval echo configure:12276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12277 eval "ac_cv_func_mdbm_set_chain=yes"
12279 echo "configure: failed program was:" >&5
12280 cat conftest.$ac_ext >&5
12282 eval "ac_cv_func_mdbm_set_chain=no"
12287 if eval "test \"`echo '$ac_cv_func_'mdbm_set_chain`\" = yes"; then
12288 echo "$ac_t""yes" 1>&6
12291 echo "$ac_t""no" 1>&6
12293 echo $ac_n "checking for mdbm_set_chain in -lmdbm""... $ac_c" 1>&6
12294 echo "configure:12295: checking for mdbm_set_chain in -lmdbm" >&5
12295 ac_lib_var=`echo mdbm'_'mdbm_set_chain | sed 'y%./+-:%__p__%'`
12296 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12297 echo $ac_n "(cached) $ac_c" 1>&6
12299 ac_save_LIBS="$LIBS"
12300 LIBS="-lmdbm $LIBS"
12301 cat > conftest.$ac_ext <<EOF
12302 #line 12303 "configure"
12303 #include "confdefs.h"
12304 /* Override any gcc2 internal prototype to avoid an error. */
12305 /* We use char because int might match the return type of a gcc2
12306 builtin and then its argument prototype would still apply. */
12307 char mdbm_set_chain();
12313 if { (eval echo configure:12314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12315 eval "ac_cv_lib_$ac_lib_var=yes"
12317 echo "configure: failed program was:" >&5
12318 cat conftest.$ac_ext >&5
12320 eval "ac_cv_lib_$ac_lib_var=no"
12323 LIBS="$ac_save_LIBS"
12326 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12327 echo "$ac_t""yes" 1>&6
12328 ol_cv_lib_mdbm=-lmdbm
12330 echo "$ac_t""no" 1>&6
12341 echo "$ac_t""$ol_cv_lib_mdbm" 1>&6
12344 for ac_hdr in mdbm.h
12346 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12347 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12348 echo "configure:12349: checking for $ac_hdr" >&5
12349 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12350 echo $ac_n "(cached) $ac_c" 1>&6
12352 cat > conftest.$ac_ext <<EOF
12353 #line 12354 "configure"
12354 #include "confdefs.h"
12357 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12358 { (eval echo configure:12359: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12359 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12360 if test -z "$ac_err"; then
12362 eval "ac_cv_header_$ac_safe=yes"
12365 echo "configure: failed program was:" >&5
12366 cat conftest.$ac_ext >&5
12368 eval "ac_cv_header_$ac_safe=no"
12372 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12373 echo "$ac_t""yes" 1>&6
12374 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12375 cat >> confdefs.h <<EOF
12376 #define $ac_tr_hdr 1
12380 echo "$ac_t""no" 1>&6
12384 echo $ac_n "checking for db""... $ac_c" 1>&6
12385 echo "configure:12386: checking for db" >&5
12386 if eval "test \"\${ol_cv_mdbm+set}\" = set"; then
12387 echo $ac_n "(cached) $ac_c" 1>&6
12390 if test $ol_cv_lib_mdbm = no -o $ac_cv_header_mdbm_h = no ; then
12398 echo "$ac_t""$ol_cv_mdbm" 1>&6
12399 if test $ol_cv_mdbm = yes ; then
12400 cat >> confdefs.h <<\EOF
12401 #define HAVE_MDBM 1
12407 if test $ol_cv_mdbm = yes ; then
12409 ol_with_ldbm_api=mdbm
12410 if test $ol_cv_lib_mdbm != yes ; then
12411 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_mdbm"
12416 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = gdbm ; then
12417 echo $ac_n "checking for GDBM library""... $ac_c" 1>&6
12418 echo "configure:12419: checking for GDBM library" >&5
12419 if eval "test \"\${ol_cv_lib_gdbm+set}\" = set"; then
12420 echo $ac_n "(cached) $ac_c" 1>&6
12423 echo $ac_n "checking for gdbm_open""... $ac_c" 1>&6
12424 echo "configure:12425: checking for gdbm_open" >&5
12425 if eval "test \"\${ac_cv_func_gdbm_open+set}\" = set"; then
12426 echo $ac_n "(cached) $ac_c" 1>&6
12428 cat > conftest.$ac_ext <<EOF
12429 #line 12430 "configure"
12430 #include "confdefs.h"
12431 /* System header to define __stub macros and hopefully few prototypes,
12432 which can conflict with char gdbm_open(); below. */
12433 #include <assert.h>
12434 /* Override any gcc2 internal prototype to avoid an error. */
12435 /* We use char because int might match the return type of a gcc2
12436 builtin and then its argument prototype would still apply. */
12442 /* The GNU C library defines this for functions which it implements
12443 to always fail with ENOSYS. Some functions are actually named
12444 something starting with __ and the normal name is an alias. */
12445 #if defined (__stub_gdbm_open) || defined (__stub___gdbm_open)
12453 if { (eval echo configure:12454: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12455 eval "ac_cv_func_gdbm_open=yes"
12457 echo "configure: failed program was:" >&5
12458 cat conftest.$ac_ext >&5
12460 eval "ac_cv_func_gdbm_open=no"
12465 if eval "test \"`echo '$ac_cv_func_'gdbm_open`\" = yes"; then
12466 echo "$ac_t""yes" 1>&6
12469 echo "$ac_t""no" 1>&6
12471 echo $ac_n "checking for gdbm_open in -lgdbm""... $ac_c" 1>&6
12472 echo "configure:12473: checking for gdbm_open in -lgdbm" >&5
12473 ac_lib_var=`echo gdbm'_'gdbm_open | sed 'y%./+-:%__p__%'`
12474 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12475 echo $ac_n "(cached) $ac_c" 1>&6
12477 ac_save_LIBS="$LIBS"
12478 LIBS="-lgdbm $LIBS"
12479 cat > conftest.$ac_ext <<EOF
12480 #line 12481 "configure"
12481 #include "confdefs.h"
12482 /* Override any gcc2 internal prototype to avoid an error. */
12483 /* We use char because int might match the return type of a gcc2
12484 builtin and then its argument prototype would still apply. */
12491 if { (eval echo configure:12492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12493 eval "ac_cv_lib_$ac_lib_var=yes"
12495 echo "configure: failed program was:" >&5
12496 cat conftest.$ac_ext >&5
12498 eval "ac_cv_lib_$ac_lib_var=no"
12501 LIBS="$ac_save_LIBS"
12504 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12505 echo "$ac_t""yes" 1>&6
12506 ol_cv_lib_gdbm=-lgdbm
12508 echo "$ac_t""no" 1>&6
12519 echo "$ac_t""$ol_cv_lib_gdbm" 1>&6
12522 for ac_hdr in gdbm.h
12524 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12525 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12526 echo "configure:12527: checking for $ac_hdr" >&5
12527 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12528 echo $ac_n "(cached) $ac_c" 1>&6
12530 cat > conftest.$ac_ext <<EOF
12531 #line 12532 "configure"
12532 #include "confdefs.h"
12535 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12536 { (eval echo configure:12537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12537 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12538 if test -z "$ac_err"; then
12540 eval "ac_cv_header_$ac_safe=yes"
12543 echo "configure: failed program was:" >&5
12544 cat conftest.$ac_ext >&5
12546 eval "ac_cv_header_$ac_safe=no"
12550 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12551 echo "$ac_t""yes" 1>&6
12552 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12553 cat >> confdefs.h <<EOF
12554 #define $ac_tr_hdr 1
12558 echo "$ac_t""no" 1>&6
12562 echo $ac_n "checking for db""... $ac_c" 1>&6
12563 echo "configure:12564: checking for db" >&5
12564 if eval "test \"\${ol_cv_gdbm+set}\" = set"; then
12565 echo $ac_n "(cached) $ac_c" 1>&6
12568 if test $ol_cv_lib_gdbm = no -o $ac_cv_header_gdbm_h = no ; then
12576 echo "$ac_t""$ol_cv_gdbm" 1>&6
12577 if test $ol_cv_gdbm = yes ; then
12578 cat >> confdefs.h <<\EOF
12579 #define HAVE_GDBM 1
12585 if test $ol_cv_gdbm = yes ; then
12587 ol_with_ldbm_api=gdbm
12589 if test $ol_cv_lib_gdbm != yes ; then
12590 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_gdbm"
12595 if test $ol_with_ldbm_api = ndbm ; then
12596 echo $ac_n "checking for NDBM library""... $ac_c" 1>&6
12597 echo "configure:12598: checking for NDBM library" >&5
12598 if eval "test \"\${ol_cv_lib_ndbm+set}\" = set"; then
12599 echo $ac_n "(cached) $ac_c" 1>&6
12602 echo $ac_n "checking for dbm_open""... $ac_c" 1>&6
12603 echo "configure:12604: checking for dbm_open" >&5
12604 if eval "test \"\${ac_cv_func_dbm_open+set}\" = set"; then
12605 echo $ac_n "(cached) $ac_c" 1>&6
12607 cat > conftest.$ac_ext <<EOF
12608 #line 12609 "configure"
12609 #include "confdefs.h"
12610 /* System header to define __stub macros and hopefully few prototypes,
12611 which can conflict with char dbm_open(); below. */
12612 #include <assert.h>
12613 /* Override any gcc2 internal prototype to avoid an error. */
12614 /* We use char because int might match the return type of a gcc2
12615 builtin and then its argument prototype would still apply. */
12621 /* The GNU C library defines this for functions which it implements
12622 to always fail with ENOSYS. Some functions are actually named
12623 something starting with __ and the normal name is an alias. */
12624 #if defined (__stub_dbm_open) || defined (__stub___dbm_open)
12632 if { (eval echo configure:12633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12634 eval "ac_cv_func_dbm_open=yes"
12636 echo "configure: failed program was:" >&5
12637 cat conftest.$ac_ext >&5
12639 eval "ac_cv_func_dbm_open=no"
12644 if eval "test \"`echo '$ac_cv_func_'dbm_open`\" = yes"; then
12645 echo "$ac_t""yes" 1>&6
12648 echo "$ac_t""no" 1>&6
12650 echo $ac_n "checking for dbm_open in -lndbm""... $ac_c" 1>&6
12651 echo "configure:12652: checking for dbm_open in -lndbm" >&5
12652 ac_lib_var=`echo ndbm'_'dbm_open | sed 'y%./+-:%__p__%'`
12653 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12654 echo $ac_n "(cached) $ac_c" 1>&6
12656 ac_save_LIBS="$LIBS"
12657 LIBS="-lndbm $LIBS"
12658 cat > conftest.$ac_ext <<EOF
12659 #line 12660 "configure"
12660 #include "confdefs.h"
12661 /* Override any gcc2 internal prototype to avoid an error. */
12662 /* We use char because int might match the return type of a gcc2
12663 builtin and then its argument prototype would still apply. */
12670 if { (eval echo configure:12671: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12672 eval "ac_cv_lib_$ac_lib_var=yes"
12674 echo "configure: failed program was:" >&5
12675 cat conftest.$ac_ext >&5
12677 eval "ac_cv_lib_$ac_lib_var=no"
12680 LIBS="$ac_save_LIBS"
12683 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12684 echo "$ac_t""yes" 1>&6
12685 ol_cv_lib_ndbm=-lndbm
12687 echo "$ac_t""no" 1>&6
12689 echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6
12690 echo "configure:12691: checking for dbm_open in -ldbm" >&5
12691 ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-:%__p__%'`
12692 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12693 echo $ac_n "(cached) $ac_c" 1>&6
12695 ac_save_LIBS="$LIBS"
12697 cat > conftest.$ac_ext <<EOF
12698 #line 12699 "configure"
12699 #include "confdefs.h"
12700 /* Override any gcc2 internal prototype to avoid an error. */
12701 /* We use char because int might match the return type of a gcc2
12702 builtin and then its argument prototype would still apply. */
12709 if { (eval echo configure:12710: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12711 eval "ac_cv_lib_$ac_lib_var=yes"
12713 echo "configure: failed program was:" >&5
12714 cat conftest.$ac_ext >&5
12716 eval "ac_cv_lib_$ac_lib_var=no"
12719 LIBS="$ac_save_LIBS"
12722 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12723 echo "$ac_t""yes" 1>&6
12724 ol_cv_lib_ndbm=-ldbm
12726 echo "$ac_t""no" 1>&6
12739 echo "$ac_t""$ol_cv_lib_ndbm" 1>&6
12742 for ac_hdr in ndbm.h
12744 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12745 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12746 echo "configure:12747: checking for $ac_hdr" >&5
12747 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12748 echo $ac_n "(cached) $ac_c" 1>&6
12750 cat > conftest.$ac_ext <<EOF
12751 #line 12752 "configure"
12752 #include "confdefs.h"
12755 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12756 { (eval echo configure:12757: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12757 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12758 if test -z "$ac_err"; then
12760 eval "ac_cv_header_$ac_safe=yes"
12763 echo "configure: failed program was:" >&5
12764 cat conftest.$ac_ext >&5
12766 eval "ac_cv_header_$ac_safe=no"
12770 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12771 echo "$ac_t""yes" 1>&6
12772 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12773 cat >> confdefs.h <<EOF
12774 #define $ac_tr_hdr 1
12778 echo "$ac_t""no" 1>&6
12782 echo $ac_n "checking for db""... $ac_c" 1>&6
12783 echo "configure:12784: checking for db" >&5
12784 if eval "test \"\${ol_cv_ndbm+set}\" = set"; then
12785 echo $ac_n "(cached) $ac_c" 1>&6
12788 if test $ol_cv_lib_ndbm = no -o $ac_cv_header_ndbm_h = no ; then
12796 echo "$ac_t""$ol_cv_ndbm" 1>&6
12797 if test $ol_cv_ndbm = yes ; then
12798 cat >> confdefs.h <<\EOF
12799 #define HAVE_NDBM 1
12805 if test $ol_cv_ndbm = yes ; then
12807 ol_with_ldbm_api=ndbm
12809 if test $ol_cv_lib_ndbm != yes ; then
12810 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_ndbm"
12815 if test $ol_link_ldbm = no -a $ol_enable_ldbm != no ; then
12816 echo "configure: warning: could not find suitable LDBM backend" 1>&2
12817 if test $ol_enable_ldbm = yes ; then
12818 { echo "configure: error: select appropriate LDBM options or disable" 1>&2; exit 1; }
12821 echo "configure: warning: disabling LDBM" 1>&2
12825 if test $ol_enable_dynamic = yes -a $enable_shared = yes ; then
12826 LINK_BINS_DYNAMIC="yes"
12828 LINK_BINS_DYNAMIC="no"
12831 if test $ol_enable_wrappers != no ; then
12832 for ac_hdr in tcpd.h
12834 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12835 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12836 echo "configure:12837: checking for $ac_hdr" >&5
12837 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12838 echo $ac_n "(cached) $ac_c" 1>&6
12840 cat > conftest.$ac_ext <<EOF
12841 #line 12842 "configure"
12842 #include "confdefs.h"
12845 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12846 { (eval echo configure:12847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12847 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12848 if test -z "$ac_err"; then
12850 eval "ac_cv_header_$ac_safe=yes"
12853 echo "configure: failed program was:" >&5
12854 cat conftest.$ac_ext >&5
12856 eval "ac_cv_header_$ac_safe=no"
12860 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12861 echo "$ac_t""yes" 1>&6
12862 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12863 cat >> confdefs.h <<EOF
12864 #define $ac_tr_hdr 1
12868 echo "$ac_t""no" 1>&6
12873 if test $ac_cv_header_tcpd_h != yes ; then
12876 cat > conftest.$ac_ext <<EOF
12877 #line 12878 "configure"
12878 #include "confdefs.h"
12880 int allow_severity = 0;
12881 int deny_severity = 0;
12887 if { (eval echo configure:12888: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
12891 echo "configure: failed program was:" >&5
12892 cat conftest.$ac_ext >&5
12899 if test $have_wrappers = yes ; then
12900 cat >> confdefs.h <<\EOF
12901 #define HAVE_TCPD 1
12906 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
12907 echo "configure:12908: checking for main in -lnsl" >&5
12908 ac_lib_var=`echo nsl'_'main | sed 'y%./+-:%__p__%'`
12909 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12910 echo $ac_n "(cached) $ac_c" 1>&6
12912 ac_save_LIBS="$LIBS"
12914 cat > conftest.$ac_ext <<EOF
12915 #line 12916 "configure"
12916 #include "confdefs.h"
12922 if { (eval echo configure:12923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12924 eval "ac_cv_lib_$ac_lib_var=yes"
12926 echo "configure: failed program was:" >&5
12927 cat conftest.$ac_ext >&5
12929 eval "ac_cv_lib_$ac_lib_var=no"
12932 LIBS="$ac_save_LIBS"
12935 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12936 echo "$ac_t""yes" 1>&6
12937 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
12938 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
12939 cat >> confdefs.h <<EOF
12940 #define $ac_tr_lib 1
12946 echo "$ac_t""no" 1>&6
12950 echo "configure: warning: could not find -lwrap" 1>&2
12951 if test $ol_enable_wrappers = yes ; then
12952 { echo "configure: error: could not find wrappers" 1>&2; exit 1; }
12955 echo "configure: warning: disabling wrappers support" 1>&2
12956 ol_enable_wrappers=no
12961 if test $ol_enable_syslog != no ; then
12962 echo $ac_n "checking for openlog""... $ac_c" 1>&6
12963 echo "configure:12964: checking for openlog" >&5
12964 if eval "test \"\${ac_cv_func_openlog+set}\" = set"; then
12965 echo $ac_n "(cached) $ac_c" 1>&6
12967 cat > conftest.$ac_ext <<EOF
12968 #line 12969 "configure"
12969 #include "confdefs.h"
12970 /* System header to define __stub macros and hopefully few prototypes,
12971 which can conflict with char openlog(); below. */
12972 #include <assert.h>
12973 /* Override any gcc2 internal prototype to avoid an error. */
12974 /* We use char because int might match the return type of a gcc2
12975 builtin and then its argument prototype would still apply. */
12981 /* The GNU C library defines this for functions which it implements
12982 to always fail with ENOSYS. Some functions are actually named
12983 something starting with __ and the normal name is an alias. */
12984 #if defined (__stub_openlog) || defined (__stub___openlog)
12992 if { (eval echo configure:12993: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12994 eval "ac_cv_func_openlog=yes"
12996 echo "configure: failed program was:" >&5
12997 cat conftest.$ac_ext >&5
12999 eval "ac_cv_func_openlog=no"
13004 if eval "test \"`echo '$ac_cv_func_'openlog`\" = yes"; then
13005 echo "$ac_t""yes" 1>&6
13008 echo "$ac_t""no" 1>&6
13011 if test $ac_cv_func_openlog = no -a $ol_enable_syslog = yes; then
13012 { echo "configure: error: could not find syslog" 1>&2; exit 1; }
13014 ol_enable_syslog=$ac_cv_func_openlog
13017 if test $ol_enable_tcl != no ; then
13018 for ac_hdr in tcl.h
13020 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13021 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13022 echo "configure:13023: checking for $ac_hdr" >&5
13023 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13024 echo $ac_n "(cached) $ac_c" 1>&6
13026 cat > conftest.$ac_ext <<EOF
13027 #line 13028 "configure"
13028 #include "confdefs.h"
13031 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13032 { (eval echo configure:13033: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13033 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13034 if test -z "$ac_err"; then
13036 eval "ac_cv_header_$ac_safe=yes"
13039 echo "configure: failed program was:" >&5
13040 cat conftest.$ac_ext >&5
13042 eval "ac_cv_header_$ac_safe=no"
13046 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13047 echo "$ac_t""yes" 1>&6
13048 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13049 cat >> confdefs.h <<EOF
13050 #define $ac_tr_hdr 1
13054 echo "$ac_t""no" 1>&6
13059 if test $ac_cv_header_tcl_h != yes ; then
13062 for lib in tcl tcl7.6 tcl8.0 tcl8.2 ; do
13063 echo $ac_n "checking for main in -l$lib""... $ac_c" 1>&6
13064 echo "configure:13065: checking for main in -l$lib" >&5
13065 ac_lib_var=`echo $lib'_'main | sed 'y%./+-:%__p__%'`
13066 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13067 echo $ac_n "(cached) $ac_c" 1>&6
13069 ac_save_LIBS="$LIBS"
13070 LIBS="-l$lib $LIBS"
13071 cat > conftest.$ac_ext <<EOF
13072 #line 13073 "configure"
13073 #include "confdefs.h"
13079 if { (eval echo configure:13080: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13081 eval "ac_cv_lib_$ac_lib_var=yes"
13083 echo "configure: failed program was:" >&5
13084 cat conftest.$ac_ext >&5
13086 eval "ac_cv_lib_$ac_lib_var=no"
13089 LIBS="$ac_save_LIBS"
13092 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13093 echo "$ac_t""yes" 1>&6
13095 if test x"$ol_with_tcl_module" = "xstatic" ; then
13096 SLAPD_LIBS="$SLAPD_LIBS -l${lib}"
13098 MOD_TCL_LIB="-l${lib}"
13101 echo "$ac_t""no" 1>&6
13108 if test $have_tcl != yes ; then
13109 echo "configure: warning: could not find -ltcl" 1>&2
13110 if test $ol_enable_tcl = yes ; then
13111 { echo "configure: error: could not find tcl, select appropriate options or disable" 1>&2; exit 1; }
13119 for ac_hdr in termcap.h ncurses.h
13121 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13122 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13123 echo "configure:13124: checking for $ac_hdr" >&5
13124 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13125 echo $ac_n "(cached) $ac_c" 1>&6
13127 cat > conftest.$ac_ext <<EOF
13128 #line 13129 "configure"
13129 #include "confdefs.h"
13132 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13133 { (eval echo configure:13134: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13134 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13135 if test -z "$ac_err"; then
13137 eval "ac_cv_header_$ac_safe=yes"
13140 echo "configure: failed program was:" >&5
13141 cat conftest.$ac_ext >&5
13143 eval "ac_cv_header_$ac_safe=no"
13147 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13148 echo "$ac_t""yes" 1>&6
13149 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13150 cat >> confdefs.h <<EOF
13151 #define $ac_tr_hdr 1
13155 echo "$ac_t""no" 1>&6
13160 if test $ol_link_termcap = no ; then
13161 echo $ac_n "checking for tputs in -ltermcap""... $ac_c" 1>&6
13162 echo "configure:13163: checking for tputs in -ltermcap" >&5
13163 ac_lib_var=`echo termcap'_'tputs | sed 'y%./+-:%__p__%'`
13164 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13165 echo $ac_n "(cached) $ac_c" 1>&6
13167 ac_save_LIBS="$LIBS"
13168 LIBS="-ltermcap $LIBS"
13169 cat > conftest.$ac_ext <<EOF
13170 #line 13171 "configure"
13171 #include "confdefs.h"
13172 /* Override any gcc2 internal prototype to avoid an error. */
13173 /* We use char because int might match the return type of a gcc2
13174 builtin and then its argument prototype would still apply. */
13181 if { (eval echo configure:13182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13183 eval "ac_cv_lib_$ac_lib_var=yes"
13185 echo "configure: failed program was:" >&5
13186 cat conftest.$ac_ext >&5
13188 eval "ac_cv_lib_$ac_lib_var=no"
13191 LIBS="$ac_save_LIBS"
13194 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13195 echo "$ac_t""yes" 1>&6
13198 echo "$ac_t""no" 1>&6
13202 if test $have_termcap = yes ; then
13203 cat >> confdefs.h <<\EOF
13204 #define HAVE_TERMCAP 1
13207 ol_link_termcap=yes
13208 TERMCAP_LIBS=-ltermcap
13212 if test $ol_link_termcap = no ; then
13213 echo $ac_n "checking for initscr in -lncurses""... $ac_c" 1>&6
13214 echo "configure:13215: checking for initscr in -lncurses" >&5
13215 ac_lib_var=`echo ncurses'_'initscr | sed 'y%./+-:%__p__%'`
13216 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13217 echo $ac_n "(cached) $ac_c" 1>&6
13219 ac_save_LIBS="$LIBS"
13220 LIBS="-lncurses $LIBS"
13221 cat > conftest.$ac_ext <<EOF
13222 #line 13223 "configure"
13223 #include "confdefs.h"
13224 /* Override any gcc2 internal prototype to avoid an error. */
13225 /* We use char because int might match the return type of a gcc2
13226 builtin and then its argument prototype would still apply. */
13233 if { (eval echo configure:13234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13235 eval "ac_cv_lib_$ac_lib_var=yes"
13237 echo "configure: failed program was:" >&5
13238 cat conftest.$ac_ext >&5
13240 eval "ac_cv_lib_$ac_lib_var=no"
13243 LIBS="$ac_save_LIBS"
13246 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13247 echo "$ac_t""yes" 1>&6
13250 echo "$ac_t""no" 1>&6
13254 if test $have_ncurses = yes ; then
13255 cat >> confdefs.h <<\EOF
13256 #define HAVE_NCURSES 1
13259 ol_link_termcap=yes
13260 TERMCAP_LIBS=-lncurses
13264 if test $ol_link_termcap = no ; then
13265 cat >> confdefs.h <<\EOF
13266 #define NO_TERMCAP 1
13274 if test $ol_with_cyrus_sasl != no ; then
13275 ac_safe=`echo "sasl.h" | sed 'y%./+-%__p_%'`
13276 echo $ac_n "checking for sasl.h""... $ac_c" 1>&6
13277 echo "configure:13278: checking for sasl.h" >&5
13278 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13279 echo $ac_n "(cached) $ac_c" 1>&6
13281 cat > conftest.$ac_ext <<EOF
13282 #line 13283 "configure"
13283 #include "confdefs.h"
13286 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13287 { (eval echo configure:13288: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13288 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13289 if test -z "$ac_err"; then
13291 eval "ac_cv_header_$ac_safe=yes"
13294 echo "configure: failed program was:" >&5
13295 cat conftest.$ac_ext >&5
13297 eval "ac_cv_header_$ac_safe=no"
13301 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13302 echo "$ac_t""yes" 1>&6
13305 echo "$ac_t""no" 1>&6
13309 if test $ac_cv_header_sasl_h = yes ; then
13310 echo $ac_n "checking for sasl_client_init in -lsasl""... $ac_c" 1>&6
13311 echo "configure:13312: checking for sasl_client_init in -lsasl" >&5
13312 ac_lib_var=`echo sasl'_'sasl_client_init | sed 'y%./+-:%__p__%'`
13313 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13314 echo $ac_n "(cached) $ac_c" 1>&6
13316 ac_save_LIBS="$LIBS"
13317 LIBS="-lsasl $LIBS"
13318 cat > conftest.$ac_ext <<EOF
13319 #line 13320 "configure"
13320 #include "confdefs.h"
13321 /* Override any gcc2 internal prototype to avoid an error. */
13322 /* We use char because int might match the return type of a gcc2
13323 builtin and then its argument prototype would still apply. */
13324 char sasl_client_init();
13330 if { (eval echo configure:13331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13332 eval "ac_cv_lib_$ac_lib_var=yes"
13334 echo "configure: failed program was:" >&5
13335 cat conftest.$ac_ext >&5
13337 eval "ac_cv_lib_$ac_lib_var=no"
13340 LIBS="$ac_save_LIBS"
13343 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13344 echo "$ac_t""yes" 1>&6
13345 have_cyrus_sasl=yes
13347 echo "$ac_t""no" 1>&6
13352 if test $have_cyrus_sasl != no ; then
13354 cat >> confdefs.h <<\EOF
13355 #define HAVE_CYRUS_SASL 1
13362 if test $ol_link_sasl = no -a $ol_with_cyrus_sasl = yes ; then
13363 { echo "configure: error: no suitable API for --with-cyrus-sasl=$ol_with_cyrus_sasl" 1>&2; exit 1; }
13367 if test $cross_compiling != yes ; then
13369 if test -r /dev/urandom ; then
13370 dev="/dev/urandom";
13371 elif test -r /idev/urandom ; then
13372 dev="/idev/urandom";
13373 elif test -r /dev/srandom ; then
13374 dev="/dev/srandom";
13375 elif test -r /dev/random ; then
13377 elif test -r /idev/random ; then
13378 dev="/idev/random";
13381 if test $dev != no ; then
13382 cat >> confdefs.h <<EOF
13383 #define URANDOM_DEVICE "$dev"
13390 if test $ol_with_fetch != no ; then
13392 LIBS="-lfetch -lcom_err $LIBS"
13393 echo $ac_n "checking fetch(3) library""... $ac_c" 1>&6
13394 echo "configure:13395: checking fetch(3) library" >&5
13395 if eval "test \"\${ol_cv_lib_fetch+set}\" = set"; then
13396 echo $ac_n "(cached) $ac_c" 1>&6
13399 cat > conftest.$ac_ext <<EOF
13400 #line 13401 "configure"
13401 #include "confdefs.h"
13403 #include <sys/param.h>
13407 struct url *u = fetchParseURL("file:///");
13410 if { (eval echo configure:13411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13412 ol_cv_lib_fetch=yes
13414 echo "configure: failed program was:" >&5
13415 cat conftest.$ac_ext >&5
13422 echo "$ac_t""$ol_cv_lib_fetch" 1>&6
13424 if test $ol_cv_lib_fetch != no ; then
13425 ol_link_fetch="-lfetch -lcom_err"
13426 cat >> confdefs.h <<\EOF
13427 #define HAVE_FETCH 1
13433 if test $ol_cv_lib_fetch != no ; then
13434 LDIF_LIBS="$LDIF_LIBS $ol_link_fetch"
13435 ol_link_fetch=freebsd
13437 elif test $ol_with_fetch != auto ; then
13438 { echo "configure: error: no suitable API for --with-fetch=$ol_with_fetch" 1>&2; exit 1; }
13442 ol_link_readline=no
13443 if test $ol_with_readline != no ; then
13444 for ac_hdr in readline/readline.h readline/history.h
13446 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13447 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13448 echo "configure:13449: checking for $ac_hdr" >&5
13449 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13450 echo $ac_n "(cached) $ac_c" 1>&6
13452 cat > conftest.$ac_ext <<EOF
13453 #line 13454 "configure"
13454 #include "confdefs.h"
13457 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13458 { (eval echo configure:13459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13459 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13460 if test -z "$ac_err"; then
13462 eval "ac_cv_header_$ac_safe=yes"
13465 echo "configure: failed program was:" >&5
13466 cat conftest.$ac_ext >&5
13468 eval "ac_cv_header_$ac_safe=no"
13472 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13473 echo "$ac_t""yes" 1>&6
13474 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13475 cat >> confdefs.h <<EOF
13476 #define $ac_tr_hdr 1
13480 echo "$ac_t""no" 1>&6
13485 if test $ac_cv_header_readline_readline_h = yes ; then
13487 LIBS="$TERMCAP_LIBS $LIBS"
13488 echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
13489 echo "configure:13490: checking for readline in -lreadline" >&5
13490 ac_lib_var=`echo readline'_'readline | sed 'y%./+-:%__p__%'`
13491 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13492 echo $ac_n "(cached) $ac_c" 1>&6
13494 ac_save_LIBS="$LIBS"
13495 LIBS="-lreadline $LIBS"
13496 cat > conftest.$ac_ext <<EOF
13497 #line 13498 "configure"
13498 #include "confdefs.h"
13499 /* Override any gcc2 internal prototype to avoid an error. */
13500 /* We use char because int might match the return type of a gcc2
13501 builtin and then its argument prototype would still apply. */
13508 if { (eval echo configure:13509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13510 eval "ac_cv_lib_$ac_lib_var=yes"
13512 echo "configure: failed program was:" >&5
13513 cat conftest.$ac_ext >&5
13515 eval "ac_cv_lib_$ac_lib_var=no"
13518 LIBS="$ac_save_LIBS"
13521 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13522 echo "$ac_t""yes" 1>&6
13525 echo "$ac_t""no" 1>&6
13531 if test $have_readline = yes ; then
13532 ol_with_readline=found
13533 ol_link_readline=yes
13535 READLINE_LIBS="-lreadline"
13540 if test $ol_link_readline = yes ; then
13541 cat >> confdefs.h <<\EOF
13542 #define HAVE_READLINE 1
13548 if test $ol_enable_crypt != no ; then
13549 echo $ac_n "checking for crypt""... $ac_c" 1>&6
13550 echo "configure:13551: checking for crypt" >&5
13551 if eval "test \"\${ac_cv_func_crypt+set}\" = set"; then
13552 echo $ac_n "(cached) $ac_c" 1>&6
13554 cat > conftest.$ac_ext <<EOF
13555 #line 13556 "configure"
13556 #include "confdefs.h"
13557 /* System header to define __stub macros and hopefully few prototypes,
13558 which can conflict with char crypt(); below. */
13559 #include <assert.h>
13560 /* Override any gcc2 internal prototype to avoid an error. */
13561 /* We use char because int might match the return type of a gcc2
13562 builtin and then its argument prototype would still apply. */
13568 /* The GNU C library defines this for functions which it implements
13569 to always fail with ENOSYS. Some functions are actually named
13570 something starting with __ and the normal name is an alias. */
13571 #if defined (__stub_crypt) || defined (__stub___crypt)
13579 if { (eval echo configure:13580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13581 eval "ac_cv_func_crypt=yes"
13583 echo "configure: failed program was:" >&5
13584 cat conftest.$ac_ext >&5
13586 eval "ac_cv_func_crypt=no"
13591 if eval "test \"`echo '$ac_cv_func_'crypt`\" = yes"; then
13592 echo "$ac_t""yes" 1>&6
13595 echo "$ac_t""no" 1>&6
13597 echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
13598 echo "configure:13599: checking for crypt in -lcrypt" >&5
13599 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-:%__p__%'`
13600 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13601 echo $ac_n "(cached) $ac_c" 1>&6
13603 ac_save_LIBS="$LIBS"
13604 LIBS="-lcrypt $LIBS"
13605 cat > conftest.$ac_ext <<EOF
13606 #line 13607 "configure"
13607 #include "confdefs.h"
13608 /* Override any gcc2 internal prototype to avoid an error. */
13609 /* We use char because int might match the return type of a gcc2
13610 builtin and then its argument prototype would still apply. */
13617 if { (eval echo configure:13618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13619 eval "ac_cv_lib_$ac_lib_var=yes"
13621 echo "configure: failed program was:" >&5
13622 cat conftest.$ac_ext >&5
13624 eval "ac_cv_lib_$ac_lib_var=no"
13627 LIBS="$ac_save_LIBS"
13630 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13631 echo "$ac_t""yes" 1>&6
13632 LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
13635 echo "$ac_t""no" 1>&6
13642 if test $have_crypt = yes ; then
13643 cat >> confdefs.h <<\EOF
13644 #define HAVE_CRYPT 1
13648 echo "configure: warning: could not find crypt" 1>&2
13649 if test $ol_enable_crypt = yes ; then
13650 { echo "configure: error: could not find crypt" 1>&2; exit 1; }
13653 echo "configure: warning: disabling crypt support" 1>&2
13658 if test $ol_enable_proctitle != no ; then
13659 echo $ac_n "checking for setproctitle""... $ac_c" 1>&6
13660 echo "configure:13661: checking for setproctitle" >&5
13661 if eval "test \"\${ac_cv_func_setproctitle+set}\" = set"; then
13662 echo $ac_n "(cached) $ac_c" 1>&6
13664 cat > conftest.$ac_ext <<EOF
13665 #line 13666 "configure"
13666 #include "confdefs.h"
13667 /* System header to define __stub macros and hopefully few prototypes,
13668 which can conflict with char setproctitle(); below. */
13669 #include <assert.h>
13670 /* Override any gcc2 internal prototype to avoid an error. */
13671 /* We use char because int might match the return type of a gcc2
13672 builtin and then its argument prototype would still apply. */
13673 char setproctitle();
13678 /* The GNU C library defines this for functions which it implements
13679 to always fail with ENOSYS. Some functions are actually named
13680 something starting with __ and the normal name is an alias. */
13681 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
13689 if { (eval echo configure:13690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13691 eval "ac_cv_func_setproctitle=yes"
13693 echo "configure: failed program was:" >&5
13694 cat conftest.$ac_ext >&5
13696 eval "ac_cv_func_setproctitle=no"
13701 if eval "test \"`echo '$ac_cv_func_'setproctitle`\" = yes"; then
13702 echo "$ac_t""yes" 1>&6
13703 have_setproctitle=yes
13705 echo "$ac_t""no" 1>&6
13707 echo $ac_n "checking for setproctitle in -lutil""... $ac_c" 1>&6
13708 echo "configure:13709: checking for setproctitle in -lutil" >&5
13709 ac_lib_var=`echo util'_'setproctitle | sed 'y%./+-:%__p__%'`
13710 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13711 echo $ac_n "(cached) $ac_c" 1>&6
13713 ac_save_LIBS="$LIBS"
13714 LIBS="-lutil $LIBS"
13715 cat > conftest.$ac_ext <<EOF
13716 #line 13717 "configure"
13717 #include "confdefs.h"
13718 /* Override any gcc2 internal prototype to avoid an error. */
13719 /* We use char because int might match the return type of a gcc2
13720 builtin and then its argument prototype would still apply. */
13721 char setproctitle();
13727 if { (eval echo configure:13728: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13729 eval "ac_cv_lib_$ac_lib_var=yes"
13731 echo "configure: failed program was:" >&5
13732 cat conftest.$ac_ext >&5
13734 eval "ac_cv_lib_$ac_lib_var=no"
13737 LIBS="$ac_save_LIBS"
13740 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13741 echo "$ac_t""yes" 1>&6
13742 have_setproctitle=yes
13743 LUTIL_LIBS="$LUTIL_LIBS -lutil"
13745 echo "$ac_t""no" 1>&6
13746 have_setproctitle=no
13747 LIBOBJS="$LIBOBJS setproctitle.o"
13748 LIBSRCS="$LIBSRCS setproctitle.c"
13754 if test $have_setproctitle = yes ; then
13755 cat >> confdefs.h <<\EOF
13756 #define HAVE_SETPROCTITLE 1
13762 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
13763 echo "configure:13764: checking for ANSI C header files" >&5
13764 if eval "test \"\${ac_cv_header_stdc+set}\" = set"; then
13765 echo $ac_n "(cached) $ac_c" 1>&6
13767 cat > conftest.$ac_ext <<EOF
13768 #line 13769 "configure"
13769 #include "confdefs.h"
13770 #include <stdlib.h>
13771 #include <stdarg.h>
13772 #include <string.h>
13775 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13776 { (eval echo configure:13777: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13777 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13778 if test -z "$ac_err"; then
13780 ac_cv_header_stdc=yes
13783 echo "configure: failed program was:" >&5
13784 cat conftest.$ac_ext >&5
13786 ac_cv_header_stdc=no
13790 if test $ac_cv_header_stdc = yes; then
13791 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13792 cat > conftest.$ac_ext <<EOF
13793 #line 13794 "configure"
13794 #include "confdefs.h"
13795 #include <string.h>
13797 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13798 egrep "memchr" >/dev/null 2>&1; then
13802 ac_cv_header_stdc=no
13808 if test $ac_cv_header_stdc = yes; then
13809 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13810 cat > conftest.$ac_ext <<EOF
13811 #line 13812 "configure"
13812 #include "confdefs.h"
13813 #include <stdlib.h>
13815 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13816 egrep "free" >/dev/null 2>&1; then
13820 ac_cv_header_stdc=no
13826 if test $ac_cv_header_stdc = yes; then
13827 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13828 if test "$cross_compiling" = yes; then
13831 cat > conftest.$ac_ext <<EOF
13832 #line 13833 "configure"
13833 #include "confdefs.h"
13835 #if ((' ' & 0x0FF) == 0x020)
13836 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13837 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13839 #define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13840 || ('j' <= (c) && (c) <= 'r') \
13841 || ('s' <= (c) && (c) <= 'z'))
13842 #define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13844 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13845 int main () { int i; for (i = 0; i < 256; i++)
13846 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13850 if { (eval echo configure:13851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
13854 echo "configure: failed program was:" >&5
13855 cat conftest.$ac_ext >&5
13857 ac_cv_header_stdc=no
13865 echo "$ac_t""$ac_cv_header_stdc" 1>&6
13866 if test $ac_cv_header_stdc = yes; then
13867 cat >> confdefs.h <<\EOF
13868 #define STDC_HEADERS 1
13873 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
13874 echo "configure:13875: checking for mode_t" >&5
13875 if eval "test \"\${ac_cv_type_mode_t+set}\" = set"; then
13876 echo $ac_n "(cached) $ac_c" 1>&6
13878 cat > conftest.$ac_ext <<EOF
13879 #line 13880 "configure"
13880 #include "confdefs.h"
13881 #include <sys/types.h>
13883 #include <stdlib.h>
13884 #include <stddef.h>
13888 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13889 egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13891 eval "ac_cv_type_mode_t=yes"
13894 eval "ac_cv_type_mode_t=no"
13899 if eval "test \"`echo '$ac_cv_type_'mode_t`\" = yes"; then
13900 echo "$ac_t""yes" 1>&6
13902 echo "$ac_t""no" 1>&6
13903 cat >> confdefs.h <<EOF
13909 echo $ac_n "checking for off_t""... $ac_c" 1>&6
13910 echo "configure:13911: checking for off_t" >&5
13911 if eval "test \"\${ac_cv_type_off_t+set}\" = set"; then
13912 echo $ac_n "(cached) $ac_c" 1>&6
13914 cat > conftest.$ac_ext <<EOF
13915 #line 13916 "configure"
13916 #include "confdefs.h"
13917 #include <sys/types.h>
13919 #include <stdlib.h>
13920 #include <stddef.h>
13924 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13925 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13927 eval "ac_cv_type_off_t=yes"
13930 eval "ac_cv_type_off_t=no"
13935 if eval "test \"`echo '$ac_cv_type_'off_t`\" = yes"; then
13936 echo "$ac_t""yes" 1>&6
13938 echo "$ac_t""no" 1>&6
13939 cat >> confdefs.h <<EOF
13945 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
13946 echo "configure:13947: checking for pid_t" >&5
13947 if eval "test \"\${ac_cv_type_pid_t+set}\" = set"; then
13948 echo $ac_n "(cached) $ac_c" 1>&6
13950 cat > conftest.$ac_ext <<EOF
13951 #line 13952 "configure"
13952 #include "confdefs.h"
13953 #include <sys/types.h>
13955 #include <stdlib.h>
13956 #include <stddef.h>
13960 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13961 egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13963 eval "ac_cv_type_pid_t=yes"
13966 eval "ac_cv_type_pid_t=no"
13971 if eval "test \"`echo '$ac_cv_type_'pid_t`\" = yes"; then
13972 echo "$ac_t""yes" 1>&6
13974 echo "$ac_t""no" 1>&6
13975 cat >> confdefs.h <<EOF
13981 echo $ac_n "checking for ptrdiff_t""... $ac_c" 1>&6
13982 echo "configure:13983: checking for ptrdiff_t" >&5
13983 if eval "test \"\${am_cv_type_ptrdiff_t+set}\" = set"; then
13984 echo $ac_n "(cached) $ac_c" 1>&6
13986 cat > conftest.$ac_ext <<EOF
13987 #line 13988 "configure"
13988 #include "confdefs.h"
13989 #include <stddef.h>
13994 if { (eval echo configure:13995: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
13996 am_cv_type_ptrdiff_t=yes
13998 echo "configure: failed program was:" >&5
13999 cat conftest.$ac_ext >&5
14001 am_cv_type_ptrdiff_t=no
14006 echo "$ac_t""$am_cv_type_ptrdiff_t" 1>&6
14007 if test $am_cv_type_ptrdiff_t = yes; then
14008 cat >> confdefs.h <<\EOF
14009 #define HAVE_PTRDIFF_T 1
14014 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
14015 echo "configure:14016: checking return type of signal handlers" >&5
14016 if eval "test \"\${ac_cv_type_signal+set}\" = set"; then
14017 echo $ac_n "(cached) $ac_c" 1>&6
14019 cat > conftest.$ac_ext <<EOF
14020 #line 14021 "configure"
14021 #include "confdefs.h"
14022 #include <sys/types.h>
14023 #include <signal.h>
14028 extern "C" void (*signal (int, void (*)(int)))(int);
14030 void (*signal ()) ();
14037 if { (eval echo configure:14038: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14039 ac_cv_type_signal=void
14041 echo "configure: failed program was:" >&5
14042 cat conftest.$ac_ext >&5
14044 ac_cv_type_signal=int
14049 echo "$ac_t""$ac_cv_type_signal" 1>&6
14050 cat >> confdefs.h <<EOF
14051 #define RETSIGTYPE $ac_cv_type_signal
14055 echo $ac_n "checking for size_t""... $ac_c" 1>&6
14056 echo "configure:14057: checking for size_t" >&5
14057 if eval "test \"\${ac_cv_type_size_t+set}\" = set"; then
14058 echo $ac_n "(cached) $ac_c" 1>&6
14060 cat > conftest.$ac_ext <<EOF
14061 #line 14062 "configure"
14062 #include "confdefs.h"
14063 #include <sys/types.h>
14065 #include <stdlib.h>
14066 #include <stddef.h>
14070 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14071 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
14073 eval "ac_cv_type_size_t=yes"
14076 eval "ac_cv_type_size_t=no"
14081 if eval "test \"`echo '$ac_cv_type_'size_t`\" = yes"; then
14082 echo "$ac_t""yes" 1>&6
14084 echo "$ac_t""no" 1>&6
14085 cat >> confdefs.h <<EOF
14086 #define size_t unsigned
14092 echo $ac_n "checking for ssize_t""... $ac_c" 1>&6
14093 echo "configure:14094: checking for ssize_t" >&5
14094 if eval "test \"\${ac_cv_type_ssize_t+set}\" = set"; then
14095 echo $ac_n "(cached) $ac_c" 1>&6
14097 cat > conftest.$ac_ext <<EOF
14098 #line 14099 "configure"
14099 #include "confdefs.h"
14100 #include <sys/types.h>
14102 #include <stdlib.h>
14103 #include <stddef.h>
14107 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14108 egrep "(^|[^a-zA-Z_0-9])ssize_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
14110 eval "ac_cv_type_ssize_t=yes"
14113 eval "ac_cv_type_ssize_t=no"
14118 if eval "test \"`echo '$ac_cv_type_'ssize_t`\" = yes"; then
14119 echo "$ac_t""yes" 1>&6
14121 echo "$ac_t""no" 1>&6
14122 cat >> confdefs.h <<EOF
14123 #define ssize_t signed int
14128 echo $ac_n "checking for caddr_t""... $ac_c" 1>&6
14129 echo "configure:14130: checking for caddr_t" >&5
14130 if eval "test \"\${ac_cv_type_caddr_t+set}\" = set"; then
14131 echo $ac_n "(cached) $ac_c" 1>&6
14133 cat > conftest.$ac_ext <<EOF
14134 #line 14135 "configure"
14135 #include "confdefs.h"
14136 #include <sys/types.h>
14138 #include <stdlib.h>
14139 #include <stddef.h>
14143 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14144 egrep "(^|[^a-zA-Z_0-9])caddr_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
14146 eval "ac_cv_type_caddr_t=yes"
14149 eval "ac_cv_type_caddr_t=no"
14154 if eval "test \"`echo '$ac_cv_type_'caddr_t`\" = yes"; then
14155 echo "$ac_t""yes" 1>&6
14157 echo "$ac_t""no" 1>&6
14158 cat >> confdefs.h <<EOF
14159 #define caddr_t char *
14165 echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
14166 echo "configure:14167: checking for socklen_t" >&5
14167 if eval "test \"\${ol_cv_type_socklen_t+set}\" = set"; then
14168 echo $ac_n "(cached) $ac_c" 1>&6
14170 cat > conftest.$ac_ext <<EOF
14171 #line 14172 "configure"
14172 #include "confdefs.h"
14174 #ifdef HAVE_SYS_TYPES_H
14175 #include <sys/types.h>
14177 #ifdef HAVE_SYS_SOCKET_H
14178 #include <sys/socket.h>
14185 if { (eval echo configure:14186: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14187 ol_cv_type_socklen_t=yes
14189 echo "configure: failed program was:" >&5
14190 cat conftest.$ac_ext >&5
14192 ol_cv_type_socklen_t=no
14197 echo "$ac_t""$ol_cv_type_socklen_t" 1>&6
14198 if test $ol_cv_type_socklen_t = no; then
14199 cat >> confdefs.h <<\EOF
14200 #define socklen_t int
14205 echo $ac_n "checking for member st_blksize in aggregate type struct stat""... $ac_c" 1>&6
14206 echo "configure:14207: checking for member st_blksize in aggregate type struct stat" >&5
14207 if eval "test \"\${ac_cv_c_struct_member_st_blksize+set}\" = set"; then
14208 echo $ac_n "(cached) $ac_c" 1>&6
14210 cat > conftest.$ac_ext <<EOF
14211 #line 14212 "configure"
14212 #include "confdefs.h"
14213 #include <sys/types.h>
14214 #include <sys/stat.h>
14216 struct stat foo; foo.st_blksize;
14219 if { (eval echo configure:14220: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14221 ac_cv_c_struct_member_st_blksize=yes
14223 echo "configure: failed program was:" >&5
14224 cat conftest.$ac_ext >&5
14226 ac_cv_c_struct_member_st_blksize=no
14231 echo "$ac_t""$ac_cv_c_struct_member_st_blksize" 1>&6
14232 st_blksize="$ac_cv_c_struct_member_st_blksize"
14233 if test $ac_cv_c_struct_member_st_blksize = yes; then
14234 cat >> confdefs.h <<\EOF
14235 #define HAVE_ST_BLKSIZE 1
14240 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
14241 echo "configure:14242: checking whether time.h and sys/time.h may both be included" >&5
14242 if eval "test \"\${ac_cv_header_time+set}\" = set"; then
14243 echo $ac_n "(cached) $ac_c" 1>&6
14245 cat > conftest.$ac_ext <<EOF
14246 #line 14247 "configure"
14247 #include "confdefs.h"
14248 #include <sys/types.h>
14249 #include <sys/time.h>
14255 if { (eval echo configure:14256: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14257 ac_cv_header_time=yes
14259 echo "configure: failed program was:" >&5
14260 cat conftest.$ac_ext >&5
14262 ac_cv_header_time=no
14267 echo "$ac_t""$ac_cv_header_time" 1>&6
14268 if test $ac_cv_header_time = yes; then
14269 cat >> confdefs.h <<\EOF
14270 #define TIME_WITH_SYS_TIME 1
14275 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
14276 echo "configure:14277: checking whether struct tm is in sys/time.h or time.h" >&5
14277 if eval "test \"\${ac_cv_struct_tm+set}\" = set"; then
14278 echo $ac_n "(cached) $ac_c" 1>&6
14280 cat > conftest.$ac_ext <<EOF
14281 #line 14282 "configure"
14282 #include "confdefs.h"
14283 #include <sys/types.h>
14286 struct tm *tp; tp->tm_sec;
14289 if { (eval echo configure:14290: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14291 ac_cv_struct_tm=time.h
14293 echo "configure: failed program was:" >&5
14294 cat conftest.$ac_ext >&5
14296 ac_cv_struct_tm=sys/time.h
14301 echo "$ac_t""$ac_cv_struct_tm" 1>&6
14302 if test $ac_cv_struct_tm = sys/time.h; then
14303 cat >> confdefs.h <<\EOF
14304 #define TM_IN_SYS_TIME 1
14309 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
14310 echo "configure:14311: checking for uid_t in sys/types.h" >&5
14311 if eval "test \"\${ac_cv_type_uid_t+set}\" = set"; then
14312 echo $ac_n "(cached) $ac_c" 1>&6
14314 cat > conftest.$ac_ext <<EOF
14315 #line 14316 "configure"
14316 #include "confdefs.h"
14317 #include <sys/types.h>
14319 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14320 egrep "uid_t" >/dev/null 2>&1; then
14322 ac_cv_type_uid_t=yes
14325 ac_cv_type_uid_t=no
14331 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
14332 if test $ac_cv_type_uid_t = no; then
14333 cat >> confdefs.h <<\EOF
14337 cat >> confdefs.h <<\EOF
14343 echo $ac_n "checking for sig_atomic_t""... $ac_c" 1>&6
14344 echo "configure:14345: checking for sig_atomic_t" >&5
14345 if eval "test \"\${ol_cv_type_sig_atomic_t+set}\" = set"; then
14346 echo $ac_n "(cached) $ac_c" 1>&6
14348 cat > conftest.$ac_ext <<EOF
14349 #line 14350 "configure"
14350 #include "confdefs.h"
14351 #include <signal.h>
14353 sig_atomic_t atomic;
14356 if { (eval echo configure:14357: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14358 ol_cv_type_sig_atomic_t=yes
14360 echo "configure: failed program was:" >&5
14361 cat conftest.$ac_ext >&5
14363 ol_cv_type_sig_atomic_t=no
14368 echo "$ac_t""$ol_cv_type_sig_atomic_t" 1>&6
14369 if test $ol_cv_type_sig_atomic_t = no; then
14370 cat >> confdefs.h <<\EOF
14371 #define sig_atomic_t int
14378 # test for pw_gecos in struct passwd
14379 echo $ac_n "checking struct passwd for pw_gecos""... $ac_c" 1>&6
14380 echo "configure:14381: checking struct passwd for pw_gecos" >&5
14381 if eval "test \"\${ol_cv_struct_passwd_pw_gecos+set}\" = set"; then
14382 echo $ac_n "(cached) $ac_c" 1>&6
14385 cat > conftest.$ac_ext <<EOF
14386 #line 14387 "configure"
14387 #include "confdefs.h"
14392 pwd.pw_gecos = pwd.pw_name;
14396 if { (eval echo configure:14397: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14398 ol_cv_struct_passwd_pw_gecos=yes
14400 echo "configure: failed program was:" >&5
14401 cat conftest.$ac_ext >&5
14403 ol_cv_struct_passwd_pw_gecos=no
14408 echo "$ac_t""$ol_cv_struct_passwd_pw_gecos" 1>&6
14409 if test $ol_cv_struct_passwd_pw_gecos = yes ; then
14410 cat >> confdefs.h <<\EOF
14411 #define HAVE_PW_GECOS 1
14416 # test for pw_passwd in struct passwd
14417 echo $ac_n "checking struct passwd for pw_passwd""... $ac_c" 1>&6
14418 echo "configure:14419: checking struct passwd for pw_passwd" >&5
14419 if eval "test \"\${ol_cv_struct_passwd_pw_passwd+set}\" = set"; then
14420 echo $ac_n "(cached) $ac_c" 1>&6
14423 cat > conftest.$ac_ext <<EOF
14424 #line 14425 "configure"
14425 #include "confdefs.h"
14430 pwd.pw_passwd = pwd.pw_name;
14434 if { (eval echo configure:14435: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14436 ol_cv_struct_passwd_pw_passwd=yes
14438 echo "configure: failed program was:" >&5
14439 cat conftest.$ac_ext >&5
14441 ol_cv_struct_passwd_pw_passwd=no
14446 echo "$ac_t""$ol_cv_struct_passwd_pw_passwd" 1>&6
14447 if test $ol_cv_struct_passwd_pw_passwd = yes ; then
14448 cat >> confdefs.h <<\EOF
14449 #define HAVE_PW_PASSWD 1
14455 echo $ac_n "checking if toupper() requires islower()""... $ac_c" 1>&6
14456 echo "configure:14457: checking if toupper() requires islower()" >&5
14457 if eval "test \"\${ol_cv_c_upper_lower+set}\" = set"; then
14458 echo $ac_n "(cached) $ac_c" 1>&6
14461 if test "$cross_compiling" = yes; then
14462 ol_cv_c_upper_lower=safe
14464 cat > conftest.$ac_ext <<EOF
14465 #line 14466 "configure"
14466 #include "confdefs.h"
14471 if ('C' == toupper('C'))
14477 if { (eval echo configure:14478: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14479 ol_cv_c_upper_lower=no
14481 echo "configure: failed program was:" >&5
14482 cat conftest.$ac_ext >&5
14484 ol_cv_c_upper_lower=yes
14491 echo "$ac_t""$ol_cv_c_upper_lower" 1>&6
14492 if test $ol_cv_c_upper_lower != no ; then
14493 cat >> confdefs.h <<\EOF
14494 #define C_UPPER_LOWER 1
14499 echo $ac_n "checking for working const""... $ac_c" 1>&6
14500 echo "configure:14501: checking for working const" >&5
14501 if eval "test \"\${ac_cv_c_const+set}\" = set"; then
14502 echo $ac_n "(cached) $ac_c" 1>&6
14504 cat > conftest.$ac_ext <<EOF
14505 #line 14506 "configure"
14506 #include "confdefs.h"
14510 /* Ultrix mips cc rejects this. */
14511 typedef int charset[2]; const charset x;
14512 /* SunOS 4.1.1 cc rejects this. */
14513 char const *const *ccp;
14515 /* NEC SVR4.0.2 mips cc rejects this. */
14516 struct point {int x, y;};
14517 static struct point const zero = {0,0};
14518 /* AIX XL C 1.02.0.0 rejects this.
14519 It does not let you subtract one const X* pointer from another in an arm
14520 of an if-expression whose if-part is not a constant expression */
14521 const char *g = "string";
14522 ccp = &g + (g ? g-g : 0);
14523 /* HPUX 7.0 cc rejects these. */
14526 ccp = (char const *const *) p;
14527 { /* SCO 3.2v4 cc rejects this. */
14529 char const *s = 0 ? (char *) 0 : (char const *) 0;
14533 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
14534 int x[] = {25, 17};
14535 const int *foo = &x[0];
14538 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14539 typedef const int *iptr;
14543 { /* AIX XL C 1.02.0.0 rejects this saying
14544 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14545 struct s { int j; const int *ap[3]; };
14546 struct s *b; b->j = 5;
14548 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14549 const int foo = 10;
14554 if { (eval echo configure:14555: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14558 echo "configure: failed program was:" >&5
14559 cat conftest.$ac_ext >&5
14566 echo "$ac_t""$ac_cv_c_const" 1>&6
14567 if test $ac_cv_c_const = no; then
14568 cat >> confdefs.h <<\EOF
14574 echo $ac_n "checking if compiler understands volatile""... $ac_c" 1>&6
14575 echo "configure:14576: checking if compiler understands volatile" >&5
14576 if eval "test \"\${ol_cv_c_volatile+set}\" = set"; then
14577 echo $ac_n "(cached) $ac_c" 1>&6
14579 cat > conftest.$ac_ext <<EOF
14580 #line 14581 "configure"
14581 #include "confdefs.h"
14584 volatile int a; int * volatile b = x ? &y : &z;
14585 /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
14589 if { (eval echo configure:14590: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14591 ol_cv_c_volatile=yes
14593 echo "configure: failed program was:" >&5
14594 cat conftest.$ac_ext >&5
14596 ol_cv_c_volatile=no
14601 echo "$ac_t""$ol_cv_c_volatile" 1>&6
14602 if test $ol_cv_c_volatile = yes; then
14605 cat >> confdefs.h <<\EOF
14612 if test $cross_compiling = yes ; then
14613 cat >> confdefs.h <<\EOF
14614 #define CROSS_COMPILING 1
14618 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
14619 echo "configure:14620: checking whether byte ordering is bigendian" >&5
14620 if eval "test \"\${ac_cv_c_bigendian+set}\" = set"; then
14621 echo $ac_n "(cached) $ac_c" 1>&6
14623 ac_cv_c_bigendian=unknown
14624 # See if sys/param.h defines the BYTE_ORDER macro.
14625 cat > conftest.$ac_ext <<EOF
14626 #line 14627 "configure"
14627 #include "confdefs.h"
14628 #include <sys/types.h>
14629 #include <sys/param.h>
14632 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
14633 bogus endian macros
14637 if { (eval echo configure:14638: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14639 # It does; now see whether it defined to BIG_ENDIAN or not.
14640 cat > conftest.$ac_ext <<EOF
14641 #line 14642 "configure"
14642 #include "confdefs.h"
14643 #include <sys/types.h>
14644 #include <sys/param.h>
14647 #if BYTE_ORDER != BIG_ENDIAN
14652 if { (eval echo configure:14653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14654 ac_cv_c_bigendian=yes
14656 echo "configure: failed program was:" >&5
14657 cat conftest.$ac_ext >&5
14659 ac_cv_c_bigendian=no
14663 echo "configure: failed program was:" >&5
14664 cat conftest.$ac_ext >&5
14667 if test $ac_cv_c_bigendian = unknown; then
14668 if test "$cross_compiling" = yes; then
14669 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
14671 cat > conftest.$ac_ext <<EOF
14672 #line 14673 "configure"
14673 #include "confdefs.h"
14675 /* Are we little or big endian? From Harbison&Steele. */
14679 char c[sizeof (long)];
14682 exit (u.c[sizeof (long) - 1] == 1);
14685 if { (eval echo configure:14686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14687 ac_cv_c_bigendian=no
14689 echo "configure: failed program was:" >&5
14690 cat conftest.$ac_ext >&5
14692 ac_cv_c_bigendian=yes
14700 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
14701 if test $ac_cv_c_bigendian = yes; then
14702 cat >> confdefs.h <<\EOF
14703 #define WORDS_BIGENDIAN 1
14710 echo $ac_n "checking size of short""... $ac_c" 1>&6
14711 echo "configure:14712: checking size of short" >&5
14712 if eval "test \"\${ac_cv_sizeof_short+set}\" = set"; then
14713 echo $ac_n "(cached) $ac_c" 1>&6
14715 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14716 cat > conftest.$ac_ext <<EOF
14717 #line 14718 "configure"
14718 #include "confdefs.h"
14719 #include "confdefs.h"
14720 #include <sys/types.h>
14724 switch (0) case 0: case (sizeof (short) == $ac_size):;
14727 if { (eval echo configure:14728: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14729 ac_cv_sizeof_short=$ac_size
14731 echo "configure: failed program was:" >&5
14732 cat conftest.$ac_ext >&5
14735 if test x$ac_cv_sizeof_short != x ; then break; fi
14740 if test x$ac_cv_sizeof_short = x ; then
14741 { echo "configure: error: cannot determine a size for short" 1>&2; exit 1; }
14743 echo "$ac_t""$ac_cv_sizeof_short" 1>&6
14744 cat >> confdefs.h <<EOF
14745 #define SIZEOF_SHORT $ac_cv_sizeof_short
14749 echo $ac_n "checking size of int""... $ac_c" 1>&6
14750 echo "configure:14751: checking size of int" >&5
14751 if eval "test \"\${ac_cv_sizeof_int+set}\" = set"; then
14752 echo $ac_n "(cached) $ac_c" 1>&6
14754 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14755 cat > conftest.$ac_ext <<EOF
14756 #line 14757 "configure"
14757 #include "confdefs.h"
14758 #include "confdefs.h"
14759 #include <sys/types.h>
14763 switch (0) case 0: case (sizeof (int) == $ac_size):;
14766 if { (eval echo configure:14767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14768 ac_cv_sizeof_int=$ac_size
14770 echo "configure: failed program was:" >&5
14771 cat conftest.$ac_ext >&5
14774 if test x$ac_cv_sizeof_int != x ; then break; fi
14779 if test x$ac_cv_sizeof_int = x ; then
14780 { echo "configure: error: cannot determine a size for int" 1>&2; exit 1; }
14782 echo "$ac_t""$ac_cv_sizeof_int" 1>&6
14783 cat >> confdefs.h <<EOF
14784 #define SIZEOF_INT $ac_cv_sizeof_int
14788 echo $ac_n "checking size of long""... $ac_c" 1>&6
14789 echo "configure:14790: checking size of long" >&5
14790 if eval "test \"\${ac_cv_sizeof_long+set}\" = set"; then
14791 echo $ac_n "(cached) $ac_c" 1>&6
14793 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14794 cat > conftest.$ac_ext <<EOF
14795 #line 14796 "configure"
14796 #include "confdefs.h"
14797 #include "confdefs.h"
14798 #include <sys/types.h>
14802 switch (0) case 0: case (sizeof (long) == $ac_size):;
14805 if { (eval echo configure:14806: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14807 ac_cv_sizeof_long=$ac_size
14809 echo "configure: failed program was:" >&5
14810 cat conftest.$ac_ext >&5
14813 if test x$ac_cv_sizeof_long != x ; then break; fi
14818 if test x$ac_cv_sizeof_long = x ; then
14819 { echo "configure: error: cannot determine a size for long" 1>&2; exit 1; }
14821 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
14822 cat >> confdefs.h <<EOF
14823 #define SIZEOF_LONG $ac_cv_sizeof_long
14828 if test "$ac_cv_sizeof_int" -lt 4 ; then
14829 echo "configure: warning: OpenLDAP requires 'int' to be 32 bits or greater." 1>&2
14831 cat >> confdefs.h <<\EOF
14832 #define LBER_INT_T long
14836 cat >> confdefs.h <<\EOF
14837 #define LBER_INT_T int
14842 cat >> confdefs.h <<\EOF
14843 #define LBER_LEN_T long
14846 cat >> confdefs.h <<\EOF
14847 #define LBER_SOCKET_T int
14850 cat >> confdefs.h <<\EOF
14851 #define LBER_TAG_T long
14855 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
14856 echo "configure:14857: checking for 8-bit clean memcmp" >&5
14857 if eval "test \"\${ac_cv_func_memcmp_clean+set}\" = set"; then
14858 echo $ac_n "(cached) $ac_c" 1>&6
14860 if test "$cross_compiling" = yes; then
14861 ac_cv_func_memcmp_clean=no
14863 cat > conftest.$ac_ext <<EOF
14864 #line 14865 "configure"
14865 #include "confdefs.h"
14869 char c0 = 0x40, c1 = 0x80, c2 = 0x81;
14870 exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
14874 if { (eval echo configure:14875: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14876 ac_cv_func_memcmp_clean=yes
14878 echo "configure: failed program was:" >&5
14879 cat conftest.$ac_ext >&5
14881 ac_cv_func_memcmp_clean=no
14888 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
14889 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
14891 echo $ac_n "checking for strftime""... $ac_c" 1>&6
14892 echo "configure:14893: checking for strftime" >&5
14893 if eval "test \"\${ac_cv_func_strftime+set}\" = set"; then
14894 echo $ac_n "(cached) $ac_c" 1>&6
14896 cat > conftest.$ac_ext <<EOF
14897 #line 14898 "configure"
14898 #include "confdefs.h"
14899 /* System header to define __stub macros and hopefully few prototypes,
14900 which can conflict with char strftime(); below. */
14901 #include <assert.h>
14902 /* Override any gcc2 internal prototype to avoid an error. */
14903 /* We use char because int might match the return type of a gcc2
14904 builtin and then its argument prototype would still apply. */
14910 /* The GNU C library defines this for functions which it implements
14911 to always fail with ENOSYS. Some functions are actually named
14912 something starting with __ and the normal name is an alias. */
14913 #if defined (__stub_strftime) || defined (__stub___strftime)
14921 if { (eval echo configure:14922: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14923 eval "ac_cv_func_strftime=yes"
14925 echo "configure: failed program was:" >&5
14926 cat conftest.$ac_ext >&5
14928 eval "ac_cv_func_strftime=no"
14933 if eval "test \"`echo '$ac_cv_func_'strftime`\" = yes"; then
14934 echo "$ac_t""yes" 1>&6
14935 cat >> confdefs.h <<\EOF
14936 #define HAVE_STRFTIME 1
14940 echo "$ac_t""no" 1>&6
14941 # strftime is in -lintl on SCO UNIX.
14942 echo $ac_n "checking for strftime in -lintl""... $ac_c" 1>&6
14943 echo "configure:14944: checking for strftime in -lintl" >&5
14944 ac_lib_var=`echo intl'_'strftime | sed 'y%./+-:%__p__%'`
14945 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
14946 echo $ac_n "(cached) $ac_c" 1>&6
14948 ac_save_LIBS="$LIBS"
14949 LIBS="-lintl $LIBS"
14950 cat > conftest.$ac_ext <<EOF
14951 #line 14952 "configure"
14952 #include "confdefs.h"
14953 /* Override any gcc2 internal prototype to avoid an error. */
14954 /* We use char because int might match the return type of a gcc2
14955 builtin and then its argument prototype would still apply. */
14962 if { (eval echo configure:14963: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14964 eval "ac_cv_lib_$ac_lib_var=yes"
14966 echo "configure: failed program was:" >&5
14967 cat conftest.$ac_ext >&5
14969 eval "ac_cv_lib_$ac_lib_var=no"
14972 LIBS="$ac_save_LIBS"
14975 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
14976 echo "$ac_t""yes" 1>&6
14977 cat >> confdefs.h <<\EOF
14978 #define HAVE_STRFTIME 1
14981 LIBS="-lintl $LIBS"
14983 echo "$ac_t""no" 1>&6
14989 echo $ac_n "checking for inet_aton()""... $ac_c" 1>&6
14990 echo "configure:14991: checking for inet_aton()" >&5
14991 if eval "test \"\${ol_cv_func_inet_aton+set}\" = set"; then
14992 echo $ac_n "(cached) $ac_c" 1>&6
14994 cat > conftest.$ac_ext <<EOF
14995 #line 14996 "configure"
14996 #include "confdefs.h"
14998 #ifdef HAVE_SYS_TYPES_H
14999 # include <sys/types.h>
15001 #ifdef HAVE_SYS_SOCKET_H
15002 # include <sys/socket.h>
15003 # ifdef HAVE_SYS_SELECT_H
15004 # include <sys/select.h>
15006 # include <netinet/in.h>
15007 # ifdef HAVE_ARPA_INET_H
15008 # include <arpa/inet.h>
15014 int rc = inet_aton( "255.255.255.255", &in );
15017 if { (eval echo configure:15018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15019 ol_cv_func_inet_aton=yes
15021 echo "configure: failed program was:" >&5
15022 cat conftest.$ac_ext >&5
15024 ol_cv_func_inet_aton=no
15029 echo "$ac_t""$ol_cv_func_inet_aton" 1>&6
15030 if test $ol_cv_func_inet_aton != no; then
15031 cat >> confdefs.h <<\EOF
15032 #define HAVE_INET_ATON 1
15038 echo $ac_n "checking for _spawnlp""... $ac_c" 1>&6
15039 echo "configure:15040: checking for _spawnlp" >&5
15040 if eval "test \"\${ac_cv_func__spawnlp+set}\" = set"; then
15041 echo $ac_n "(cached) $ac_c" 1>&6
15043 cat > conftest.$ac_ext <<EOF
15044 #line 15045 "configure"
15045 #include "confdefs.h"
15046 /* System header to define __stub macros and hopefully few prototypes,
15047 which can conflict with char _spawnlp(); below. */
15048 #include <assert.h>
15049 /* Override any gcc2 internal prototype to avoid an error. */
15050 /* We use char because int might match the return type of a gcc2
15051 builtin and then its argument prototype would still apply. */
15057 /* The GNU C library defines this for functions which it implements
15058 to always fail with ENOSYS. Some functions are actually named
15059 something starting with __ and the normal name is an alias. */
15060 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
15068 if { (eval echo configure:15069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15070 eval "ac_cv_func__spawnlp=yes"
15072 echo "configure: failed program was:" >&5
15073 cat conftest.$ac_ext >&5
15075 eval "ac_cv_func__spawnlp=no"
15080 if eval "test \"`echo '$ac_cv_func_'_spawnlp`\" = yes"; then
15081 echo "$ac_t""yes" 1>&6
15082 cat >> confdefs.h <<\EOF
15083 #define HAVE_SPAWNLP 1
15087 echo "$ac_t""no" 1>&6
15091 echo $ac_n "checking for _snprintf""... $ac_c" 1>&6
15092 echo "configure:15093: checking for _snprintf" >&5
15093 if eval "test \"\${ac_cv_func__snprintf+set}\" = set"; then
15094 echo $ac_n "(cached) $ac_c" 1>&6
15096 cat > conftest.$ac_ext <<EOF
15097 #line 15098 "configure"
15098 #include "confdefs.h"
15099 /* System header to define __stub macros and hopefully few prototypes,
15100 which can conflict with char _snprintf(); below. */
15101 #include <assert.h>
15102 /* Override any gcc2 internal prototype to avoid an error. */
15103 /* We use char because int might match the return type of a gcc2
15104 builtin and then its argument prototype would still apply. */
15110 /* The GNU C library defines this for functions which it implements
15111 to always fail with ENOSYS. Some functions are actually named
15112 something starting with __ and the normal name is an alias. */
15113 #if defined (__stub__snprintf) || defined (__stub____snprintf)
15121 if { (eval echo configure:15122: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15123 eval "ac_cv_func__snprintf=yes"
15125 echo "configure: failed program was:" >&5
15126 cat conftest.$ac_ext >&5
15128 eval "ac_cv_func__snprintf=no"
15133 if eval "test \"`echo '$ac_cv_func_'_snprintf`\" = yes"; then
15134 echo "$ac_t""yes" 1>&6
15135 ac_cv_func_snprintf=yes
15136 cat >> confdefs.h <<\EOF
15137 #define snprintf _snprintf
15142 echo "$ac_t""no" 1>&6
15146 echo $ac_n "checking for _vsnprintf""... $ac_c" 1>&6
15147 echo "configure:15148: checking for _vsnprintf" >&5
15148 if eval "test \"\${ac_cv_func__vsnprintf+set}\" = set"; then
15149 echo $ac_n "(cached) $ac_c" 1>&6
15151 cat > conftest.$ac_ext <<EOF
15152 #line 15153 "configure"
15153 #include "confdefs.h"
15154 /* System header to define __stub macros and hopefully few prototypes,
15155 which can conflict with char _vsnprintf(); below. */
15156 #include <assert.h>
15157 /* Override any gcc2 internal prototype to avoid an error. */
15158 /* We use char because int might match the return type of a gcc2
15159 builtin and then its argument prototype would still apply. */
15165 /* The GNU C library defines this for functions which it implements
15166 to always fail with ENOSYS. Some functions are actually named
15167 something starting with __ and the normal name is an alias. */
15168 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
15176 if { (eval echo configure:15177: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15178 eval "ac_cv_func__vsnprintf=yes"
15180 echo "configure: failed program was:" >&5
15181 cat conftest.$ac_ext >&5
15183 eval "ac_cv_func__vsnprintf=no"
15188 if eval "test \"`echo '$ac_cv_func_'_vsnprintf`\" = yes"; then
15189 echo "$ac_t""yes" 1>&6
15190 ac_cv_func_vsnprintf=yes
15191 cat >> confdefs.h <<\EOF
15192 #define vsnprintf _vsnprintf
15197 echo "$ac_t""no" 1>&6
15201 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
15202 echo "configure:15203: checking for vprintf" >&5
15203 if eval "test \"\${ac_cv_func_vprintf+set}\" = set"; then
15204 echo $ac_n "(cached) $ac_c" 1>&6
15206 cat > conftest.$ac_ext <<EOF
15207 #line 15208 "configure"
15208 #include "confdefs.h"
15209 /* System header to define __stub macros and hopefully few prototypes,
15210 which can conflict with char vprintf(); below. */
15211 #include <assert.h>
15212 /* Override any gcc2 internal prototype to avoid an error. */
15213 /* We use char because int might match the return type of a gcc2
15214 builtin and then its argument prototype would still apply. */
15220 /* The GNU C library defines this for functions which it implements
15221 to always fail with ENOSYS. Some functions are actually named
15222 something starting with __ and the normal name is an alias. */
15223 #if defined (__stub_vprintf) || defined (__stub___vprintf)
15231 if { (eval echo configure:15232: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15233 eval "ac_cv_func_vprintf=yes"
15235 echo "configure: failed program was:" >&5
15236 cat conftest.$ac_ext >&5
15238 eval "ac_cv_func_vprintf=no"
15243 if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
15244 echo "$ac_t""yes" 1>&6
15245 cat >> confdefs.h <<\EOF
15246 #define HAVE_VPRINTF 1
15250 echo "$ac_t""no" 1>&6
15253 if test "$ac_cv_func_vprintf" != yes; then
15254 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
15255 echo "configure:15256: checking for _doprnt" >&5
15256 if eval "test \"\${ac_cv_func__doprnt+set}\" = set"; then
15257 echo $ac_n "(cached) $ac_c" 1>&6
15259 cat > conftest.$ac_ext <<EOF
15260 #line 15261 "configure"
15261 #include "confdefs.h"
15262 /* System header to define __stub macros and hopefully few prototypes,
15263 which can conflict with char _doprnt(); below. */
15264 #include <assert.h>
15265 /* Override any gcc2 internal prototype to avoid an error. */
15266 /* We use char because int might match the return type of a gcc2
15267 builtin and then its argument prototype would still apply. */
15273 /* The GNU C library defines this for functions which it implements
15274 to always fail with ENOSYS. Some functions are actually named
15275 something starting with __ and the normal name is an alias. */
15276 #if defined (__stub__doprnt) || defined (__stub____doprnt)
15284 if { (eval echo configure:15285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15286 eval "ac_cv_func__doprnt=yes"
15288 echo "configure: failed program was:" >&5
15289 cat conftest.$ac_ext >&5
15291 eval "ac_cv_func__doprnt=no"
15296 if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
15297 echo "$ac_t""yes" 1>&6
15298 cat >> confdefs.h <<\EOF
15299 #define HAVE_DOPRNT 1
15303 echo "$ac_t""no" 1>&6
15309 if test $ac_cv_func_vprintf = yes ; then
15310 for ac_func in vsnprintf vsprintf
15312 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15313 echo "configure:15314: checking for $ac_func" >&5
15314 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15315 echo $ac_n "(cached) $ac_c" 1>&6
15317 cat > conftest.$ac_ext <<EOF
15318 #line 15319 "configure"
15319 #include "confdefs.h"
15320 /* System header to define __stub macros and hopefully few prototypes,
15321 which can conflict with char $ac_func(); below. */
15322 #include <assert.h>
15323 /* Override any gcc2 internal prototype to avoid an error. */
15324 /* We use char because int might match the return type of a gcc2
15325 builtin and then its argument prototype would still apply. */
15331 /* The GNU C library defines this for functions which it implements
15332 to always fail with ENOSYS. Some functions are actually named
15333 something starting with __ and the normal name is an alias. */
15334 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15342 if { (eval echo configure:15343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15344 eval "ac_cv_func_$ac_func=yes"
15346 echo "configure: failed program was:" >&5
15347 cat conftest.$ac_ext >&5
15349 eval "ac_cv_func_$ac_func=no"
15354 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15355 echo "$ac_t""yes" 1>&6
15356 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15357 cat >> confdefs.h <<EOF
15358 #define $ac_tr_func 1
15362 echo "$ac_t""no" 1>&6
15420 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15421 echo "configure:15422: checking for $ac_func" >&5
15422 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15423 echo $ac_n "(cached) $ac_c" 1>&6
15425 cat > conftest.$ac_ext <<EOF
15426 #line 15427 "configure"
15427 #include "confdefs.h"
15428 /* System header to define __stub macros and hopefully few prototypes,
15429 which can conflict with char $ac_func(); below. */
15430 #include <assert.h>
15431 /* Override any gcc2 internal prototype to avoid an error. */
15432 /* We use char because int might match the return type of a gcc2
15433 builtin and then its argument prototype would still apply. */
15439 /* The GNU C library defines this for functions which it implements
15440 to always fail with ENOSYS. Some functions are actually named
15441 something starting with __ and the normal name is an alias. */
15442 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15450 if { (eval echo configure:15451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15452 eval "ac_cv_func_$ac_func=yes"
15454 echo "configure: failed program was:" >&5
15455 cat conftest.$ac_ext >&5
15457 eval "ac_cv_func_$ac_func=no"
15462 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15463 echo "$ac_t""yes" 1>&6
15464 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15465 cat >> confdefs.h <<EOF
15466 #define $ac_tr_func 1
15470 echo "$ac_t""no" 1>&6
15475 for ac_func in getopt tempnam
15477 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15478 echo "configure:15479: checking for $ac_func" >&5
15479 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15480 echo $ac_n "(cached) $ac_c" 1>&6
15482 cat > conftest.$ac_ext <<EOF
15483 #line 15484 "configure"
15484 #include "confdefs.h"
15485 /* System header to define __stub macros and hopefully few prototypes,
15486 which can conflict with char $ac_func(); below. */
15487 #include <assert.h>
15488 /* Override any gcc2 internal prototype to avoid an error. */
15489 /* We use char because int might match the return type of a gcc2
15490 builtin and then its argument prototype would still apply. */
15496 /* The GNU C library defines this for functions which it implements
15497 to always fail with ENOSYS. Some functions are actually named
15498 something starting with __ and the normal name is an alias. */
15499 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15507 if { (eval echo configure:15508: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15509 eval "ac_cv_func_$ac_func=yes"
15511 echo "configure: failed program was:" >&5
15512 cat conftest.$ac_ext >&5
15514 eval "ac_cv_func_$ac_func=no"
15519 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15520 echo "$ac_t""yes" 1>&6
15521 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15522 cat >> confdefs.h <<EOF
15523 #define $ac_tr_func 1
15527 echo "$ac_t""no" 1>&6
15528 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
15534 if test "$ac_cv_func_getopt" != yes; then
15535 LIBSRCS="$LIBSRCS getopt.c"
15538 if test "$ac_cv_func_tempnam" != yes; then
15539 LIBSRCS="$LIBSRCS tempnam.c"
15542 # Check Configuration
15543 echo $ac_n "checking declaration of sys_errlist""... $ac_c" 1>&6
15544 echo "configure:15545: checking declaration of sys_errlist" >&5
15545 if eval "test \"\${ol_cv_dcl_sys_errlist+set}\" = set"; then
15546 echo $ac_n "(cached) $ac_c" 1>&6
15549 cat > conftest.$ac_ext <<EOF
15550 #line 15551 "configure"
15551 #include "confdefs.h"
15554 #include <sys/types.h>
15557 #include <stdlib.h>
15560 char *c = (char *) *sys_errlist
15563 if { (eval echo configure:15564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
15565 ol_cv_dcl_sys_errlist=yes
15566 ol_cv_have_sys_errlist=yes
15568 echo "configure: failed program was:" >&5
15569 cat conftest.$ac_ext >&5
15571 ol_cv_dcl_sys_errlist=no
15576 echo "$ac_t""$ol_cv_dcl_sys_errlist" 1>&6
15578 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
15579 if test $ol_cv_dcl_sys_errlist = no ; then
15580 cat >> confdefs.h <<\EOF
15581 #define DECL_SYS_ERRLIST 1
15585 echo $ac_n "checking existence of sys_errlist""... $ac_c" 1>&6
15586 echo "configure:15587: checking existence of sys_errlist" >&5
15587 if eval "test \"\${ol_cv_have_sys_errlist+set}\" = set"; then
15588 echo $ac_n "(cached) $ac_c" 1>&6
15591 cat > conftest.$ac_ext <<EOF
15592 #line 15593 "configure"
15593 #include "confdefs.h"
15596 char *c = (char *) *sys_errlist
15599 if { (eval echo configure:15600: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15601 ol_cv_have_sys_errlist=yes
15603 echo "configure: failed program was:" >&5
15604 cat conftest.$ac_ext >&5
15606 ol_cv_have_sys_errlist=no
15611 echo "$ac_t""$ol_cv_have_sys_errlist" 1>&6
15613 if test $ol_cv_have_sys_errlist = yes ; then
15614 cat >> confdefs.h <<\EOF
15615 #define HAVE_SYS_ERRLIST 1
15622 if test "$ol_enable_debug" != no ; then
15623 cat >> confdefs.h <<\EOF
15624 #define LDAP_DEBUG 1
15628 if test "$ol_enable_syslog" = yes ; then
15629 cat >> confdefs.h <<\EOF
15630 #define LDAP_SYSLOG 1
15634 if test "$ol_enable_libui" = yes ; then
15635 cat >> confdefs.h <<\EOF
15636 #define LDAP_LIBUI 1
15640 if test "$ol_enable_cache" = no ; then
15641 cat >> confdefs.h <<\EOF
15642 #define LDAP_NOCACHE 1
15646 if test "$ol_link_kbind" != no ; then
15647 cat >> confdefs.h <<\EOF
15648 #define LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND LDAP_VENDOR_VERSION
15652 if test "$ol_enable_proctitle" != no ; then
15653 cat >> confdefs.h <<\EOF
15654 #define LDAP_PROCTITLE 1
15658 if test "$ol_enable_referrals" != no ; then
15659 cat >> confdefs.h <<\EOF
15660 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
15664 if test "$ol_enable_cldap" != no ; then
15665 cat >> confdefs.h <<\EOF
15666 #define LDAP_CONNECTIONLESS 1
15670 if test "$ol_enable_ldapi" != no; then
15671 cat >> confdefs.h <<\EOF
15672 #define USE_PF_LOCAL 1
15677 if test "$ol_enable_cleartext" != no ; then
15678 cat >> confdefs.h <<\EOF
15679 #define SLAPD_CLEARTEXT 1
15683 if test "$ol_enable_crypt" != no ; then
15684 cat >> confdefs.h <<\EOF
15685 #define SLAPD_CRYPT 1
15689 if test "$ol_link_kpasswd" != no ; then
15690 cat >> confdefs.h <<\EOF
15691 #define SLAPD_KPASSWD 1
15695 if test "$ol_link_spasswd" != no ; then
15696 cat >> confdefs.h <<\EOF
15697 #define SLAPD_SPASSWD 1
15701 if test "$ol_enable_multimaster" != no ; then
15702 cat >> confdefs.h <<\EOF
15703 #define SLAPD_MULTIMASTER 1
15707 if test "$ol_enable_phonetic" != no ; then
15708 cat >> confdefs.h <<\EOF
15709 #define SLAPD_PHONETIC 1
15713 if test "$ol_enable_rlookups" != no ; then
15714 cat >> confdefs.h <<\EOF
15715 #define SLAPD_RLOOKUPS 1
15719 if test "$ol_enable_aci" != no ; then
15720 cat >> confdefs.h <<\EOF
15721 #define SLAPD_ACI_ENABLED 1
15726 if test "$ol_link_modules" != no ; then
15727 cat >> confdefs.h <<\EOF
15728 #define SLAPD_MODULES 1
15732 SLAPD_MODULES_LDFLAGS="-dlopen self"
15735 if test "$ol_link_dnssrv" != no ; then
15736 cat >> confdefs.h <<\EOF
15737 #define SLAPD_DNSSRV 1
15742 if test "$ol_with_dnssrv_module" != static ; then
15743 cat >> confdefs.h <<\EOF
15744 #define SLAPD_DNSSRV_DYNAMIC 1
15748 BUILD_DNSSRV_DYNAMIC=shared
15749 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-dnssrv/back_dnssrv.la"
15753 if test "$ol_enable_ldap" != no ; then
15754 cat >> confdefs.h <<\EOF
15755 #define SLAPD_LDAP 1
15760 if test "$ol_with_ldap_module" != static ; then
15761 cat >> confdefs.h <<\EOF
15762 #define SLAPD_LDAP_DYNAMIC 1
15766 BUILD_LDAP_DYNAMIC=shared
15767 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-ldap/back_ldap.la"
15771 if test "$ol_link_ldbm" != no ; then
15772 cat >> confdefs.h <<\EOF
15773 #define SLAPD_LDBM 1
15778 if test "$ol_with_ldbm_module" != static ; then
15779 cat >> confdefs.h <<\EOF
15780 #define SLAPD_LDBM_DYNAMIC 1
15784 BUILD_LDBM_DYNAMIC=shared
15785 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-ldbm/back_ldbm.la"
15789 if test "$ol_enable_passwd" != no ; then
15790 cat >> confdefs.h <<\EOF
15791 #define SLAPD_PASSWD 1
15796 if test "$ol_with_passwd_module" != static ; then
15797 cat >> confdefs.h <<\EOF
15798 #define SLAPD_PASSWD_DYNAMIC 1
15802 BUILD_PASSWD_DYNAMIC=shared
15803 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-passwd/back_passwd.la"
15807 if test "$ol_link_perl" != no ; then
15808 cat >> confdefs.h <<\EOF
15809 #define SLAPD_PERL 1
15814 if test "$ol_with_perl_module" != static ; then
15815 cat >> confdefs.h <<\EOF
15816 #define SLAPD_PERL_DYNAMIC 1
15820 BUILD_PERL_DYNAMIC=shared
15821 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-perl/back_perl.la"
15825 if test "$ol_enable_shell" != no ; then
15826 cat >> confdefs.h <<\EOF
15827 #define SLAPD_SHELL 1
15832 if test "$ol_with_shell_module" != static ; then
15833 cat >> confdefs.h <<\EOF
15834 #define SLAPD_SHELL_DYNAMIC 1
15838 BUILD_SHELL_DYNAMIC=shared
15839 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-shell/back_shell.la"
15843 if test "$ol_enable_tcl" != no ; then
15844 cat >> confdefs.h <<\EOF
15845 #define SLAPD_TCL 1
15850 if test "$ol_with_tcl_module" != static; then
15851 cat >> confdefs.h <<\EOF
15852 #define SLAPD_TCL_DYNAMIC 1
15856 BUILD_TCL_DYNAMIC=shared
15857 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-tcl/back_tcl.la"
15861 if test "$ol_enable_sql" != no ; then
15862 cat >> confdefs.h <<\EOF
15863 #define SLAPD_SQL 1
15868 SLAPD_SQL_LIBS=-liodbc
15869 if test "$ol_with_sql_module" != static; then
15870 cat >> confdefs.h <<\EOF
15871 #define SLAPD_SQL_DYNAMIC 1
15875 BUILD_SQL_DYNAMIC=shared
15876 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-sql/back_sql.la"
15880 if test "$ol_enable_slurpd" != no -a "$ol_link_threads" != no -a \
15881 $BUILD_SLAPD = yes ; then
15886 if test "$LINK_BINS_DYNAMIC" = yes; then
15888 LT_LIB_LINKAGE=shared
15891 LT_LIB_LINKAGE=static
15894 if test "$ac_cv_mingw32" = yes ; then
15965 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
15967 test "x$prefix" = xNONE && prefix=$ac_default_prefix
15968 # Let make expand exec_prefix.
15969 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15971 # Any assignment to VPATH causes Sun make to only execute
15972 # the first set of double-colon rules, so remove it if not needed.
15973 # If there is a colon in the path, we need to keep it.
15974 if test "x$srcdir" = x.; then
15975 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
15978 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
15980 DEFS=-DHAVE_CONFIG_H
15982 # Without the "./", some shells look in PATH for config.status.
15983 : ${CONFIG_STATUS=./config.status}
15985 echo creating $CONFIG_STATUS
15986 rm -f $CONFIG_STATUS
15987 cat > $CONFIG_STATUS <<EOF
15989 # Generated automatically by configure.
15990 # Run this file to recreate the current configuration.
15991 # This directory was configured as follows,
15992 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
15994 # $0 $ac_configure_args
15996 # Compiler output produced by configure, useful for debugging
15997 # configure, is in ./config.log if it exists.
15999 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
16002 case "\$ac_option" in
16003 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16004 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
16005 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
16006 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
16007 echo "$CONFIG_STATUS generated by autoconf version 2.13.1"
16009 -help | --help | --hel | --he | --h)
16010 echo "\$ac_cs_usage"; exit 0 ;;
16011 *) echo "\$ac_cs_usage"; exit 1 ;;
16015 ac_given_srcdir=$srcdir
16016 ac_given_INSTALL="$INSTALL"
16018 trap 'rm -fr `echo "\
16019 Makefile:build/top.mk:Makefile.in:build/dir.mk \
16020 doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk \
16021 doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk \
16022 doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk \
16023 doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk \
16024 doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk \
16025 doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk \
16026 clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk \
16027 clients/finger/Makefile:build/top.mk:clients/finger/Makefile.in:build/rules.mk \
16028 clients/fax500/Makefile:build/top.mk:clients/fax500/Makefile.in:build/rules.mk \
16029 clients/gopher/Makefile:build/top.mk:clients/gopher/Makefile.in:build/rules.mk \
16030 clients/mail500/Makefile:build/top.mk:clients/mail500/Makefile.in:build/rules.mk \
16031 clients/rcpt500/Makefile:build/top.mk:clients/rcpt500/Makefile.in:build/rules.mk \
16032 clients/ud/Makefile:build/top.mk:clients/ud/Makefile.in:build/rules.mk \
16033 clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk \
16034 include/Makefile:build/top.mk:include/Makefile.in \
16035 libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk \
16036 libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk \
16037 libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk \
16038 libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk \
16039 libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk \
16040 libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk \
16041 libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk \
16042 libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk \
16043 libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk \
16044 servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk \
16045 servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk \
16046 servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk \
16047 servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk \
16048 servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk \
16049 servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk \
16050 servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk \
16051 servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk \
16052 servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk \
16053 servers/slapd/back-tcl/Makefile:build/top.mk:servers/slapd/back-tcl/Makefile.in:build/mod.mk \
16054 servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk \
16055 servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in \
16056 servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk \
16057 tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk \
16058 tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk \
16059 contrib/Makefile:build/top.mk:contrib/Makefile.in:build/dir.mk \
16060 contrib/saucer/Makefile:build/top.mk:contrib/saucer/Makefile.in:build/rules.mk \
16061 contrib/web_ldap/Makefile:build/top.mk:contrib/web_ldap/Makefile.in:build/rules.mk \
16062 include/portable.h include/ldap_features.h include/lber_types.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
16064 cat >> $CONFIG_STATUS <<EOF
16066 # Protect against being on the right side of a sed subst in config.status.
16067 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
16068 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
16072 s%@CFLAGS@%$CFLAGS%g
16073 s%@CPPFLAGS@%$CPPFLAGS%g
16074 s%@CXXFLAGS@%$CXXFLAGS%g
16075 s%@FFLAGS@%$FFLAGS%g
16077 s%@LDFLAGS@%$LDFLAGS%g
16079 s%@exec_prefix@%$exec_prefix%g
16080 s%@prefix@%$prefix%g
16081 s%@program_transform_name@%$program_transform_name%g
16082 s%@bindir@%$bindir%g
16083 s%@sbindir@%$sbindir%g
16084 s%@libexecdir@%$libexecdir%g
16085 s%@datadir@%$datadir%g
16086 s%@sysconfdir@%$sysconfdir%g
16087 s%@sharedstatedir@%$sharedstatedir%g
16088 s%@localstatedir@%$localstatedir%g
16089 s%@libdir@%$libdir%g
16090 s%@includedir@%$includedir%g
16091 s%@oldincludedir@%$oldincludedir%g
16092 s%@infodir@%$infodir%g
16093 s%@mandir@%$mandir%g
16095 s%@host_alias@%$host_alias%g
16096 s%@host_cpu@%$host_cpu%g
16097 s%@host_vendor@%$host_vendor%g
16098 s%@host_os@%$host_os%g
16099 s%@target@%$target%g
16100 s%@target_alias@%$target_alias%g
16101 s%@target_cpu@%$target_cpu%g
16102 s%@target_vendor@%$target_vendor%g
16103 s%@target_os@%$target_os%g
16105 s%@build_alias@%$build_alias%g
16106 s%@build_cpu@%$build_cpu%g
16107 s%@build_vendor@%$build_vendor%g
16108 s%@build_os@%$build_os%g
16109 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
16110 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
16111 s%@INSTALL_DATA@%$INSTALL_DATA%g
16112 s%@PACKAGE@%$PACKAGE%g
16113 s%@VERSION@%$VERSION%g
16114 s%@ACLOCAL@%$ACLOCAL%g
16115 s%@AUTOCONF@%$AUTOCONF%g
16116 s%@AUTOMAKE@%$AUTOMAKE%g
16117 s%@AUTOHEADER@%$AUTOHEADER%g
16118 s%@MAKEINFO@%$MAKEINFO%g
16119 s%@install_sh@%$install_sh%g
16122 s%@AMTARFLAGS@%$AMTARFLAGS%g
16123 s%@SET_MAKE@%$SET_MAKE%g
16124 s%@top_builddir@%$top_builddir%g
16125 s%@ldap_subdir@%$ldap_subdir%g
16127 s%@RANLIB@%$RANLIB%g
16129 s%@DLLTOOL@%$DLLTOOL%g
16131 s%@OBJDUMP@%$OBJDUMP%g
16132 s%@LIBTOOL@%$LIBTOOL%g
16134 s%@SENDMAIL@%$SENDMAIL%g
16135 s%@EDITOR@%$EDITOR%g
16136 s%@FINGER@%$FINGER%g
16137 s%@PERLBIN@%$PERLBIN%g
16139 s%@EXEEXT@%$EXEEXT%g
16140 s%@OBJEXT@%$OBJEXT%g
16141 s%@OL_MKDEP@%$OL_MKDEP%g
16142 s%@OL_MKDEP_FLAGS@%$OL_MKDEP_FLAGS%g
16143 s%@LIBOBJS@%$LIBOBJS%g
16144 s%@LIBSRCS@%$LIBSRCS%g
16146 s%@LIB_LINKAGE@%$LIB_LINKAGE%g
16147 s%@LT_LIB_LINKAGE@%$LT_LIB_LINKAGE%g
16148 s%@DYN_EXT@%$DYN_EXT%g
16149 s%@BUILD_SLAPD@%$BUILD_SLAPD%g
16150 s%@BUILD_DNSSRV@%$BUILD_DNSSRV%g
16151 s%@BUILD_LDAP@%$BUILD_LDAP%g
16152 s%@BUILD_LDBM@%$BUILD_LDBM%g
16153 s%@BUILD_PASSWD@%$BUILD_PASSWD%g
16154 s%@BUILD_PERL@%$BUILD_PERL%g
16155 s%@BUILD_QUIPU@%$BUILD_QUIPU%g
16156 s%@BUILD_SHELL@%$BUILD_SHELL%g
16157 s%@BUILD_SQL@%$BUILD_SQL%g
16158 s%@BUILD_TCL@%$BUILD_TCL%g
16159 s%@BUILD_DNSSRV_DYNAMIC@%$BUILD_DNSSRV_DYNAMIC%g
16160 s%@BUILD_LDAP_DYNAMIC@%$BUILD_LDAP_DYNAMIC%g
16161 s%@BUILD_LDBM_DYNAMIC@%$BUILD_LDBM_DYNAMIC%g
16162 s%@BUILD_PASSWD_DYNAMIC@%$BUILD_PASSWD_DYNAMIC%g
16163 s%@BUILD_PERL_DYNAMIC@%$BUILD_PERL_DYNAMIC%g
16164 s%@BUILD_SHELL_DYNAMIC@%$BUILD_SHELL_DYNAMIC%g
16165 s%@BUILD_SQL_DYNAMIC@%$BUILD_SQL_DYNAMIC%g
16166 s%@BUILD_TCL_DYNAMIC@%$BUILD_TCL_DYNAMIC%g
16167 s%@BUILD_SLURPD@%$BUILD_SLURPD%g
16168 s%@LDAP_LIBS@%$LDAP_LIBS%g
16169 s%@LDIF_LIBS@%$LDIF_LIBS%g
16170 s%@SLAPD_LIBS@%$SLAPD_LIBS%g
16171 s%@QUIPU_LIBS@%$QUIPU_LIBS%g
16172 s%@SLURPD_LIBS@%$SLURPD_LIBS%g
16173 s%@LDBM_LIBS@%$LDBM_LIBS%g
16174 s%@LTHREAD_LIBS@%$LTHREAD_LIBS%g
16175 s%@LUTIL_LIBS@%$LUTIL_LIBS%g
16176 s%@WRAP_LIBS@%$WRAP_LIBS%g
16177 s%@MOD_TCL_LIB@%$MOD_TCL_LIB%g
16178 s%@LINK_BINS_DYNAMIC@%$LINK_BINS_DYNAMIC%g
16179 s%@SLAPD_MODULES_CPPFLAGS@%$SLAPD_MODULES_CPPFLAGS%g
16180 s%@SLAPD_MODULES_LDFLAGS@%$SLAPD_MODULES_LDFLAGS%g
16181 s%@SLAPD_MODULES_LIST@%$SLAPD_MODULES_LIST%g
16182 s%@PERL_CPPFLAGS@%$PERL_CPPFLAGS%g
16183 s%@SLAPD_PERL_LDFLAGS@%$SLAPD_PERL_LDFLAGS%g
16184 s%@MOD_PERL_LDFLAGS@%$MOD_PERL_LDFLAGS%g
16185 s%@KRB4_LIBS@%$KRB4_LIBS%g
16186 s%@KRB5_LIBS@%$KRB5_LIBS%g
16187 s%@READLINE_LIBS@%$READLINE_LIBS%g
16188 s%@SASL_LIBS@%$SASL_LIBS%g
16189 s%@TERMCAP_LIBS@%$TERMCAP_LIBS%g
16190 s%@TLS_LIBS@%$TLS_LIBS%g
16191 s%@MODULES_LIBS@%$MODULES_LIBS%g
16192 s%@AUTH_LIBS@%$AUTH_LIBS%g
16193 s%@SLAPD_SQL_LDFLAGS@%$SLAPD_SQL_LDFLAGS%g
16194 s%@SLAPD_SQL_LIBS@%$SLAPD_SQL_LIBS%g
16195 s%@SLAPD_SQL_INCLUDES@%$SLAPD_SQL_INCLUDES%g
16200 cat >> $CONFIG_STATUS <<\EOF
16202 # Split the substitutions into bite-sized pieces for seds with
16203 # small command number limits, like on Digital OSF/1 and HP-UX.
16204 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
16205 ac_file=1 # Number of current file.
16206 ac_beg=1 # First line for current file.
16207 ac_end=$ac_max_sed_cmds # Line after last line for current file.
16210 while $ac_more_lines; do
16211 if test $ac_beg -gt 1; then
16212 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
16214 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
16216 if test ! -s conftest.s$ac_file; then
16217 ac_more_lines=false
16218 rm -f conftest.s$ac_file
16220 if test -z "$ac_sed_cmds"; then
16221 ac_sed_cmds="sed -f conftest.s$ac_file"
16223 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
16225 ac_file=`expr $ac_file + 1`
16227 ac_end=`expr $ac_end + $ac_max_sed_cmds`
16230 if test -z "$ac_sed_cmds"; then
16235 cat >> $CONFIG_STATUS <<EOF
16237 CONFIG_FILES=\${CONFIG_FILES-"\
16238 Makefile:build/top.mk:Makefile.in:build/dir.mk \
16239 doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk \
16240 doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk \
16241 doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk \
16242 doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk \
16243 doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk \
16244 doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk \
16245 clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk \
16246 clients/finger/Makefile:build/top.mk:clients/finger/Makefile.in:build/rules.mk \
16247 clients/fax500/Makefile:build/top.mk:clients/fax500/Makefile.in:build/rules.mk \
16248 clients/gopher/Makefile:build/top.mk:clients/gopher/Makefile.in:build/rules.mk \
16249 clients/mail500/Makefile:build/top.mk:clients/mail500/Makefile.in:build/rules.mk \
16250 clients/rcpt500/Makefile:build/top.mk:clients/rcpt500/Makefile.in:build/rules.mk \
16251 clients/ud/Makefile:build/top.mk:clients/ud/Makefile.in:build/rules.mk \
16252 clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk \
16253 include/Makefile:build/top.mk:include/Makefile.in \
16254 libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk \
16255 libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk \
16256 libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk \
16257 libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk \
16258 libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk \
16259 libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk \
16260 libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk \
16261 libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk \
16262 libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk \
16263 servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk \
16264 servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk \
16265 servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk \
16266 servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk \
16267 servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk \
16268 servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk \
16269 servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk \
16270 servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk \
16271 servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk \
16272 servers/slapd/back-tcl/Makefile:build/top.mk:servers/slapd/back-tcl/Makefile.in:build/mod.mk \
16273 servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk \
16274 servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in \
16275 servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk \
16276 tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk \
16277 tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk \
16278 contrib/Makefile:build/top.mk:contrib/Makefile.in:build/dir.mk \
16279 contrib/saucer/Makefile:build/top.mk:contrib/saucer/Makefile.in:build/rules.mk \
16280 contrib/web_ldap/Makefile:build/top.mk:contrib/web_ldap/Makefile.in:build/rules.mk \
16283 cat >> $CONFIG_STATUS <<\EOF
16284 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
16285 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16287 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
16288 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16289 *) ac_file_in="${ac_file}.in" ;;
16292 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
16294 # Remove last slash and all that follows it. Not all systems have dirname.
16295 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
16296 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16297 # The file is in a subdirectory.
16298 test ! -d "$ac_dir" && mkdir "$ac_dir"
16299 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
16300 # A "../" for each directory in $ac_dir_suffix.
16301 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
16303 ac_dir_suffix= ac_dots=
16306 case "$ac_given_srcdir" in
16308 if test -z "$ac_dots"; then top_srcdir=.
16309 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
16310 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
16311 *) # Relative path.
16312 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
16313 top_srcdir="$ac_dots$ac_given_srcdir" ;;
16316 case "$ac_given_INSTALL" in
16317 [/$]*) INSTALL="$ac_given_INSTALL" ;;
16318 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
16321 echo creating "$ac_file"
16323 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
16325 *[Mm]akefile*) ac_comsub="1i\\
16326 # $configure_input" ;;
16330 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
16332 s%@configure_input@%$configure_input%g
16333 s%@srcdir@%$srcdir%g
16334 s%@top_srcdir@%$top_srcdir%g
16335 s%@INSTALL@%$INSTALL%g
16336 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
16340 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16341 # NAME is the cpp macro being defined and VALUE is the value it is being given.
16343 # ac_d sets the value in "#define NAME VALUE" lines.
16344 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16345 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
16348 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
16349 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16350 ac_uB='\([ ]\)%\1#\2define\3'
16353 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16354 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16355 ac_eB='$%\1#\2define\3'
16359 if test "${CONFIG_HEADERS+set}" != set; then
16361 cat >> $CONFIG_STATUS <<EOF
16362 CONFIG_HEADERS="include/portable.h include/ldap_features.h include/lber_types.h"
16364 cat >> $CONFIG_STATUS <<\EOF
16366 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
16367 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16369 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
16370 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16371 *) ac_file_in="${ac_file}.in" ;;
16374 echo creating $ac_file
16376 rm -f conftest.frag conftest.in conftest.out
16377 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
16378 cat $ac_file_inputs > conftest.in
16382 # Transform confdefs.h into a sed script conftest.vals that substitutes
16383 # the proper values into config.h.in to produce config.h. And first:
16384 # Protect against being on the right side of a sed subst in config.status.
16385 # Protect against being in an unquoted here document in config.status.
16386 rm -f conftest.vals
16387 cat > conftest.hdr <<\EOF
16390 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
16394 sed -n -f conftest.hdr confdefs.h > conftest.vals
16397 # This sed command replaces #undef with comments. This is necessary, for
16398 # example, in the case of _POSIX_SOURCE, which is predefined and required
16399 # on some systems where configure will not decide to define it.
16400 cat >> conftest.vals <<\EOF
16401 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
16404 # Break up conftest.vals because some shells have a limit on
16405 # the size of here documents, and old seds have small limits too.
16407 rm -f conftest.tail
16410 ac_lines=`grep -c . conftest.vals`
16411 # grep -c gives empty output for an empty file on some AIX systems.
16412 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
16413 # Write a limited-size here document to conftest.frag.
16414 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
16415 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
16417 sed -f conftest.frag conftest.in > conftest.out
16419 mv conftest.out conftest.in
16420 ' >> $CONFIG_STATUS
16421 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
16422 rm -f conftest.vals
16423 mv conftest.tail conftest.vals
16425 rm -f conftest.vals
16427 cat >> $CONFIG_STATUS <<\EOF
16428 rm -f conftest.frag conftest.h
16429 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
16430 cat conftest.in >> conftest.h
16432 if cmp -s $ac_file conftest.h 2>/dev/null; then
16433 echo "$ac_file is unchanged"
16436 # Remove last slash and all that follows it. Not all systems have dirname.
16437 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
16438 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16439 # The file is in a subdirectory.
16440 test ! -d "$ac_dir" && mkdir "$ac_dir"
16443 mv conftest.h $ac_file
16448 cat >> $CONFIG_STATUS <<EOF
16451 cat >> $CONFIG_STATUS <<\EOF
16454 echo Please \"make depend\" to build dependencies
16458 chmod +x $CONFIG_STATUS
16459 rm -fr confdefs* $ac_clean_files
16460 test "$no_create" = yes || $SHELL $CONFIG_STATUS || exit 1