3 # from OpenLDAP: pkg/ldap/configure.in,v 1.223.2.15 2000/09/13 00:42:32 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 "Restrictions apply, see COPYRIGHT and LICENSE files."
15 # Guess values for system-dependent variables and create Makefiles.
16 # Generated automatically using autoconf version 2.13.1
17 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
19 # This configure script is free software; the Free Software Foundation
20 # gives unlimited permission to copy, distribute and modify it.
24 ac_default_prefix=/usr/local
25 # Any additions from configure.in:
26 ac_default_prefix=/usr/local
28 --with-subdir=DIR change default subdirectory used for installs"
30 --enable-debug enable debugging (yes)"
32 --enable-syslog enable syslog support (auto)"
34 --enable-proctitle enable proctitle support (yes)"
36 --enable-cache enable caching (yes)"
38 --enable-referrals enable V2 Referrals extension (yes)"
40 --enable-kbind enable V2 Kerberos IV bind (no)"
42 --enable-ipv6 enable IPv6 support (auto)"
44 --enable-local enable AF_LOCAL (AF_UNIX) socket support (auto)"
46 --enable-x-compile enable cross compiling (no)"
48 --with-cyrus-sasl with Cyrus SASL support (auto)"
50 --with-fetch with fetch URL support (auto)"
52 --with-kerberos with support (auto)"
54 --with-readline with readline support (auto)"
56 --with-threads with threads (auto)"
58 --with-tls with TLS/SSL support (auto)"
60 --with-yielding-select with implicitly yielding select (auto)"
62 SLAPD (Standalone LDAP Daemon) Options:"
64 --enable-slapd enable building slapd (yes)"
66 --enable-cleartext enable cleartext passwords (yes)"
68 --enable-crypt enable crypt(3) passwords (auto)"
70 --enable-kpasswd enable kerberos password verification (no)"
72 --enable-spasswd enable (Cyrus) SASL password verification (no)"
74 --enable-modules enable dynamic module support (no)"
76 --enable-multimaster enable multimaster replication (no)"
78 --enable-phonetic enable phonetic/soundex (no)"
80 --enable-rlookups enable reverse lookups (auto)"
82 --enable-aci enable per-object ACIs (no)"
84 --enable-wrappers enable tcp wrapper support (no)"
86 --enable-dynamic enable linking built binaries with dynamic libs (no)"
88 --enable-dnssrv enable dnssrv backend (no)"
90 --with-dnssrv-module module type (static)"
92 --enable-ldap enable ldap backend (no)"
94 --with-ldap-module module type (static)"
96 --enable-ldbm enable ldbm backend (yes)"
98 --with-ldbm-api with LDBM API (auto)"
100 --with-ldbm-module module type (static)"
102 --with-ldbm-type use LDBM type (auto)"
104 --enable-passwd enable passwd backend (no)"
106 --with-passwd-module module type (static)"
108 --enable-shell enable shell backend (no)"
110 --with-shell-module module type (static)"
112 --enable-sql enable sql backend (no)"
114 --with-sql-module module type (static)"
116 SLURPD (Replication Daemon) Options:"
118 --enable-slurpd enable building slurpd (auto)"
120 Library Generation & Linking Options"
122 --enable-static[=PKGS] build static libraries [default=yes]"
124 --enable-shared[=PKGS] build shared libraries [default=yes]"
126 --enable-fast-install[=PKGS] optimize for fast installation [default=yes]"
128 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
130 --disable-libtool-lock avoid locking (might break parallel builds)"
132 # Initialize some variables set by options.
133 # The variables have the same names as the options, with
134 # dashes changed to underlines.
136 cache_file=./config.cache
145 program_transform_name=s,x,x,
153 bindir='${exec_prefix}/bin'
154 sbindir='${exec_prefix}/sbin'
155 libexecdir='${exec_prefix}/libexec'
156 datadir='${prefix}/share'
157 sysconfdir='${prefix}/etc'
158 sharedstatedir='${prefix}/com'
159 localstatedir='${prefix}/var'
160 libdir='${exec_prefix}/lib'
161 includedir='${prefix}/include'
162 oldincludedir='/usr/include'
163 infodir='${prefix}/info'
164 mandir='${prefix}/man'
166 # Initialize some other variables.
169 SHELL=${CONFIG_SHELL-/bin/sh}
170 # Maximum number of lines to put in a shell here document.
177 # If the previous option needs an argument, assign it.
178 if test -n "$ac_prev"; then
179 eval "$ac_prev=\$ac_option"
185 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
189 # Accept the important Cygnus configure options, so we can diagnose typos.
193 -bindir | --bindir | --bindi | --bind | --bin | --bi)
195 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
196 bindir="$ac_optarg" ;;
198 -build | --build | --buil | --bui | --bu)
200 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
201 build="$ac_optarg" ;;
203 -cache-file | --cache-file | --cache-fil | --cache-fi \
204 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
205 ac_prev=cache_file ;;
206 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
207 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
208 cache_file="$ac_optarg" ;;
210 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
212 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
214 datadir="$ac_optarg" ;;
216 -disable-* | --disable-*)
217 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
218 # Reject names that are not valid shell variable names.
219 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
220 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
222 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
223 eval "enable_${ac_feature}=no" ;;
225 -enable-* | --enable-*)
226 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
227 # Reject names that are not valid shell variable names.
228 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
229 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
231 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
236 eval "enable_${ac_feature}='$ac_optarg'" ;;
238 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
239 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
240 | --exec | --exe | --ex)
241 ac_prev=exec_prefix ;;
242 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
243 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
244 | --exec=* | --exe=* | --ex=*)
245 exec_prefix="$ac_optarg" ;;
247 -gas | --gas | --ga | --g)
248 # Obsolete; use --with-gas.
251 -help | --help | --hel | --he)
252 # Omit some internal or obsolete options to make the list less imposing.
253 # This message is too long to be a string in the A/UX 3.1 sh.
255 Usage: configure [options] [host]
256 Options: [defaults in brackets after descriptions]
258 --cache-file=FILE cache test results in FILE
259 --help print this message
260 --no-create do not create output files
261 --quiet, --silent do not print \`checking...' messages
262 --version print the version of autoconf that created configure
263 Directory and file names:
264 --prefix=PREFIX install architecture-independent files in PREFIX
266 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
268 --bindir=DIR user executables in DIR [EPREFIX/bin]
269 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
270 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
271 --datadir=DIR read-only architecture-independent data in DIR
273 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
274 --sharedstatedir=DIR modifiable architecture-independent data in DIR
276 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
277 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
278 --includedir=DIR C header files in DIR [PREFIX/include]
279 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
280 --infodir=DIR info documentation in DIR [PREFIX/info]
281 --mandir=DIR man documentation in DIR [PREFIX/man]
282 --srcdir=DIR find the sources in DIR [configure dir or ..]
283 --program-prefix=PREFIX prepend PREFIX to installed program names
284 --program-suffix=SUFFIX append SUFFIX to installed program names
285 --program-transform-name=PROGRAM
286 run sed PROGRAM on installed program names
290 --build=BUILD configure for building on BUILD [BUILD=HOST]
291 --host=HOST configure for HOST [guessed]
292 --target=TARGET configure for TARGET [TARGET=HOST]
293 Features and packages:
294 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
295 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
296 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
297 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
298 --x-includes=DIR X include files are in DIR
299 --x-libraries=DIR X library files are in DIR
301 if test -n "$ac_help"; then
302 echo "--enable and --with options recognized:$ac_help"
306 -host | --host | --hos | --ho)
308 -host=* | --host=* | --hos=* | --ho=*)
311 -includedir | --includedir | --includedi | --included | --include \
312 | --includ | --inclu | --incl | --inc)
313 ac_prev=includedir ;;
314 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
315 | --includ=* | --inclu=* | --incl=* | --inc=*)
316 includedir="$ac_optarg" ;;
318 -infodir | --infodir | --infodi | --infod | --info | --inf)
320 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
321 infodir="$ac_optarg" ;;
323 -libdir | --libdir | --libdi | --libd)
325 -libdir=* | --libdir=* | --libdi=* | --libd=*)
326 libdir="$ac_optarg" ;;
328 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
329 | --libexe | --libex | --libe)
330 ac_prev=libexecdir ;;
331 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
332 | --libexe=* | --libex=* | --libe=*)
333 libexecdir="$ac_optarg" ;;
335 -localstatedir | --localstatedir | --localstatedi | --localstated \
336 | --localstate | --localstat | --localsta | --localst \
337 | --locals | --local | --loca | --loc | --lo)
338 ac_prev=localstatedir ;;
339 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
340 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
341 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
342 localstatedir="$ac_optarg" ;;
344 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
346 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
347 mandir="$ac_optarg" ;;
350 # Obsolete; use --without-fp.
353 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
357 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
358 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
361 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
362 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
363 | --oldin | --oldi | --old | --ol | --o)
364 ac_prev=oldincludedir ;;
365 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
366 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
367 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
368 oldincludedir="$ac_optarg" ;;
370 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
372 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
373 prefix="$ac_optarg" ;;
375 -program-prefix | --program-prefix | --program-prefi | --program-pref \
376 | --program-pre | --program-pr | --program-p)
377 ac_prev=program_prefix ;;
378 -program-prefix=* | --program-prefix=* | --program-prefi=* \
379 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
380 program_prefix="$ac_optarg" ;;
382 -program-suffix | --program-suffix | --program-suffi | --program-suff \
383 | --program-suf | --program-su | --program-s)
384 ac_prev=program_suffix ;;
385 -program-suffix=* | --program-suffix=* | --program-suffi=* \
386 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
387 program_suffix="$ac_optarg" ;;
389 -program-transform-name | --program-transform-name \
390 | --program-transform-nam | --program-transform-na \
391 | --program-transform-n | --program-transform- \
392 | --program-transform | --program-transfor \
393 | --program-transfo | --program-transf \
394 | --program-trans | --program-tran \
395 | --progr-tra | --program-tr | --program-t)
396 ac_prev=program_transform_name ;;
397 -program-transform-name=* | --program-transform-name=* \
398 | --program-transform-nam=* | --program-transform-na=* \
399 | --program-transform-n=* | --program-transform-=* \
400 | --program-transform=* | --program-transfor=* \
401 | --program-transfo=* | --program-transf=* \
402 | --program-trans=* | --program-tran=* \
403 | --progr-tra=* | --program-tr=* | --program-t=*)
404 program_transform_name="$ac_optarg" ;;
406 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
407 | -silent | --silent | --silen | --sile | --sil)
410 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
412 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
414 sbindir="$ac_optarg" ;;
416 -sharedstatedir | --sharedstatedir | --sharedstatedi \
417 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
418 | --sharedst | --shareds | --shared | --share | --shar \
420 ac_prev=sharedstatedir ;;
421 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
422 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
423 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
425 sharedstatedir="$ac_optarg" ;;
427 -site | --site | --sit)
429 -site=* | --site=* | --sit=*)
432 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
434 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
435 srcdir="$ac_optarg" ;;
437 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
438 | --syscon | --sysco | --sysc | --sys | --sy)
439 ac_prev=sysconfdir ;;
440 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
441 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
442 sysconfdir="$ac_optarg" ;;
444 -target | --target | --targe | --targ | --tar | --ta | --t)
446 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
447 target="$ac_optarg" ;;
449 -v | -verbose | --verbose | --verbos | --verbo | --verb)
452 -version | --version | --versio | --versi | --vers)
453 echo "configure generated by autoconf version 2.13.1"
457 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
458 # Reject names that are not valid shell variable names.
459 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
460 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
462 ac_package=`echo $ac_package| sed 's/-/_/g'`
467 eval "with_${ac_package}='$ac_optarg'" ;;
469 -without-* | --without-*)
470 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
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'`
476 eval "with_${ac_package}=no" ;;
479 # Obsolete; use --with-x.
482 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
483 | --x-incl | --x-inc | --x-in | --x-i)
484 ac_prev=x_includes ;;
485 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
486 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
487 x_includes="$ac_optarg" ;;
489 -x-libraries | --x-libraries | --x-librarie | --x-librari \
490 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
491 ac_prev=x_libraries ;;
492 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
493 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
494 x_libraries="$ac_optarg" ;;
496 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
500 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
501 echo "configure: warning: $ac_option: invalid host type" 1>&2
503 if test "x$nonopt" != xNONE; then
504 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
512 if test -n "$ac_prev"; then
513 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
516 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
518 # File descriptor usage:
521 # 2 errors and warnings
522 # 3 some systems may open it to /dev/tty
523 # 4 used on the Kubota Titan
524 # 6 checking for... messages and results
525 # 5 compiler messages saved in config.log
526 if test "$silent" = yes; then
534 This file contains any messages produced by compilers while
535 running configure, to aid debugging if configure makes a mistake.
538 # Strip out --no-create and --no-recursion so they do not pile up.
539 # Also quote any args containing shell metacharacters.
544 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
545 | --no-cr | --no-c) ;;
546 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
547 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
548 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
549 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
550 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
555 # Only set these to C if already set. These must not be set unconditionally
556 # because not all systems understand e.g. LANG=C (notably SCO).
557 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
558 # Non-C LC_CTYPE values break the ctype check.
559 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
560 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
561 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
562 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
564 # confdefs.h avoids OS command line length limits that DEFS can exceed.
565 rm -rf conftest* confdefs.h
566 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
569 # A filename unique to this package, relative to the directory that
570 # configure is in, which we can look for to find out if srcdir is correct.
571 ac_unique_file=build/version
573 # Find the source files, if location was not specified.
574 if test -z "$srcdir"; then
575 ac_srcdir_defaulted=yes
576 # Try the directory containing this script, then its parent.
578 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
579 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
581 if test ! -r $srcdir/$ac_unique_file; then
585 ac_srcdir_defaulted=no
587 if test ! -r $srcdir/$ac_unique_file; then
588 if test "$ac_srcdir_defaulted" = yes; then
589 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
591 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
594 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
596 # Prefer explicitly selected file to automatically selected ones.
597 if test -z "$CONFIG_SITE"; then
598 if test "x$prefix" != xNONE; then
599 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
601 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
604 for ac_site_file in $CONFIG_SITE; do
605 if test -r "$ac_site_file"; then
606 echo "loading site script $ac_site_file"
613 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
614 ac_cpp='$CPP $CPPFLAGS'
615 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
616 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
617 cross_compiling=$ac_cv_prog_cc_cross
621 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
622 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
623 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
630 ac_n= ac_c='\c' ac_t=
634 # set unset (borrowed from autoconf 2.14a)
635 if (unset FOO) >/dev/null 2>&1; then
641 $ol_unset CDPATH || test "${CDPATH+set}" != set || CDPATH=: && export CDPATH
644 for ac_dir in build $srcdir/build; do
645 if test -f $ac_dir/install-sh; then
647 ac_install_sh="$ac_aux_dir/install-sh -c"
649 elif test -f $ac_dir/install.sh; then
651 ac_install_sh="$ac_aux_dir/install.sh -c"
653 elif test -f $ac_dir/shtool; then
655 ac_install_sh="$ac_aux_dir/shtool install -c"
659 if test -z "$ac_aux_dir"; then
660 { echo "configure: error: can not find install-sh or install.sh in build $srcdir/build" 1>&2; exit 1; }
662 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
663 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
664 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
666 OL_VERSION=`cat $ac_aux_dir/version`
667 if test -z "$OL_VERSION"; then
668 { echo "configure: error: could not determine version" 1>&2; exit 1; }
671 echo "Configuring OpenLDAP $OL_VERSION ..."
674 echo $ac_n "checking host system type""... $ac_c" 1>&6
675 echo "configure:676: checking host system type" >&5
676 if test "x$ac_cv_host" = "x" || (test "x$host" != "xNONE" && test "x$host" != "x$ac_cv_host_alias"); then
678 # Make sure we can run config.sub.
679 if $ac_config_sub sun4 >/dev/null 2>&1; then :
680 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
683 ac_cv_host_alias=$host
684 case "$ac_cv_host_alias" in
688 if ac_cv_host_alias=`$ac_config_guess`; then :
689 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
691 *) ac_cv_host_alias=$nonopt ;;
695 ac_cv_host=`$ac_config_sub $ac_cv_host_alias`
696 ac_cv_host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
697 ac_cv_host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
698 ac_cv_host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
700 echo $ac_n "(cached) $ac_c" 1>&6
703 echo "$ac_t""$ac_cv_host" 1>&6
706 host_alias=$ac_cv_host_alias
707 host_cpu=$ac_cv_host_cpu
708 host_vendor=$ac_cv_host_vendor
709 host_os=$ac_cv_host_os
715 echo $ac_n "checking target system type""... $ac_c" 1>&6
716 echo "configure:717: checking target system type" >&5
717 if test "x$ac_cv_target" = "x" || (test "x$target" != "xNONE" && test "x$target" != "x$ac_cv_target_alias"); then
719 # Make sure we can run config.sub.
720 if $ac_config_sub sun4 >/dev/null 2>&1; then :
721 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
724 ac_cv_target_alias=$target
725 case "$ac_cv_target_alias" in
729 ac_cv_target_alias=$host_alias ;;
731 *) ac_cv_target_alias=$nonopt ;;
735 ac_cv_target=`$ac_config_sub $ac_cv_target_alias`
736 ac_cv_target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
737 ac_cv_target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
738 ac_cv_target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
740 echo $ac_n "(cached) $ac_c" 1>&6
743 echo "$ac_t""$ac_cv_target" 1>&6
746 target_alias=$ac_cv_target_alias
747 target_cpu=$ac_cv_target_cpu
748 target_vendor=$ac_cv_target_vendor
749 target_os=$ac_cv_target_os
755 echo $ac_n "checking build system type""... $ac_c" 1>&6
756 echo "configure:757: checking build system type" >&5
757 if test "x$ac_cv_build" = "x" || (test "x$build" != "xNONE" && test "x$build" != "x$ac_cv_build_alias"); then
759 # Make sure we can run config.sub.
760 if $ac_config_sub sun4 >/dev/null 2>&1; then :
761 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
764 ac_cv_build_alias=$build
765 case "$ac_cv_build_alias" in
769 ac_cv_build_alias=$host_alias ;;
771 *) ac_cv_build_alias=$nonopt ;;
775 ac_cv_build=`$ac_config_sub $ac_cv_build_alias`
776 ac_cv_build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
777 ac_cv_build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
778 ac_cv_build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
780 echo $ac_n "(cached) $ac_c" 1>&6
783 echo "$ac_t""$ac_cv_build" 1>&6
786 build_alias=$ac_cv_build_alias
787 build_cpu=$ac_cv_build_cpu
788 build_vendor=$ac_cv_build_vendor
789 build_os=$ac_cv_build_os
795 # Do some error checking and defaulting for the host and target type.
797 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
800 # 1. You are not allowed to specify --host, --target, and nonopt at the
802 # 2. Host defaults to nonopt.
803 # 3. If nonopt is not specified, then host defaults to the current host,
804 # as determined by config.guess.
805 # 4. Target and build default to nonopt.
806 # 5. If nonopt is not specified, then target and build default to host.
808 # The aliases save the names the user supplied, while $host etc.
809 # will get canonicalized.
810 case $host---$target---$nonopt in
811 NONE---*---* | *---NONE---* | *---*---NONE) ;;
812 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
815 test "$host_alias" != "$target_alias" &&
816 test "$program_prefix$program_suffix$program_transform_name" = \
818 program_prefix=${target_alias}-
821 # Find a good install program. We prefer a C program (faster),
822 # so one script is as good as another. But avoid the broken or
823 # incompatible versions:
824 # SysV /etc/install, /usr/sbin/install
825 # SunOS /usr/etc/install
828 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
829 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
830 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
831 # ./install, which can be erroneously created by make from ./install.sh.
832 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
833 echo "configure:834: checking for a BSD compatible install" >&5
834 if test -z "$INSTALL"; then
835 if eval "test \"\${ac_cv_path_install+set}\" = set"; then
836 echo $ac_n "(cached) $ac_c" 1>&6
838 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
839 for ac_dir in $PATH; do
840 # Account for people who put trailing slashes in PATH elements.
842 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
844 # OSF1 and SCO ODT 3.0 have their own names for install.
845 # Don't use installbsd from OSF since it installs stuff as root
847 for ac_prog in ginstall scoinst install; do
848 if test -f $ac_dir/$ac_prog; then
849 if test $ac_prog = install &&
850 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
851 # AIX install. It has an incompatible calling convention.
853 elif test $ac_prog = install &&
854 grep pwplus $ac_dir/$ac_prog >/dev/null 2>&1; then
855 # program-specific install script used by HP pwplus--don't use.
858 ac_cv_path_install="$ac_dir/$ac_prog -c"
869 if test "${ac_cv_path_install+set}" = set; then
870 INSTALL="$ac_cv_path_install"
872 # As a last resort, use the slow shell script. We don't cache a
873 # path for INSTALL within a source directory, because that will
874 # break other packages using the cache if that directory is
875 # removed, or if the path is relative.
876 INSTALL="$ac_install_sh"
879 echo "$ac_t""$INSTALL" 1>&6
881 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
882 # It thinks the first close brace ends the variable substitution.
883 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
885 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
887 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
889 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
890 echo "configure:891: checking whether build environment is sane" >&5
893 echo timestamp > conftestfile
894 # Do `set' in a subshell so we don't clobber the current shell's
895 # arguments. Must try -L first in case configure is actually a
896 # symlink; some systems play weird games with the mod time of symlinks
897 # (eg FreeBSD returns the mod time of the symlink's containing
900 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
901 if test "$*" = "X"; then
903 set X `ls -t $srcdir/configure conftestfile`
905 if test "$*" != "X $srcdir/configure conftestfile" \
906 && test "$*" != "X conftestfile $srcdir/configure"; then
908 # If neither matched, then we have a broken ls. This can happen
909 # if, for instance, CONFIG_SHELL is bash and it inherits a
910 # broken ls alias from the environment. This has actually
911 # happened. Such a system could not be considered "sane".
912 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
913 alias in your environment" 1>&2; exit 1; }
916 test "$2" = conftestfile
922 { echo "configure: error: newly created file is older than distributed files!
923 Check your system clock" 1>&2; exit 1; }
926 echo "$ac_t""yes" 1>&6
927 if test "$program_transform_name" = s,x,x,; then
928 program_transform_name=
930 # Double any \ or $. echo might interpret backslashes.
931 cat <<\EOF_SED > conftestsed
932 s,\\,\\\\,g; s,\$,$$,g
934 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
937 test "$program_prefix" != NONE &&
938 program_transform_name="s,^,${program_prefix},;$program_transform_name"
939 # Use a double $ so make ignores it.
940 test "$program_suffix" != NONE &&
941 program_transform_name="s,\$\$,${program_suffix},;$program_transform_name"
943 # sed with no file args requires a program.
944 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
946 for ac_prog in mawk gawk nawk awk
948 # Extract the first word of "$ac_prog", so it can be a program name with args.
949 set dummy $ac_prog; ac_word=$2
950 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
951 echo "configure:952: checking for $ac_word" >&5
952 if eval "test \"\${ac_cv_prog_AWK+set}\" = set"; then
953 echo $ac_n "(cached) $ac_c" 1>&6
955 if test -n "$AWK"; then
956 ac_cv_prog_AWK="$AWK" # Let the user override the test.
958 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
960 for ac_dir in $ac_dummy; do
961 test -z "$ac_dir" && ac_dir=.
962 if test -f $ac_dir/$ac_word; then
963 ac_cv_prog_AWK="$ac_prog"
970 AWK="$ac_cv_prog_AWK"
971 if test -n "$AWK"; then
972 echo "$ac_t""$AWK" 1>&6
974 echo "$ac_t""no" 1>&6
977 test -n "$AWK" && break
980 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
981 echo "configure:982: checking whether ${MAKE-make} sets \${MAKE}" >&5
982 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
983 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
984 echo $ac_n "(cached) $ac_c" 1>&6
986 cat > conftestmake <<\EOF
988 @echo 'ac_maketemp="${MAKE}"'
990 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
991 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
992 if test -n "$ac_maketemp"; then
993 eval ac_cv_prog_make_${ac_make}_set=yes
995 eval ac_cv_prog_make_${ac_make}_set=no
999 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1000 echo "$ac_t""yes" 1>&6
1003 echo "$ac_t""no" 1>&6
1004 SET_MAKE="MAKE=${MAKE-make}"
1013 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1014 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1019 missing_dir=`cd $ac_aux_dir && pwd`
1020 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
1021 echo "configure:1022: checking for working aclocal" >&5
1022 # Run test in a subshell; some versions of sh will print an error if
1023 # an executable is not found, even if stderr is redirected.
1024 # Redirect stdin to placate older versions of autoconf. Sigh.
1025 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1027 echo "$ac_t""found" 1>&6
1029 ACLOCAL="$missing_dir/missing aclocal"
1030 echo "$ac_t""missing" 1>&6
1033 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
1034 echo "configure:1035: checking for working autoconf" >&5
1035 # Run test in a subshell; some versions of sh will print an error if
1036 # an executable is not found, even if stderr is redirected.
1037 # Redirect stdin to placate older versions of autoconf. Sigh.
1038 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1040 echo "$ac_t""found" 1>&6
1042 AUTOCONF="$missing_dir/missing autoconf"
1043 echo "$ac_t""missing" 1>&6
1046 echo $ac_n "checking for working automake""... $ac_c" 1>&6
1047 echo "configure:1048: checking for working automake" >&5
1048 # Run test in a subshell; some versions of sh will print an error if
1049 # an executable is not found, even if stderr is redirected.
1050 # Redirect stdin to placate older versions of autoconf. Sigh.
1051 if (automake --version) < /dev/null > /dev/null 2>&1; then
1053 echo "$ac_t""found" 1>&6
1055 AUTOMAKE="$missing_dir/missing automake"
1056 echo "$ac_t""missing" 1>&6
1059 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
1060 echo "configure:1061: checking for working autoheader" >&5
1061 # Run test in a subshell; some versions of sh will print an error if
1062 # an executable is not found, even if stderr is redirected.
1063 # Redirect stdin to placate older versions of autoconf. Sigh.
1064 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1065 AUTOHEADER=autoheader
1066 echo "$ac_t""found" 1>&6
1068 AUTOHEADER="$missing_dir/missing autoheader"
1069 echo "$ac_t""missing" 1>&6
1072 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
1073 echo "configure:1074: checking for working makeinfo" >&5
1074 # Run test in a subshell; some versions of sh will print an error if
1075 # an executable is not found, even if stderr is redirected.
1076 # Redirect stdin to placate older versions of autoconf. Sigh.
1077 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1079 echo "$ac_t""found" 1>&6
1081 MAKEINFO="$missing_dir/missing makeinfo"
1082 echo "$ac_t""missing" 1>&6
1085 install_sh="$missing_dir/install-sh"
1086 test -f "$install_sh" || install_sh="$missing_dir/install.sh"
1088 for ac_prog in gnutar gtar tar
1090 # Extract the first word of "$ac_prog", so it can be a program name with args.
1091 set dummy $ac_prog; ac_word=$2
1092 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1093 echo "configure:1094: checking for $ac_word" >&5
1094 if eval "test \"\${ac_cv_prog_AMTAR+set}\" = set"; then
1095 echo $ac_n "(cached) $ac_c" 1>&6
1097 if test -n "$AMTAR"; then
1098 ac_cv_prog_AMTAR="$AMTAR" # Let the user override the test.
1100 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1102 for ac_dir in $ac_dummy; do
1103 test -z "$ac_dir" && ac_dir=.
1104 if test -f $ac_dir/$ac_word; then
1105 ac_cv_prog_AMTAR="$ac_prog"
1112 AMTAR="$ac_cv_prog_AMTAR"
1113 if test -n "$AMTAR"; then
1114 echo "$ac_t""$AMTAR" 1>&6
1116 echo "$ac_t""no" 1>&6
1119 test -n "$AMTAR" && break
1124 if test -n "$AMTAR"; then
1125 if $SHELL -c "$AMTAR --version" > /dev/null 2>&1; then
1132 cat >> confdefs.h <<EOF
1133 #define OPENLDAP_PACKAGE "$PACKAGE"
1136 cat >> confdefs.h <<EOF
1137 #define OPENLDAP_VERSION "$VERSION"
1143 echo $ac_n "checking configure arguments""... $ac_c" 1>&6
1144 echo "configure:1145: checking configure arguments" >&5
1149 ldap_subdir="/openldap"
1151 # Check whether --with-subdir or --without-subdir was given.
1152 if test "${with_subdir+set}" = set; then
1153 withval="$with_subdir"
1160 ldap_subdir="$withval"
1163 ldap_subdir="/$withval"
1170 # OpenLDAP --enable-debug
1171 # Check whether --enable-debug or --disable-debug was given.
1172 if test "${enable_debug+set}" = set; then
1173 enableval="$enable_debug"
1176 for ol_val in auto yes no ; do
1177 if test "$enableval" = "$ol_val" ; then
1181 if test "$ol_arg" = "invalid" ; then
1182 { echo "configure: error: bad value $enableval for --enable-debug" 1>&2; exit 1; }
1184 ol_enable_debug="$ol_arg"
1187 ol_enable_debug="yes"
1189 # end --enable-debug
1190 # OpenLDAP --enable-syslog
1191 # Check whether --enable-syslog or --disable-syslog was given.
1192 if test "${enable_syslog+set}" = set; then
1193 enableval="$enable_syslog"
1196 for ol_val in auto yes no ; do
1197 if test "$enableval" = "$ol_val" ; then
1201 if test "$ol_arg" = "invalid" ; then
1202 { echo "configure: error: bad value $enableval for --enable-syslog" 1>&2; exit 1; }
1204 ol_enable_syslog="$ol_arg"
1207 ol_enable_syslog="auto"
1209 # end --enable-syslog
1210 # OpenLDAP --enable-proctitle
1211 # Check whether --enable-proctitle or --disable-proctitle was given.
1212 if test "${enable_proctitle+set}" = set; then
1213 enableval="$enable_proctitle"
1216 for ol_val in auto yes no ; do
1217 if test "$enableval" = "$ol_val" ; then
1221 if test "$ol_arg" = "invalid" ; then
1222 { echo "configure: error: bad value $enableval for --enable-proctitle" 1>&2; exit 1; }
1224 ol_enable_proctitle="$ol_arg"
1227 ol_enable_proctitle="yes"
1229 # end --enable-proctitle
1230 # OpenLDAP --enable-cache
1231 # Check whether --enable-cache or --disable-cache was given.
1232 if test "${enable_cache+set}" = set; then
1233 enableval="$enable_cache"
1236 for ol_val in auto yes no ; do
1237 if test "$enableval" = "$ol_val" ; then
1241 if test "$ol_arg" = "invalid" ; then
1242 { echo "configure: error: bad value $enableval for --enable-cache" 1>&2; exit 1; }
1244 ol_enable_cache="$ol_arg"
1247 ol_enable_cache="yes"
1249 # end --enable-cache
1250 # OpenLDAP --enable-referrals
1251 # Check whether --enable-referrals or --disable-referrals was given.
1252 if test "${enable_referrals+set}" = set; then
1253 enableval="$enable_referrals"
1256 for ol_val in auto yes no ; do
1257 if test "$enableval" = "$ol_val" ; then
1261 if test "$ol_arg" = "invalid" ; then
1262 { echo "configure: error: bad value $enableval for --enable-referrals" 1>&2; exit 1; }
1264 ol_enable_referrals="$ol_arg"
1267 ol_enable_referrals="yes"
1269 # end --enable-referrals
1270 # OpenLDAP --enable-kbind
1271 # Check whether --enable-kbind or --disable-kbind was given.
1272 if test "${enable_kbind+set}" = set; then
1273 enableval="$enable_kbind"
1276 for ol_val in auto yes no ; do
1277 if test "$enableval" = "$ol_val" ; then
1281 if test "$ol_arg" = "invalid" ; then
1282 { echo "configure: error: bad value $enableval for --enable-kbind" 1>&2; exit 1; }
1284 ol_enable_kbind="$ol_arg"
1287 ol_enable_kbind="no"
1289 # end --enable-kbind
1290 # OpenLDAP --enable-ipv6
1291 # Check whether --enable-ipv6 or --disable-ipv6 was given.
1292 if test "${enable_ipv6+set}" = set; then
1293 enableval="$enable_ipv6"
1296 for ol_val in auto yes no ; do
1297 if test "$enableval" = "$ol_val" ; then
1301 if test "$ol_arg" = "invalid" ; then
1302 { echo "configure: error: bad value $enableval for --enable-ipv6" 1>&2; exit 1; }
1304 ol_enable_ipv6="$ol_arg"
1307 ol_enable_ipv6="auto"
1310 # OpenLDAP --enable-local
1311 # Check whether --enable-local or --disable-local was given.
1312 if test "${enable_local+set}" = set; then
1313 enableval="$enable_local"
1316 for ol_val in auto yes no ; do
1317 if test "$enableval" = "$ol_val" ; then
1321 if test "$ol_arg" = "invalid" ; then
1322 { echo "configure: error: bad value $enableval for --enable-local" 1>&2; exit 1; }
1324 ol_enable_local="$ol_arg"
1327 ol_enable_local="auto"
1329 # end --enable-local
1330 # OpenLDAP --enable-x_compile
1331 # Check whether --enable-x_compile or --disable-x_compile was given.
1332 if test "${enable_x_compile+set}" = set; then
1333 enableval="$enable_x_compile"
1336 for ol_val in yes no ; do
1337 if test "$enableval" = "$ol_val" ; then
1341 if test "$ol_arg" = "invalid" ; then
1342 { echo "configure: error: bad value $enableval for --enable-x_compile" 1>&2; exit 1; }
1344 ol_enable_x_compile="$ol_arg"
1347 ol_enable_x_compile="no"
1349 # end --enable-x_compile
1352 # OpenLDAP --with-cyrus_sasl
1353 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
1354 if test "${with_cyrus_sasl+set}" = set; then
1355 withval="$with_cyrus_sasl"
1358 for ol_val in auto yes no ; do
1359 if test "$withval" = "$ol_val" ; then
1363 if test "$ol_arg" = "invalid" ; then
1364 { echo "configure: error: bad value $withval for --with-cyrus_sasl" 1>&2; exit 1; }
1366 ol_with_cyrus_sasl="$ol_arg"
1369 ol_with_cyrus_sasl="auto"
1371 # end --with-cyrus_sasl
1373 # OpenLDAP --with-fetch
1374 # Check whether --with-fetch or --without-fetch was given.
1375 if test "${with_fetch+set}" = set; then
1376 withval="$with_fetch"
1379 for ol_val in auto yes no ; do
1380 if test "$withval" = "$ol_val" ; then
1384 if test "$ol_arg" = "invalid" ; then
1385 { echo "configure: error: bad value $withval for --with-fetch" 1>&2; exit 1; }
1387 ol_with_fetch="$ol_arg"
1390 ol_with_fetch="auto"
1394 # OpenLDAP --with-kerberos
1395 # Check whether --with-kerberos or --without-kerberos was given.
1396 if test "${with_kerberos+set}" = set; then
1397 withval="$with_kerberos"
1400 for ol_val in auto k5 k5only k425 kth k4 afs yes no ; do
1401 if test "$withval" = "$ol_val" ; then
1405 if test "$ol_arg" = "invalid" ; then
1406 { echo "configure: error: bad value $withval for --with-kerberos" 1>&2; exit 1; }
1408 ol_with_kerberos="$ol_arg"
1411 ol_with_kerberos="auto"
1413 # end --with-kerberos
1415 # OpenLDAP --with-readline
1416 # Check whether --with-readline or --without-readline was given.
1417 if test "${with_readline+set}" = set; then
1418 withval="$with_readline"
1421 for ol_val in auto yes no ; do
1422 if test "$withval" = "$ol_val" ; then
1426 if test "$ol_arg" = "invalid" ; then
1427 { echo "configure: error: bad value $withval for --with-readline" 1>&2; exit 1; }
1429 ol_with_readline="$ol_arg"
1432 ol_with_readline="auto"
1434 # end --with-readline
1436 # OpenLDAP --with-threads
1437 # Check whether --with-threads or --without-threads was given.
1438 if test "${with_threads+set}" = set; then
1439 withval="$with_threads"
1442 for ol_val in auto nt posix mach pth lwp yes no manual ; do
1443 if test "$withval" = "$ol_val" ; then
1447 if test "$ol_arg" = "invalid" ; then
1448 { echo "configure: error: bad value $withval for --with-threads" 1>&2; exit 1; }
1450 ol_with_threads="$ol_arg"
1453 ol_with_threads="auto"
1455 # end --with-threads
1457 # OpenLDAP --with-tls
1458 # Check whether --with-tls or --without-tls was given.
1459 if test "${with_tls+set}" = set; then
1463 for ol_val in auto ssleay openssl yes no ; do
1464 if test "$withval" = "$ol_val" ; then
1468 if test "$ol_arg" = "invalid" ; then
1469 { echo "configure: error: bad value $withval for --with-tls" 1>&2; exit 1; }
1471 ol_with_tls="$ol_arg"
1478 # OpenLDAP --with-yielding_select
1479 # Check whether --with-yielding_select or --without-yielding_select was given.
1480 if test "${with_yielding_select+set}" = set; then
1481 withval="$with_yielding_select"
1484 for ol_val in auto yes no manual ; do
1485 if test "$withval" = "$ol_val" ; then
1489 if test "$ol_arg" = "invalid" ; then
1490 { echo "configure: error: bad value $withval for --with-yielding_select" 1>&2; exit 1; }
1492 ol_with_yielding_select="$ol_arg"
1495 ol_with_yielding_select="auto"
1497 # end --with-yielding_select
1501 # Check whether --with-xxslapdoptions or --without-xxslapdoptions was given.
1502 if test "${with_xxslapdoptions+set}" = set; then
1503 withval="$with_xxslapdoptions"
1507 # OpenLDAP --enable-slapd
1508 # Check whether --enable-slapd or --disable-slapd was given.
1509 if test "${enable_slapd+set}" = set; then
1510 enableval="$enable_slapd"
1513 for ol_val in auto yes no ; do
1514 if test "$enableval" = "$ol_val" ; then
1518 if test "$ol_arg" = "invalid" ; then
1519 { echo "configure: error: bad value $enableval for --enable-slapd" 1>&2; exit 1; }
1521 ol_enable_slapd="$ol_arg"
1524 ol_enable_slapd="yes"
1526 # end --enable-slapd
1527 # OpenLDAP --enable-cleartext
1528 # Check whether --enable-cleartext or --disable-cleartext was given.
1529 if test "${enable_cleartext+set}" = set; then
1530 enableval="$enable_cleartext"
1533 for ol_val in auto yes no ; do
1534 if test "$enableval" = "$ol_val" ; then
1538 if test "$ol_arg" = "invalid" ; then
1539 { echo "configure: error: bad value $enableval for --enable-cleartext" 1>&2; exit 1; }
1541 ol_enable_cleartext="$ol_arg"
1544 ol_enable_cleartext="yes"
1546 # end --enable-cleartext
1547 # OpenLDAP --enable-crypt
1548 # Check whether --enable-crypt or --disable-crypt was given.
1549 if test "${enable_crypt+set}" = set; then
1550 enableval="$enable_crypt"
1553 for ol_val in auto yes no ; do
1554 if test "$enableval" = "$ol_val" ; then
1558 if test "$ol_arg" = "invalid" ; then
1559 { echo "configure: error: bad value $enableval for --enable-crypt" 1>&2; exit 1; }
1561 ol_enable_crypt="$ol_arg"
1564 ol_enable_crypt="auto"
1566 # end --enable-crypt
1567 # OpenLDAP --enable-kpasswd
1568 # Check whether --enable-kpasswd or --disable-kpasswd was given.
1569 if test "${enable_kpasswd+set}" = set; then
1570 enableval="$enable_kpasswd"
1573 for ol_val in auto yes no ; do
1574 if test "$enableval" = "$ol_val" ; then
1578 if test "$ol_arg" = "invalid" ; then
1579 { echo "configure: error: bad value $enableval for --enable-kpasswd" 1>&2; exit 1; }
1581 ol_enable_kpasswd="$ol_arg"
1584 ol_enable_kpasswd="no"
1586 # end --enable-kpasswd
1587 # OpenLDAP --enable-spasswd
1588 # Check whether --enable-spasswd or --disable-spasswd was given.
1589 if test "${enable_spasswd+set}" = set; then
1590 enableval="$enable_spasswd"
1593 for ol_val in auto yes no ; do
1594 if test "$enableval" = "$ol_val" ; then
1598 if test "$ol_arg" = "invalid" ; then
1599 { echo "configure: error: bad value $enableval for --enable-spasswd" 1>&2; exit 1; }
1601 ol_enable_spasswd="$ol_arg"
1604 ol_enable_spasswd="no"
1606 # end --enable-spasswd
1607 # OpenLDAP --enable-modules
1608 # Check whether --enable-modules or --disable-modules was given.
1609 if test "${enable_modules+set}" = set; then
1610 enableval="$enable_modules"
1613 for ol_val in auto yes no ; do
1614 if test "$enableval" = "$ol_val" ; then
1618 if test "$ol_arg" = "invalid" ; then
1619 { echo "configure: error: bad value $enableval for --enable-modules" 1>&2; exit 1; }
1621 ol_enable_modules="$ol_arg"
1624 ol_enable_modules="no"
1626 # end --enable-modules
1627 # OpenLDAP --enable-multimaster
1628 # Check whether --enable-multimaster or --disable-multimaster was given.
1629 if test "${enable_multimaster+set}" = set; then
1630 enableval="$enable_multimaster"
1633 for ol_val in auto yes no ; do
1634 if test "$enableval" = "$ol_val" ; then
1638 if test "$ol_arg" = "invalid" ; then
1639 { echo "configure: error: bad value $enableval for --enable-multimaster" 1>&2; exit 1; }
1641 ol_enable_multimaster="$ol_arg"
1644 ol_enable_multimaster="no"
1646 # end --enable-multimaster
1647 # OpenLDAP --enable-phonetic
1648 # Check whether --enable-phonetic or --disable-phonetic was given.
1649 if test "${enable_phonetic+set}" = set; then
1650 enableval="$enable_phonetic"
1653 for ol_val in auto yes no ; do
1654 if test "$enableval" = "$ol_val" ; then
1658 if test "$ol_arg" = "invalid" ; then
1659 { echo "configure: error: bad value $enableval for --enable-phonetic" 1>&2; exit 1; }
1661 ol_enable_phonetic="$ol_arg"
1664 ol_enable_phonetic="no"
1666 # end --enable-phonetic
1667 # OpenLDAP --enable-rlookups
1668 # Check whether --enable-rlookups or --disable-rlookups was given.
1669 if test "${enable_rlookups+set}" = set; then
1670 enableval="$enable_rlookups"
1673 for ol_val in auto yes no ; do
1674 if test "$enableval" = "$ol_val" ; then
1678 if test "$ol_arg" = "invalid" ; then
1679 { echo "configure: error: bad value $enableval for --enable-rlookups" 1>&2; exit 1; }
1681 ol_enable_rlookups="$ol_arg"
1684 ol_enable_rlookups="auto"
1686 # end --enable-rlookups
1687 # OpenLDAP --enable-aci
1688 # Check whether --enable-aci or --disable-aci was given.
1689 if test "${enable_aci+set}" = set; then
1690 enableval="$enable_aci"
1693 for ol_val in auto yes no ; do
1694 if test "$enableval" = "$ol_val" ; then
1698 if test "$ol_arg" = "invalid" ; then
1699 { echo "configure: error: bad value $enableval for --enable-aci" 1>&2; exit 1; }
1701 ol_enable_aci="$ol_arg"
1707 # OpenLDAP --enable-wrappers
1708 # Check whether --enable-wrappers or --disable-wrappers was given.
1709 if test "${enable_wrappers+set}" = set; then
1710 enableval="$enable_wrappers"
1713 for ol_val in auto yes no ; do
1714 if test "$enableval" = "$ol_val" ; then
1718 if test "$ol_arg" = "invalid" ; then
1719 { echo "configure: error: bad value $enableval for --enable-wrappers" 1>&2; exit 1; }
1721 ol_enable_wrappers="$ol_arg"
1724 ol_enable_wrappers="no"
1726 # end --enable-wrappers
1727 # OpenLDAP --enable-dynamic
1728 # Check whether --enable-dynamic or --disable-dynamic was given.
1729 if test "${enable_dynamic+set}" = set; then
1730 enableval="$enable_dynamic"
1733 for ol_val in auto yes no ; do
1734 if test "$enableval" = "$ol_val" ; then
1738 if test "$ol_arg" = "invalid" ; then
1739 { echo "configure: error: bad value $enableval for --enable-dynamic" 1>&2; exit 1; }
1741 ol_enable_dynamic="$ol_arg"
1744 ol_enable_dynamic="no"
1746 # end --enable-dynamic
1748 # OpenLDAP --enable-dnssrv
1749 # Check whether --enable-dnssrv or --disable-dnssrv was given.
1750 if test "${enable_dnssrv+set}" = set; then
1751 enableval="$enable_dnssrv"
1754 for ol_val in auto yes no ; do
1755 if test "$enableval" = "$ol_val" ; then
1759 if test "$ol_arg" = "invalid" ; then
1760 { echo "configure: error: bad value $enableval for --enable-dnssrv" 1>&2; exit 1; }
1762 ol_enable_dnssrv="$ol_arg"
1765 ol_enable_dnssrv="no"
1767 # end --enable-dnssrv
1768 # OpenLDAP --with-dnssrv_module
1769 # Check whether --with-dnssrv_module or --without-dnssrv_module was given.
1770 if test "${with_dnssrv_module+set}" = set; then
1771 withval="$with_dnssrv_module"
1774 for ol_val in static dynamic ; do
1775 if test "$withval" = "$ol_val" ; then
1779 if test "$ol_arg" = "invalid" ; then
1780 { echo "configure: error: bad value $withval for --with-dnssrv_module" 1>&2; exit 1; }
1782 ol_with_dnssrv_module="$ol_arg"
1785 ol_with_dnssrv_module="static"
1787 # end --with-dnssrv_module
1789 # OpenLDAP --enable-ldap
1790 # Check whether --enable-ldap or --disable-ldap was given.
1791 if test "${enable_ldap+set}" = set; then
1792 enableval="$enable_ldap"
1795 for ol_val in auto yes no ; do
1796 if test "$enableval" = "$ol_val" ; then
1800 if test "$ol_arg" = "invalid" ; then
1801 { echo "configure: error: bad value $enableval for --enable-ldap" 1>&2; exit 1; }
1803 ol_enable_ldap="$ol_arg"
1809 # OpenLDAP --with-ldap_module
1810 # Check whether --with-ldap_module or --without-ldap_module was given.
1811 if test "${with_ldap_module+set}" = set; then
1812 withval="$with_ldap_module"
1815 for ol_val in static dynamic ; do
1816 if test "$withval" = "$ol_val" ; then
1820 if test "$ol_arg" = "invalid" ; then
1821 { echo "configure: error: bad value $withval for --with-ldap_module" 1>&2; exit 1; }
1823 ol_with_ldap_module="$ol_arg"
1826 ol_with_ldap_module="static"
1828 # end --with-ldap_module
1830 # OpenLDAP --enable-ldbm
1831 # Check whether --enable-ldbm or --disable-ldbm was given.
1832 if test "${enable_ldbm+set}" = set; then
1833 enableval="$enable_ldbm"
1836 for ol_val in auto yes no ; do
1837 if test "$enableval" = "$ol_val" ; then
1841 if test "$ol_arg" = "invalid" ; then
1842 { echo "configure: error: bad value $enableval for --enable-ldbm" 1>&2; exit 1; }
1844 ol_enable_ldbm="$ol_arg"
1847 ol_enable_ldbm="yes"
1850 # OpenLDAP --with-ldbm_api
1851 # Check whether --with-ldbm_api or --without-ldbm_api was given.
1852 if test "${with_ldbm_api+set}" = set; then
1853 withval="$with_ldbm_api"
1856 for ol_val in auto berkeley bcompat mdbm gdbm ; do
1857 if test "$withval" = "$ol_val" ; then
1861 if test "$ol_arg" = "invalid" ; then
1862 { echo "configure: error: bad value $withval for --with-ldbm_api" 1>&2; exit 1; }
1864 ol_with_ldbm_api="$ol_arg"
1867 ol_with_ldbm_api="auto"
1869 # end --with-ldbm_api
1871 # OpenLDAP --with-ldbm_module
1872 # Check whether --with-ldbm_module or --without-ldbm_module was given.
1873 if test "${with_ldbm_module+set}" = set; then
1874 withval="$with_ldbm_module"
1877 for ol_val in static dynamic ; do
1878 if test "$withval" = "$ol_val" ; then
1882 if test "$ol_arg" = "invalid" ; then
1883 { echo "configure: error: bad value $withval for --with-ldbm_module" 1>&2; exit 1; }
1885 ol_with_ldbm_module="$ol_arg"
1888 ol_with_ldbm_module="static"
1890 # end --with-ldbm_module
1892 # OpenLDAP --with-ldbm_type
1893 # Check whether --with-ldbm_type or --without-ldbm_type was given.
1894 if test "${with_ldbm_type+set}" = set; then
1895 withval="$with_ldbm_type"
1898 for ol_val in auto btree hash ; do
1899 if test "$withval" = "$ol_val" ; then
1903 if test "$ol_arg" = "invalid" ; then
1904 { echo "configure: error: bad value $withval for --with-ldbm_type" 1>&2; exit 1; }
1906 ol_with_ldbm_type="$ol_arg"
1909 ol_with_ldbm_type="auto"
1911 # end --with-ldbm_type
1913 # OpenLDAP --enable-passwd
1914 # Check whether --enable-passwd or --disable-passwd was given.
1915 if test "${enable_passwd+set}" = set; then
1916 enableval="$enable_passwd"
1919 for ol_val in auto yes no ; do
1920 if test "$enableval" = "$ol_val" ; then
1924 if test "$ol_arg" = "invalid" ; then
1925 { echo "configure: error: bad value $enableval for --enable-passwd" 1>&2; exit 1; }
1927 ol_enable_passwd="$ol_arg"
1930 ol_enable_passwd="no"
1932 # end --enable-passwd
1933 # OpenLDAP --with-passwd_module
1934 # Check whether --with-passwd_module or --without-passwd_module was given.
1935 if test "${with_passwd_module+set}" = set; then
1936 withval="$with_passwd_module"
1939 for ol_val in static dynamic ; do
1940 if test "$withval" = "$ol_val" ; then
1944 if test "$ol_arg" = "invalid" ; then
1945 { echo "configure: error: bad value $withval for --with-passwd_module" 1>&2; exit 1; }
1947 ol_with_passwd_module="$ol_arg"
1950 ol_with_passwd_module="static"
1952 # end --with-passwd_module
1954 # OpenLDAP --enable-shell
1955 # Check whether --enable-shell or --disable-shell was given.
1956 if test "${enable_shell+set}" = set; then
1957 enableval="$enable_shell"
1960 for ol_val in auto yes no ; do
1961 if test "$enableval" = "$ol_val" ; then
1965 if test "$ol_arg" = "invalid" ; then
1966 { echo "configure: error: bad value $enableval for --enable-shell" 1>&2; exit 1; }
1968 ol_enable_shell="$ol_arg"
1971 ol_enable_shell="no"
1973 # end --enable-shell
1974 # OpenLDAP --with-shell_module
1975 # Check whether --with-shell_module or --without-shell_module was given.
1976 if test "${with_shell_module+set}" = set; then
1977 withval="$with_shell_module"
1980 for ol_val in static dynamic ; do
1981 if test "$withval" = "$ol_val" ; then
1985 if test "$ol_arg" = "invalid" ; then
1986 { echo "configure: error: bad value $withval for --with-shell_module" 1>&2; exit 1; }
1988 ol_with_shell_module="$ol_arg"
1991 ol_with_shell_module="static"
1993 # end --with-shell_module
1995 # OpenLDAP --enable-sql
1996 # Check whether --enable-sql or --disable-sql was given.
1997 if test "${enable_sql+set}" = set; then
1998 enableval="$enable_sql"
2001 for ol_val in auto yes no ; do
2002 if test "$enableval" = "$ol_val" ; then
2006 if test "$ol_arg" = "invalid" ; then
2007 { echo "configure: error: bad value $enableval for --enable-sql" 1>&2; exit 1; }
2009 ol_enable_sql="$ol_arg"
2015 # OpenLDAP --with-sql_module
2016 # Check whether --with-sql_module or --without-sql_module was given.
2017 if test "${with_sql_module+set}" = set; then
2018 withval="$with_sql_module"
2021 for ol_val in static dynamic ; do
2022 if test "$withval" = "$ol_val" ; then
2026 if test "$ol_arg" = "invalid" ; then
2027 { echo "configure: error: bad value $withval for --with-sql_module" 1>&2; exit 1; }
2029 ol_with_sql_module="$ol_arg"
2032 ol_with_sql_module="static"
2034 # end --with-sql_module
2037 # Check whether --with-xxslurpdoptions or --without-xxslurpdoptions was given.
2038 if test "${with_xxslurpdoptions+set}" = set; then
2039 withval="$with_xxslurpdoptions"
2043 # OpenLDAP --enable-slurpd
2044 # Check whether --enable-slurpd or --disable-slurpd was given.
2045 if test "${enable_slurpd+set}" = set; then
2046 enableval="$enable_slurpd"
2049 for ol_val in auto yes no ; do
2050 if test "$enableval" = "$ol_val" ; then
2054 if test "$ol_arg" = "invalid" ; then
2055 { echo "configure: error: bad value $enableval for --enable-slurpd" 1>&2; exit 1; }
2057 ol_enable_slurpd="$ol_arg"
2060 ol_enable_slurpd="auto"
2062 # end --enable-slurpd
2064 # Check whether --with-xxliboptions or --without-xxliboptions was given.
2065 if test "${with_xxliboptions+set}" = set; then
2066 withval="$with_xxliboptions"
2070 # Check whether --enable-static or --disable-static was given.
2071 if test "${enable_static+set}" = set; then
2072 enableval="$enable_static"
2073 p=${PACKAGE-default}
2074 case "$enableval" in
2075 yes) enable_static=yes ;;
2076 no) enable_static=no ;;
2079 # Look at the argument we got. We use all the common list separators.
2080 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2081 for pkg in $enableval; do
2082 if test "X$pkg" = "X$p"; then
2093 # Check whether --enable-shared or --disable-shared was given.
2094 if test "${enable_shared+set}" = set; then
2095 enableval="$enable_shared"
2096 p=${PACKAGE-default}
2097 case "$enableval" in
2098 yes) enable_shared=yes ;;
2099 no) enable_shared=no ;;
2102 # Look at the argument we got. We use all the common list separators.
2103 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2104 for pkg in $enableval; do
2105 if test "X$pkg" = "X$p"; then
2119 if test $ol_enable_slapd = no ; then
2120 if test $ol_enable_dnssrv = yes ; then
2121 echo "configure: warning: slapd disabled, ignoring --enable-dnssrv argument" 1>&2
2123 if test $ol_enable_ldap = yes ; then
2124 echo "configure: warning: slapd disabled, ignoring --enable-ldap argument" 1>&2
2126 if test $ol_enable_ldbm = yes ; then
2127 echo "configure: warning: slapd disabled, ignoring --enable-ldbm argument" 1>&2
2129 if test $ol_enable_passwd = yes ; then
2130 echo "configure: warning: slapd disabled, ignoring --enable-passwd argument" 1>&2
2132 if test $ol_enable_shell = yes ; then
2133 echo "configure: warning: slapd disabled, ignoring --enable-shell argument" 1>&2
2135 if test $ol_enable_sql = yes ; then
2136 echo "configure: warning: slapd disabled, ignoring --enable-sql argument" 1>&2
2138 if test $ol_enable_modules = yes ; then
2139 echo "configure: warning: slapd disabled, ignoring --enable-modules argument" 1>&2
2141 if test $ol_enable_multimaster = yes ; then
2142 echo "configure: warning: slapd disabled, ignoring --enable-multimaster argument" 1>&2
2144 if test $ol_enable_wrappers = yes ; then
2145 echo "configure: warning: slapd disabled, ignoring --enable-wrappers argument" 1>&2
2147 if test $ol_enable_phonetic = yes ; then
2148 echo "configure: warning: slapd disabled, ignoring --enable-phonetic argument" 1>&2
2150 if test $ol_enable_rlookups = yes ; then
2151 echo "configure: warning: slapd disabled, ignoring --enable-rlookups argument" 1>&2
2153 if test $ol_enable_aci = yes ; then
2154 echo "configure: warning: slapd disabled, ignoring --enable-aci argument" 1>&2
2156 if test $ol_with_ldbm_api != auto ; then
2157 echo "configure: warning: slapd disabled, ignoring --with-ldbm-api argument" 1>&2
2159 if test $ol_with_ldbm_type != auto ; then
2160 echo "configure: warning: slapd disabled, ignoring --with-ldbm-type argument" 1>&2
2162 if test $ol_with_dnssrv_module != static ; then
2163 echo "configure: warning: slapd disabled, ignoring --with-dnssrv-module argument" 1>&2
2165 if test $ol_with_ldap_module != static ; then
2166 echo "configure: warning: slapd disabled, ignoring --with-ldap-module argument" 1>&2
2168 if test $ol_with_ldbm_module != static ; then
2169 echo "configure: warning: slapd disabled, ignoring --with-ldbm-module argument" 1>&2
2171 if test $ol_with_passwd_module != static ; then
2172 echo "configure: warning: slapd disabled, ignoring --with-passwd-module argument" 1>&2
2174 if test $ol_with_shell_module != static ; then
2175 echo "configure: warning: slapd disabled, ignoring --with-shell-module argument" 1>&2
2177 if test $ol_with_sql_module != static ; then
2178 echo "configure: warning: slapd disabled, ignoring --with-sql-module argument" 1>&2
2180 if test $ol_enable_slurpd = yes ; then
2181 { echo "configure: error: slurpd requires slapd" 1>&2; exit 1; }
2184 # force settings to no
2192 ol_enable_modules=no
2193 ol_enable_multimaster=no
2194 ol_enable_phonetic=no
2195 ol_enable_rlookups=no
2197 ol_enable_wrappers=no
2198 ol_enable_dynamic=no
2201 ol_with_ldbm_type=no
2203 ol_with_dnssrv_module=static
2204 ol_with_ldap_module=static
2205 ol_with_ldbm_module=static
2206 ol_with_passwd_module=static
2207 ol_with_shell_module=static
2208 ol_with_sql_module=static
2212 elif test $ol_enable_ldbm = no ; then
2214 if test $ol_with_ldbm_api != auto ; then
2215 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-api argument" 1>&2
2218 if test $ol_with_ldbm_type != auto ; then
2219 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-type argument" 1>&2
2222 if test $ol_with_ldbm_module != static ; then
2223 echo "configure: warning: LDBM disabled, ignoring --with-ldbm-module argument" 1>&2
2226 if test $ol_enable_modules != yes -a \
2227 $ol_enable_dnssrv = no -a \
2228 $ol_enable_ldap = no -a \
2229 $ol_enable_passwd = no -a \
2230 $ol_enable_shell = no -a \
2231 $ol_enable_sql = no ; then
2232 { echo "configure: error: slapd requires a backend" 1>&2; exit 1; }
2236 ol_with_ldbm_type=no
2237 ol_with_ldbm_module=static
2240 if test $ol_with_ldbm_api = gdbm -a \
2241 $ol_with_ldbm_type = btree ; then
2242 { echo "configure: error: GDBM only supports LDBM type hash" 1>&2; exit 1; }
2244 if test $ol_with_ldbm_api = mdbm -a \
2245 $ol_with_ldbm_type = btree ; then
2246 { echo "configure: error: MDBM only supports LDBM type hash" 1>&2; exit 1; }
2248 if test $ol_with_ldbm_api = ndbm -a \
2249 $ol_with_ldbm_type = btree ; then
2250 { echo "configure: error: NDBM only supports LDBM type hash" 1>&2; exit 1; }
2254 if test $ol_enable_slurpd = yes ; then
2255 if test $ol_with_threads = no ; then
2256 { echo "configure: error: slurpd requires threads" 1>&2; exit 1; }
2260 if test $ol_enable_kbind = yes -o $ol_enable_kpasswd = yes ; then
2261 if test $ol_with_kerberos = no ; then
2262 { echo "configure: error: options require --with-kerberos" 1>&2; exit 1; }
2264 ol_with_kerberos=yes
2265 elif test $ol_enable_kbind = no -o $ol_enable_kpasswd = no ; then
2266 if test $ol_with_kerberos != no -a $ol_with_kerberos != auto ; then
2267 echo "configure: warning: Kerberos detection enabled unnecessarily" 1>&2;
2272 if test $ol_enable_spasswd = yes ; then
2273 if test $ol_with_cyrus_sasl = no ; then
2274 { echo "configure: error: options require --with-cyrus-sasl" 1>&2; exit 1; }
2279 echo "$ac_t""done" 1>&6
2302 BUILD_DNSSRV_DYNAMIC=static
2303 BUILD_LDAP_DYNAMIC=static
2304 BUILD_LDBM_DYNAMIC=static
2305 BUILD_PASSWD_DYNAMIC=static
2306 BUILD_SHELL_DYNAMIC=static
2307 BUILD_SQL_DYNAMIC=static
2309 SLAPD_MODULES_LDFLAGS=
2310 SLAPD_MODULES_CPPFLAGS=
2328 cat >> confdefs.h <<\EOF
2329 #define HAVE_MKVERSION 1
2337 *-*-aix*) if test -z "$CC" ; then
2338 case "$ol_with_threads" in
2339 auto | yes | posix) ol_aix_threads=yes ;;
2345 if test $ol_aix_threads = yes ; then
2346 if test -z "${CC}" ; then
2347 for ac_prog in cc_r xlc_r cc
2349 # Extract the first word of "$ac_prog", so it can be a program name with args.
2350 set dummy $ac_prog; ac_word=$2
2351 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2352 echo "configure:2353: checking for $ac_word" >&5
2353 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2354 echo $ac_n "(cached) $ac_c" 1>&6
2356 if test -n "$CC"; then
2357 ac_cv_prog_CC="$CC" # Let the user override the test.
2359 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2361 for ac_dir in $ac_dummy; do
2362 test -z "$ac_dir" && ac_dir=.
2363 if test -f $ac_dir/$ac_word; then
2364 ac_cv_prog_CC="$ac_prog"
2372 if test -n "$CC"; then
2373 echo "$ac_t""$CC" 1>&6
2375 echo "$ac_t""no" 1>&6
2378 test -n "$CC" && break
2382 if test "$CC" = cc ; then
2383 if test $ol_with_threads != auto ; then
2384 { echo "configure: error: --with-threads requires cc_r (or other suitable compiler) on AIX" 1>&2; exit 1; }
2386 echo "configure: warning: disabling threads, no cc_r on AIX" 1>&2
2392 if test "${CC}" = "cc_r" -o "${CC}" = "xlc_r" ; then
2393 ol_with_threads=posix
2394 ol_cv_pthread_create=yes
2398 if test -z "${CC}"; then
2401 # Extract the first word of "$ac_prog", so it can be a program name with args.
2402 set dummy $ac_prog; ac_word=$2
2403 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2404 echo "configure:2405: checking for $ac_word" >&5
2405 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2406 echo $ac_n "(cached) $ac_c" 1>&6
2408 if test -n "$CC"; then
2409 ac_cv_prog_CC="$CC" # Let the user override the test.
2411 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2413 for ac_dir in $ac_dummy; do
2414 test -z "$ac_dir" && ac_dir=.
2415 if test -f $ac_dir/$ac_word; then
2416 ac_cv_prog_CC="$ac_prog"
2424 if test -n "$CC"; then
2425 echo "$ac_t""$CC" 1>&6
2427 echo "$ac_t""no" 1>&6
2430 test -n "$CC" && break
2438 # Check whether --enable-fast-install or --disable-fast-install was given.
2439 if test "${enable_fast_install+set}" = set; then
2440 enableval="$enable_fast_install"
2441 p=${PACKAGE-default}
2442 case "$enableval" in
2443 yes) enable_fast_install=yes ;;
2444 no) enable_fast_install=no ;;
2446 enable_fast_install=no
2447 # Look at the argument we got. We use all the common list separators.
2448 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2449 for pkg in $enableval; do
2450 if test "X$pkg" = "X$p"; then
2451 enable_fast_install=yes
2458 enable_fast_install=yes
2461 # Extract the first word of "ranlib", so it can be a program name with args.
2462 set dummy ranlib; ac_word=$2
2463 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2464 echo "configure:2465: checking for $ac_word" >&5
2465 if eval "test \"\${ac_cv_prog_RANLIB+set}\" = set"; then
2466 echo $ac_n "(cached) $ac_c" 1>&6
2468 if test -n "$RANLIB"; then
2469 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2471 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2473 for ac_dir in $ac_dummy; do
2474 test -z "$ac_dir" && ac_dir=.
2475 if test -f $ac_dir/$ac_word; then
2476 ac_cv_prog_RANLIB="ranlib"
2481 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
2484 RANLIB="$ac_cv_prog_RANLIB"
2485 if test -n "$RANLIB"; then
2486 echo "$ac_t""$RANLIB" 1>&6
2488 echo "$ac_t""no" 1>&6
2491 # Extract the first word of "gcc", so it can be a program name with args.
2492 set dummy gcc; ac_word=$2
2493 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2494 echo "configure:2495: checking for $ac_word" >&5
2495 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2496 echo $ac_n "(cached) $ac_c" 1>&6
2498 if test -n "$CC"; then
2499 ac_cv_prog_CC="$CC" # Let the user override the test.
2501 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2503 for ac_dir in $ac_dummy; do
2504 test -z "$ac_dir" && ac_dir=.
2505 if test -f $ac_dir/$ac_word; then
2514 if test -n "$CC"; then
2515 echo "$ac_t""$CC" 1>&6
2517 echo "$ac_t""no" 1>&6
2520 if test -z "$CC"; then
2521 # Extract the first word of "cc", so it can be a program name with args.
2522 set dummy cc; ac_word=$2
2523 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2524 echo "configure:2525: checking for $ac_word" >&5
2525 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2526 echo $ac_n "(cached) $ac_c" 1>&6
2528 if test -n "$CC"; then
2529 ac_cv_prog_CC="$CC" # Let the user override the test.
2531 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2534 for ac_dir in $ac_dummy; do
2535 test -z "$ac_dir" && ac_dir=.
2536 if test -f $ac_dir/$ac_word; then
2537 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
2538 ac_prog_rejected=yes
2546 if test $ac_prog_rejected = yes; then
2547 # We found a bogon in the path, so make sure we never use it.
2548 set dummy $ac_cv_prog_CC
2550 if test $# -gt 0; then
2551 # We chose a different compiler from the bogus one.
2552 # However, it has the same basename, so the bogon will be chosen
2553 # first if we set CC to just the basename; use the full file name.
2555 set dummy "$ac_dir/$ac_word" "$@"
2563 if test -n "$CC"; then
2564 echo "$ac_t""$CC" 1>&6
2566 echo "$ac_t""no" 1>&6
2569 if test -z "$CC"; then
2570 case "`uname -s`" in
2571 *win32* | *WIN32* | *CYGWIN*)
2572 # Extract the first word of "cl", so it can be a program name with args.
2573 set dummy cl; ac_word=$2
2574 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2575 echo "configure:2576: checking for $ac_word" >&5
2576 if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
2577 echo $ac_n "(cached) $ac_c" 1>&6
2579 if test -n "$CC"; then
2580 ac_cv_prog_CC="$CC" # Let the user override the test.
2582 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2584 for ac_dir in $ac_dummy; do
2585 test -z "$ac_dir" && ac_dir=.
2586 if test -f $ac_dir/$ac_word; then
2595 if test -n "$CC"; then
2596 echo "$ac_t""$CC" 1>&6
2598 echo "$ac_t""no" 1>&6
2603 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
2606 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works""... $ac_c" 1>&6
2607 echo "configure:2608: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works" >&5
2610 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2611 ac_cpp='$CPP $CPPFLAGS'
2612 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2613 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2614 cross_compiling=$ac_cv_prog_cc_cross
2616 cat > conftest.$ac_ext << EOF
2618 #line 2619 "configure"
2619 #include "confdefs.h"
2623 if { (eval echo configure:2624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2624 ac_cv_prog_cc_works=yes
2625 # If we can't run a trivial program, we are probably using a cross compiler.
2626 if (./conftest; exit) 2>/dev/null; then
2627 ac_cv_prog_cc_cross=no
2629 ac_cv_prog_cc_cross=yes
2632 echo "configure: failed program was:" >&5
2633 cat conftest.$ac_ext >&5
2634 ac_cv_prog_cc_works=no
2638 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2639 ac_cpp='$CPP $CPPFLAGS'
2640 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2641 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2642 cross_compiling=$ac_cv_prog_cc_cross
2644 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2645 if test $ac_cv_prog_cc_works = no; then
2646 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2648 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
2649 echo "configure:2650: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler" >&5
2650 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2651 cross_compiling=$ac_cv_prog_cc_cross
2653 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
2654 echo "configure:2655: checking whether we are using GNU C" >&5
2655 if eval "test \"\${ac_cv_prog_gcc+set}\" = set"; then
2656 echo $ac_n "(cached) $ac_c" 1>&6
2658 cat > conftest.c <<EOF
2663 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2664: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
2670 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2672 if test $ac_cv_prog_gcc = yes; then
2678 ac_test_CFLAGS="${CFLAGS+set}"
2679 ac_save_CFLAGS="$CFLAGS"
2681 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
2682 echo "configure:2683: checking whether ${CC-cc} accepts -g" >&5
2683 if eval "test \"\${ac_cv_prog_cc_g+set}\" = set"; then
2684 echo $ac_n "(cached) $ac_c" 1>&6
2686 echo 'void f(){}' > conftest.c
2687 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
2696 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
2697 if test "$ac_test_CFLAGS" = set; then
2698 CFLAGS="$ac_save_CFLAGS"
2699 elif test $ac_cv_prog_cc_g = yes; then
2700 if test "$GCC" = yes; then
2706 if test "$GCC" = yes; then
2713 # Check whether --with-gnu-ld or --without-gnu-ld was given.
2714 if test "${with_gnu_ld+set}" = set; then
2715 withval="$with_gnu_ld"
2716 test "$withval" = no || with_gnu_ld=yes
2722 if test "$ac_cv_prog_gcc" = yes; then
2723 # Check if gcc -print-prog-name=ld gives a path.
2724 echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
2725 echo "configure:2726: checking for ld used by GCC" >&5
2726 ac_prog=`($CC -print-prog-name=ld) 2>&5`
2728 # Accept absolute paths.
2729 [\\/]* | [A-Za-z]:[\\/]*)
2730 re_direlt='/[^/][^/]*/\.\./'
2731 # Canonicalize the path of ld
2732 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
2733 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2734 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
2736 test -z "$LD" && LD="$ac_prog"
2739 # If it fails, then pretend we aren't using GCC.
2743 # If it is relative, then search for the first ld in PATH.
2747 elif test "$with_gnu_ld" = yes; then
2748 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
2749 echo "configure:2750: checking for GNU ld" >&5
2751 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
2752 echo "configure:2753: checking for non-GNU ld" >&5
2754 if eval "test \"\${ac_cv_path_LD+set}\" = set"; then
2755 echo $ac_n "(cached) $ac_c" 1>&6
2757 if test -z "$LD"; then
2758 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2759 for ac_dir in $PATH; do
2760 test -z "$ac_dir" && ac_dir=.
2761 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2762 ac_cv_path_LD="$ac_dir/$ac_prog"
2763 # Check to see if the program is GNU ld. I'd rather use --version,
2764 # but apparently some GNU ld's only accept -v.
2765 # Break only if it was the GNU/non-GNU ld that we prefer.
2766 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
2767 test "$with_gnu_ld" != no && break
2769 test "$with_gnu_ld" != yes && break
2775 ac_cv_path_LD="$LD" # Let the user override the test with a path.
2780 if test -n "$LD"; then
2781 echo "$ac_t""$LD" 1>&6
2783 echo "$ac_t""no" 1>&6
2785 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
2786 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
2787 echo "configure:2788: checking if the linker ($LD) is GNU ld" >&5
2788 if eval "test \"\${ac_cv_prog_gnu_ld+set}\" = set"; then
2789 echo $ac_n "(cached) $ac_c" 1>&6
2791 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
2792 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
2793 ac_cv_prog_gnu_ld=yes
2795 ac_cv_prog_gnu_ld=no
2799 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
2802 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
2803 echo "configure:2804: checking for BSD-compatible nm" >&5
2804 if eval "test \"\${ac_cv_path_NM+set}\" = set"; then
2805 echo $ac_n "(cached) $ac_c" 1>&6
2807 if test -n "$NM"; then
2808 # Let the user override the test.
2811 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2812 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2813 test -z "$ac_dir" && ac_dir=.
2814 if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
2815 # Check to see if the nm accepts a BSD-compat flag.
2816 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2817 # nm: unknown option "B" ignored
2818 if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2819 ac_cv_path_NM="$ac_dir/nm -B"
2821 elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2822 ac_cv_path_NM="$ac_dir/nm -p"
2825 ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
2826 continue # so that we can try to find one that supports BSD flags
2831 test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
2836 echo "$ac_t""$NM" 1>&6
2838 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
2839 echo "configure:2840: checking whether ln -s works" >&5
2840 if eval "test \"\${ac_cv_prog_LN_S+set}\" = set"; then
2841 echo $ac_n "(cached) $ac_c" 1>&6
2844 if ln -s X conftestdata 2>/dev/null
2847 ac_cv_prog_LN_S="ln -s"
2852 LN_S="$ac_cv_prog_LN_S"
2853 if test "$ac_cv_prog_LN_S" = "ln -s"; then
2854 echo "$ac_t""yes" 1>&6
2856 echo "$ac_t""no" 1>&6
2859 if test $host != $build; then
2860 ac_tool_prefix=${host_alias}-
2867 NONE) lt_target="$host" ;;
2868 *) lt_target="$target" ;;
2871 # Check for any special flags to pass to ltconfig.
2872 libtool_flags="--cache-file=$cache_file"
2873 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
2874 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
2875 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
2876 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
2877 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
2878 libtool_flags="$libtool_flags --enable-dlopen"
2879 libtool_flags="$libtool_flags --enable-win32-dll"
2880 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
2881 if test "${enable_libtool_lock+set}" = set; then
2882 enableval="$enable_libtool_lock"
2886 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
2887 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
2889 # Some flags need to be propagated to the compiler or linker for good
2891 case "$lt_target" in
2893 # Find out which ABI we are using.
2894 echo '#line 2895 "configure"' > conftest.$ac_ext
2895 if { (eval echo configure:2896: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2896 case "`/usr/bin/file conftest.o`" in
2912 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
2913 SAVE_CFLAGS="$CFLAGS"
2914 CFLAGS="$CFLAGS -belf"
2915 echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
2916 echo "configure:2917: checking whether the C compiler needs -belf" >&5
2917 if eval "test \"\${lt_cv_cc_needs_belf+set}\" = set"; then
2918 echo $ac_n "(cached) $ac_c" 1>&6
2920 cat > conftest.$ac_ext <<EOF
2921 #line 2922 "configure"
2922 #include "confdefs.h"
2928 if { (eval echo configure:2929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2930 lt_cv_cc_needs_belf=yes
2932 echo "configure: failed program was:" >&5
2933 cat conftest.$ac_ext >&5
2935 lt_cv_cc_needs_belf=no
2940 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
2941 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
2942 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
2943 CFLAGS="$SAVE_CFLAGS"
2947 *-*-cygwin* | *-*-mingw*)
2948 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
2949 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
2950 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2951 echo "configure:2952: checking for $ac_word" >&5
2952 if eval "test \"\${ac_cv_prog_DLLTOOL+set}\" = set"; then
2953 echo $ac_n "(cached) $ac_c" 1>&6
2955 if test -n "$DLLTOOL"; then
2956 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
2958 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2960 for ac_dir in $ac_dummy; do
2961 test -z "$ac_dir" && ac_dir=.
2962 if test -f $ac_dir/$ac_word; then
2963 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
2970 DLLTOOL="$ac_cv_prog_DLLTOOL"
2971 if test -n "$DLLTOOL"; then
2972 echo "$ac_t""$DLLTOOL" 1>&6
2974 echo "$ac_t""no" 1>&6
2978 if test -z "$ac_cv_prog_DLLTOOL"; then
2979 if test -n "$ac_tool_prefix"; then
2980 # Extract the first word of "dlltool", so it can be a program name with args.
2981 set dummy dlltool; ac_word=$2
2982 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2983 echo "configure:2984: checking for $ac_word" >&5
2984 if eval "test \"\${ac_cv_prog_DLLTOOL+set}\" = set"; then
2985 echo $ac_n "(cached) $ac_c" 1>&6
2987 if test -n "$DLLTOOL"; then
2988 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
2990 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2992 for ac_dir in $ac_dummy; do
2993 test -z "$ac_dir" && ac_dir=.
2994 if test -f $ac_dir/$ac_word; then
2995 ac_cv_prog_DLLTOOL="dlltool"
3000 test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="false"
3003 DLLTOOL="$ac_cv_prog_DLLTOOL"
3004 if test -n "$DLLTOOL"; then
3005 echo "$ac_t""$DLLTOOL" 1>&6
3007 echo "$ac_t""no" 1>&6
3015 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
3016 set dummy ${ac_tool_prefix}as; ac_word=$2
3017 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3018 echo "configure:3019: checking for $ac_word" >&5
3019 if eval "test \"\${ac_cv_prog_AS+set}\" = set"; then
3020 echo $ac_n "(cached) $ac_c" 1>&6
3022 if test -n "$AS"; then
3023 ac_cv_prog_AS="$AS" # Let the user override the test.
3025 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3027 for ac_dir in $ac_dummy; do
3028 test -z "$ac_dir" && ac_dir=.
3029 if test -f $ac_dir/$ac_word; then
3030 ac_cv_prog_AS="${ac_tool_prefix}as"
3038 if test -n "$AS"; then
3039 echo "$ac_t""$AS" 1>&6
3041 echo "$ac_t""no" 1>&6
3045 if test -z "$ac_cv_prog_AS"; then
3046 if test -n "$ac_tool_prefix"; then
3047 # Extract the first word of "as", so it can be a program name with args.
3048 set dummy as; ac_word=$2
3049 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3050 echo "configure:3051: checking for $ac_word" >&5
3051 if eval "test \"\${ac_cv_prog_AS+set}\" = set"; then
3052 echo $ac_n "(cached) $ac_c" 1>&6
3054 if test -n "$AS"; then
3055 ac_cv_prog_AS="$AS" # Let the user override the test.
3057 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3059 for ac_dir in $ac_dummy; do
3060 test -z "$ac_dir" && ac_dir=.
3061 if test -f $ac_dir/$ac_word; then
3067 test -z "$ac_cv_prog_AS" && ac_cv_prog_AS="false"
3071 if test -n "$AS"; then
3072 echo "$ac_t""$AS" 1>&6
3074 echo "$ac_t""no" 1>&6
3082 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
3083 set dummy ${ac_tool_prefix}objdump; ac_word=$2
3084 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3085 echo "configure:3086: checking for $ac_word" >&5
3086 if eval "test \"\${ac_cv_prog_OBJDUMP+set}\" = set"; then
3087 echo $ac_n "(cached) $ac_c" 1>&6
3089 if test -n "$OBJDUMP"; then
3090 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
3092 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3094 for ac_dir in $ac_dummy; do
3095 test -z "$ac_dir" && ac_dir=.
3096 if test -f $ac_dir/$ac_word; then
3097 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
3104 OBJDUMP="$ac_cv_prog_OBJDUMP"
3105 if test -n "$OBJDUMP"; then
3106 echo "$ac_t""$OBJDUMP" 1>&6
3108 echo "$ac_t""no" 1>&6
3112 if test -z "$ac_cv_prog_OBJDUMP"; then
3113 if test -n "$ac_tool_prefix"; then
3114 # Extract the first word of "objdump", so it can be a program name with args.
3115 set dummy objdump; ac_word=$2
3116 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3117 echo "configure:3118: checking for $ac_word" >&5
3118 if eval "test \"\${ac_cv_prog_OBJDUMP+set}\" = set"; then
3119 echo $ac_n "(cached) $ac_c" 1>&6
3121 if test -n "$OBJDUMP"; then
3122 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
3124 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3126 for ac_dir in $ac_dummy; do
3127 test -z "$ac_dir" && ac_dir=.
3128 if test -f $ac_dir/$ac_word; then
3129 ac_cv_prog_OBJDUMP="objdump"
3134 test -z "$ac_cv_prog_OBJDUMP" && ac_cv_prog_OBJDUMP="false"
3137 OBJDUMP="$ac_cv_prog_OBJDUMP"
3138 if test -n "$OBJDUMP"; then
3139 echo "$ac_t""$OBJDUMP" 1>&6
3141 echo "$ac_t""no" 1>&6
3154 # Save cache, so that ltconfig can load it
3157 # Actually configure libtool. ac_aux_dir is where install-sh is found.
3158 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
3159 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
3160 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
3161 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
3162 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
3163 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
3164 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
3166 # Reload cache, that may have been modified by ltconfig
3169 # This can be used to rebuild libtool when needed
3170 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
3172 # Always use our own libtool.
3173 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
3175 # Redirect the config.log output again, so that the ltconfig log is not
3176 # clobbered by the next message.
3177 exec 5>>./config.log
3180 for ac_prog in mawk gawk nawk awk
3182 # Extract the first word of "$ac_prog", so it can be a program name with args.
3183 set dummy $ac_prog; ac_word=$2
3184 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3185 echo "configure:3186: checking for $ac_word" >&5
3186 if eval "test \"\${ac_cv_prog_AWK+set}\" = set"; then
3187 echo $ac_n "(cached) $ac_c" 1>&6
3189 if test -n "$AWK"; then
3190 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3192 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3194 for ac_dir in $ac_dummy; do
3195 test -z "$ac_dir" && ac_dir=.
3196 if test -f $ac_dir/$ac_word; then
3197 ac_cv_prog_AWK="$ac_prog"
3204 AWK="$ac_cv_prog_AWK"
3205 if test -n "$AWK"; then
3206 echo "$ac_t""$AWK" 1>&6
3208 echo "$ac_t""no" 1>&6
3211 test -n "$AWK" && break
3214 # test for ln hardlink support
3215 echo $ac_n "checking whether ln works""... $ac_c" 1>&6
3216 echo "configure:3217: checking whether ln works" >&5
3217 if eval "test \"\${ol_cv_prog_LN_H+set}\" = set"; then
3218 echo $ac_n "(cached) $ac_c" 1>&6
3220 rm -f conftest.src conftest.dst
3221 echo "conftest" > conftest.src
3222 if ln conftest.src conftest.dst 2>/dev/null
3224 ol_cv_prog_LN_H="ln"
3226 ol_cv_prog_LN_H="cp"
3228 rm -f conftest.src conftest.dst
3231 LN_H="$ol_cv_prog_LN_H"
3232 if test "$ol_cv_prog_LN_H" = "ln"; then
3233 echo "$ac_t""yes" 1>&6
3235 echo "$ac_t""no" 1>&6
3238 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
3239 echo "configure:3240: checking whether ln -s works" >&5
3240 if eval "test \"\${ac_cv_prog_LN_S+set}\" = set"; then
3241 echo $ac_n "(cached) $ac_c" 1>&6
3244 if ln -s X conftestdata 2>/dev/null
3247 ac_cv_prog_LN_S="ln -s"
3252 LN_S="$ac_cv_prog_LN_S"
3253 if test "$ac_cv_prog_LN_S" = "ln -s"; then
3254 echo "$ac_t""yes" 1>&6
3256 echo "$ac_t""no" 1>&6
3260 if test "$LN_H" = "cp" -a "$LN_S" = "ln"; then
3264 # Extract the first word of "sendmail", so it can be a program name with args.
3265 set dummy sendmail; ac_word=$2
3266 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3267 echo "configure:3268: checking for $ac_word" >&5
3268 if eval "test \"\${ac_cv_path_SENDMAIL+set}\" = set"; then
3269 echo $ac_n "(cached) $ac_c" 1>&6
3273 ac_cv_path_SENDMAIL="$SENDMAIL" # Let the user override the test with a path.
3276 ac_cv_path_SENDMAIL="$SENDMAIL" # Let the user override the test with a dos path.
3279 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3280 ac_dummy="$PATH:/usr/libexec:/usr/lib:/usr/sbin:/usr/etc:/etc"
3281 for ac_dir in $ac_dummy; do
3282 test -z "$ac_dir" && ac_dir=.
3283 if test -f $ac_dir/$ac_word; then
3284 ac_cv_path_SENDMAIL="$ac_dir/$ac_word"
3289 test -z "$ac_cv_path_SENDMAIL" && ac_cv_path_SENDMAIL="/usr/lib/sendmail"
3293 SENDMAIL="$ac_cv_path_SENDMAIL"
3294 if test -n "$SENDMAIL"; then
3295 echo "$ac_t""$SENDMAIL" 1>&6
3297 echo "$ac_t""no" 1>&6
3300 # Extract the first word of "vi", so it can be a program name with args.
3301 set dummy vi; ac_word=$2
3302 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3303 echo "configure:3304: checking for $ac_word" >&5
3304 if eval "test \"\${ac_cv_path_EDITOR+set}\" = set"; then
3305 echo $ac_n "(cached) $ac_c" 1>&6
3309 ac_cv_path_EDITOR="$EDITOR" # Let the user override the test with a path.
3312 ac_cv_path_EDITOR="$EDITOR" # Let the user override the test with a dos path.
3315 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3316 ac_dummy="$PATH:/usr/ucb"
3317 for ac_dir in $ac_dummy; do
3318 test -z "$ac_dir" && ac_dir=.
3319 if test -f $ac_dir/$ac_word; then
3320 ac_cv_path_EDITOR="$ac_dir/$ac_word"
3325 test -z "$ac_cv_path_EDITOR" && ac_cv_path_EDITOR="/usr/ucb/vi"
3329 EDITOR="$ac_cv_path_EDITOR"
3330 if test -n "$EDITOR"; then
3331 echo "$ac_t""$EDITOR" 1>&6
3333 echo "$ac_t""no" 1>&6
3336 # Extract the first word of "finger", so it can be a program name with args.
3337 set dummy finger; ac_word=$2
3338 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3339 echo "configure:3340: checking for $ac_word" >&5
3340 if eval "test \"\${ac_cv_path_FINGER+set}\" = set"; then
3341 echo $ac_n "(cached) $ac_c" 1>&6
3345 ac_cv_path_FINGER="$FINGER" # Let the user override the test with a path.
3348 ac_cv_path_FINGER="$FINGER" # Let the user override the test with a dos path.
3351 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3352 ac_dummy="$PATH:/usr/ucb"
3353 for ac_dir in $ac_dummy; do
3354 test -z "$ac_dir" && ac_dir=.
3355 if test -f $ac_dir/$ac_word; then
3356 ac_cv_path_FINGER="$ac_dir/$ac_word"
3361 test -z "$ac_cv_path_FINGER" && ac_cv_path_FINGER="/usr/ucb/finger"
3365 FINGER="$ac_cv_path_FINGER"
3366 if test -n "$FINGER"; then
3367 echo "$ac_t""$FINGER" 1>&6
3369 echo "$ac_t""no" 1>&6
3373 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
3374 echo "configure:3375: checking how to run the C preprocessor" >&5
3375 # On Suns, sometimes $CPP names a directory.
3376 if test -n "$CPP" && test -d "$CPP"; then
3379 if test -z "$CPP"; then
3380 if eval "test \"\${ac_cv_prog_CPP+set}\" = set"; then
3381 echo $ac_n "(cached) $ac_c" 1>&6
3383 # This must be in double quotes, not single quotes, because CPP may get
3384 # substituted into the Makefile and "${CC-cc}" will confuse make.
3386 # On the NeXT, cc -E runs the code through the compiler's parser,
3387 # not just through cpp.
3388 cat > conftest.$ac_ext <<EOF
3389 #line 3390 "configure"
3390 #include "confdefs.h"
3394 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3395 { (eval echo configure:3396: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3396 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3397 if test -z "$ac_err"; then
3401 echo "configure: failed program was:" >&5
3402 cat conftest.$ac_ext >&5
3404 CPP="${CC-cc} -E -traditional-cpp"
3405 cat > conftest.$ac_ext <<EOF
3406 #line 3407 "configure"
3407 #include "confdefs.h"
3411 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3412 { (eval echo configure:3413: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3413 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3414 if test -z "$ac_err"; then
3418 echo "configure: failed program was:" >&5
3419 cat conftest.$ac_ext >&5
3421 CPP="${CC-cc} -nologo -E"
3422 cat > conftest.$ac_ext <<EOF
3423 #line 3424 "configure"
3424 #include "confdefs.h"
3428 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3429 { (eval echo configure:3430: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3430 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3431 if test -z "$ac_err"; then
3435 echo "configure: failed program was:" >&5
3436 cat conftest.$ac_ext >&5
3445 ac_cv_prog_CPP="$CPP"
3447 CPP="$ac_cv_prog_CPP"
3449 ac_cv_prog_CPP="$CPP"
3451 echo "$ac_t""$CPP" 1>&6
3454 if test $cross_compiling = yes -a $ol_enable_x_compile = yes; then
3455 echo "configure: warning: cross compiling.... some functionality will be removed." 1>&2
3457 elif test $cross_compiling = no -a $ol_enable_x_compile = yes; then
3458 echo "configure: warning: programs compiled here do run here..." 1>&2
3459 { echo "configure: error: if not cross compiling, use --disable-x-compile." 1>&2; exit 1; }
3461 elif test $cross_compiling = yes -a $ol_enable_x_compile = no; then
3462 echo "configure: warning: programs compiled here do not run here..." 1>&2
3463 { echo "configure: error: if cross compiling, add --enable-x-compile." 1>&2; exit 1; }
3466 echo $ac_n "checking for AIX""... $ac_c" 1>&6
3467 echo "configure:3468: checking for AIX" >&5
3468 cat > conftest.$ac_ext <<EOF
3469 #line 3470 "configure"
3470 #include "confdefs.h"
3476 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3477 egrep "yes" >/dev/null 2>&1; then
3479 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
3480 #define _ALL_SOURCE 1
3485 echo "$ac_t""no" 1>&6
3490 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
3491 echo "configure:3492: checking for POSIXized ISC" >&5
3492 if test -d /etc/conf/kconfig.d &&
3493 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
3495 echo "$ac_t""yes" 1>&6
3496 ISC=yes # If later tests want to check for ISC.
3497 cat >> confdefs.h <<\EOF
3498 #define _POSIX_SOURCE 1
3501 if test "$GCC" = yes; then
3507 echo "$ac_t""no" 1>&6
3511 ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
3512 echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
3513 echo "configure:3514: checking for minix/config.h" >&5
3514 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
3515 echo $ac_n "(cached) $ac_c" 1>&6
3517 cat > conftest.$ac_ext <<EOF
3518 #line 3519 "configure"
3519 #include "confdefs.h"
3520 #include <minix/config.h>
3522 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3523 { (eval echo configure:3524: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3524 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3525 if test -z "$ac_err"; then
3527 eval "ac_cv_header_$ac_safe=yes"
3530 echo "configure: failed program was:" >&5
3531 cat conftest.$ac_ext >&5
3533 eval "ac_cv_header_$ac_safe=no"
3537 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3538 echo "$ac_t""yes" 1>&6
3541 echo "$ac_t""no" 1>&6
3545 if test "$MINIX" = yes; then
3546 cat >> confdefs.h <<\EOF
3547 #define _POSIX_SOURCE 1
3550 cat >> confdefs.h <<\EOF
3551 #define _POSIX_1_SOURCE 2
3554 cat >> confdefs.h <<\EOF
3561 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
3562 echo "configure:3563: checking for Cygwin environment" >&5
3563 if eval "test \"\${ac_cv_cygwin+set}\" = set"; then
3564 echo $ac_n "(cached) $ac_c" 1>&6
3566 cat > conftest.$ac_ext <<EOF
3567 #line 3568 "configure"
3568 #include "confdefs.h"
3573 #define __CYGWIN__ __CYGWIN32__
3578 if { (eval echo configure:3579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3582 echo "configure: failed program was:" >&5
3583 cat conftest.$ac_ext >&5
3590 echo "$ac_t""$ac_cv_cygwin" 1>&6
3592 test "$ac_cv_cygwin" = yes && CYGWIN=yes
3593 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
3594 echo "configure:3595: checking for mingw32 environment" >&5
3595 if eval "test \"\${ac_cv_mingw32+set}\" = set"; then
3596 echo $ac_n "(cached) $ac_c" 1>&6
3598 cat > conftest.$ac_ext <<EOF
3599 #line 3600 "configure"
3600 #include "confdefs.h"
3606 if { (eval echo configure:3607: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3610 echo "configure: failed program was:" >&5
3611 cat conftest.$ac_ext >&5
3618 echo "$ac_t""$ac_cv_mingw32" 1>&6
3620 test "$ac_cv_mingw32" = yes && MINGW32=yes
3621 echo $ac_n "checking for EMX OS/2 environment""... $ac_c" 1>&6
3622 echo "configure:3623: checking for EMX OS/2 environment" >&5
3623 if eval "test \"\${ac_cv_emxos2+set}\" = set"; then
3624 echo $ac_n "(cached) $ac_c" 1>&6
3626 cat > conftest.$ac_ext <<EOF
3627 #line 3628 "configure"
3628 #include "confdefs.h"
3634 if { (eval echo configure:3635: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3638 echo "configure: failed program was:" >&5
3639 cat conftest.$ac_ext >&5
3646 echo "$ac_t""$ac_cv_emxos2" 1>&6
3648 test "$ac_cv_emxos2" = yes && EMXOS2=yes
3652 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
3653 echo "configure:3654: checking for executable suffix" >&5
3654 if eval "test \"\${ac_cv_exeext+set}\" = set"; then
3655 echo $ac_n "(cached) $ac_c" 1>&6
3657 if test "$CYGWIN" = yes || test "$MINGW32" = yes || test "$EMXOS2" = yes; then
3661 echo 'int main () { return 0; }' > conftest.$ac_ext
3663 if { (eval echo configure:3664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
3664 for file in conftest.*; do
3666 *.c | *.C | *.o | *.obj | *.xcoff) ;;
3667 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
3671 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
3674 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
3679 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
3680 echo "$ac_t""${ac_cv_exeext}" 1>&6
3683 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
3684 echo "configure:3685: checking for object suffix" >&5
3685 if eval "test \"\${ac_cv_objext+set}\" = set"; then
3686 echo $ac_n "(cached) $ac_c" 1>&6
3689 echo 'int i = 1;' > conftest.$ac_ext
3690 if { (eval echo configure:3691: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3691 for ac_file in conftest.*; do
3694 *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
3698 { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
3703 echo "$ac_t""$ac_cv_objext" 1>&6
3704 OBJEXT=$ac_cv_objext
3705 ac_objext=$ac_cv_objext
3708 cat >> confdefs.h <<EOF
3709 #define EXEEXT "${EXEEXT}"
3713 echo $ac_n "checking for be_app in -lbe""... $ac_c" 1>&6
3714 echo "configure:3715: checking for be_app in -lbe" >&5
3715 ac_lib_var=`echo be'_'be_app | sed 'y%./+-:%__p__%'`
3716 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
3717 echo $ac_n "(cached) $ac_c" 1>&6
3719 ac_save_LIBS="$LIBS"
3720 LIBS="-lbe -lroot -lnet $LIBS"
3721 cat > conftest.$ac_ext <<EOF
3722 #line 3723 "configure"
3723 #include "confdefs.h"
3724 /* Override any gcc2 internal prototype to avoid an error. */
3725 /* We use char because int might match the return type of a gcc2
3726 builtin and then its argument prototype would still apply. */
3733 if { (eval echo configure:3734: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3735 eval "ac_cv_lib_$ac_lib_var=yes"
3737 echo "configure: failed program was:" >&5
3738 cat conftest.$ac_ext >&5
3740 eval "ac_cv_lib_$ac_lib_var=no"
3743 LIBS="$ac_save_LIBS"
3746 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3747 echo "$ac_t""yes" 1>&6
3748 LIBS="$LIBS -lbe -lroot -lnet"
3750 echo "$ac_t""no" 1>&6
3758 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
3759 echo "configure:3760: checking for ${CC-cc} option to accept ANSI C" >&5
3760 if eval "test \"\${am_cv_prog_cc_stdc+set}\" = set"; then
3761 echo $ac_n "(cached) $ac_c" 1>&6
3763 am_cv_prog_cc_stdc=no
3765 # Don't try gcc -ansi; that turns off useful extensions and
3766 # breaks some systems' header files.
3767 # AIX -qlanglvl=ansi
3768 # Ultrix and OSF/1 -std1
3769 # HP-UX 10.20 and later -Ae
3770 # HP-UX older versions -Aa -D_HPUX_SOURCE
3771 # SVR4 -Xc -D__EXTENSIONS__
3772 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3774 CC="$ac_save_CC $ac_arg"
3775 cat > conftest.$ac_ext <<EOF
3776 #line 3777 "configure"
3777 #include "confdefs.h"
3780 #include <sys/types.h>
3781 #include <sys/stat.h>
3782 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3783 struct buf { int x; };
3784 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3785 static char *e (p, i)
3791 static char *f (char * (*g) (char **, int), char **p, ...)
3796 s = g (p, va_arg (v,int));
3800 int test (int i, double x);
3801 struct s1 {int (*f) (int a);};
3802 struct s2 {int (*f) (double a);};
3803 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3809 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3813 if { (eval echo configure:3814: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3815 am_cv_prog_cc_stdc="$ac_arg"; break
3817 echo "configure: failed program was:" >&5
3818 cat conftest.$ac_ext >&5
3826 if test -z "$am_cv_prog_cc_stdc"; then
3827 echo "$ac_t""none needed" 1>&6
3829 echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
3831 case "x$am_cv_prog_cc_stdc" in
3833 *) CC="$CC $am_cv_prog_cc_stdc" ;;
3836 if test "X${am_cv_prog_cc_stdc}" = "Xno" ; then
3837 { echo "configure: error: OpenLDAP requires compiler to support STDC constructs." 1>&2; exit 1; }
3840 # test for make depend flag
3843 if test -z "${MKDEP}"; then
3845 if test -z "${MKDEP_FLAGS}"; then
3846 echo $ac_n "checking for ${OL_MKDEP} depend flag""... $ac_c" 1>&6
3847 echo "configure:3848: checking for ${OL_MKDEP} depend flag" >&5
3848 if eval "test \"\${ol_cv_mkdep+set}\" = set"; then
3849 echo $ac_n "(cached) $ac_c" 1>&6
3853 for flag in "-M" "-xM"; do
3854 cat > conftest.c <<EOF
3857 if { ac_try='$OL_MKDEP $flag conftest.c'; { (eval echo configure:3858: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
3858 | egrep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
3860 if test ! -f conftest."${ac_object}" ; then
3862 OL_MKDEP_FLAGS="$flag"
3871 echo "$ac_t""$ol_cv_mkdep" 1>&6
3874 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
3879 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
3884 if test "${ol_cv_mkdep}" = no ; then
3885 # this will soon become an error
3886 echo "configure: warning: do not know how to generate dependencies" 1>&2
3889 echo $ac_n "checking for afopen in -ls""... $ac_c" 1>&6
3890 echo "configure:3891: checking for afopen in -ls" >&5
3891 ac_lib_var=`echo s'_'afopen | sed 'y%./+-:%__p__%'`
3892 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
3893 echo $ac_n "(cached) $ac_c" 1>&6
3895 ac_save_LIBS="$LIBS"
3897 cat > conftest.$ac_ext <<EOF
3898 #line 3899 "configure"
3899 #include "confdefs.h"
3900 /* Override any gcc2 internal prototype to avoid an error. */
3901 /* We use char because int might match the return type of a gcc2
3902 builtin and then its argument prototype would still apply. */
3909 if { (eval echo configure:3910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3911 eval "ac_cv_lib_$ac_lib_var=yes"
3913 echo "configure: failed program was:" >&5
3914 cat conftest.$ac_ext >&5
3916 eval "ac_cv_lib_$ac_lib_var=no"
3919 LIBS="$ac_save_LIBS"
3922 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3923 echo "$ac_t""yes" 1>&6
3926 cat >> confdefs.h <<\EOF
3927 #define HAVE_AIX_SECURITY 1
3932 echo "$ac_t""no" 1>&6
3937 for ac_func in getaddrinfo
3939 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3940 echo "configure:3941: checking for $ac_func" >&5
3941 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
3942 echo $ac_n "(cached) $ac_c" 1>&6
3944 cat > conftest.$ac_ext <<EOF
3945 #line 3946 "configure"
3946 #include "confdefs.h"
3947 /* System header to define __stub macros and hopefully few prototypes,
3948 which can conflict with char $ac_func(); below. */
3950 /* Override any gcc2 internal prototype to avoid an error. */
3951 /* We use char because int might match the return type of a gcc2
3952 builtin and then its argument prototype would still apply. */
3958 /* The GNU C library defines this for functions which it implements
3959 to always fail with ENOSYS. Some functions are actually named
3960 something starting with __ and the normal name is an alias. */
3961 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3969 if { (eval echo configure:3970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3971 eval "ac_cv_func_$ac_func=yes"
3973 echo "configure: failed program was:" >&5
3974 cat conftest.$ac_ext >&5
3976 eval "ac_cv_func_$ac_func=no"
3981 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3982 echo "$ac_t""yes" 1>&6
3983 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3984 cat >> confdefs.h <<EOF
3985 #define $ac_tr_func 1
3989 echo "$ac_t""no" 1>&6
3994 if test $ac_cv_func_getaddrinfo = no ; then
3995 if test $ol_enable_ipv6 = yes ; then
3996 { echo "configure: error: IPv6 support requires getaddrinfo()" 1>&2; exit 1; }
4001 if test $ol_enable_local != no ; then
4002 for ac_hdr in sys/un.h
4004 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4005 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4006 echo "configure:4007: checking for $ac_hdr" >&5
4007 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
4008 echo $ac_n "(cached) $ac_c" 1>&6
4010 cat > conftest.$ac_ext <<EOF
4011 #line 4012 "configure"
4012 #include "confdefs.h"
4015 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4016 { (eval echo configure:4017: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4017 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4018 if test -z "$ac_err"; then
4020 eval "ac_cv_header_$ac_safe=yes"
4023 echo "configure: failed program was:" >&5
4024 cat conftest.$ac_ext >&5
4026 eval "ac_cv_header_$ac_safe=no"
4030 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4031 echo "$ac_t""yes" 1>&6
4032 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4033 cat >> confdefs.h <<EOF
4034 #define $ac_tr_hdr 1
4038 echo "$ac_t""no" 1>&6
4043 if test $ol_enable_local = auto ; then
4044 ol_enable_local=$ac_cv_header_sys_un_h
4045 elif test $ac_cv_header_sys_un_h = no ; then
4046 { echo "configure: error: AF_LOCAL domain support requires sys/un.h" 1>&2; exit 1; }
4051 if test $ol_enable_modules != no ; then
4052 for ac_hdr in ltdl.h
4054 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4055 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4056 echo "configure:4057: checking for $ac_hdr" >&5
4057 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
4058 echo $ac_n "(cached) $ac_c" 1>&6
4060 cat > conftest.$ac_ext <<EOF
4061 #line 4062 "configure"
4062 #include "confdefs.h"
4065 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4066 { (eval echo configure:4067: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4067 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4068 if test -z "$ac_err"; then
4070 eval "ac_cv_header_$ac_safe=yes"
4073 echo "configure: failed program was:" >&5
4074 cat conftest.$ac_ext >&5
4076 eval "ac_cv_header_$ac_safe=no"
4080 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4081 echo "$ac_t""yes" 1>&6
4082 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4083 cat >> confdefs.h <<EOF
4084 #define $ac_tr_hdr 1
4088 echo "$ac_t""no" 1>&6
4093 if test $ac_cv_header_ltdl_h = no ; then
4094 { echo "configure: error: could not locate libtool ltdl.h" 1>&2; exit 1; }
4097 echo $ac_n "checking for lt_dlinit in -lltdl""... $ac_c" 1>&6
4098 echo "configure:4099: checking for lt_dlinit in -lltdl" >&5
4099 ac_lib_var=`echo ltdl'_'lt_dlinit | sed 'y%./+-:%__p__%'`
4100 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4101 echo $ac_n "(cached) $ac_c" 1>&6
4103 ac_save_LIBS="$LIBS"
4105 cat > conftest.$ac_ext <<EOF
4106 #line 4107 "configure"
4107 #include "confdefs.h"
4108 /* Override any gcc2 internal prototype to avoid an error. */
4109 /* We use char because int might match the return type of a gcc2
4110 builtin and then its argument prototype would still apply. */
4117 if { (eval echo configure:4118: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4119 eval "ac_cv_lib_$ac_lib_var=yes"
4121 echo "configure: failed program was:" >&5
4122 cat conftest.$ac_ext >&5
4124 eval "ac_cv_lib_$ac_lib_var=no"
4127 LIBS="$ac_save_LIBS"
4130 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4131 echo "$ac_t""yes" 1>&6
4134 cat >> confdefs.h <<\EOF
4135 #define HAVE_LIBLTDL 1
4140 echo "$ac_t""no" 1>&6
4144 if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
4145 { echo "configure: error: could not locate libtool -lltdl" 1>&2; exit 1; }
4149 ol_with_dnssrv_module=static
4150 ol_with_ldap_module=static
4151 ol_with_ldbm_module=static
4152 ol_with_passwd_module=static
4153 ol_with_shell_module=static
4154 ol_with_sql_module=static
4158 echo $ac_n "checking for EBCDIC""... $ac_c" 1>&6
4159 echo "configure:4160: checking for EBCDIC" >&5
4160 if eval "test \"\${ol_cv_cpp_ebcdic+set}\" = set"; then
4161 echo $ac_n "(cached) $ac_c" 1>&6
4164 cat > conftest.$ac_ext <<EOF
4165 #line 4166 "configure"
4166 #include "confdefs.h"
4169 #include <__ASCII__/generate_error.h>
4173 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4174 { (eval echo configure:4175: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4175 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4176 if test -z "$ac_err"; then
4178 ol_cv_cpp_ebcdic=yes
4181 echo "configure: failed program was:" >&5
4182 cat conftest.$ac_ext >&5
4189 echo "$ac_t""$ol_cv_cpp_ebcdic" 1>&6
4190 if test $ol_cv_cpp_ebcdic = yes ; then
4191 cat >> confdefs.h <<\EOF
4192 #define HAVE_EBCDIC 1
4197 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
4198 echo "configure:4199: checking for ANSI C header files" >&5
4199 if eval "test \"\${ol_cv_header_stdc+set}\" = set"; then
4200 echo $ac_n "(cached) $ac_c" 1>&6
4202 cat > conftest.$ac_ext <<EOF
4203 #line 4204 "configure"
4204 #include "confdefs.h"
4210 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4211 { (eval echo configure:4212: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4212 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4213 if test -z "$ac_err"; then
4215 ol_cv_header_stdc=yes
4218 echo "configure: failed program was:" >&5
4219 cat conftest.$ac_ext >&5
4221 ol_cv_header_stdc=no
4225 if test $ol_cv_header_stdc = yes; then
4226 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4227 cat > conftest.$ac_ext <<EOF
4228 #line 4229 "configure"
4229 #include "confdefs.h"
4232 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4233 egrep "memchr" >/dev/null 2>&1; then
4237 ol_cv_header_stdc=no
4243 if test $ol_cv_header_stdc = yes; then
4244 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4245 cat > conftest.$ac_ext <<EOF
4246 #line 4247 "configure"
4247 #include "confdefs.h"
4250 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4251 egrep "free" >/dev/null 2>&1; then
4255 ol_cv_header_stdc=no
4261 if test $ol_cv_header_stdc = yes; then
4262 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4263 if test "$cross_compiling" = yes; then
4266 cat > conftest.$ac_ext <<EOF
4267 #line 4268 "configure"
4268 #include "confdefs.h"
4271 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4272 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4274 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
4275 || ('j' <= (c) && (c) <= 'r') \
4276 || ('s' <= (c) && (c) <= 'z'))
4277 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4279 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4280 int main () { int i; for (i = 0; i < 256; i++)
4281 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
4285 if { (eval echo configure:4286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4289 echo "configure: failed program was:" >&5
4290 cat conftest.$ac_ext >&5
4292 ol_cv_header_stdc=no
4300 echo "$ac_t""$ol_cv_header_stdc" 1>&6
4301 if test $ol_cv_header_stdc = yes; then
4302 cat >> confdefs.h <<\EOF
4303 #define STDC_HEADERS 1
4307 ac_cv_header_stdc=disable
4310 if test $ol_cv_header_stdc != yes; then
4311 echo "configure: warning: could not locate Standard C compliant headers" 1>&2
4315 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
4317 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4318 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
4319 echo "configure:4320: checking for $ac_hdr that defines DIR" >&5
4320 if eval "test \"\${ac_cv_header_dirent_$ac_safe+set}\" = set"; then
4321 echo $ac_n "(cached) $ac_c" 1>&6
4323 cat > conftest.$ac_ext <<EOF
4324 #line 4325 "configure"
4325 #include "confdefs.h"
4326 #include <sys/types.h>
4332 if { (eval echo configure:4333: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4334 eval "ac_cv_header_dirent_$ac_safe=yes"
4336 echo "configure: failed program was:" >&5
4337 cat conftest.$ac_ext >&5
4339 eval "ac_cv_header_dirent_$ac_safe=no"
4343 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
4344 echo "$ac_t""yes" 1>&6
4345 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4346 cat >> confdefs.h <<EOF
4347 #define $ac_tr_hdr 1
4349 ac_header_dirent=$ac_hdr; break
4351 echo "$ac_t""no" 1>&6
4354 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4355 if test $ac_header_dirent = dirent.h; then
4356 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
4357 echo "configure:4358: checking for opendir in -ldir" >&5
4358 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-:%__p__%'`
4359 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4360 echo $ac_n "(cached) $ac_c" 1>&6
4362 ac_save_LIBS="$LIBS"
4364 cat > conftest.$ac_ext <<EOF
4365 #line 4366 "configure"
4366 #include "confdefs.h"
4367 /* Override any gcc2 internal prototype to avoid an error. */
4368 /* We use char because int might match the return type of a gcc2
4369 builtin and then its argument prototype would still apply. */
4376 if { (eval echo configure:4377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4378 eval "ac_cv_lib_$ac_lib_var=yes"
4380 echo "configure: failed program was:" >&5
4381 cat conftest.$ac_ext >&5
4383 eval "ac_cv_lib_$ac_lib_var=no"
4386 LIBS="$ac_save_LIBS"
4389 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4390 echo "$ac_t""yes" 1>&6
4393 echo "$ac_t""no" 1>&6
4397 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
4398 echo "configure:4399: checking for opendir in -lx" >&5
4399 ac_lib_var=`echo x'_'opendir | sed 'y%./+-:%__p__%'`
4400 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4401 echo $ac_n "(cached) $ac_c" 1>&6
4403 ac_save_LIBS="$LIBS"
4405 cat > conftest.$ac_ext <<EOF
4406 #line 4407 "configure"
4407 #include "confdefs.h"
4408 /* Override any gcc2 internal prototype to avoid an error. */
4409 /* We use char because int might match the return type of a gcc2
4410 builtin and then its argument prototype would still apply. */
4417 if { (eval echo configure:4418: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4419 eval "ac_cv_lib_$ac_lib_var=yes"
4421 echo "configure: failed program was:" >&5
4422 cat conftest.$ac_ext >&5
4424 eval "ac_cv_lib_$ac_lib_var=no"
4427 LIBS="$ac_save_LIBS"
4430 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4431 echo "$ac_t""yes" 1>&6
4434 echo "$ac_t""no" 1>&6
4439 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
4440 echo "configure:4441: checking for sys/wait.h that is POSIX.1 compatible" >&5
4441 if eval "test \"\${ac_cv_header_sys_wait_h+set}\" = set"; then
4442 echo $ac_n "(cached) $ac_c" 1>&6
4444 cat > conftest.$ac_ext <<EOF
4445 #line 4446 "configure"
4446 #include "confdefs.h"
4447 #include <sys/types.h>
4448 #include <sys/wait.h>
4450 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
4453 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
4458 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
4461 if { (eval echo configure:4462: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4463 ac_cv_header_sys_wait_h=yes
4465 echo "configure: failed program was:" >&5
4466 cat conftest.$ac_ext >&5
4468 ac_cv_header_sys_wait_h=no
4473 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
4474 if test $ac_cv_header_sys_wait_h = yes; then
4475 cat >> confdefs.h <<\EOF
4476 #define HAVE_SYS_WAIT_H 1
4481 echo $ac_n "checking POSIX termios""... $ac_c" 1>&6
4482 echo "configure:4483: checking POSIX termios" >&5
4483 if eval "test \"\${am_cv_sys_posix_termios+set}\" = set"; then
4484 echo $ac_n "(cached) $ac_c" 1>&6
4486 cat > conftest.$ac_ext <<EOF
4487 #line 4488 "configure"
4488 #include "confdefs.h"
4489 #include <sys/types.h>
4491 #include <termios.h>
4493 /* SunOS 4.0.3 has termios.h but not the library calls. */
4497 if { (eval echo configure:4498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4499 am_cv_sys_posix_termios=yes
4501 echo "configure: failed program was:" >&5
4502 cat conftest.$ac_ext >&5
4504 am_cv_sys_posix_termios=no
4509 echo "$ac_t""$am_cv_sys_posix_termios" 1>&6
4512 echo $ac_n "checking whether use of TIOCGWINSZ requires sys/ioctl.h""... $ac_c" 1>&6
4513 echo "configure:4514: checking whether use of TIOCGWINSZ requires sys/ioctl.h" >&5
4514 if eval "test \"\${am_cv_sys_tiocgwinsz_needs_sys_ioctl_h+set}\" = set"; then
4515 echo $ac_n "(cached) $ac_c" 1>&6
4517 am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=no
4519 gwinsz_in_termios_h=no
4520 if test $am_cv_sys_posix_termios = yes; then
4521 cat > conftest.$ac_ext <<EOF
4522 #line 4523 "configure"
4523 #include "confdefs.h"
4524 #include <sys/types.h>
4525 # include <termios.h>
4531 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4532 egrep "yes" >/dev/null 2>&1; then
4534 gwinsz_in_termios_h=yes
4540 if test $gwinsz_in_termios_h = no; then
4541 cat > conftest.$ac_ext <<EOF
4542 #line 4543 "configure"
4543 #include "confdefs.h"
4544 #include <sys/types.h>
4545 # include <sys/ioctl.h>
4551 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4552 egrep "yes" >/dev/null 2>&1; then
4554 am_cv_sys_tiocgwinsz_needs_sys_ioctl_h=yes
4562 echo "$ac_t""$am_cv_sys_tiocgwinsz_needs_sys_ioctl_h" 1>&6
4563 if test $am_cv_sys_tiocgwinsz_needs_sys_ioctl_h = yes; then
4564 cat >> confdefs.h <<\EOF
4565 #define GWINSZ_IN_SYS_IOCTL 1
4570 if test $am_cv_sys_posix_termios = yes ; then
4571 cat >> confdefs.h <<\EOF
4572 #define HAVE_POSIX_TERMIOS 1
4623 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4624 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4625 echo "configure:4626: checking for $ac_hdr" >&5
4626 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
4627 echo $ac_n "(cached) $ac_c" 1>&6
4629 cat > conftest.$ac_ext <<EOF
4630 #line 4631 "configure"
4631 #include "confdefs.h"
4634 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4635 { (eval echo configure:4636: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4636 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4637 if test -z "$ac_err"; then
4639 eval "ac_cv_header_$ac_safe=yes"
4642 echo "configure: failed program was:" >&5
4643 cat conftest.$ac_ext >&5
4645 eval "ac_cv_header_$ac_safe=no"
4649 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4650 echo "$ac_t""yes" 1>&6
4651 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4652 cat >> confdefs.h <<EOF
4653 #define $ac_tr_hdr 1
4657 echo "$ac_t""no" 1>&6
4664 echo $ac_n "checking for sigset in -lV3""... $ac_c" 1>&6
4665 echo "configure:4666: checking for sigset in -lV3" >&5
4666 ac_lib_var=`echo V3'_'sigset | sed 'y%./+-:%__p__%'`
4667 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4668 echo $ac_n "(cached) $ac_c" 1>&6
4670 ac_save_LIBS="$LIBS"
4672 cat > conftest.$ac_ext <<EOF
4673 #line 4674 "configure"
4674 #include "confdefs.h"
4675 /* Override any gcc2 internal prototype to avoid an error. */
4676 /* We use char because int might match the return type of a gcc2
4677 builtin and then its argument prototype would still apply. */
4684 if { (eval echo configure:4685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4686 eval "ac_cv_lib_$ac_lib_var=yes"
4688 echo "configure: failed program was:" >&5
4689 cat conftest.$ac_ext >&5
4691 eval "ac_cv_lib_$ac_lib_var=no"
4694 LIBS="$ac_save_LIBS"
4697 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4698 echo "$ac_t""yes" 1>&6
4699 ac_tr_lib=HAVE_LIB`echo V3 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4700 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4701 cat >> confdefs.h <<EOF
4702 #define $ac_tr_lib 1
4708 echo "$ac_t""no" 1>&6
4712 if test $ac_cv_header_winsock_h = yes; then
4713 echo $ac_n "checking for winsock""... $ac_c" 1>&6
4714 echo "configure:4715: checking for winsock" >&5
4715 if eval "test \"\${ol_cv_winsock+set}\" = set"; then
4716 echo $ac_n "(cached) $ac_c" 1>&6
4718 cat > conftest.$ac_ext <<EOF
4719 #line 4720 "configure"
4720 #include "confdefs.h"
4721 #include <winsock.h>
4725 select(0,NULL,NULL,NULL,NULL);
4727 gethostname(NULL,0);
4731 if { (eval echo configure:4732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4735 echo "configure: failed program was:" >&5
4736 cat conftest.$ac_ext >&5
4743 echo "$ac_t""$ol_cv_winsock" 1>&6
4745 if test $ol_cv_winsock = yes ; then
4746 cat >> confdefs.h <<\EOF
4747 #define HAVE_WINSOCK 1
4750 ac_cv_func_socket=yes
4751 ac_cv_func_select=yes
4752 ac_cv_func_closesocket=yes
4753 ac_cv_func_gethostname=yes
4758 echo $ac_n "checking for socket""... $ac_c" 1>&6
4759 echo "configure:4760: checking for socket" >&5
4760 if eval "test \"\${ac_cv_func_socket+set}\" = set"; then
4761 echo $ac_n "(cached) $ac_c" 1>&6
4763 cat > conftest.$ac_ext <<EOF
4764 #line 4765 "configure"
4765 #include "confdefs.h"
4766 /* System header to define __stub macros and hopefully few prototypes,
4767 which can conflict with char socket(); below. */
4769 /* Override any gcc2 internal prototype to avoid an error. */
4770 /* We use char because int might match the return type of a gcc2
4771 builtin and then its argument prototype would still apply. */
4777 /* The GNU C library defines this for functions which it implements
4778 to always fail with ENOSYS. Some functions are actually named
4779 something starting with __ and the normal name is an alias. */
4780 #if defined (__stub_socket) || defined (__stub___socket)
4788 if { (eval echo configure:4789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4790 eval "ac_cv_func_socket=yes"
4792 echo "configure: failed program was:" >&5
4793 cat conftest.$ac_ext >&5
4795 eval "ac_cv_func_socket=no"
4800 if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
4801 echo "$ac_t""yes" 1>&6
4804 echo "$ac_t""no" 1>&6
4806 echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6
4807 echo "configure:4808: checking for main in -lsocket" >&5
4808 ac_lib_var=`echo socket'_'main | sed 'y%./+-:%__p__%'`
4809 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4810 echo $ac_n "(cached) $ac_c" 1>&6
4812 ac_save_LIBS="$LIBS"
4813 LIBS="-lsocket $LIBS"
4814 cat > conftest.$ac_ext <<EOF
4815 #line 4816 "configure"
4816 #include "confdefs.h"
4822 if { (eval echo configure:4823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4824 eval "ac_cv_lib_$ac_lib_var=yes"
4826 echo "configure: failed program was:" >&5
4827 cat conftest.$ac_ext >&5
4829 eval "ac_cv_lib_$ac_lib_var=no"
4832 LIBS="$ac_save_LIBS"
4835 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4836 echo "$ac_t""yes" 1>&6
4837 ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4838 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4839 cat >> confdefs.h <<EOF
4840 #define $ac_tr_lib 1
4843 LIBS="-lsocket $LIBS"
4846 echo "$ac_t""no" 1>&6
4849 echo $ac_n "checking for main in -lnet""... $ac_c" 1>&6
4850 echo "configure:4851: checking for main in -lnet" >&5
4851 ac_lib_var=`echo net'_'main | sed 'y%./+-:%__p__%'`
4852 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4853 echo $ac_n "(cached) $ac_c" 1>&6
4855 ac_save_LIBS="$LIBS"
4857 cat > conftest.$ac_ext <<EOF
4858 #line 4859 "configure"
4859 #include "confdefs.h"
4865 if { (eval echo configure:4866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4867 eval "ac_cv_lib_$ac_lib_var=yes"
4869 echo "configure: failed program was:" >&5
4870 cat conftest.$ac_ext >&5
4872 eval "ac_cv_lib_$ac_lib_var=no"
4875 LIBS="$ac_save_LIBS"
4878 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4879 echo "$ac_t""yes" 1>&6
4880 ac_tr_lib=HAVE_LIB`echo net | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4881 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4882 cat >> confdefs.h <<EOF
4883 #define $ac_tr_lib 1
4889 echo "$ac_t""no" 1>&6
4892 echo $ac_n "checking for main in -lnsl_s""... $ac_c" 1>&6
4893 echo "configure:4894: checking for main in -lnsl_s" >&5
4894 ac_lib_var=`echo nsl_s'_'main | sed 'y%./+-:%__p__%'`
4895 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4896 echo $ac_n "(cached) $ac_c" 1>&6
4898 ac_save_LIBS="$LIBS"
4899 LIBS="-lnsl_s $LIBS"
4900 cat > conftest.$ac_ext <<EOF
4901 #line 4902 "configure"
4902 #include "confdefs.h"
4908 if { (eval echo configure:4909: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4910 eval "ac_cv_lib_$ac_lib_var=yes"
4912 echo "configure: failed program was:" >&5
4913 cat conftest.$ac_ext >&5
4915 eval "ac_cv_lib_$ac_lib_var=no"
4918 LIBS="$ac_save_LIBS"
4921 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4922 echo "$ac_t""yes" 1>&6
4923 ac_tr_lib=HAVE_LIB`echo nsl_s | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4924 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4925 cat >> confdefs.h <<EOF
4926 #define $ac_tr_lib 1
4929 LIBS="-lnsl_s $LIBS"
4932 echo "$ac_t""no" 1>&6
4935 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
4936 echo "configure:4937: checking for main in -lnsl" >&5
4937 ac_lib_var=`echo nsl'_'main | sed 'y%./+-:%__p__%'`
4938 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4939 echo $ac_n "(cached) $ac_c" 1>&6
4941 ac_save_LIBS="$LIBS"
4943 cat > conftest.$ac_ext <<EOF
4944 #line 4945 "configure"
4945 #include "confdefs.h"
4951 if { (eval echo configure:4952: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4953 eval "ac_cv_lib_$ac_lib_var=yes"
4955 echo "configure: failed program was:" >&5
4956 cat conftest.$ac_ext >&5
4958 eval "ac_cv_lib_$ac_lib_var=no"
4961 LIBS="$ac_save_LIBS"
4964 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4965 echo "$ac_t""yes" 1>&6
4966 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4967 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4968 cat >> confdefs.h <<EOF
4969 #define $ac_tr_lib 1
4975 echo "$ac_t""no" 1>&6
4978 echo $ac_n "checking for socket in -linet""... $ac_c" 1>&6
4979 echo "configure:4980: checking for socket in -linet" >&5
4980 ac_lib_var=`echo inet'_'socket | sed 'y%./+-:%__p__%'`
4981 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
4982 echo $ac_n "(cached) $ac_c" 1>&6
4984 ac_save_LIBS="$LIBS"
4986 cat > conftest.$ac_ext <<EOF
4987 #line 4988 "configure"
4988 #include "confdefs.h"
4989 /* Override any gcc2 internal prototype to avoid an error. */
4990 /* We use char because int might match the return type of a gcc2
4991 builtin and then its argument prototype would still apply. */
4998 if { (eval echo configure:4999: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5000 eval "ac_cv_lib_$ac_lib_var=yes"
5002 echo "configure: failed program was:" >&5
5003 cat conftest.$ac_ext >&5
5005 eval "ac_cv_lib_$ac_lib_var=no"
5008 LIBS="$ac_save_LIBS"
5011 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5012 echo "$ac_t""yes" 1>&6
5013 ac_tr_lib=HAVE_LIB`echo inet | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5014 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5015 cat >> confdefs.h <<EOF
5016 #define $ac_tr_lib 1
5022 echo "$ac_t""no" 1>&6
5025 echo $ac_n "checking for main in -lgen""... $ac_c" 1>&6
5026 echo "configure:5027: checking for main in -lgen" >&5
5027 ac_lib_var=`echo gen'_'main | sed 'y%./+-:%__p__%'`
5028 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5029 echo $ac_n "(cached) $ac_c" 1>&6
5031 ac_save_LIBS="$LIBS"
5033 cat > conftest.$ac_ext <<EOF
5034 #line 5035 "configure"
5035 #include "confdefs.h"
5041 if { (eval echo configure:5042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5043 eval "ac_cv_lib_$ac_lib_var=yes"
5045 echo "configure: failed program was:" >&5
5046 cat conftest.$ac_ext >&5
5048 eval "ac_cv_lib_$ac_lib_var=no"
5051 LIBS="$ac_save_LIBS"
5054 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5055 echo "$ac_t""yes" 1>&6
5056 ac_tr_lib=HAVE_LIB`echo gen | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5057 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5058 cat >> confdefs.h <<EOF
5059 #define $ac_tr_lib 1
5065 echo "$ac_t""no" 1>&6
5072 echo $ac_n "checking for select""... $ac_c" 1>&6
5073 echo "configure:5074: checking for select" >&5
5074 if eval "test \"\${ac_cv_func_select+set}\" = set"; then
5075 echo $ac_n "(cached) $ac_c" 1>&6
5077 cat > conftest.$ac_ext <<EOF
5078 #line 5079 "configure"
5079 #include "confdefs.h"
5080 /* System header to define __stub macros and hopefully few prototypes,
5081 which can conflict with char select(); below. */
5083 /* Override any gcc2 internal prototype to avoid an error. */
5084 /* We use char because int might match the return type of a gcc2
5085 builtin and then its argument prototype would still apply. */
5091 /* The GNU C library defines this for functions which it implements
5092 to always fail with ENOSYS. Some functions are actually named
5093 something starting with __ and the normal name is an alias. */
5094 #if defined (__stub_select) || defined (__stub___select)
5102 if { (eval echo configure:5103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5104 eval "ac_cv_func_select=yes"
5106 echo "configure: failed program was:" >&5
5107 cat conftest.$ac_ext >&5
5109 eval "ac_cv_func_select=no"
5114 if eval "test \"`echo '$ac_cv_func_'select`\" = yes"; then
5115 echo "$ac_t""yes" 1>&6
5118 echo "$ac_t""no" 1>&6
5119 { echo "configure: error: select() required." 1>&2; exit 1; }
5123 if test "${ac_cv_header_winsock_h}" != yes; then
5124 echo $ac_n "checking types of arguments for select()""... $ac_c" 1>&6
5125 echo "configure:5126: checking types of arguments for select()" >&5
5126 if eval "test \"\${ac_cv_func_select_arg234+set}\" = set"; then
5127 echo $ac_n "(cached) $ac_c" 1>&6
5129 if eval "test \"\${ac_cv_func_select_arg1+set}\" = set"; then
5130 echo $ac_n "(cached) $ac_c" 1>&6
5132 if eval "test \"\${ac_cv_func_select_arg5+set}\" = set"; then
5133 echo $ac_n "(cached) $ac_c" 1>&6
5135 for ac_cv_func_select_arg234 in 'fd_set *' 'int *' 'void *'; do
5136 for ac_cv_func_select_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
5137 for ac_cv_func_select_arg5 in 'struct timeval *' 'const struct timeval *'; do
5138 cat > conftest.$ac_ext <<EOF
5139 #line 5140 "configure"
5140 #include "confdefs.h"
5141 #ifdef HAVE_SYS_TYPES_H
5142 #include <sys/types.h>
5144 #ifdef HAVE_SYS_TIME_H
5145 #include <sys/time.h>
5147 #ifdef HAVE_SYS_SELECT_H
5148 #include <sys/select.h>
5150 #ifdef HAVE_SYS_SOCKET_H
5151 #include <sys/socket.h>
5153 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);
5158 if { (eval echo configure:5159: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5160 ac_not_found=no ; break 3
5162 echo "configure: failed program was:" >&5
5163 cat conftest.$ac_ext >&5
5177 if test "$ac_not_found" = yes; then
5178 ac_cv_func_select_arg1=int
5179 ac_cv_func_select_arg234='int *'
5180 ac_cv_func_select_arg5='struct timeval *'
5182 echo "$ac_t""$ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5" 1>&6
5183 cat >> confdefs.h <<EOF
5184 #define SELECT_TYPE_ARG1 $ac_cv_func_select_arg1
5187 cat >> confdefs.h <<EOF
5188 #define SELECT_TYPE_ARG234 ($ac_cv_func_select_arg234)
5191 cat >> confdefs.h <<EOF
5192 #define SELECT_TYPE_ARG5 ($ac_cv_func_select_arg5)
5199 for ac_hdr in regex.h
5201 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5202 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5203 echo "configure:5204: checking for $ac_hdr" >&5
5204 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5205 echo $ac_n "(cached) $ac_c" 1>&6
5207 cat > conftest.$ac_ext <<EOF
5208 #line 5209 "configure"
5209 #include "confdefs.h"
5212 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5213 { (eval echo configure:5214: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5214 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5215 if test -z "$ac_err"; then
5217 eval "ac_cv_header_$ac_safe=yes"
5220 echo "configure: failed program was:" >&5
5221 cat conftest.$ac_ext >&5
5223 eval "ac_cv_header_$ac_safe=no"
5227 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5228 echo "$ac_t""yes" 1>&6
5229 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5230 cat >> confdefs.h <<EOF
5231 #define $ac_tr_hdr 1
5235 echo "$ac_t""no" 1>&6
5239 if test "$ac_cv_header_regex_h" != yes ; then
5240 { echo "configure: error: POSIX regex.h required." 1>&2; exit 1; }
5242 echo $ac_n "checking for regfree""... $ac_c" 1>&6
5243 echo "configure:5244: checking for regfree" >&5
5244 if eval "test \"\${ac_cv_func_regfree+set}\" = set"; then
5245 echo $ac_n "(cached) $ac_c" 1>&6
5247 cat > conftest.$ac_ext <<EOF
5248 #line 5249 "configure"
5249 #include "confdefs.h"
5250 /* System header to define __stub macros and hopefully few prototypes,
5251 which can conflict with char regfree(); below. */
5253 /* Override any gcc2 internal prototype to avoid an error. */
5254 /* We use char because int might match the return type of a gcc2
5255 builtin and then its argument prototype would still apply. */
5261 /* The GNU C library defines this for functions which it implements
5262 to always fail with ENOSYS. Some functions are actually named
5263 something starting with __ and the normal name is an alias. */
5264 #if defined (__stub_regfree) || defined (__stub___regfree)
5272 if { (eval echo configure:5273: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5274 eval "ac_cv_func_regfree=yes"
5276 echo "configure: failed program was:" >&5
5277 cat conftest.$ac_ext >&5
5279 eval "ac_cv_func_regfree=no"
5284 if eval "test \"`echo '$ac_cv_func_'regfree`\" = yes"; then
5285 echo "$ac_t""yes" 1>&6
5288 echo "$ac_t""no" 1>&6
5289 { echo "configure: error: POSIX regex required." 1>&2; exit 1; }
5294 echo $ac_n "checking for compatible POSIX regex""... $ac_c" 1>&6
5295 echo "configure:5296: checking for compatible POSIX regex" >&5
5296 if eval "test \"\${ol_cv_c_posix_regex+set}\" = set"; then
5297 echo $ac_n "(cached) $ac_c" 1>&6
5300 if test "$cross_compiling" = yes; then
5301 ol_cv_c_posix_regex=cross
5303 cat > conftest.$ac_ext <<EOF
5304 #line 5305 "configure"
5305 #include "confdefs.h"
5307 #include <sys/types.h>
5309 static char *pattern, *string;
5317 if(regcomp(&re, pattern, 0)) {
5321 string = "ALL MATCH";
5323 rc = regexec(&re, string, 0, (void*)0, 0);
5330 if { (eval echo configure:5331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5332 ol_cv_c_posix_regex=yes
5334 echo "configure: failed program was:" >&5
5335 cat conftest.$ac_ext >&5
5337 ol_cv_c_posix_regex=no
5344 echo "$ac_t""$ol_cv_c_posix_regex" 1>&6
5346 if test "$ol_cv_c_posix_regex" = no ; then
5347 { echo "configure: error: broken POSIX regex!" 1>&2; exit 1; }
5351 echo $ac_n "checking for res_query""... $ac_c" 1>&6
5352 echo "configure:5353: checking for res_query" >&5
5353 if eval "test \"\${ac_cv_func_res_query+set}\" = set"; then
5354 echo $ac_n "(cached) $ac_c" 1>&6
5356 cat > conftest.$ac_ext <<EOF
5357 #line 5358 "configure"
5358 #include "confdefs.h"
5359 /* System header to define __stub macros and hopefully few prototypes,
5360 which can conflict with char res_query(); below. */
5362 /* Override any gcc2 internal prototype to avoid an error. */
5363 /* We use char because int might match the return type of a gcc2
5364 builtin and then its argument prototype would still apply. */
5370 /* The GNU C library defines this for functions which it implements
5371 to always fail with ENOSYS. Some functions are actually named
5372 something starting with __ and the normal name is an alias. */
5373 #if defined (__stub_res_query) || defined (__stub___res_query)
5381 if { (eval echo configure:5382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5383 eval "ac_cv_func_res_query=yes"
5385 echo "configure: failed program was:" >&5
5386 cat conftest.$ac_ext >&5
5388 eval "ac_cv_func_res_query=no"
5393 if eval "test \"`echo '$ac_cv_func_'res_query`\" = yes"; then
5394 echo "$ac_t""yes" 1>&6
5397 echo "$ac_t""no" 1>&6
5400 if test $ac_cv_func_res_query = no ; then
5401 echo $ac_n "checking for res_query in -lbind""... $ac_c" 1>&6
5402 echo "configure:5403: checking for res_query in -lbind" >&5
5403 ac_lib_var=`echo bind'_'res_query | sed 'y%./+-:%__p__%'`
5404 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5405 echo $ac_n "(cached) $ac_c" 1>&6
5407 ac_save_LIBS="$LIBS"
5409 cat > conftest.$ac_ext <<EOF
5410 #line 5411 "configure"
5411 #include "confdefs.h"
5412 /* Override any gcc2 internal prototype to avoid an error. */
5413 /* We use char because int might match the return type of a gcc2
5414 builtin and then its argument prototype would still apply. */
5421 if { (eval echo configure:5422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5423 eval "ac_cv_lib_$ac_lib_var=yes"
5425 echo "configure: failed program was:" >&5
5426 cat conftest.$ac_ext >&5
5428 eval "ac_cv_lib_$ac_lib_var=no"
5431 LIBS="$ac_save_LIBS"
5434 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5435 echo "$ac_t""yes" 1>&6
5436 ac_tr_lib=HAVE_LIB`echo bind | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5437 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5438 cat >> confdefs.h <<EOF
5439 #define $ac_tr_lib 1
5445 echo "$ac_t""no" 1>&6
5448 ac_cv_func_res_query=$ac_cv_lib_bind_res_query
5451 if test $ac_cv_func_res_query = no ; then
5452 echo $ac_n "checking for __res_query in -lbind""... $ac_c" 1>&6
5453 echo "configure:5454: checking for __res_query in -lbind" >&5
5454 ac_lib_var=`echo bind'_'__res_query | sed 'y%./+-:%__p__%'`
5455 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5456 echo $ac_n "(cached) $ac_c" 1>&6
5458 ac_save_LIBS="$LIBS"
5460 cat > conftest.$ac_ext <<EOF
5461 #line 5462 "configure"
5462 #include "confdefs.h"
5463 /* Override any gcc2 internal prototype to avoid an error. */
5464 /* We use char because int might match the return type of a gcc2
5465 builtin and then its argument prototype would still apply. */
5472 if { (eval echo configure:5473: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5474 eval "ac_cv_lib_$ac_lib_var=yes"
5476 echo "configure: failed program was:" >&5
5477 cat conftest.$ac_ext >&5
5479 eval "ac_cv_lib_$ac_lib_var=no"
5482 LIBS="$ac_save_LIBS"
5485 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5486 echo "$ac_t""yes" 1>&6
5487 ac_tr_lib=HAVE_LIB`echo bind | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5488 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5489 cat >> confdefs.h <<EOF
5490 #define $ac_tr_lib 1
5496 echo "$ac_t""no" 1>&6
5499 ac_cv_func_res_query=$ac_cv_lib_bind___res_query
5502 if test $ac_cv_func_res_query = no ; then
5503 echo $ac_n "checking for res_query in -lresolv""... $ac_c" 1>&6
5504 echo "configure:5505: checking for res_query in -lresolv" >&5
5505 ac_lib_var=`echo resolv'_'res_query | sed 'y%./+-:%__p__%'`
5506 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5507 echo $ac_n "(cached) $ac_c" 1>&6
5509 ac_save_LIBS="$LIBS"
5510 LIBS="-lresolv $LIBS"
5511 cat > conftest.$ac_ext <<EOF
5512 #line 5513 "configure"
5513 #include "confdefs.h"
5514 /* Override any gcc2 internal prototype to avoid an error. */
5515 /* We use char because int might match the return type of a gcc2
5516 builtin and then its argument prototype would still apply. */
5523 if { (eval echo configure:5524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5525 eval "ac_cv_lib_$ac_lib_var=yes"
5527 echo "configure: failed program was:" >&5
5528 cat conftest.$ac_ext >&5
5530 eval "ac_cv_lib_$ac_lib_var=no"
5533 LIBS="$ac_save_LIBS"
5536 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5537 echo "$ac_t""yes" 1>&6
5538 ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5539 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5540 cat >> confdefs.h <<EOF
5541 #define $ac_tr_lib 1
5544 LIBS="-lresolv $LIBS"
5547 echo "$ac_t""no" 1>&6
5550 ac_cv_func_res_query=$ac_cv_lib_resolv_res_query
5553 if test "$ac_cv_func_res_query" = yes ; then
5554 cat >> confdefs.h <<\EOF
5555 #define HAVE_RES_QUERY 1
5559 if test $ol_enable_dnssrv != no ; then
5564 if test "$ol_enable_dnssrv" = yes -a "$ol_link_dnssrv" = no ; then
5565 { echo "configure: error: DNSSRV requires res_query()" 1>&2; exit 1; }
5573 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
5574 -o $ol_with_kerberos = k5 -o $ol_with_kerberos = k5only \
5575 -o $ol_with_kerberos = k425 ; then
5577 for ac_hdr in krb5.h
5579 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5580 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5581 echo "configure:5582: checking for $ac_hdr" >&5
5582 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5583 echo $ac_n "(cached) $ac_c" 1>&6
5585 cat > conftest.$ac_ext <<EOF
5586 #line 5587 "configure"
5587 #include "confdefs.h"
5590 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5591 { (eval echo configure:5592: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5592 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5593 if test -z "$ac_err"; then
5595 eval "ac_cv_header_$ac_safe=yes"
5598 echo "configure: failed program was:" >&5
5599 cat conftest.$ac_ext >&5
5601 eval "ac_cv_header_$ac_safe=no"
5605 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5606 echo "$ac_t""yes" 1>&6
5607 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5608 cat >> confdefs.h <<EOF
5609 #define $ac_tr_hdr 1
5613 echo "$ac_t""no" 1>&6
5618 if test $ac_cv_header_krb5_h = yes ; then
5619 for ac_hdr in heim_err.h
5621 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5622 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5623 echo "configure:5624: checking for $ac_hdr" >&5
5624 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5625 echo $ac_n "(cached) $ac_c" 1>&6
5627 cat > conftest.$ac_ext <<EOF
5628 #line 5629 "configure"
5629 #include "confdefs.h"
5632 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5633 { (eval echo configure:5634: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5634 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5635 if test -z "$ac_err"; then
5637 eval "ac_cv_header_$ac_safe=yes"
5640 echo "configure: failed program was:" >&5
5641 cat conftest.$ac_ext >&5
5643 eval "ac_cv_header_$ac_safe=no"
5647 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5648 echo "$ac_t""yes" 1>&6
5649 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5650 cat >> confdefs.h <<EOF
5651 #define $ac_tr_hdr 1
5655 echo "$ac_t""no" 1>&6
5659 if test $ac_cv_header_heim_err_h = yes ; then
5665 if test $krb5_impl = mit; then
5666 echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6
5667 echo "configure:5668: checking for main in -lkrb5" >&5
5668 ac_lib_var=`echo krb5'_'main | sed 'y%./+-:%__p__%'`
5669 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5670 echo $ac_n "(cached) $ac_c" 1>&6
5672 ac_save_LIBS="$LIBS"
5673 LIBS="-lkrb5 -lcrypto -lcom_err $LIBS"
5674 cat > conftest.$ac_ext <<EOF
5675 #line 5676 "configure"
5676 #include "confdefs.h"
5682 if { (eval echo configure:5683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5684 eval "ac_cv_lib_$ac_lib_var=yes"
5686 echo "configure: failed program was:" >&5
5687 cat conftest.$ac_ext >&5
5689 eval "ac_cv_lib_$ac_lib_var=no"
5692 LIBS="$ac_save_LIBS"
5695 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5696 echo "$ac_t""yes" 1>&6
5698 KRB5_LIBS="-lkrb5 -lcrypto -lcom_err"
5700 echo "$ac_t""no" 1>&6
5705 elif test $krb5_impl = heimdal; then
5706 echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6
5707 echo "configure:5708: checking for main in -lkrb5" >&5
5708 ac_lib_var=`echo krb5'_'main | sed 'y%./+-:%__p__%'`
5709 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5710 echo $ac_n "(cached) $ac_c" 1>&6
5712 ac_save_LIBS="$LIBS"
5713 LIBS="-lkrb5 -ldes -lasn1 -lroken -lcom_err $LIBS"
5714 cat > conftest.$ac_ext <<EOF
5715 #line 5716 "configure"
5716 #include "confdefs.h"
5722 if { (eval echo configure:5723: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5724 eval "ac_cv_lib_$ac_lib_var=yes"
5726 echo "configure: failed program was:" >&5
5727 cat conftest.$ac_ext >&5
5729 eval "ac_cv_lib_$ac_lib_var=no"
5732 LIBS="$ac_save_LIBS"
5735 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5736 echo "$ac_t""yes" 1>&6
5738 KRB5_LIBS="-lkrb5 -ldes -lasn1 -lroken -lcom_err"
5740 echo "$ac_t""no" 1>&6
5745 cat >> confdefs.h <<\EOF
5746 #define HAVE_HEIMDAL_KERBEROS 1
5751 echo "configure: warning: Unrecongized Kerberos5 Implementation" 1>&2
5754 if test $have_krb5 = yes ; then
5757 cat >> confdefs.h <<\EOF
5762 if test $ol_enable_kpasswd != no ; then
5763 ol_link_kpasswd=yes;
5766 if test $ol_with_kerberos = k5only ; then
5767 ol_with_kerberos=found
5770 elif test $ol_with_kerberos != auto ; then
5771 { echo "configure: error: Required Kerberos 5 support not available" 1>&2; exit 1; }
5777 if test $ol_link_krb5 = yes -a \( $ol_with_kerberos = yes -o \
5778 $ol_with_kerberos = auto -o $ol_with_kerberos = k425 \) ; then
5780 for ac_hdr in kerberosIV/krb.h kerberosIV/des.h
5782 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5783 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5784 echo "configure:5785: checking for $ac_hdr" >&5
5785 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5786 echo $ac_n "(cached) $ac_c" 1>&6
5788 cat > conftest.$ac_ext <<EOF
5789 #line 5790 "configure"
5790 #include "confdefs.h"
5793 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5794 { (eval echo configure:5795: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5795 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5796 if test -z "$ac_err"; then
5798 eval "ac_cv_header_$ac_safe=yes"
5801 echo "configure: failed program was:" >&5
5802 cat conftest.$ac_ext >&5
5804 eval "ac_cv_header_$ac_safe=no"
5808 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5809 echo "$ac_t""yes" 1>&6
5810 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5811 cat >> confdefs.h <<EOF
5812 #define $ac_tr_hdr 1
5816 echo "$ac_t""no" 1>&6
5821 if test $ac_cv_header_kerberosIV_krb_h = yes ; then
5822 if test $krb5_impl = mit; then
5823 echo $ac_n "checking for main in -lkrb4""... $ac_c" 1>&6
5824 echo "configure:5825: checking for main in -lkrb4" >&5
5825 ac_lib_var=`echo krb4'_'main | sed 'y%./+-:%__p__%'`
5826 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5827 echo $ac_n "(cached) $ac_c" 1>&6
5829 ac_save_LIBS="$LIBS"
5830 LIBS="-lkrb4 -ldes425 -lkrb5 -lcrypto -lcom_err $LIBS"
5831 cat > conftest.$ac_ext <<EOF
5832 #line 5833 "configure"
5833 #include "confdefs.h"
5839 if { (eval echo configure:5840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5841 eval "ac_cv_lib_$ac_lib_var=yes"
5843 echo "configure: failed program was:" >&5
5844 cat conftest.$ac_ext >&5
5846 eval "ac_cv_lib_$ac_lib_var=no"
5849 LIBS="$ac_save_LIBS"
5852 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5853 echo "$ac_t""yes" 1>&6
5855 KRB4_LIBS="-lkrb4 -ldes425"
5857 echo "$ac_t""no" 1>&6
5862 elif test $krb5_impl = heimdal; then
5863 echo $ac_n "checking for main in -lkrb4""... $ac_c" 1>&6
5864 echo "configure:5865: checking for main in -lkrb4" >&5
5865 ac_lib_var=`echo krb4'_'main | sed 'y%./+-:%__p__%'`
5866 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
5867 echo $ac_n "(cached) $ac_c" 1>&6
5869 ac_save_LIBS="$LIBS"
5870 LIBS="-lkrb4 -lkrb5 -ldes -lasn1 -lroken -lcom_err $LIBS"
5871 cat > conftest.$ac_ext <<EOF
5872 #line 5873 "configure"
5873 #include "confdefs.h"
5879 if { (eval echo configure:5880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5881 eval "ac_cv_lib_$ac_lib_var=yes"
5883 echo "configure: failed program was:" >&5
5884 cat conftest.$ac_ext >&5
5886 eval "ac_cv_lib_$ac_lib_var=no"
5889 LIBS="$ac_save_LIBS"
5892 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5893 echo "$ac_t""yes" 1>&6
5897 echo "$ac_t""no" 1>&6
5904 echo "configure: warning: Unrecongized Kerberos5 Implementation" 1>&2
5907 if test $have_k425 = yes ; then
5908 ol_with_kerberos=found
5911 cat >> confdefs.h <<\EOF
5912 #define HAVE_KRB425 1
5915 cat >> confdefs.h <<\EOF
5920 echo $ac_n "checking for des_debug in Kerberos libraries""... $ac_c" 1>&6
5921 echo "configure:5922: checking for des_debug in Kerberos libraries" >&5
5922 if eval "test \"\${ol_cv_var_des_debug+set}\" = set"; then
5923 echo $ac_n "(cached) $ac_c" 1>&6
5927 LIBS="$KRB4_LIBS $KRB5_LIBS $LIBS"
5928 cat > conftest.$ac_ext <<EOF
5929 #line 5930 "configure"
5930 #include "confdefs.h"
5932 #include <kerberosIV/krb.h>
5933 #include <kerberosIV/des.h>
5934 extern int des_debug;
5942 if { (eval echo configure:5943: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5944 ol_cv_var_des_debug=yes
5946 echo "configure: failed program was:" >&5
5947 cat conftest.$ac_ext >&5
5949 ol_cv_var_des_debug=no
5956 echo "$ac_t""$ol_cv_var_des_debug" 1>&6
5958 if test $ol_cv_var_des_debug = yes ; then
5959 cat >> confdefs.h <<\EOF
5960 #define HAVE_DES_DEBUG 1
5970 if test $ol_link_krb5 = yes ; then
5971 ol_with_kerberos=found
5974 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
5975 -o $ol_with_kerberos = k4 -o $ol_with_kerberos = kth ; then
5977 for ac_hdr in krb.h des.h krb-archaeology.h
5979 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5980 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5981 echo "configure:5982: checking for $ac_hdr" >&5
5982 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
5983 echo $ac_n "(cached) $ac_c" 1>&6
5985 cat > conftest.$ac_ext <<EOF
5986 #line 5987 "configure"
5987 #include "confdefs.h"
5990 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5991 { (eval echo configure:5992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5992 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5993 if test -z "$ac_err"; then
5995 eval "ac_cv_header_$ac_safe=yes"
5998 echo "configure: failed program was:" >&5
5999 cat conftest.$ac_ext >&5
6001 eval "ac_cv_header_$ac_safe=no"
6005 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6006 echo "$ac_t""yes" 1>&6
6007 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6008 cat >> confdefs.h <<EOF
6009 #define $ac_tr_hdr 1
6013 echo "$ac_t""no" 1>&6
6018 if test $ac_cv_header_krb_h = yes ; then
6019 echo $ac_n "checking for main in -lkrb""... $ac_c" 1>&6
6020 echo "configure:6021: checking for main in -lkrb" >&5
6021 ac_lib_var=`echo krb'_'main | sed 'y%./+-:%__p__%'`
6022 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6023 echo $ac_n "(cached) $ac_c" 1>&6
6025 ac_save_LIBS="$LIBS"
6026 LIBS="-lkrb -ldes $LIBS"
6027 cat > conftest.$ac_ext <<EOF
6028 #line 6029 "configure"
6029 #include "confdefs.h"
6035 if { (eval echo configure:6036: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6037 eval "ac_cv_lib_$ac_lib_var=yes"
6039 echo "configure: failed program was:" >&5
6040 cat conftest.$ac_ext >&5
6042 eval "ac_cv_lib_$ac_lib_var=no"
6045 LIBS="$ac_save_LIBS"
6048 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6049 echo "$ac_t""yes" 1>&6
6052 echo "$ac_t""no" 1>&6
6057 if test $have_k4 = yes ; then
6058 ol_with_kerberos=found
6061 cat >> confdefs.h <<\EOF
6066 KRB4_LIBS="-lkrb -ldes"
6068 if test $ac_cv_header_krb_archaeology_h = yes ; then
6069 cat >> confdefs.h <<\EOF
6070 #define HAVE_KTH_KERBEROS 1
6078 if test $ol_link_krb4 = yes -a $ol_enable_kpasswd != no ; then
6082 if test $ol_link_krb4 = yes -a $ol_enable_kbind != no ; then
6085 elif test $ol_enable_kbind = yes ; then
6086 { echo "configure: error: Kerberos IV detection failed" 1>&2; exit 1; }
6089 if test $ol_link_krb4 = yes -o $ol_link_krb5 = yes ; then
6090 cat >> confdefs.h <<\EOF
6091 #define HAVE_KERBEROS 1
6095 elif test $ol_with_kerberos != auto -a $ol_with_kerberos != no ; then
6096 { echo "configure: error: Kerberos detection failed" 1>&2; exit 1; }
6100 if test $ol_with_tls != no ; then
6101 for ac_hdr in openssl/ssl.h ssl.h
6103 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6104 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6105 echo "configure:6106: checking for $ac_hdr" >&5
6106 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6107 echo $ac_n "(cached) $ac_c" 1>&6
6109 cat > conftest.$ac_ext <<EOF
6110 #line 6111 "configure"
6111 #include "confdefs.h"
6114 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6115 { (eval echo configure:6116: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6116 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6117 if test -z "$ac_err"; then
6119 eval "ac_cv_header_$ac_safe=yes"
6122 echo "configure: failed program was:" >&5
6123 cat conftest.$ac_ext >&5
6125 eval "ac_cv_header_$ac_safe=no"
6129 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6130 echo "$ac_t""yes" 1>&6
6131 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6132 cat >> confdefs.h <<EOF
6133 #define $ac_tr_hdr 1
6137 echo "$ac_t""no" 1>&6
6142 if test $ac_cv_header_openssl_ssl_h = yes -o $ac_cv_header_ssl_h = yes ; then
6143 echo $ac_n "checking for SSLeay_add_ssl_algorithms in -lssl""... $ac_c" 1>&6
6144 echo "configure:6145: checking for SSLeay_add_ssl_algorithms in -lssl" >&5
6145 ac_lib_var=`echo ssl'_'SSLeay_add_ssl_algorithms | sed 'y%./+-:%__p__%'`
6146 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6147 echo $ac_n "(cached) $ac_c" 1>&6
6149 ac_save_LIBS="$LIBS"
6150 LIBS="-lssl -lcrypto $LIBS"
6151 cat > conftest.$ac_ext <<EOF
6152 #line 6153 "configure"
6153 #include "confdefs.h"
6154 /* Override any gcc2 internal prototype to avoid an error. */
6155 /* We use char because int might match the return type of a gcc2
6156 builtin and then its argument prototype would still apply. */
6157 char SSLeay_add_ssl_algorithms();
6160 SSLeay_add_ssl_algorithms()
6163 if { (eval echo configure:6164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6165 eval "ac_cv_lib_$ac_lib_var=yes"
6167 echo "configure: failed program was:" >&5
6168 cat conftest.$ac_ext >&5
6170 eval "ac_cv_lib_$ac_lib_var=no"
6173 LIBS="$ac_save_LIBS"
6176 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6177 echo "$ac_t""yes" 1>&6
6181 echo "$ac_t""no" 1>&6
6186 if test $have_ssleay = no ; then
6187 echo $ac_n "checking for SSL_library_init in -lssl""... $ac_c" 1>&6
6188 echo "configure:6189: checking for SSL_library_init in -lssl" >&5
6189 ac_lib_var=`echo ssl'_'SSL_library_init | sed 'y%./+-:%__p__%'`
6190 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6191 echo $ac_n "(cached) $ac_c" 1>&6
6193 ac_save_LIBS="$LIBS"
6194 LIBS="-lssl -lcrypto $LIBS"
6195 cat > conftest.$ac_ext <<EOF
6196 #line 6197 "configure"
6197 #include "confdefs.h"
6198 /* Override any gcc2 internal prototype to avoid an error. */
6199 /* We use char because int might match the return type of a gcc2
6200 builtin and then its argument prototype would still apply. */
6201 char SSL_library_init();
6207 if { (eval echo configure:6208: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6209 eval "ac_cv_lib_$ac_lib_var=yes"
6211 echo "configure: failed program was:" >&5
6212 cat conftest.$ac_ext >&5
6214 eval "ac_cv_lib_$ac_lib_var=no"
6217 LIBS="$ac_save_LIBS"
6220 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6221 echo "$ac_t""yes" 1>&6
6225 echo "$ac_t""no" 1>&6
6231 if test $have_ssleay = no ; then
6232 echo $ac_n "checking for ssl3_accept in -lssl""... $ac_c" 1>&6
6233 echo "configure:6234: checking for ssl3_accept in -lssl" >&5
6234 ac_lib_var=`echo ssl'_'ssl3_accept | sed 'y%./+-:%__p__%'`
6235 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
6236 echo $ac_n "(cached) $ac_c" 1>&6
6238 ac_save_LIBS="$LIBS"
6239 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
6240 cat > conftest.$ac_ext <<EOF
6241 #line 6242 "configure"
6242 #include "confdefs.h"
6243 /* Override any gcc2 internal prototype to avoid an error. */
6244 /* We use char because int might match the return type of a gcc2
6245 builtin and then its argument prototype would still apply. */
6252 if { (eval echo configure:6253: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6254 eval "ac_cv_lib_$ac_lib_var=yes"
6256 echo "configure: failed program was:" >&5
6257 cat conftest.$ac_ext >&5
6259 eval "ac_cv_lib_$ac_lib_var=no"
6262 LIBS="$ac_save_LIBS"
6265 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6266 echo "$ac_t""yes" 1>&6
6270 echo "$ac_t""no" 1>&6
6276 if test $have_ssleay = yes ; then
6280 cat >> confdefs.h <<\EOF
6281 #define HAVE_SSLEAY 1
6285 if test $need_rsaref = yes; then
6286 cat >> confdefs.h <<\EOF
6287 #define HAVE_RSAREF 1
6291 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
6293 TLS_LIBS="-lssl -lcrypto"
6299 echo "configure: warning: TLS privacy protection not supported!" 1>&2
6302 if test $ol_link_tls = yes ; then
6303 cat >> confdefs.h <<\EOF
6308 elif test $ol_with_tls = auto ; then
6309 echo "configure: warning: Could not locate TLS/SSL package" 1>&2
6310 echo "configure: warning: TLS privacy protection not supported!" 1>&2
6312 elif test $ol_with_tls != no ; then
6313 { echo "configure: error: Could not locate TLS/SSL package" 1>&2; exit 1; }
6318 gethostbyname_r gethostbyaddr_r \
6321 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6322 echo "configure:6323: checking for $ac_func" >&5
6323 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
6324 echo $ac_n "(cached) $ac_c" 1>&6
6326 cat > conftest.$ac_ext <<EOF
6327 #line 6328 "configure"
6328 #include "confdefs.h"
6329 /* System header to define __stub macros and hopefully few prototypes,
6330 which can conflict with char $ac_func(); below. */
6332 /* Override any gcc2 internal prototype to avoid an error. */
6333 /* We use char because int might match the return type of a gcc2
6334 builtin and then its argument prototype would still apply. */
6340 /* The GNU C library defines this for functions which it implements
6341 to always fail with ENOSYS. Some functions are actually named
6342 something starting with __ and the normal name is an alias. */
6343 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6351 if { (eval echo configure:6352: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6353 eval "ac_cv_func_$ac_func=yes"
6355 echo "configure: failed program was:" >&5
6356 cat conftest.$ac_ext >&5
6358 eval "ac_cv_func_$ac_func=no"
6363 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6364 echo "$ac_t""yes" 1>&6
6365 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6366 cat >> confdefs.h <<EOF
6367 #define $ac_tr_func 1
6371 echo "$ac_t""no" 1>&6
6376 if test "$ac_cv_func_ctime_r" = no ; then
6377 ol_cv_func_ctime_r_nargs=0
6379 echo $ac_n "checking number of arguments of ctime_r""... $ac_c" 1>&6
6380 echo "configure:6381: checking number of arguments of ctime_r" >&5
6381 if eval "test \"\${ol_cv_func_ctime_r_nargs+set}\" = set"; then
6382 echo $ac_n "(cached) $ac_c" 1>&6
6384 cat > conftest.$ac_ext <<EOF
6385 #line 6386 "configure"
6386 #include "confdefs.h"
6389 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
6392 if { (eval echo configure:6393: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6394 ol_cv_func_ctime_r_nargs3=yes
6396 echo "configure: failed program was:" >&5
6397 cat conftest.$ac_ext >&5
6399 ol_cv_func_ctime_r_nargs3=no
6403 cat > conftest.$ac_ext <<EOF
6404 #line 6405 "configure"
6405 #include "confdefs.h"
6408 time_t ti; char *buffer; ctime_r(&ti,buffer);
6411 if { (eval echo configure:6412: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6413 ol_cv_func_ctime_r_nargs2=yes
6415 echo "configure: failed program was:" >&5
6416 cat conftest.$ac_ext >&5
6418 ol_cv_func_ctime_r_nargs2=no
6422 if test $ol_cv_func_ctime_r_nargs3 = yes -a \
6423 $ol_cv_func_ctime_r_nargs2 = no ; then
6425 ol_cv_func_ctime_r_nargs=3
6427 elif test $ol_cv_func_ctime_r_nargs3 = no -a \
6428 $ol_cv_func_ctime_r_nargs2 = yes ; then
6430 ol_cv_func_ctime_r_nargs=2
6433 ol_cv_func_ctime_r_nargs=0
6438 echo "$ac_t""$ol_cv_func_ctime_r_nargs" 1>&6
6440 if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
6441 cat >> confdefs.h <<EOF
6442 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
6449 if test "$ac_cv_func_gethostbyname_r" = yes ; then
6450 echo $ac_n "checking number of arguments of gethostbyname_r""... $ac_c" 1>&6
6451 echo "configure:6452: checking number of arguments of gethostbyname_r" >&5
6452 if eval "test \"\${ol_cv_func_gethostbyname_r_nargs+set}\" = set"; then
6453 echo $ac_n "(cached) $ac_c" 1>&6
6455 cat > conftest.$ac_ext <<EOF
6456 #line 6457 "configure"
6457 #include "confdefs.h"
6458 #include <sys/types.h>
6459 #include <sys/socket.h>
6460 #include <netinet/in.h>
6462 #define BUFSIZE (sizeof(struct hostent)+10)
6464 struct hostent hent; char buffer[BUFSIZE];
6465 int bufsize=BUFSIZE;int h_errno;
6466 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
6467 buffer, bufsize, &h_errno);
6470 if { (eval echo configure:6471: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6472 ol_cv_func_gethostbyname_r_nargs5=yes
6474 echo "configure: failed program was:" >&5
6475 cat conftest.$ac_ext >&5
6477 ol_cv_func_gethostbyname_r_nargs5=no
6481 cat > conftest.$ac_ext <<EOF
6482 #line 6483 "configure"
6483 #include "confdefs.h"
6484 #include <sys/types.h>
6485 #include <sys/socket.h>
6486 #include <netinet/in.h>
6488 #define BUFSIZE (sizeof(struct hostent)+10)
6490 struct hostent hent;struct hostent *rhent;
6491 char buffer[BUFSIZE];
6492 int bufsize=BUFSIZE;int h_errno;
6493 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
6497 if { (eval echo configure:6498: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6499 ol_cv_func_gethostbyname_r_nargs6=yes
6501 echo "configure: failed program was:" >&5
6502 cat conftest.$ac_ext >&5
6504 ol_cv_func_gethostbyname_r_nargs6=no
6508 if test $ol_cv_func_gethostbyname_r_nargs5 = yes -a \
6509 $ol_cv_func_gethostbyname_r_nargs6 = no ; then
6511 ol_cv_func_gethostbyname_r_nargs=5
6513 elif test $ol_cv_func_gethostbyname_r_nargs5 = no -a \
6514 $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
6516 ol_cv_func_gethostbyname_r_nargs=6
6519 ol_cv_func_gethostbyname_r_nargs=0
6524 echo "$ac_t""$ol_cv_func_gethostbyname_r_nargs" 1>&6
6525 if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
6526 cat >> confdefs.h <<EOF
6527 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
6533 ol_cv_func_gethostbyname_r_nargs=0
6536 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
6537 echo $ac_n "checking number of arguments of gethostbyaddr_r""... $ac_c" 1>&6
6538 echo "configure:6539: checking number of arguments of gethostbyaddr_r" >&5
6539 if eval "test \"\${ol_cv_func_gethostbyaddr_r_nargs+set}\" = set"; then
6540 echo $ac_n "(cached) $ac_c" 1>&6
6542 cat > conftest.$ac_ext <<EOF
6543 #line 6544 "configure"
6544 #include "confdefs.h"
6545 #include <sys/types.h>
6546 #include <sys/socket.h>
6547 #include <netinet/in.h>
6549 #define BUFSIZE (sizeof(struct hostent)+10)
6551 struct hostent hent; char buffer[BUFSIZE];
6553 size_t alen=sizeof(struct in_addr);
6554 int bufsize=BUFSIZE;int h_errno;
6555 (void)gethostbyaddr_r( (void *)&(add.s_addr),
6556 alen, AF_INET, &hent, buffer, bufsize, &h_errno);
6559 if { (eval echo configure:6560: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6561 ol_cv_func_gethostbyaddr_r_nargs7=yes
6563 echo "configure: failed program was:" >&5
6564 cat conftest.$ac_ext >&5
6566 ol_cv_func_gethostbyaddr_r_nargs7=no
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;
6580 struct hostent *rhent; char buffer[BUFSIZE];
6582 size_t alen=sizeof(struct in_addr);
6583 int bufsize=BUFSIZE;int h_errno;
6584 (void)gethostbyaddr_r( (void *)&(add.s_addr),
6585 alen, AF_INET, &hent, buffer, bufsize,
6589 if { (eval echo configure:6590: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6591 ol_cv_func_gethostbyaddr_r_nargs8=yes
6593 echo "configure: failed program was:" >&5
6594 cat conftest.$ac_ext >&5
6596 ol_cv_func_gethostbyaddr_r_nargs8=no
6600 if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes -a \
6601 $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
6603 ol_cv_func_gethostbyaddr_r_nargs=7
6605 elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no -a \
6606 $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
6608 ol_cv_func_gethostbyaddr_r_nargs=8
6611 ol_cv_func_gethostbyaddr_r_nargs=0
6616 echo "$ac_t""$ol_cv_func_gethostbyaddr_r_nargs" 1>&6
6617 if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
6618 cat >> confdefs.h <<EOF
6619 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
6625 ol_cv_func_gethostbyaddr_r_nargs=0
6628 if test "$ac_cv_func_ctime_r" = yes \
6629 -a "$ol_cv_func_ctime_r_nargs" -ge 2 \
6630 -a "$ol_cv_func_ctime_r_nargs" -le 3 \
6631 -a "$ac_cv_func_gethostbyname_r" = yes \
6632 -a "$ol_cv_func_gethostbyname_r_nargs" -ge 5 \
6633 -a "$ol_cv_func_gethostbyname_r_nargs" -le 6 \
6634 -a "$ac_cv_func_gethostbyaddr_r" = yes \
6635 -a "$ol_cv_func_gethostbyaddr_r_nargs" -ge 5 \
6636 -a "$ol_cv_func_gethostbyaddr_r_nargs" -le 6 \
6639 cat >> confdefs.h <<\EOF
6640 #define LDAP_API_FEATURE_X_OPENLDAP_REENTRANT 1
6647 if test $ol_with_threads = auto -o $ol_with_threads = yes \
6648 -o $ol_with_threads = nt ; then
6651 echo $ac_n "checking for NT Threads""... $ac_c" 1>&6
6652 echo "configure:6653: checking for NT Threads" >&5
6653 if eval "test \"\${ol_cv_nt_threads+set}\" = set"; then
6654 echo $ac_n "(cached) $ac_c" 1>&6
6657 echo $ac_n "checking for _beginthread""... $ac_c" 1>&6
6658 echo "configure:6659: checking for _beginthread" >&5
6659 if eval "test \"\${ac_cv_func__beginthread+set}\" = set"; then
6660 echo $ac_n "(cached) $ac_c" 1>&6
6662 cat > conftest.$ac_ext <<EOF
6663 #line 6664 "configure"
6664 #include "confdefs.h"
6665 /* System header to define __stub macros and hopefully few prototypes,
6666 which can conflict with char _beginthread(); below. */
6668 /* Override any gcc2 internal prototype to avoid an error. */
6669 /* We use char because int might match the return type of a gcc2
6670 builtin and then its argument prototype would still apply. */
6671 char _beginthread();
6676 /* The GNU C library defines this for functions which it implements
6677 to always fail with ENOSYS. Some functions are actually named
6678 something starting with __ and the normal name is an alias. */
6679 #if defined (__stub__beginthread) || defined (__stub____beginthread)
6687 if { (eval echo configure:6688: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6689 eval "ac_cv_func__beginthread=yes"
6691 echo "configure: failed program was:" >&5
6692 cat conftest.$ac_ext >&5
6694 eval "ac_cv_func__beginthread=no"
6699 if eval "test \"`echo '$ac_cv_func_'_beginthread`\" = yes"; then
6700 echo "$ac_t""yes" 1>&6
6701 ol_cv_nt_threads=yes
6703 echo "$ac_t""no" 1>&6
6710 echo "$ac_t""$ol_cv_nt_threads" 1>&6
6712 if test $ol_cv_nt_threads = yes ; then
6713 cat >> confdefs.h <<\EOF
6714 #define HAVE_NT_THREADS 1
6720 if test "$ol_cv_nt_threads" = yes ; then
6722 ol_with_threads=found
6723 ol_with_yielding_select=yes
6725 cat >> confdefs.h <<\EOF
6726 #define HAVE_NT_SERVICE_MANAGER 1
6729 cat >> confdefs.h <<\EOF
6730 #define HAVE_NT_EVENT_LOG 1
6735 if test $ol_with_threads = nt ; then
6736 { echo "configure: error: could not locate NT Threads" 1>&2; exit 1; }
6740 if test $ol_with_threads = auto -o $ol_with_threads = yes \
6741 -o $ol_with_threads = posix ; then
6743 for ac_hdr in pthread.h
6745 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6746 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6747 echo "configure:6748: checking for $ac_hdr" >&5
6748 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6749 echo $ac_n "(cached) $ac_c" 1>&6
6751 cat > conftest.$ac_ext <<EOF
6752 #line 6753 "configure"
6753 #include "confdefs.h"
6756 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6757 { (eval echo configure:6758: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6758 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6759 if test -z "$ac_err"; then
6761 eval "ac_cv_header_$ac_safe=yes"
6764 echo "configure: failed program was:" >&5
6765 cat conftest.$ac_ext >&5
6767 eval "ac_cv_header_$ac_safe=no"
6771 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6772 echo "$ac_t""yes" 1>&6
6773 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6774 cat >> confdefs.h <<EOF
6775 #define $ac_tr_hdr 1
6779 echo "$ac_t""no" 1>&6
6784 if test $ac_cv_header_pthread_h = yes ; then
6785 echo $ac_n "checking POSIX thread version""... $ac_c" 1>&6
6786 echo "configure:6787: checking POSIX thread version" >&5
6787 if eval "test \"\${ol_cv_pthread_version+set}\" = set"; then
6788 echo $ac_n "(cached) $ac_c" 1>&6
6791 cat > conftest.$ac_ext <<EOF
6792 #line 6793 "configure"
6793 #include "confdefs.h"
6795 # include <pthread.h>
6796 /* this check could be improved */
6797 # ifdef PTHREAD_ONCE_INIT
6798 pthread_version_final;
6802 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6803 egrep "pthread_version_final" >/dev/null 2>&1; then
6805 ol_pthread_final=yes
6813 cat > conftest.$ac_ext <<EOF
6814 #line 6815 "configure"
6815 #include "confdefs.h"
6817 # include <pthread.h>
6818 /* this check could be improved */
6819 # ifdef pthread_once_init
6820 pthread_version_draft4;
6824 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6825 egrep "pthread_version_draft4" >/dev/null 2>&1; then
6827 ol_pthread_draft4=yes
6830 ol_pthread_draft4=no
6835 if test $ol_pthread_final = yes -a $ol_pthread_draft4 = no; then
6836 ol_cv_pthread_version=final
6837 elif test $ol_pthread_final = no -a $ol_pthread_draft4 = yes; then
6838 ol_cv_pthread_version=draft4
6840 ol_cv_pthread_version=unknown
6845 echo "$ac_t""$ol_cv_pthread_version" 1>&6
6848 if test $ol_cv_pthread_version = final ; then
6849 cat >> confdefs.h <<\EOF
6850 #define HAVE_PTHREADS_FINAL 1
6853 elif test $ol_cv_pthread_version = draft4 ; then
6854 cat >> confdefs.h <<\EOF
6855 #define HAVE_PTHREADS_D4 1
6859 { echo "configure: error: unknown pthread version" 1>&2; exit 1; }
6862 # consider threads found
6863 ol_with_threads=found
6866 echo $ac_n "checking for LinuxThreads pthread.h""... $ac_c" 1>&6
6867 echo "configure:6868: checking for LinuxThreads pthread.h" >&5
6868 if eval "test \"\${ol_cv_header_linux_threads+set}\" = set"; then
6869 echo $ac_n "(cached) $ac_c" 1>&6
6871 cat > conftest.$ac_ext <<EOF
6872 #line 6873 "configure"
6873 #include "confdefs.h"
6874 #include <pthread.h>
6876 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6877 egrep "pthread_kill_other_threads_np" >/dev/null 2>&1; then
6879 ol_cv_header_linux_threads=yes
6882 ol_cv_header_linux_threads=no
6889 echo "$ac_t""$ol_cv_header_linux_threads" 1>&6
6890 if test $ol_cv_header_linux_threads = yes; then
6891 cat >> confdefs.h <<\EOF
6892 #define HAVE_LINUX_THREADS 1
6898 echo $ac_n "checking for GNU Pth pthread.h""... $ac_c" 1>&6
6899 echo "configure:6900: checking for GNU Pth pthread.h" >&5
6900 if eval "test \"\${ol_cv_header_gnu_pth_pthread_h+set}\" = set"; then
6901 echo $ac_n "(cached) $ac_c" 1>&6
6903 cat > conftest.$ac_ext <<EOF
6904 #line 6905 "configure"
6905 #include "confdefs.h"
6906 #include <pthread.h>
6907 #ifdef _POSIX_THREAD_IS_GNU_PTH
6912 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6913 egrep "__gnu_pth__" >/dev/null 2>&1; then
6915 ol_cv_header_gnu_pth_pthread_h=yes
6918 ol_cv_header_gnu_pth_pthread_h=no
6925 echo "$ac_t""$ol_cv_header_gnu_pth_pthread_h" 1>&6
6928 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
6929 for ac_hdr in sched.h
6931 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6932 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6933 echo "configure:6934: checking for $ac_hdr" >&5
6934 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
6935 echo $ac_n "(cached) $ac_c" 1>&6
6937 cat > conftest.$ac_ext <<EOF
6938 #line 6939 "configure"
6939 #include "confdefs.h"
6942 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6943 { (eval echo configure:6944: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6944 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6945 if test -z "$ac_err"; then
6947 eval "ac_cv_header_$ac_safe=yes"
6950 echo "configure: failed program was:" >&5
6951 cat conftest.$ac_ext >&5
6953 eval "ac_cv_header_$ac_safe=no"
6957 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6958 echo "$ac_t""yes" 1>&6
6959 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6960 cat >> confdefs.h <<EOF
6961 #define $ac_tr_hdr 1
6965 echo "$ac_t""no" 1>&6
6972 echo $ac_n "checking for pthread_create in default libraries""... $ac_c" 1>&6
6973 echo "configure:6974: checking for pthread_create in default libraries" >&5
6974 if eval "test \"\${ol_cv_pthread_create+set}\" = set"; then
6975 echo $ac_n "(cached) $ac_c" 1>&6
6978 if test "$cross_compiling" = yes; then
6979 cat > conftest.$ac_ext <<EOF
6980 #line 6981 "configure"
6981 #include "confdefs.h"
6982 /* pthread test headers */
6983 #include <pthread.h>
6985 #define NULL (void*)0
6988 static void *task(p)
6991 return (void *) (p == NULL);
6996 /* pthread test function */
6999 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7000 /* This system (e.g. AIX) defaults detached; must override */
7001 pthread_attr_t attr;
7003 status = pthread_attr_init(&attr);
7004 if( status ) exit( status );
7006 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7007 if( status ) exit( status );
7011 #if HAVE_PTHREADS_D4
7012 #define ATTR pthread_attr_default
7017 /* make sure pthread_create() isn't just a stub */
7018 status = pthread_create(&t, ATTR, task, NULL);
7019 if( status ) exit( status );
7021 /* make sure pthread_detach() isn't just a stub */
7022 #if HAVE_PTHREADS_D4
7023 status = pthread_detach( &t );
7025 status = pthread_detach( t );
7028 #ifdef HAVE_LINUX_THREADS
7029 pthread_kill_other_threads_np();
7036 if { (eval echo configure:7037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7038 ol_cv_pthread_create=yes
7040 echo "configure: failed program was:" >&5
7041 cat conftest.$ac_ext >&5
7043 ol_cv_pthread_create=no
7047 cat > conftest.$ac_ext <<EOF
7048 #line 7049 "configure"
7049 #include "confdefs.h"
7050 /* pthread test headers */
7051 #include <pthread.h>
7053 #define NULL (void*)0
7056 static void *task(p)
7059 return (void *) (p == NULL);
7063 int main(argc, argv)
7068 /* pthread test function */
7071 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7072 /* This system (e.g. AIX) defaults detached; must override */
7073 pthread_attr_t attr;
7075 status = pthread_attr_init(&attr);
7076 if( status ) exit( status );
7078 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7079 if( status ) exit( status );
7083 #if HAVE_PTHREADS_D4
7084 #define ATTR pthread_attr_default
7089 /* make sure pthread_create() isn't just a stub */
7090 status = pthread_create(&t, ATTR, task, NULL);
7091 if( status ) exit( status );
7093 /* make sure pthread_detach() isn't just a stub */
7094 #if HAVE_PTHREADS_D4
7095 status = pthread_detach( &t );
7097 status = pthread_detach( t );
7100 #ifdef HAVE_LINUX_THREADS
7101 pthread_kill_other_threads_np();
7109 if { (eval echo configure:7110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7111 ol_cv_pthread_create=yes
7113 echo "configure: failed program was:" >&5
7114 cat conftest.$ac_ext >&5
7116 ol_cv_pthread_create=no
7123 echo "$ac_t""$ol_cv_pthread_create" 1>&6
7125 if test $ol_cv_pthread_create != no ; then
7126 ol_link_threads=posix
7130 # Pthread try link: -kthread (ol_cv_pthread_kthread)
7131 if test "$ol_link_threads" = no ; then
7133 echo $ac_n "checking for pthread link with -kthread""... $ac_c" 1>&6
7134 echo "configure:7135: checking for pthread link with -kthread" >&5
7135 if eval "test \"\${ol_cv_pthread_kthread+set}\" = set"; then
7136 echo $ac_n "(cached) $ac_c" 1>&6
7141 LIBS="-kthread $LIBS"
7143 if test "$cross_compiling" = yes; then
7144 cat > conftest.$ac_ext <<EOF
7145 #line 7146 "configure"
7146 #include "confdefs.h"
7147 /* pthread test headers */
7148 #include <pthread.h>
7150 #define NULL (void*)0
7153 static void *task(p)
7156 return (void *) (p == NULL);
7161 /* pthread test function */
7164 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7165 /* This system (e.g. AIX) defaults detached; must override */
7166 pthread_attr_t attr;
7168 status = pthread_attr_init(&attr);
7169 if( status ) exit( status );
7171 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7172 if( status ) exit( status );
7176 #if HAVE_PTHREADS_D4
7177 #define ATTR pthread_attr_default
7182 /* make sure pthread_create() isn't just a stub */
7183 status = pthread_create(&t, ATTR, task, NULL);
7184 if( status ) exit( status );
7186 /* make sure pthread_detach() isn't just a stub */
7187 #if HAVE_PTHREADS_D4
7188 status = pthread_detach( &t );
7190 status = pthread_detach( t );
7193 #ifdef HAVE_LINUX_THREADS
7194 pthread_kill_other_threads_np();
7201 if { (eval echo configure:7202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7203 ol_cv_pthread_kthread=yes
7205 echo "configure: failed program was:" >&5
7206 cat conftest.$ac_ext >&5
7208 ol_cv_pthread_kthread=no
7212 cat > conftest.$ac_ext <<EOF
7213 #line 7214 "configure"
7214 #include "confdefs.h"
7215 /* pthread test headers */
7216 #include <pthread.h>
7218 #define NULL (void*)0
7221 static void *task(p)
7224 return (void *) (p == NULL);
7228 int main(argc, argv)
7233 /* pthread test function */
7236 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7237 /* This system (e.g. AIX) defaults detached; must override */
7238 pthread_attr_t attr;
7240 status = pthread_attr_init(&attr);
7241 if( status ) exit( status );
7243 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7244 if( status ) exit( status );
7248 #if HAVE_PTHREADS_D4
7249 #define ATTR pthread_attr_default
7254 /* make sure pthread_create() isn't just a stub */
7255 status = pthread_create(&t, ATTR, task, NULL);
7256 if( status ) exit( status );
7258 /* make sure pthread_detach() isn't just a stub */
7259 #if HAVE_PTHREADS_D4
7260 status = pthread_detach( &t );
7262 status = pthread_detach( t );
7265 #ifdef HAVE_LINUX_THREADS
7266 pthread_kill_other_threads_np();
7274 if { (eval echo configure:7275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7276 ol_cv_pthread_kthread=yes
7278 echo "configure: failed program was:" >&5
7279 cat conftest.$ac_ext >&5
7281 ol_cv_pthread_kthread=no
7292 echo "$ac_t""$ol_cv_pthread_kthread" 1>&6
7294 if test $ol_cv_pthread_kthread = yes ; then
7295 ol_link_pthreads="-kthread"
7296 ol_link_threads=posix
7300 # Pthread try link: -pthread (ol_cv_pthread_pthread)
7301 if test "$ol_link_threads" = no ; then
7303 echo $ac_n "checking for pthread link with -pthread""... $ac_c" 1>&6
7304 echo "configure:7305: checking for pthread link with -pthread" >&5
7305 if eval "test \"\${ol_cv_pthread_pthread+set}\" = set"; then
7306 echo $ac_n "(cached) $ac_c" 1>&6
7311 LIBS="-pthread $LIBS"
7313 if test "$cross_compiling" = yes; then
7314 cat > conftest.$ac_ext <<EOF
7315 #line 7316 "configure"
7316 #include "confdefs.h"
7317 /* pthread test headers */
7318 #include <pthread.h>
7320 #define NULL (void*)0
7323 static void *task(p)
7326 return (void *) (p == NULL);
7331 /* pthread test function */
7334 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7335 /* This system (e.g. AIX) defaults detached; must override */
7336 pthread_attr_t attr;
7338 status = pthread_attr_init(&attr);
7339 if( status ) exit( status );
7341 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7342 if( status ) exit( status );
7346 #if HAVE_PTHREADS_D4
7347 #define ATTR pthread_attr_default
7352 /* make sure pthread_create() isn't just a stub */
7353 status = pthread_create(&t, ATTR, task, NULL);
7354 if( status ) exit( status );
7356 /* make sure pthread_detach() isn't just a stub */
7357 #if HAVE_PTHREADS_D4
7358 status = pthread_detach( &t );
7360 status = pthread_detach( t );
7363 #ifdef HAVE_LINUX_THREADS
7364 pthread_kill_other_threads_np();
7371 if { (eval echo configure:7372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7373 ol_cv_pthread_pthread=yes
7375 echo "configure: failed program was:" >&5
7376 cat conftest.$ac_ext >&5
7378 ol_cv_pthread_pthread=no
7382 cat > conftest.$ac_ext <<EOF
7383 #line 7384 "configure"
7384 #include "confdefs.h"
7385 /* pthread test headers */
7386 #include <pthread.h>
7388 #define NULL (void*)0
7391 static void *task(p)
7394 return (void *) (p == NULL);
7398 int main(argc, argv)
7403 /* pthread test function */
7406 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7407 /* This system (e.g. AIX) defaults detached; must override */
7408 pthread_attr_t attr;
7410 status = pthread_attr_init(&attr);
7411 if( status ) exit( status );
7413 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7414 if( status ) exit( status );
7418 #if HAVE_PTHREADS_D4
7419 #define ATTR pthread_attr_default
7424 /* make sure pthread_create() isn't just a stub */
7425 status = pthread_create(&t, ATTR, task, NULL);
7426 if( status ) exit( status );
7428 /* make sure pthread_detach() isn't just a stub */
7429 #if HAVE_PTHREADS_D4
7430 status = pthread_detach( &t );
7432 status = pthread_detach( t );
7435 #ifdef HAVE_LINUX_THREADS
7436 pthread_kill_other_threads_np();
7444 if { (eval echo configure:7445: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7446 ol_cv_pthread_pthread=yes
7448 echo "configure: failed program was:" >&5
7449 cat conftest.$ac_ext >&5
7451 ol_cv_pthread_pthread=no
7462 echo "$ac_t""$ol_cv_pthread_pthread" 1>&6
7464 if test $ol_cv_pthread_pthread = yes ; then
7465 ol_link_pthreads="-pthread"
7466 ol_link_threads=posix
7470 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
7471 if test "$ol_link_threads" = no ; then
7473 echo $ac_n "checking for pthread link with -pthreads""... $ac_c" 1>&6
7474 echo "configure:7475: checking for pthread link with -pthreads" >&5
7475 if eval "test \"\${ol_cv_pthread_pthreads+set}\" = set"; then
7476 echo $ac_n "(cached) $ac_c" 1>&6
7481 LIBS="-pthreads $LIBS"
7483 if test "$cross_compiling" = yes; then
7484 cat > conftest.$ac_ext <<EOF
7485 #line 7486 "configure"
7486 #include "confdefs.h"
7487 /* pthread test headers */
7488 #include <pthread.h>
7490 #define NULL (void*)0
7493 static void *task(p)
7496 return (void *) (p == NULL);
7501 /* pthread test function */
7504 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7505 /* This system (e.g. AIX) defaults detached; must override */
7506 pthread_attr_t attr;
7508 status = pthread_attr_init(&attr);
7509 if( status ) exit( status );
7511 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7512 if( status ) exit( status );
7516 #if HAVE_PTHREADS_D4
7517 #define ATTR pthread_attr_default
7522 /* make sure pthread_create() isn't just a stub */
7523 status = pthread_create(&t, ATTR, task, NULL);
7524 if( status ) exit( status );
7526 /* make sure pthread_detach() isn't just a stub */
7527 #if HAVE_PTHREADS_D4
7528 status = pthread_detach( &t );
7530 status = pthread_detach( t );
7533 #ifdef HAVE_LINUX_THREADS
7534 pthread_kill_other_threads_np();
7541 if { (eval echo configure:7542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7543 ol_cv_pthread_pthreads=yes
7545 echo "configure: failed program was:" >&5
7546 cat conftest.$ac_ext >&5
7548 ol_cv_pthread_pthreads=no
7552 cat > conftest.$ac_ext <<EOF
7553 #line 7554 "configure"
7554 #include "confdefs.h"
7555 /* pthread test headers */
7556 #include <pthread.h>
7558 #define NULL (void*)0
7561 static void *task(p)
7564 return (void *) (p == NULL);
7568 int main(argc, argv)
7573 /* pthread test function */
7576 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7577 /* This system (e.g. AIX) defaults detached; must override */
7578 pthread_attr_t attr;
7580 status = pthread_attr_init(&attr);
7581 if( status ) exit( status );
7583 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7584 if( status ) exit( status );
7588 #if HAVE_PTHREADS_D4
7589 #define ATTR pthread_attr_default
7594 /* make sure pthread_create() isn't just a stub */
7595 status = pthread_create(&t, ATTR, task, NULL);
7596 if( status ) exit( status );
7598 /* make sure pthread_detach() isn't just a stub */
7599 #if HAVE_PTHREADS_D4
7600 status = pthread_detach( &t );
7602 status = pthread_detach( t );
7605 #ifdef HAVE_LINUX_THREADS
7606 pthread_kill_other_threads_np();
7614 if { (eval echo configure:7615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7616 ol_cv_pthread_pthreads=yes
7618 echo "configure: failed program was:" >&5
7619 cat conftest.$ac_ext >&5
7621 ol_cv_pthread_pthreads=no
7632 echo "$ac_t""$ol_cv_pthread_pthreads" 1>&6
7634 if test $ol_cv_pthread_pthreads = yes ; then
7635 ol_link_pthreads="-pthreads"
7636 ol_link_threads=posix
7640 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
7641 if test "$ol_link_threads" = no ; then
7643 echo $ac_n "checking for pthread link with -mthreads""... $ac_c" 1>&6
7644 echo "configure:7645: checking for pthread link with -mthreads" >&5
7645 if eval "test \"\${ol_cv_pthread_mthreads+set}\" = set"; then
7646 echo $ac_n "(cached) $ac_c" 1>&6
7651 LIBS="-mthreads $LIBS"
7653 if test "$cross_compiling" = yes; then
7654 cat > conftest.$ac_ext <<EOF
7655 #line 7656 "configure"
7656 #include "confdefs.h"
7657 /* pthread test headers */
7658 #include <pthread.h>
7660 #define NULL (void*)0
7663 static void *task(p)
7666 return (void *) (p == NULL);
7671 /* pthread test function */
7674 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7675 /* This system (e.g. AIX) defaults detached; must override */
7676 pthread_attr_t attr;
7678 status = pthread_attr_init(&attr);
7679 if( status ) exit( status );
7681 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7682 if( status ) exit( status );
7686 #if HAVE_PTHREADS_D4
7687 #define ATTR pthread_attr_default
7692 /* make sure pthread_create() isn't just a stub */
7693 status = pthread_create(&t, ATTR, task, NULL);
7694 if( status ) exit( status );
7696 /* make sure pthread_detach() isn't just a stub */
7697 #if HAVE_PTHREADS_D4
7698 status = pthread_detach( &t );
7700 status = pthread_detach( t );
7703 #ifdef HAVE_LINUX_THREADS
7704 pthread_kill_other_threads_np();
7711 if { (eval echo configure:7712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7713 ol_cv_pthread_mthreads=yes
7715 echo "configure: failed program was:" >&5
7716 cat conftest.$ac_ext >&5
7718 ol_cv_pthread_mthreads=no
7722 cat > conftest.$ac_ext <<EOF
7723 #line 7724 "configure"
7724 #include "confdefs.h"
7725 /* pthread test headers */
7726 #include <pthread.h>
7728 #define NULL (void*)0
7731 static void *task(p)
7734 return (void *) (p == NULL);
7738 int main(argc, argv)
7743 /* pthread test function */
7746 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7747 /* This system (e.g. AIX) defaults detached; must override */
7748 pthread_attr_t attr;
7750 status = pthread_attr_init(&attr);
7751 if( status ) exit( status );
7753 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7754 if( status ) exit( status );
7758 #if HAVE_PTHREADS_D4
7759 #define ATTR pthread_attr_default
7764 /* make sure pthread_create() isn't just a stub */
7765 status = pthread_create(&t, ATTR, task, NULL);
7766 if( status ) exit( status );
7768 /* make sure pthread_detach() isn't just a stub */
7769 #if HAVE_PTHREADS_D4
7770 status = pthread_detach( &t );
7772 status = pthread_detach( t );
7775 #ifdef HAVE_LINUX_THREADS
7776 pthread_kill_other_threads_np();
7784 if { (eval echo configure:7785: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7786 ol_cv_pthread_mthreads=yes
7788 echo "configure: failed program was:" >&5
7789 cat conftest.$ac_ext >&5
7791 ol_cv_pthread_mthreads=no
7802 echo "$ac_t""$ol_cv_pthread_mthreads" 1>&6
7804 if test $ol_cv_pthread_mthreads = yes ; then
7805 ol_link_pthreads="-mthreads"
7806 ol_link_threads=posix
7810 # Pthread try link: -thread (ol_cv_pthread_thread)
7811 if test "$ol_link_threads" = no ; then
7813 echo $ac_n "checking for pthread link with -thread""... $ac_c" 1>&6
7814 echo "configure:7815: checking for pthread link with -thread" >&5
7815 if eval "test \"\${ol_cv_pthread_thread+set}\" = set"; then
7816 echo $ac_n "(cached) $ac_c" 1>&6
7821 LIBS="-thread $LIBS"
7823 if test "$cross_compiling" = yes; then
7824 cat > conftest.$ac_ext <<EOF
7825 #line 7826 "configure"
7826 #include "confdefs.h"
7827 /* pthread test headers */
7828 #include <pthread.h>
7830 #define NULL (void*)0
7833 static void *task(p)
7836 return (void *) (p == NULL);
7841 /* pthread test function */
7844 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7845 /* This system (e.g. AIX) defaults detached; must override */
7846 pthread_attr_t attr;
7848 status = pthread_attr_init(&attr);
7849 if( status ) exit( status );
7851 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7852 if( status ) exit( status );
7856 #if HAVE_PTHREADS_D4
7857 #define ATTR pthread_attr_default
7862 /* make sure pthread_create() isn't just a stub */
7863 status = pthread_create(&t, ATTR, task, NULL);
7864 if( status ) exit( status );
7866 /* make sure pthread_detach() isn't just a stub */
7867 #if HAVE_PTHREADS_D4
7868 status = pthread_detach( &t );
7870 status = pthread_detach( t );
7873 #ifdef HAVE_LINUX_THREADS
7874 pthread_kill_other_threads_np();
7881 if { (eval echo configure:7882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7883 ol_cv_pthread_thread=yes
7885 echo "configure: failed program was:" >&5
7886 cat conftest.$ac_ext >&5
7888 ol_cv_pthread_thread=no
7892 cat > conftest.$ac_ext <<EOF
7893 #line 7894 "configure"
7894 #include "confdefs.h"
7895 /* pthread test headers */
7896 #include <pthread.h>
7898 #define NULL (void*)0
7901 static void *task(p)
7904 return (void *) (p == NULL);
7908 int main(argc, argv)
7913 /* pthread test function */
7916 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
7917 /* This system (e.g. AIX) defaults detached; must override */
7918 pthread_attr_t attr;
7920 status = pthread_attr_init(&attr);
7921 if( status ) exit( status );
7923 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
7924 if( status ) exit( status );
7928 #if HAVE_PTHREADS_D4
7929 #define ATTR pthread_attr_default
7934 /* make sure pthread_create() isn't just a stub */
7935 status = pthread_create(&t, ATTR, task, NULL);
7936 if( status ) exit( status );
7938 /* make sure pthread_detach() isn't just a stub */
7939 #if HAVE_PTHREADS_D4
7940 status = pthread_detach( &t );
7942 status = pthread_detach( t );
7945 #ifdef HAVE_LINUX_THREADS
7946 pthread_kill_other_threads_np();
7954 if { (eval echo configure:7955: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7956 ol_cv_pthread_thread=yes
7958 echo "configure: failed program was:" >&5
7959 cat conftest.$ac_ext >&5
7961 ol_cv_pthread_thread=no
7972 echo "$ac_t""$ol_cv_pthread_thread" 1>&6
7974 if test $ol_cv_pthread_thread = yes ; then
7975 ol_link_pthreads="-thread"
7976 ol_link_threads=posix
7981 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
7982 if test "$ol_link_threads" = no ; then
7983 # try -lpthread -lmach -lexc -lc_r
7984 echo $ac_n "checking for pthread link with -lpthread -lmach -lexc -lc_r""... $ac_c" 1>&6
7985 echo "configure:7986: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
7986 if eval "test \"\${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}\" = set"; then
7987 echo $ac_n "(cached) $ac_c" 1>&6
7992 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
7994 if test "$cross_compiling" = yes; then
7995 cat > conftest.$ac_ext <<EOF
7996 #line 7997 "configure"
7997 #include "confdefs.h"
7998 /* pthread test headers */
7999 #include <pthread.h>
8001 #define NULL (void*)0
8004 static void *task(p)
8007 return (void *) (p == NULL);
8012 /* pthread test function */
8015 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8016 /* This system (e.g. AIX) defaults detached; must override */
8017 pthread_attr_t attr;
8019 status = pthread_attr_init(&attr);
8020 if( status ) exit( status );
8022 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8023 if( status ) exit( status );
8027 #if HAVE_PTHREADS_D4
8028 #define ATTR pthread_attr_default
8033 /* make sure pthread_create() isn't just a stub */
8034 status = pthread_create(&t, ATTR, task, NULL);
8035 if( status ) exit( status );
8037 /* make sure pthread_detach() isn't just a stub */
8038 #if HAVE_PTHREADS_D4
8039 status = pthread_detach( &t );
8041 status = pthread_detach( t );
8044 #ifdef HAVE_LINUX_THREADS
8045 pthread_kill_other_threads_np();
8052 if { (eval echo configure:8053: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8054 ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
8056 echo "configure: failed program was:" >&5
8057 cat conftest.$ac_ext >&5
8059 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
8063 cat > conftest.$ac_ext <<EOF
8064 #line 8065 "configure"
8065 #include "confdefs.h"
8066 /* pthread test headers */
8067 #include <pthread.h>
8069 #define NULL (void*)0
8072 static void *task(p)
8075 return (void *) (p == NULL);
8079 int main(argc, argv)
8084 /* pthread test function */
8087 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8088 /* This system (e.g. AIX) defaults detached; must override */
8089 pthread_attr_t attr;
8091 status = pthread_attr_init(&attr);
8092 if( status ) exit( status );
8094 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8095 if( status ) exit( status );
8099 #if HAVE_PTHREADS_D4
8100 #define ATTR pthread_attr_default
8105 /* make sure pthread_create() isn't just a stub */
8106 status = pthread_create(&t, ATTR, task, NULL);
8107 if( status ) exit( status );
8109 /* make sure pthread_detach() isn't just a stub */
8110 #if HAVE_PTHREADS_D4
8111 status = pthread_detach( &t );
8113 status = pthread_detach( t );
8116 #ifdef HAVE_LINUX_THREADS
8117 pthread_kill_other_threads_np();
8125 if { (eval echo configure:8126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8127 ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
8129 echo "configure: failed program was:" >&5
8130 cat conftest.$ac_ext >&5
8132 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
8143 echo "$ac_t""$ol_cv_pthread_lpthread_lmach_lexc_lc_r" 1>&6
8145 if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
8146 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
8147 ol_link_threads=posix
8151 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
8152 if test "$ol_link_threads" = no ; then
8153 # try -lpthread -lmach -lexc
8154 echo $ac_n "checking for pthread link with -lpthread -lmach -lexc""... $ac_c" 1>&6
8155 echo "configure:8156: checking for pthread link with -lpthread -lmach -lexc" >&5
8156 if eval "test \"\${ol_cv_pthread_lpthread_lmach_lexc+set}\" = set"; then
8157 echo $ac_n "(cached) $ac_c" 1>&6
8162 LIBS="-lpthread -lmach -lexc $LIBS"
8164 if test "$cross_compiling" = yes; then
8165 cat > conftest.$ac_ext <<EOF
8166 #line 8167 "configure"
8167 #include "confdefs.h"
8168 /* pthread test headers */
8169 #include <pthread.h>
8171 #define NULL (void*)0
8174 static void *task(p)
8177 return (void *) (p == NULL);
8182 /* pthread test function */
8185 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8186 /* This system (e.g. AIX) defaults detached; must override */
8187 pthread_attr_t attr;
8189 status = pthread_attr_init(&attr);
8190 if( status ) exit( status );
8192 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8193 if( status ) exit( status );
8197 #if HAVE_PTHREADS_D4
8198 #define ATTR pthread_attr_default
8203 /* make sure pthread_create() isn't just a stub */
8204 status = pthread_create(&t, ATTR, task, NULL);
8205 if( status ) exit( status );
8207 /* make sure pthread_detach() isn't just a stub */
8208 #if HAVE_PTHREADS_D4
8209 status = pthread_detach( &t );
8211 status = pthread_detach( t );
8214 #ifdef HAVE_LINUX_THREADS
8215 pthread_kill_other_threads_np();
8222 if { (eval echo configure:8223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8224 ol_cv_pthread_lpthread_lmach_lexc=yes
8226 echo "configure: failed program was:" >&5
8227 cat conftest.$ac_ext >&5
8229 ol_cv_pthread_lpthread_lmach_lexc=no
8233 cat > conftest.$ac_ext <<EOF
8234 #line 8235 "configure"
8235 #include "confdefs.h"
8236 /* pthread test headers */
8237 #include <pthread.h>
8239 #define NULL (void*)0
8242 static void *task(p)
8245 return (void *) (p == NULL);
8249 int main(argc, argv)
8254 /* pthread test function */
8257 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8258 /* This system (e.g. AIX) defaults detached; must override */
8259 pthread_attr_t attr;
8261 status = pthread_attr_init(&attr);
8262 if( status ) exit( status );
8264 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8265 if( status ) exit( status );
8269 #if HAVE_PTHREADS_D4
8270 #define ATTR pthread_attr_default
8275 /* make sure pthread_create() isn't just a stub */
8276 status = pthread_create(&t, ATTR, task, NULL);
8277 if( status ) exit( status );
8279 /* make sure pthread_detach() isn't just a stub */
8280 #if HAVE_PTHREADS_D4
8281 status = pthread_detach( &t );
8283 status = pthread_detach( t );
8286 #ifdef HAVE_LINUX_THREADS
8287 pthread_kill_other_threads_np();
8295 if { (eval echo configure:8296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8297 ol_cv_pthread_lpthread_lmach_lexc=yes
8299 echo "configure: failed program was:" >&5
8300 cat conftest.$ac_ext >&5
8302 ol_cv_pthread_lpthread_lmach_lexc=no
8313 echo "$ac_t""$ol_cv_pthread_lpthread_lmach_lexc" 1>&6
8315 if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
8316 ol_link_pthreads="-lpthread -lmach -lexc"
8317 ol_link_threads=posix
8322 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
8323 if test "$ol_link_threads" = no ; then
8324 # try -lpthread -Wl,-woff,85
8325 echo $ac_n "checking for pthread link with -lpthread -Wl,-woff,85""... $ac_c" 1>&6
8326 echo "configure:8327: checking for pthread link with -lpthread -Wl,-woff,85" >&5
8327 if eval "test \"\${ol_cv_pthread_lib_lpthread_woff+set}\" = set"; then
8328 echo $ac_n "(cached) $ac_c" 1>&6
8333 LIBS="-lpthread -Wl,-woff,85 $LIBS"
8335 if test "$cross_compiling" = yes; then
8336 cat > conftest.$ac_ext <<EOF
8337 #line 8338 "configure"
8338 #include "confdefs.h"
8339 /* pthread test headers */
8340 #include <pthread.h>
8342 #define NULL (void*)0
8345 static void *task(p)
8348 return (void *) (p == NULL);
8353 /* pthread test function */
8356 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8357 /* This system (e.g. AIX) defaults detached; must override */
8358 pthread_attr_t attr;
8360 status = pthread_attr_init(&attr);
8361 if( status ) exit( status );
8363 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8364 if( status ) exit( status );
8368 #if HAVE_PTHREADS_D4
8369 #define ATTR pthread_attr_default
8374 /* make sure pthread_create() isn't just a stub */
8375 status = pthread_create(&t, ATTR, task, NULL);
8376 if( status ) exit( status );
8378 /* make sure pthread_detach() isn't just a stub */
8379 #if HAVE_PTHREADS_D4
8380 status = pthread_detach( &t );
8382 status = pthread_detach( t );
8385 #ifdef HAVE_LINUX_THREADS
8386 pthread_kill_other_threads_np();
8393 if { (eval echo configure:8394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8395 ol_cv_pthread_lib_lpthread_woff=yes
8397 echo "configure: failed program was:" >&5
8398 cat conftest.$ac_ext >&5
8400 ol_cv_pthread_lib_lpthread_woff=no
8404 cat > conftest.$ac_ext <<EOF
8405 #line 8406 "configure"
8406 #include "confdefs.h"
8407 /* pthread test headers */
8408 #include <pthread.h>
8410 #define NULL (void*)0
8413 static void *task(p)
8416 return (void *) (p == NULL);
8420 int main(argc, argv)
8425 /* pthread test function */
8428 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8429 /* This system (e.g. AIX) defaults detached; must override */
8430 pthread_attr_t attr;
8432 status = pthread_attr_init(&attr);
8433 if( status ) exit( status );
8435 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8436 if( status ) exit( status );
8440 #if HAVE_PTHREADS_D4
8441 #define ATTR pthread_attr_default
8446 /* make sure pthread_create() isn't just a stub */
8447 status = pthread_create(&t, ATTR, task, NULL);
8448 if( status ) exit( status );
8450 /* make sure pthread_detach() isn't just a stub */
8451 #if HAVE_PTHREADS_D4
8452 status = pthread_detach( &t );
8454 status = pthread_detach( t );
8457 #ifdef HAVE_LINUX_THREADS
8458 pthread_kill_other_threads_np();
8466 if { (eval echo configure:8467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8468 ol_cv_pthread_lib_lpthread_woff=yes
8470 echo "configure: failed program was:" >&5
8471 cat conftest.$ac_ext >&5
8473 ol_cv_pthread_lib_lpthread_woff=no
8484 echo "$ac_t""$ol_cv_pthread_lib_lpthread_woff" 1>&6
8486 if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
8487 ol_link_pthreads="-lpthread -Wl,-woff,85"
8488 ol_link_threads=posix
8493 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
8494 if test "$ol_link_threads" = no ; then
8496 echo $ac_n "checking for pthread link with -lpthread""... $ac_c" 1>&6
8497 echo "configure:8498: checking for pthread link with -lpthread" >&5
8498 if eval "test \"\${ol_cv_pthread_lpthread+set}\" = set"; then
8499 echo $ac_n "(cached) $ac_c" 1>&6
8504 LIBS="-lpthread $LIBS"
8506 if test "$cross_compiling" = yes; then
8507 cat > conftest.$ac_ext <<EOF
8508 #line 8509 "configure"
8509 #include "confdefs.h"
8510 /* pthread test headers */
8511 #include <pthread.h>
8513 #define NULL (void*)0
8516 static void *task(p)
8519 return (void *) (p == NULL);
8524 /* pthread test function */
8527 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8528 /* This system (e.g. AIX) defaults detached; must override */
8529 pthread_attr_t attr;
8531 status = pthread_attr_init(&attr);
8532 if( status ) exit( status );
8534 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8535 if( status ) exit( status );
8539 #if HAVE_PTHREADS_D4
8540 #define ATTR pthread_attr_default
8545 /* make sure pthread_create() isn't just a stub */
8546 status = pthread_create(&t, ATTR, task, NULL);
8547 if( status ) exit( status );
8549 /* make sure pthread_detach() isn't just a stub */
8550 #if HAVE_PTHREADS_D4
8551 status = pthread_detach( &t );
8553 status = pthread_detach( t );
8556 #ifdef HAVE_LINUX_THREADS
8557 pthread_kill_other_threads_np();
8564 if { (eval echo configure:8565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8566 ol_cv_pthread_lpthread=yes
8568 echo "configure: failed program was:" >&5
8569 cat conftest.$ac_ext >&5
8571 ol_cv_pthread_lpthread=no
8575 cat > conftest.$ac_ext <<EOF
8576 #line 8577 "configure"
8577 #include "confdefs.h"
8578 /* pthread test headers */
8579 #include <pthread.h>
8581 #define NULL (void*)0
8584 static void *task(p)
8587 return (void *) (p == NULL);
8591 int main(argc, argv)
8596 /* pthread test function */
8599 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8600 /* This system (e.g. AIX) defaults detached; must override */
8601 pthread_attr_t attr;
8603 status = pthread_attr_init(&attr);
8604 if( status ) exit( status );
8606 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8607 if( status ) exit( status );
8611 #if HAVE_PTHREADS_D4
8612 #define ATTR pthread_attr_default
8617 /* make sure pthread_create() isn't just a stub */
8618 status = pthread_create(&t, ATTR, task, NULL);
8619 if( status ) exit( status );
8621 /* make sure pthread_detach() isn't just a stub */
8622 #if HAVE_PTHREADS_D4
8623 status = pthread_detach( &t );
8625 status = pthread_detach( t );
8628 #ifdef HAVE_LINUX_THREADS
8629 pthread_kill_other_threads_np();
8637 if { (eval echo configure:8638: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8639 ol_cv_pthread_lpthread=yes
8641 echo "configure: failed program was:" >&5
8642 cat conftest.$ac_ext >&5
8644 ol_cv_pthread_lpthread=no
8655 echo "$ac_t""$ol_cv_pthread_lpthread" 1>&6
8657 if test $ol_cv_pthread_lpthread = yes ; then
8658 ol_link_pthreads="-lpthread"
8659 ol_link_threads=posix
8663 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
8664 if test "$ol_link_threads" = no ; then
8666 echo $ac_n "checking for pthread link with -lc_r""... $ac_c" 1>&6
8667 echo "configure:8668: checking for pthread link with -lc_r" >&5
8668 if eval "test \"\${ol_cv_pthread_lc_r+set}\" = set"; then
8669 echo $ac_n "(cached) $ac_c" 1>&6
8676 if test "$cross_compiling" = yes; then
8677 cat > conftest.$ac_ext <<EOF
8678 #line 8679 "configure"
8679 #include "confdefs.h"
8680 /* pthread test headers */
8681 #include <pthread.h>
8683 #define NULL (void*)0
8686 static void *task(p)
8689 return (void *) (p == NULL);
8694 /* pthread test function */
8697 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8698 /* This system (e.g. AIX) defaults detached; must override */
8699 pthread_attr_t attr;
8701 status = pthread_attr_init(&attr);
8702 if( status ) exit( status );
8704 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8705 if( status ) exit( status );
8709 #if HAVE_PTHREADS_D4
8710 #define ATTR pthread_attr_default
8715 /* make sure pthread_create() isn't just a stub */
8716 status = pthread_create(&t, ATTR, task, NULL);
8717 if( status ) exit( status );
8719 /* make sure pthread_detach() isn't just a stub */
8720 #if HAVE_PTHREADS_D4
8721 status = pthread_detach( &t );
8723 status = pthread_detach( t );
8726 #ifdef HAVE_LINUX_THREADS
8727 pthread_kill_other_threads_np();
8734 if { (eval echo configure:8735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8736 ol_cv_pthread_lc_r=yes
8738 echo "configure: failed program was:" >&5
8739 cat conftest.$ac_ext >&5
8741 ol_cv_pthread_lc_r=no
8745 cat > conftest.$ac_ext <<EOF
8746 #line 8747 "configure"
8747 #include "confdefs.h"
8748 /* pthread test headers */
8749 #include <pthread.h>
8751 #define NULL (void*)0
8754 static void *task(p)
8757 return (void *) (p == NULL);
8761 int main(argc, argv)
8766 /* pthread test function */
8769 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8770 /* This system (e.g. AIX) defaults detached; must override */
8771 pthread_attr_t attr;
8773 status = pthread_attr_init(&attr);
8774 if( status ) exit( status );
8776 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8777 if( status ) exit( status );
8781 #if HAVE_PTHREADS_D4
8782 #define ATTR pthread_attr_default
8787 /* make sure pthread_create() isn't just a stub */
8788 status = pthread_create(&t, ATTR, task, NULL);
8789 if( status ) exit( status );
8791 /* make sure pthread_detach() isn't just a stub */
8792 #if HAVE_PTHREADS_D4
8793 status = pthread_detach( &t );
8795 status = pthread_detach( t );
8798 #ifdef HAVE_LINUX_THREADS
8799 pthread_kill_other_threads_np();
8807 if { (eval echo configure:8808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8809 ol_cv_pthread_lc_r=yes
8811 echo "configure: failed program was:" >&5
8812 cat conftest.$ac_ext >&5
8814 ol_cv_pthread_lc_r=no
8825 echo "$ac_t""$ol_cv_pthread_lc_r" 1>&6
8827 if test $ol_cv_pthread_lc_r = yes ; then
8828 ol_link_pthreads="-lc_r"
8829 ol_link_threads=posix
8834 # Pthread try link: -threads (ol_cv_pthread_threads)
8835 if test "$ol_link_threads" = no ; then
8837 echo $ac_n "checking for pthread link with -threads""... $ac_c" 1>&6
8838 echo "configure:8839: checking for pthread link with -threads" >&5
8839 if eval "test \"\${ol_cv_pthread_threads+set}\" = set"; then
8840 echo $ac_n "(cached) $ac_c" 1>&6
8845 LIBS="-threads $LIBS"
8847 if test "$cross_compiling" = yes; then
8848 cat > conftest.$ac_ext <<EOF
8849 #line 8850 "configure"
8850 #include "confdefs.h"
8851 /* pthread test headers */
8852 #include <pthread.h>
8854 #define NULL (void*)0
8857 static void *task(p)
8860 return (void *) (p == NULL);
8865 /* pthread test function */
8868 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8869 /* This system (e.g. AIX) defaults detached; must override */
8870 pthread_attr_t attr;
8872 status = pthread_attr_init(&attr);
8873 if( status ) exit( status );
8875 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8876 if( status ) exit( status );
8880 #if HAVE_PTHREADS_D4
8881 #define ATTR pthread_attr_default
8886 /* make sure pthread_create() isn't just a stub */
8887 status = pthread_create(&t, ATTR, task, NULL);
8888 if( status ) exit( status );
8890 /* make sure pthread_detach() isn't just a stub */
8891 #if HAVE_PTHREADS_D4
8892 status = pthread_detach( &t );
8894 status = pthread_detach( t );
8897 #ifdef HAVE_LINUX_THREADS
8898 pthread_kill_other_threads_np();
8905 if { (eval echo configure:8906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8907 ol_cv_pthread_threads=yes
8909 echo "configure: failed program was:" >&5
8910 cat conftest.$ac_ext >&5
8912 ol_cv_pthread_threads=no
8916 cat > conftest.$ac_ext <<EOF
8917 #line 8918 "configure"
8918 #include "confdefs.h"
8919 /* pthread test headers */
8920 #include <pthread.h>
8922 #define NULL (void*)0
8925 static void *task(p)
8928 return (void *) (p == NULL);
8932 int main(argc, argv)
8937 /* pthread test function */
8940 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
8941 /* This system (e.g. AIX) defaults detached; must override */
8942 pthread_attr_t attr;
8944 status = pthread_attr_init(&attr);
8945 if( status ) exit( status );
8947 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
8948 if( status ) exit( status );
8952 #if HAVE_PTHREADS_D4
8953 #define ATTR pthread_attr_default
8958 /* make sure pthread_create() isn't just a stub */
8959 status = pthread_create(&t, ATTR, task, NULL);
8960 if( status ) exit( status );
8962 /* make sure pthread_detach() isn't just a stub */
8963 #if HAVE_PTHREADS_D4
8964 status = pthread_detach( &t );
8966 status = pthread_detach( t );
8969 #ifdef HAVE_LINUX_THREADS
8970 pthread_kill_other_threads_np();
8978 if { (eval echo configure:8979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8980 ol_cv_pthread_threads=yes
8982 echo "configure: failed program was:" >&5
8983 cat conftest.$ac_ext >&5
8985 ol_cv_pthread_threads=no
8996 echo "$ac_t""$ol_cv_pthread_threads" 1>&6
8998 if test $ol_cv_pthread_threads = yes ; then
8999 ol_link_pthreads="-threads"
9000 ol_link_threads=posix
9005 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
9006 if test "$ol_link_threads" = no ; then
9007 # try -lpthreads -lmach -lexc -lc_r
9008 echo $ac_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r""... $ac_c" 1>&6
9009 echo "configure:9010: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
9010 if eval "test \"\${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}\" = set"; then
9011 echo $ac_n "(cached) $ac_c" 1>&6
9016 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
9018 if test "$cross_compiling" = yes; then
9019 cat > conftest.$ac_ext <<EOF
9020 #line 9021 "configure"
9021 #include "confdefs.h"
9022 /* pthread test headers */
9023 #include <pthread.h>
9025 #define NULL (void*)0
9028 static void *task(p)
9031 return (void *) (p == NULL);
9036 /* pthread test function */
9039 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9040 /* This system (e.g. AIX) defaults detached; must override */
9041 pthread_attr_t attr;
9043 status = pthread_attr_init(&attr);
9044 if( status ) exit( status );
9046 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9047 if( status ) exit( status );
9051 #if HAVE_PTHREADS_D4
9052 #define ATTR pthread_attr_default
9057 /* make sure pthread_create() isn't just a stub */
9058 status = pthread_create(&t, ATTR, task, NULL);
9059 if( status ) exit( status );
9061 /* make sure pthread_detach() isn't just a stub */
9062 #if HAVE_PTHREADS_D4
9063 status = pthread_detach( &t );
9065 status = pthread_detach( t );
9068 #ifdef HAVE_LINUX_THREADS
9069 pthread_kill_other_threads_np();
9076 if { (eval echo configure:9077: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9078 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
9080 echo "configure: failed program was:" >&5
9081 cat conftest.$ac_ext >&5
9083 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
9087 cat > conftest.$ac_ext <<EOF
9088 #line 9089 "configure"
9089 #include "confdefs.h"
9090 /* pthread test headers */
9091 #include <pthread.h>
9093 #define NULL (void*)0
9096 static void *task(p)
9099 return (void *) (p == NULL);
9103 int main(argc, argv)
9108 /* pthread test function */
9111 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9112 /* This system (e.g. AIX) defaults detached; must override */
9113 pthread_attr_t attr;
9115 status = pthread_attr_init(&attr);
9116 if( status ) exit( status );
9118 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9119 if( status ) exit( status );
9123 #if HAVE_PTHREADS_D4
9124 #define ATTR pthread_attr_default
9129 /* make sure pthread_create() isn't just a stub */
9130 status = pthread_create(&t, ATTR, task, NULL);
9131 if( status ) exit( status );
9133 /* make sure pthread_detach() isn't just a stub */
9134 #if HAVE_PTHREADS_D4
9135 status = pthread_detach( &t );
9137 status = pthread_detach( t );
9140 #ifdef HAVE_LINUX_THREADS
9141 pthread_kill_other_threads_np();
9149 if { (eval echo configure:9150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9151 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
9153 echo "configure: failed program was:" >&5
9154 cat conftest.$ac_ext >&5
9156 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
9167 echo "$ac_t""$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" 1>&6
9169 if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
9170 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
9171 ol_link_threads=posix
9175 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
9176 if test "$ol_link_threads" = no ; then
9177 # try -lpthreads -lmach -lexc
9178 echo $ac_n "checking for pthread link with -lpthreads -lmach -lexc""... $ac_c" 1>&6
9179 echo "configure:9180: checking for pthread link with -lpthreads -lmach -lexc" >&5
9180 if eval "test \"\${ol_cv_pthread_lpthreads_lmach_lexc+set}\" = set"; then
9181 echo $ac_n "(cached) $ac_c" 1>&6
9186 LIBS="-lpthreads -lmach -lexc $LIBS"
9188 if test "$cross_compiling" = yes; then
9189 cat > conftest.$ac_ext <<EOF
9190 #line 9191 "configure"
9191 #include "confdefs.h"
9192 /* pthread test headers */
9193 #include <pthread.h>
9195 #define NULL (void*)0
9198 static void *task(p)
9201 return (void *) (p == NULL);
9206 /* pthread test function */
9209 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9210 /* This system (e.g. AIX) defaults detached; must override */
9211 pthread_attr_t attr;
9213 status = pthread_attr_init(&attr);
9214 if( status ) exit( status );
9216 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9217 if( status ) exit( status );
9221 #if HAVE_PTHREADS_D4
9222 #define ATTR pthread_attr_default
9227 /* make sure pthread_create() isn't just a stub */
9228 status = pthread_create(&t, ATTR, task, NULL);
9229 if( status ) exit( status );
9231 /* make sure pthread_detach() isn't just a stub */
9232 #if HAVE_PTHREADS_D4
9233 status = pthread_detach( &t );
9235 status = pthread_detach( t );
9238 #ifdef HAVE_LINUX_THREADS
9239 pthread_kill_other_threads_np();
9246 if { (eval echo configure:9247: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9248 ol_cv_pthread_lpthreads_lmach_lexc=yes
9250 echo "configure: failed program was:" >&5
9251 cat conftest.$ac_ext >&5
9253 ol_cv_pthread_lpthreads_lmach_lexc=no
9257 cat > conftest.$ac_ext <<EOF
9258 #line 9259 "configure"
9259 #include "confdefs.h"
9260 /* pthread test headers */
9261 #include <pthread.h>
9263 #define NULL (void*)0
9266 static void *task(p)
9269 return (void *) (p == NULL);
9273 int main(argc, argv)
9278 /* pthread test function */
9281 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9282 /* This system (e.g. AIX) defaults detached; must override */
9283 pthread_attr_t attr;
9285 status = pthread_attr_init(&attr);
9286 if( status ) exit( status );
9288 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9289 if( status ) exit( status );
9293 #if HAVE_PTHREADS_D4
9294 #define ATTR pthread_attr_default
9299 /* make sure pthread_create() isn't just a stub */
9300 status = pthread_create(&t, ATTR, task, NULL);
9301 if( status ) exit( status );
9303 /* make sure pthread_detach() isn't just a stub */
9304 #if HAVE_PTHREADS_D4
9305 status = pthread_detach( &t );
9307 status = pthread_detach( t );
9310 #ifdef HAVE_LINUX_THREADS
9311 pthread_kill_other_threads_np();
9319 if { (eval echo configure:9320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9321 ol_cv_pthread_lpthreads_lmach_lexc=yes
9323 echo "configure: failed program was:" >&5
9324 cat conftest.$ac_ext >&5
9326 ol_cv_pthread_lpthreads_lmach_lexc=no
9337 echo "$ac_t""$ol_cv_pthread_lpthreads_lmach_lexc" 1>&6
9339 if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
9340 ol_link_pthreads="-lpthreads -lmach -lexc"
9341 ol_link_threads=posix
9345 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
9346 if test "$ol_link_threads" = no ; then
9347 # try -lpthreads -lexc
9348 echo $ac_n "checking for pthread link with -lpthreads -lexc""... $ac_c" 1>&6
9349 echo "configure:9350: checking for pthread link with -lpthreads -lexc" >&5
9350 if eval "test \"\${ol_cv_pthread_lpthreads_lexc+set}\" = set"; then
9351 echo $ac_n "(cached) $ac_c" 1>&6
9356 LIBS="-lpthreads -lexc $LIBS"
9358 if test "$cross_compiling" = yes; then
9359 cat > conftest.$ac_ext <<EOF
9360 #line 9361 "configure"
9361 #include "confdefs.h"
9362 /* pthread test headers */
9363 #include <pthread.h>
9365 #define NULL (void*)0
9368 static void *task(p)
9371 return (void *) (p == NULL);
9376 /* pthread test function */
9379 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9380 /* This system (e.g. AIX) defaults detached; must override */
9381 pthread_attr_t attr;
9383 status = pthread_attr_init(&attr);
9384 if( status ) exit( status );
9386 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9387 if( status ) exit( status );
9391 #if HAVE_PTHREADS_D4
9392 #define ATTR pthread_attr_default
9397 /* make sure pthread_create() isn't just a stub */
9398 status = pthread_create(&t, ATTR, task, NULL);
9399 if( status ) exit( status );
9401 /* make sure pthread_detach() isn't just a stub */
9402 #if HAVE_PTHREADS_D4
9403 status = pthread_detach( &t );
9405 status = pthread_detach( t );
9408 #ifdef HAVE_LINUX_THREADS
9409 pthread_kill_other_threads_np();
9416 if { (eval echo configure:9417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9418 ol_cv_pthread_lpthreads_lexc=yes
9420 echo "configure: failed program was:" >&5
9421 cat conftest.$ac_ext >&5
9423 ol_cv_pthread_lpthreads_lexc=no
9427 cat > conftest.$ac_ext <<EOF
9428 #line 9429 "configure"
9429 #include "confdefs.h"
9430 /* pthread test headers */
9431 #include <pthread.h>
9433 #define NULL (void*)0
9436 static void *task(p)
9439 return (void *) (p == NULL);
9443 int main(argc, argv)
9448 /* pthread test function */
9451 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9452 /* This system (e.g. AIX) defaults detached; must override */
9453 pthread_attr_t attr;
9455 status = pthread_attr_init(&attr);
9456 if( status ) exit( status );
9458 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9459 if( status ) exit( status );
9463 #if HAVE_PTHREADS_D4
9464 #define ATTR pthread_attr_default
9469 /* make sure pthread_create() isn't just a stub */
9470 status = pthread_create(&t, ATTR, task, NULL);
9471 if( status ) exit( status );
9473 /* make sure pthread_detach() isn't just a stub */
9474 #if HAVE_PTHREADS_D4
9475 status = pthread_detach( &t );
9477 status = pthread_detach( t );
9480 #ifdef HAVE_LINUX_THREADS
9481 pthread_kill_other_threads_np();
9489 if { (eval echo configure:9490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9491 ol_cv_pthread_lpthreads_lexc=yes
9493 echo "configure: failed program was:" >&5
9494 cat conftest.$ac_ext >&5
9496 ol_cv_pthread_lpthreads_lexc=no
9507 echo "$ac_t""$ol_cv_pthread_lpthreads_lexc" 1>&6
9509 if test $ol_cv_pthread_lpthreads_lexc = yes ; then
9510 ol_link_pthreads="-lpthreads -lexc"
9511 ol_link_threads=posix
9516 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
9517 if test "$ol_link_threads" = no ; then
9519 echo $ac_n "checking for pthread link with -lpthreads""... $ac_c" 1>&6
9520 echo "configure:9521: checking for pthread link with -lpthreads" >&5
9521 if eval "test \"\${ol_cv_pthread_lib_lpthreads+set}\" = set"; then
9522 echo $ac_n "(cached) $ac_c" 1>&6
9527 LIBS="-lpthreads $LIBS"
9529 if test "$cross_compiling" = yes; then
9530 cat > conftest.$ac_ext <<EOF
9531 #line 9532 "configure"
9532 #include "confdefs.h"
9533 /* pthread test headers */
9534 #include <pthread.h>
9536 #define NULL (void*)0
9539 static void *task(p)
9542 return (void *) (p == NULL);
9547 /* pthread test function */
9550 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9551 /* This system (e.g. AIX) defaults detached; must override */
9552 pthread_attr_t attr;
9554 status = pthread_attr_init(&attr);
9555 if( status ) exit( status );
9557 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9558 if( status ) exit( status );
9562 #if HAVE_PTHREADS_D4
9563 #define ATTR pthread_attr_default
9568 /* make sure pthread_create() isn't just a stub */
9569 status = pthread_create(&t, ATTR, task, NULL);
9570 if( status ) exit( status );
9572 /* make sure pthread_detach() isn't just a stub */
9573 #if HAVE_PTHREADS_D4
9574 status = pthread_detach( &t );
9576 status = pthread_detach( t );
9579 #ifdef HAVE_LINUX_THREADS
9580 pthread_kill_other_threads_np();
9587 if { (eval echo configure:9588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9589 ol_cv_pthread_lib_lpthreads=yes
9591 echo "configure: failed program was:" >&5
9592 cat conftest.$ac_ext >&5
9594 ol_cv_pthread_lib_lpthreads=no
9598 cat > conftest.$ac_ext <<EOF
9599 #line 9600 "configure"
9600 #include "confdefs.h"
9601 /* pthread test headers */
9602 #include <pthread.h>
9604 #define NULL (void*)0
9607 static void *task(p)
9610 return (void *) (p == NULL);
9614 int main(argc, argv)
9619 /* pthread test function */
9622 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
9623 /* This system (e.g. AIX) defaults detached; must override */
9624 pthread_attr_t attr;
9626 status = pthread_attr_init(&attr);
9627 if( status ) exit( status );
9629 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
9630 if( status ) exit( status );
9634 #if HAVE_PTHREADS_D4
9635 #define ATTR pthread_attr_default
9640 /* make sure pthread_create() isn't just a stub */
9641 status = pthread_create(&t, ATTR, task, NULL);
9642 if( status ) exit( status );
9644 /* make sure pthread_detach() isn't just a stub */
9645 #if HAVE_PTHREADS_D4
9646 status = pthread_detach( &t );
9648 status = pthread_detach( t );
9651 #ifdef HAVE_LINUX_THREADS
9652 pthread_kill_other_threads_np();
9660 if { (eval echo configure:9661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
9662 ol_cv_pthread_lib_lpthreads=yes
9664 echo "configure: failed program was:" >&5
9665 cat conftest.$ac_ext >&5
9667 ol_cv_pthread_lib_lpthreads=no
9678 echo "$ac_t""$ol_cv_pthread_lib_lpthreads" 1>&6
9680 if test $ol_cv_pthread_lib_lpthreads = yes ; then
9681 ol_link_pthreads="-lpthreads"
9682 ol_link_threads=posix
9687 if test $ol_link_threads != no ; then
9688 cat >> confdefs.h <<\EOF
9689 #define HAVE_PTHREADS 1
9693 LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
9695 save_CPPFLAGS="$CPPFLAGS"
9697 LIBS="$LTHREAD_LIBS $LIBS"
9699 for ac_func in sched_yield pthread_yield
9701 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9702 echo "configure:9703: checking for $ac_func" >&5
9703 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9704 echo $ac_n "(cached) $ac_c" 1>&6
9706 cat > conftest.$ac_ext <<EOF
9707 #line 9708 "configure"
9708 #include "confdefs.h"
9709 /* System header to define __stub macros and hopefully few prototypes,
9710 which can conflict with char $ac_func(); below. */
9712 /* Override any gcc2 internal prototype to avoid an error. */
9713 /* We use char because int might match the return type of a gcc2
9714 builtin and then its argument prototype would still apply. */
9720 /* The GNU C library defines this for functions which it implements
9721 to always fail with ENOSYS. Some functions are actually named
9722 something starting with __ and the normal name is an alias. */
9723 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9731 if { (eval echo configure:9732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9733 eval "ac_cv_func_$ac_func=yes"
9735 echo "configure: failed program was:" >&5
9736 cat conftest.$ac_ext >&5
9738 eval "ac_cv_func_$ac_func=no"
9743 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
9744 echo "$ac_t""yes" 1>&6
9745 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
9746 cat >> confdefs.h <<EOF
9747 #define $ac_tr_func 1
9751 echo "$ac_t""no" 1>&6
9756 if test $ac_cv_func_sched_yield = no -a \
9757 $ac_cv_func_pthread_yield = no ; then
9758 echo $ac_n "checking for sched_yield in -lrt""... $ac_c" 1>&6
9759 echo "configure:9760: checking for sched_yield in -lrt" >&5
9760 ac_lib_var=`echo rt'_'sched_yield | sed 'y%./+-:%__p__%'`
9761 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
9762 echo $ac_n "(cached) $ac_c" 1>&6
9764 ac_save_LIBS="$LIBS"
9766 cat > conftest.$ac_ext <<EOF
9767 #line 9768 "configure"
9768 #include "confdefs.h"
9769 /* Override any gcc2 internal prototype to avoid an error. */
9770 /* We use char because int might match the return type of a gcc2
9771 builtin and then its argument prototype would still apply. */
9778 if { (eval echo configure:9779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9780 eval "ac_cv_lib_$ac_lib_var=yes"
9782 echo "configure: failed program was:" >&5
9783 cat conftest.$ac_ext >&5
9785 eval "ac_cv_lib_$ac_lib_var=no"
9788 LIBS="$ac_save_LIBS"
9791 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
9792 echo "$ac_t""yes" 1>&6
9793 LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
9794 cat >> confdefs.h <<\EOF
9795 #define HAVE_SCHED_YIELD 1
9798 ac_cv_func_sched_yield=yes
9800 echo "$ac_t""no" 1>&6
9801 ac_cv_func_sched_yield=no
9805 if test $ac_cv_func_sched_yield = no -a \
9806 $ac_cv_func_pthread_yield = no ; then
9807 for ac_func in thr_yield
9809 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9810 echo "configure:9811: checking for $ac_func" >&5
9811 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9812 echo $ac_n "(cached) $ac_c" 1>&6
9814 cat > conftest.$ac_ext <<EOF
9815 #line 9816 "configure"
9816 #include "confdefs.h"
9817 /* System header to define __stub macros and hopefully few prototypes,
9818 which can conflict with char $ac_func(); below. */
9820 /* Override any gcc2 internal prototype to avoid an error. */
9821 /* We use char because int might match the return type of a gcc2
9822 builtin and then its argument prototype would still apply. */
9828 /* The GNU C library defines this for functions which it implements
9829 to always fail with ENOSYS. Some functions are actually named
9830 something starting with __ and the normal name is an alias. */
9831 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9839 if { (eval echo configure:9840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9841 eval "ac_cv_func_$ac_func=yes"
9843 echo "configure: failed program was:" >&5
9844 cat conftest.$ac_ext >&5
9846 eval "ac_cv_func_$ac_func=no"
9851 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
9852 echo "$ac_t""yes" 1>&6
9853 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
9854 cat >> confdefs.h <<EOF
9855 #define $ac_tr_func 1
9859 echo "$ac_t""no" 1>&6
9864 if test $ac_cv_func_sched_yield = no -a \
9865 $ac_cv_func_pthread_yield = no -a \
9866 "$ac_cv_func_thr_yield" = no ; then
9867 echo "configure: warning: could not locate sched_yield() or pthread_yield()" 1>&2
9870 for ac_func in pthread_kill pthread_rwlock_destroy
9872 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9873 echo "configure:9874: checking for $ac_func" >&5
9874 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9875 echo $ac_n "(cached) $ac_c" 1>&6
9877 cat > conftest.$ac_ext <<EOF
9878 #line 9879 "configure"
9879 #include "confdefs.h"
9880 /* System header to define __stub macros and hopefully few prototypes,
9881 which can conflict with char $ac_func(); below. */
9883 /* Override any gcc2 internal prototype to avoid an error. */
9884 /* We use char because int might match the return type of a gcc2
9885 builtin and then its argument prototype would still apply. */
9891 /* The GNU C library defines this for functions which it implements
9892 to always fail with ENOSYS. Some functions are actually named
9893 something starting with __ and the normal name is an alias. */
9894 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9902 if { (eval echo configure:9903: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9904 eval "ac_cv_func_$ac_func=yes"
9906 echo "configure: failed program was:" >&5
9907 cat conftest.$ac_ext >&5
9909 eval "ac_cv_func_$ac_func=no"
9914 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
9915 echo "$ac_t""yes" 1>&6
9916 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
9917 cat >> confdefs.h <<EOF
9918 #define $ac_tr_func 1
9922 echo "$ac_t""no" 1>&6
9927 echo $ac_n "checking for pthread_detach with <pthread.h>""... $ac_c" 1>&6
9928 echo "configure:9929: checking for pthread_detach with <pthread.h>" >&5
9929 if eval "test \"\${ol_cv_func_pthread_detach+set}\" = set"; then
9930 echo $ac_n "(cached) $ac_c" 1>&6
9933 cat > conftest.$ac_ext <<EOF
9934 #line 9935 "configure"
9935 #include "confdefs.h"
9937 #include <pthread.h>
9939 #define NULL (void*)0
9943 pthread_detach(NULL);
9946 if { (eval echo configure:9947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9948 ol_cv_func_pthread_detach=yes
9950 echo "configure: failed program was:" >&5
9951 cat conftest.$ac_ext >&5
9953 ol_cv_func_pthread_detach=no
9959 echo "$ac_t""$ol_cv_func_pthread_detach" 1>&6
9961 if test $ol_cv_func_pthread_detach = no ; then
9962 { echo "configure: error: could not locate pthread_detach()" 1>&2; exit 1; }
9965 cat >> confdefs.h <<\EOF
9966 #define HAVE_PTHREAD_DETACH 1
9971 pthread_setconcurrency \
9972 pthread_getconcurrency \
9973 thr_setconcurrency \
9974 thr_getconcurrency \
9977 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
9978 echo "configure:9979: checking for $ac_func" >&5
9979 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
9980 echo $ac_n "(cached) $ac_c" 1>&6
9982 cat > conftest.$ac_ext <<EOF
9983 #line 9984 "configure"
9984 #include "confdefs.h"
9985 /* System header to define __stub macros and hopefully few prototypes,
9986 which can conflict with char $ac_func(); below. */
9988 /* Override any gcc2 internal prototype to avoid an error. */
9989 /* We use char because int might match the return type of a gcc2
9990 builtin and then its argument prototype would still apply. */
9996 /* The GNU C library defines this for functions which it implements
9997 to always fail with ENOSYS. Some functions are actually named
9998 something starting with __ and the normal name is an alias. */
9999 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10007 if { (eval echo configure:10008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10009 eval "ac_cv_func_$ac_func=yes"
10011 echo "configure: failed program was:" >&5
10012 cat conftest.$ac_ext >&5
10014 eval "ac_cv_func_$ac_func=no"
10019 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10020 echo "$ac_t""yes" 1>&6
10021 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10022 cat >> confdefs.h <<EOF
10023 #define $ac_tr_func 1
10027 echo "$ac_t""no" 1>&6
10033 for ac_func in pthread_kill_other_threads_np
10035 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
10036 echo "configure:10037: checking for $ac_func" >&5
10037 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
10038 echo $ac_n "(cached) $ac_c" 1>&6
10040 cat > conftest.$ac_ext <<EOF
10041 #line 10042 "configure"
10042 #include "confdefs.h"
10043 /* System header to define __stub macros and hopefully few prototypes,
10044 which can conflict with char $ac_func(); below. */
10045 #include <assert.h>
10046 /* Override any gcc2 internal prototype to avoid an error. */
10047 /* We use char because int might match the return type of a gcc2
10048 builtin and then its argument prototype would still apply. */
10054 /* The GNU C library defines this for functions which it implements
10055 to always fail with ENOSYS. Some functions are actually named
10056 something starting with __ and the normal name is an alias. */
10057 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10065 if { (eval echo configure:10066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10067 eval "ac_cv_func_$ac_func=yes"
10069 echo "configure: failed program was:" >&5
10070 cat conftest.$ac_ext >&5
10072 eval "ac_cv_func_$ac_func=no"
10077 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10078 echo "$ac_t""yes" 1>&6
10079 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10080 cat >> confdefs.h <<EOF
10081 #define $ac_tr_func 1
10085 echo "$ac_t""no" 1>&6
10089 echo $ac_n "checking for LinuxThreads implementation""... $ac_c" 1>&6
10090 echo "configure:10091: checking for LinuxThreads implementation" >&5
10091 if eval "test \"\${ol_cv_sys_linux_threads+set}\" = set"; then
10092 echo $ac_n "(cached) $ac_c" 1>&6
10094 ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
10097 echo "$ac_t""$ol_cv_sys_linux_threads" 1>&6
10102 echo $ac_n "checking for LinuxThreads consistency""... $ac_c" 1>&6
10103 echo "configure:10104: checking for LinuxThreads consistency" >&5
10104 if eval "test \"\${ol_cv_linux_threads+set}\" = set"; then
10105 echo $ac_n "(cached) $ac_c" 1>&6
10108 if test $ol_cv_header_linux_threads = yes -a \
10109 $ol_cv_sys_linux_threads = yes; then
10110 ol_cv_linux_threads=yes
10111 elif test $ol_cv_header_linux_threads = no -a \
10112 $ol_cv_sys_linux_threads = no; then
10113 ol_cv_linux_threads=no
10115 ol_cv_linux_threads=error
10120 echo "$ac_t""$ol_cv_linux_threads" 1>&6
10123 if test $ol_cv_linux_threads = error; then
10124 { echo "configure: error: LinuxThreads header/library mismatch" 1>&2; exit 1; };
10127 echo $ac_n "checking if pthread_create() works""... $ac_c" 1>&6
10128 echo "configure:10129: checking if pthread_create() works" >&5
10129 if eval "test \"\${ol_cv_pthread_create_works+set}\" = set"; then
10130 echo $ac_n "(cached) $ac_c" 1>&6
10133 if test "$cross_compiling" = yes; then
10134 ol_cv_pthread_create_works=yes
10136 cat > conftest.$ac_ext <<EOF
10137 #line 10138 "configure"
10138 #include "confdefs.h"
10139 /* pthread test headers */
10140 #include <pthread.h>
10142 #define NULL (void*)0
10145 static void *task(p)
10148 return (void *) (p == NULL);
10152 int main(argc, argv)
10157 /* pthread test function */
10160 #if HAVE_PTHREADS_FINAL && defined(PTHREAD_CREATE_UNDETACHED)
10161 /* This system (e.g. AIX) defaults detached; must override */
10162 pthread_attr_t attr;
10164 status = pthread_attr_init(&attr);
10165 if( status ) exit( status );
10167 status = pthread_attr_setdetachstate(&attr,PTHREAD_CREATE_UNDETACHED);
10168 if( status ) exit( status );
10172 #if HAVE_PTHREADS_D4
10173 #define ATTR pthread_attr_default
10178 /* make sure pthread_create() isn't just a stub */
10179 status = pthread_create(&t, ATTR, task, NULL);
10180 if( status ) exit( status );
10182 /* make sure pthread_detach() isn't just a stub */
10183 #if HAVE_PTHREADS_D4
10184 status = pthread_detach( &t );
10186 status = pthread_detach( t );
10189 #ifdef HAVE_LINUX_THREADS
10190 pthread_kill_other_threads_np();
10198 if { (eval echo configure:10199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
10200 ol_cv_pthread_create_works=yes
10202 echo "configure: failed program was:" >&5
10203 cat conftest.$ac_ext >&5
10205 ol_cv_pthread_create_works=no
10212 echo "$ac_t""$ol_cv_pthread_create_works" 1>&6
10214 if test $ol_cv_pthread_create_works = no ; then
10215 { echo "configure: error: pthread_create is not usable, check environment settings" 1>&2; exit 1; }
10218 if test $ol_with_yielding_select = auto ; then
10219 echo $ac_n "checking if select yields when using pthreads""... $ac_c" 1>&6
10220 echo "configure:10221: checking if select yields when using pthreads" >&5
10221 if eval "test \"\${ol_cv_pthread_select_yields+set}\" = set"; then
10222 echo $ac_n "(cached) $ac_c" 1>&6
10225 if test "$cross_compiling" = yes; then
10226 ol_cv_pthread_select_yields=cross
10228 cat > conftest.$ac_ext <<EOF
10229 #line 10230 "configure"
10230 #include "confdefs.h"
10232 #include <sys/types.h>
10233 #include <sys/time.h>
10234 #include <unistd.h>
10235 #include <pthread.h>
10237 #define NULL (void*) 0
10240 static int fildes[2];
10242 static void *task(p)
10254 FD_SET(fildes[0], &rfds);
10256 /* we're not interested in any fds */
10257 i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
10264 exit(0); /* if we exit here, the select blocked the whole process */
10267 int main(argc, argv)
10273 /* create a pipe to select */
10274 if(pipe(&fildes[0])) {
10279 #ifdef HAVE_PTHREAD_SETCONCURRENCY
10280 (void) pthread_setconcurrency(2);
10282 #ifdef HAVE_THR_SETCONCURRENCY
10283 /* Set Solaris LWP concurrency to 2 */
10284 thr_setconcurrency(2);
10288 #if HAVE_PTHREADS_D4
10289 pthread_create(&t, pthread_attr_default, task, NULL);
10291 pthread_create(&t, NULL, task, NULL);
10294 #if HAVE_SCHED_YIELD
10295 sched_yield(); /* make sure task runs first */
10297 #ifdef HAVE_PTHREAD_YIELD
10298 pthread_yield(); /* make sure task runs first */
10305 if { (eval echo configure:10306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
10307 ol_cv_pthread_select_yields=no
10309 echo "configure: failed program was:" >&5
10310 cat conftest.$ac_ext >&5
10312 ol_cv_pthread_select_yields=yes
10319 echo "$ac_t""$ol_cv_pthread_select_yields" 1>&6
10321 if test $ol_cv_pthread_select_yields = cross ; then
10322 { echo "configure: error: crossing compiling: use --with-yielding_select=yes|no|manual" 1>&2; exit 1; }
10325 if test $ol_cv_pthread_select_yields = yes ; then
10326 ol_with_yielding_select=yes
10330 CPPFLAGS="$save_CPPFLAGS"
10333 { echo "configure: error: could not link with POSIX Threads" 1>&2; exit 1; }
10337 if test $ol_with_threads = posix ; then
10338 { echo "configure: error: could not locate POSIX Threads" 1>&2; exit 1; }
10342 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10343 -o $ol_with_threads = mach ; then
10345 for ac_hdr in mach/cthreads.h
10347 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10348 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10349 echo "configure:10350: checking for $ac_hdr" >&5
10350 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10351 echo $ac_n "(cached) $ac_c" 1>&6
10353 cat > conftest.$ac_ext <<EOF
10354 #line 10355 "configure"
10355 #include "confdefs.h"
10358 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10359 { (eval echo configure:10360: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10360 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10361 if test -z "$ac_err"; then
10363 eval "ac_cv_header_$ac_safe=yes"
10366 echo "configure: failed program was:" >&5
10367 cat conftest.$ac_ext >&5
10369 eval "ac_cv_header_$ac_safe=no"
10373 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10374 echo "$ac_t""yes" 1>&6
10375 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10376 cat >> confdefs.h <<EOF
10377 #define $ac_tr_hdr 1
10381 echo "$ac_t""no" 1>&6
10385 if test $ac_cv_header_mach_cthreads_h = yes ; then
10386 ol_with_threads=found
10388 echo $ac_n "checking for cthread_fork""... $ac_c" 1>&6
10389 echo "configure:10390: checking for cthread_fork" >&5
10390 if eval "test \"\${ac_cv_func_cthread_fork+set}\" = set"; then
10391 echo $ac_n "(cached) $ac_c" 1>&6
10393 cat > conftest.$ac_ext <<EOF
10394 #line 10395 "configure"
10395 #include "confdefs.h"
10396 /* System header to define __stub macros and hopefully few prototypes,
10397 which can conflict with char cthread_fork(); below. */
10398 #include <assert.h>
10399 /* Override any gcc2 internal prototype to avoid an error. */
10400 /* We use char because int might match the return type of a gcc2
10401 builtin and then its argument prototype would still apply. */
10402 char cthread_fork();
10407 /* The GNU C library defines this for functions which it implements
10408 to always fail with ENOSYS. Some functions are actually named
10409 something starting with __ and the normal name is an alias. */
10410 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
10418 if { (eval echo configure:10419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10420 eval "ac_cv_func_cthread_fork=yes"
10422 echo "configure: failed program was:" >&5
10423 cat conftest.$ac_ext >&5
10425 eval "ac_cv_func_cthread_fork=no"
10430 if eval "test \"`echo '$ac_cv_func_'cthread_fork`\" = yes"; then
10431 echo "$ac_t""yes" 1>&6
10432 ol_link_threads=yes
10434 echo "$ac_t""no" 1>&6
10438 if test $ol_link_threads = no ; then
10439 echo $ac_n "checking for cthread_fork with -all_load""... $ac_c" 1>&6
10440 echo "configure:10441: checking for cthread_fork with -all_load" >&5
10441 if eval "test \"\${ol_cv_cthread_all_load+set}\" = set"; then
10442 echo $ac_n "(cached) $ac_c" 1>&6
10446 LIBS="-all_load $LIBS"
10447 cat > conftest.$ac_ext <<EOF
10448 #line 10449 "configure"
10449 #include "confdefs.h"
10450 #include <mach/cthreads.h>
10453 cthread_fork((void *)0, (void *)0);
10457 if { (eval echo configure:10458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10459 ol_cv_cthread_all_load=yes
10461 echo "configure: failed program was:" >&5
10462 cat conftest.$ac_ext >&5
10464 ol_cv_cthread_all_load=no
10471 echo "$ac_t""$ol_cv_cthread_all_load" 1>&6
10473 if test $ol_cv_cthread_all_load = yes ; then
10474 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
10475 ol_link_threads=mach
10479 if test $ol_link_threads != no ; then
10480 : check for cthread specific functionality here
10481 cat >> confdefs.h <<\EOF
10482 #define HAVE_MACH_CTHREADS 1
10486 { echo "configure: error: could not link with Mach CThreads" 1>&2; exit 1; }
10490 if test $ol_with_threads = mach ; then
10491 { echo "configure: error: could not locate Mach CThreads" 1>&2; exit 1; }
10495 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10496 -o $ol_with_threads = pth ; then
10498 for ac_hdr in pth.h
10500 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10501 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10502 echo "configure:10503: checking for $ac_hdr" >&5
10503 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10504 echo $ac_n "(cached) $ac_c" 1>&6
10506 cat > conftest.$ac_ext <<EOF
10507 #line 10508 "configure"
10508 #include "confdefs.h"
10511 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10512 { (eval echo configure:10513: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10513 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10514 if test -z "$ac_err"; then
10516 eval "ac_cv_header_$ac_safe=yes"
10519 echo "configure: failed program was:" >&5
10520 cat conftest.$ac_ext >&5
10522 eval "ac_cv_header_$ac_safe=no"
10526 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10527 echo "$ac_t""yes" 1>&6
10528 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10529 cat >> confdefs.h <<EOF
10530 #define $ac_tr_hdr 1
10534 echo "$ac_t""no" 1>&6
10539 if test $ac_cv_header_pth_h = yes ; then
10540 echo $ac_n "checking for pth_version in -lpth""... $ac_c" 1>&6
10541 echo "configure:10542: checking for pth_version in -lpth" >&5
10542 ac_lib_var=`echo pth'_'pth_version | sed 'y%./+-:%__p__%'`
10543 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10544 echo $ac_n "(cached) $ac_c" 1>&6
10546 ac_save_LIBS="$LIBS"
10548 cat > conftest.$ac_ext <<EOF
10549 #line 10550 "configure"
10550 #include "confdefs.h"
10551 /* Override any gcc2 internal prototype to avoid an error. */
10552 /* We use char because int might match the return type of a gcc2
10553 builtin and then its argument prototype would still apply. */
10554 char pth_version();
10560 if { (eval echo configure:10561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10562 eval "ac_cv_lib_$ac_lib_var=yes"
10564 echo "configure: failed program was:" >&5
10565 cat conftest.$ac_ext >&5
10567 eval "ac_cv_lib_$ac_lib_var=no"
10570 LIBS="$ac_save_LIBS"
10573 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10574 echo "$ac_t""yes" 1>&6
10577 echo "$ac_t""no" 1>&6
10582 if test $have_pth = yes ; then
10583 cat >> confdefs.h <<\EOF
10584 #define HAVE_GNU_PTH 1
10587 LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
10588 ol_link_threads=pth
10590 if test $ol_with_yielding_select = auto ; then
10591 ol_with_yielding_select=yes
10597 if test $ol_with_threads = auto -o $ol_with_threads = yes \
10598 -o $ol_with_threads = lwp ; then
10600 for ac_hdr in thread.h synch.h
10602 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10603 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10604 echo "configure:10605: checking for $ac_hdr" >&5
10605 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10606 echo $ac_n "(cached) $ac_c" 1>&6
10608 cat > conftest.$ac_ext <<EOF
10609 #line 10610 "configure"
10610 #include "confdefs.h"
10613 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10614 { (eval echo configure:10615: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10615 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10616 if test -z "$ac_err"; then
10618 eval "ac_cv_header_$ac_safe=yes"
10621 echo "configure: failed program was:" >&5
10622 cat conftest.$ac_ext >&5
10624 eval "ac_cv_header_$ac_safe=no"
10628 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10629 echo "$ac_t""yes" 1>&6
10630 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10631 cat >> confdefs.h <<EOF
10632 #define $ac_tr_hdr 1
10636 echo "$ac_t""no" 1>&6
10640 if test $ac_cv_header_thread_h = yes -a $ac_cv_header_synch_h = yes ; then
10641 echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6
10642 echo "configure:10643: checking for thr_create in -lthread" >&5
10643 ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-:%__p__%'`
10644 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10645 echo $ac_n "(cached) $ac_c" 1>&6
10647 ac_save_LIBS="$LIBS"
10648 LIBS="-lthread $LIBS"
10649 cat > conftest.$ac_ext <<EOF
10650 #line 10651 "configure"
10651 #include "confdefs.h"
10652 /* Override any gcc2 internal prototype to avoid an error. */
10653 /* We use char because int might match the return type of a gcc2
10654 builtin and then its argument prototype would still apply. */
10661 if { (eval echo configure:10662: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10663 eval "ac_cv_lib_$ac_lib_var=yes"
10665 echo "configure: failed program was:" >&5
10666 cat conftest.$ac_ext >&5
10668 eval "ac_cv_lib_$ac_lib_var=no"
10671 LIBS="$ac_save_LIBS"
10674 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10675 echo "$ac_t""yes" 1>&6
10678 echo "$ac_t""no" 1>&6
10683 if test $have_thr = yes ; then
10684 cat >> confdefs.h <<\EOF
10688 LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
10689 ol_link_threads=thr
10691 if test $ol_with_yielding_select = auto ; then
10692 ol_with_yielding_select=yes
10696 thr_setconcurrency \
10697 thr_getconcurrency \
10700 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
10701 echo "configure:10702: checking for $ac_func" >&5
10702 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
10703 echo $ac_n "(cached) $ac_c" 1>&6
10705 cat > conftest.$ac_ext <<EOF
10706 #line 10707 "configure"
10707 #include "confdefs.h"
10708 /* System header to define __stub macros and hopefully few prototypes,
10709 which can conflict with char $ac_func(); below. */
10710 #include <assert.h>
10711 /* Override any gcc2 internal prototype to avoid an error. */
10712 /* We use char because int might match the return type of a gcc2
10713 builtin and then its argument prototype would still apply. */
10719 /* The GNU C library defines this for functions which it implements
10720 to always fail with ENOSYS. Some functions are actually named
10721 something starting with __ and the normal name is an alias. */
10722 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10730 if { (eval echo configure:10731: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10732 eval "ac_cv_func_$ac_func=yes"
10734 echo "configure: failed program was:" >&5
10735 cat conftest.$ac_ext >&5
10737 eval "ac_cv_func_$ac_func=no"
10742 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10743 echo "$ac_t""yes" 1>&6
10744 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10745 cat >> confdefs.h <<EOF
10746 #define $ac_tr_func 1
10750 echo "$ac_t""no" 1>&6
10757 for ac_hdr in lwp/lwp.h
10759 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10760 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10761 echo "configure:10762: checking for $ac_hdr" >&5
10762 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10763 echo $ac_n "(cached) $ac_c" 1>&6
10765 cat > conftest.$ac_ext <<EOF
10766 #line 10767 "configure"
10767 #include "confdefs.h"
10770 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10771 { (eval echo configure:10772: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10772 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10773 if test -z "$ac_err"; then
10775 eval "ac_cv_header_$ac_safe=yes"
10778 echo "configure: failed program was:" >&5
10779 cat conftest.$ac_ext >&5
10781 eval "ac_cv_header_$ac_safe=no"
10785 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10786 echo "$ac_t""yes" 1>&6
10787 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10788 cat >> confdefs.h <<EOF
10789 #define $ac_tr_hdr 1
10793 echo "$ac_t""no" 1>&6
10797 if test $ac_cv_header_lwp_lwp_h = yes ; then
10798 echo $ac_n "checking for lwp_create in -llwp""... $ac_c" 1>&6
10799 echo "configure:10800: checking for lwp_create in -llwp" >&5
10800 ac_lib_var=`echo lwp'_'lwp_create | sed 'y%./+-:%__p__%'`
10801 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
10802 echo $ac_n "(cached) $ac_c" 1>&6
10804 ac_save_LIBS="$LIBS"
10806 cat > conftest.$ac_ext <<EOF
10807 #line 10808 "configure"
10808 #include "confdefs.h"
10809 /* Override any gcc2 internal prototype to avoid an error. */
10810 /* We use char because int might match the return type of a gcc2
10811 builtin and then its argument prototype would still apply. */
10818 if { (eval echo configure:10819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10820 eval "ac_cv_lib_$ac_lib_var=yes"
10822 echo "configure: failed program was:" >&5
10823 cat conftest.$ac_ext >&5
10825 eval "ac_cv_lib_$ac_lib_var=no"
10828 LIBS="$ac_save_LIBS"
10831 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
10832 echo "$ac_t""yes" 1>&6
10835 echo "$ac_t""no" 1>&6
10840 if test $have_lwp = yes ; then
10841 cat >> confdefs.h <<\EOF
10845 LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
10846 ol_link_threads=lwp
10848 if test $ol_with_yielding_select = auto ; then
10849 ol_with_yielding_select=no
10855 if test $ol_with_yielding_select = yes ; then
10856 cat >> confdefs.h <<\EOF
10857 #define HAVE_YIELDING_SELECT 1
10862 if test $ol_with_threads = manual ; then
10863 ol_link_threads=yes
10865 echo "configure: warning: thread defines and link options must be set manually" 1>&2
10867 for ac_hdr in pthread.h sched.h
10869 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10870 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
10871 echo "configure:10872: checking for $ac_hdr" >&5
10872 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
10873 echo $ac_n "(cached) $ac_c" 1>&6
10875 cat > conftest.$ac_ext <<EOF
10876 #line 10877 "configure"
10877 #include "confdefs.h"
10880 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10881 { (eval echo configure:10882: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10882 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10883 if test -z "$ac_err"; then
10885 eval "ac_cv_header_$ac_safe=yes"
10888 echo "configure: failed program was:" >&5
10889 cat conftest.$ac_ext >&5
10891 eval "ac_cv_header_$ac_safe=no"
10895 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
10896 echo "$ac_t""yes" 1>&6
10897 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
10898 cat >> confdefs.h <<EOF
10899 #define $ac_tr_hdr 1
10903 echo "$ac_t""no" 1>&6
10907 for ac_func in sched_yield pthread_yield
10909 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
10910 echo "configure:10911: checking for $ac_func" >&5
10911 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
10912 echo $ac_n "(cached) $ac_c" 1>&6
10914 cat > conftest.$ac_ext <<EOF
10915 #line 10916 "configure"
10916 #include "confdefs.h"
10917 /* System header to define __stub macros and hopefully few prototypes,
10918 which can conflict with char $ac_func(); below. */
10919 #include <assert.h>
10920 /* Override any gcc2 internal prototype to avoid an error. */
10921 /* We use char because int might match the return type of a gcc2
10922 builtin and then its argument prototype would still apply. */
10928 /* The GNU C library defines this for functions which it implements
10929 to always fail with ENOSYS. Some functions are actually named
10930 something starting with __ and the normal name is an alias. */
10931 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10939 if { (eval echo configure:10940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10941 eval "ac_cv_func_$ac_func=yes"
10943 echo "configure: failed program was:" >&5
10944 cat conftest.$ac_ext >&5
10946 eval "ac_cv_func_$ac_func=no"
10951 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
10952 echo "$ac_t""yes" 1>&6
10953 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
10954 cat >> confdefs.h <<EOF
10955 #define $ac_tr_func 1
10959 echo "$ac_t""no" 1>&6
10964 echo $ac_n "checking for LinuxThreads pthread.h""... $ac_c" 1>&6
10965 echo "configure:10966: checking for LinuxThreads pthread.h" >&5
10966 if eval "test \"\${ol_cv_header_linux_threads+set}\" = set"; then
10967 echo $ac_n "(cached) $ac_c" 1>&6
10969 cat > conftest.$ac_ext <<EOF
10970 #line 10971 "configure"
10971 #include "confdefs.h"
10972 #include <pthread.h>
10974 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10975 egrep "pthread_kill_other_threads_np" >/dev/null 2>&1; then
10977 ol_cv_header_linux_threads=yes
10980 ol_cv_header_linux_threads=no
10987 echo "$ac_t""$ol_cv_header_linux_threads" 1>&6
10988 if test $ol_cv_header_linux_threads = yes; then
10989 cat >> confdefs.h <<\EOF
10990 #define HAVE_LINUX_THREADS 1
10996 for ac_hdr in mach/cthreads.h
10998 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
10999 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11000 echo "configure:11001: checking for $ac_hdr" >&5
11001 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11002 echo $ac_n "(cached) $ac_c" 1>&6
11004 cat > conftest.$ac_ext <<EOF
11005 #line 11006 "configure"
11006 #include "confdefs.h"
11009 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11010 { (eval echo configure:11011: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11011 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11012 if test -z "$ac_err"; then
11014 eval "ac_cv_header_$ac_safe=yes"
11017 echo "configure: failed program was:" >&5
11018 cat conftest.$ac_ext >&5
11020 eval "ac_cv_header_$ac_safe=no"
11024 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11025 echo "$ac_t""yes" 1>&6
11026 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11027 cat >> confdefs.h <<EOF
11028 #define $ac_tr_hdr 1
11032 echo "$ac_t""no" 1>&6
11036 for ac_hdr in lwp/lwp.h
11038 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11039 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11040 echo "configure:11041: checking for $ac_hdr" >&5
11041 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11042 echo $ac_n "(cached) $ac_c" 1>&6
11044 cat > conftest.$ac_ext <<EOF
11045 #line 11046 "configure"
11046 #include "confdefs.h"
11049 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11050 { (eval echo configure:11051: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11051 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11052 if test -z "$ac_err"; then
11054 eval "ac_cv_header_$ac_safe=yes"
11057 echo "configure: failed program was:" >&5
11058 cat conftest.$ac_ext >&5
11060 eval "ac_cv_header_$ac_safe=no"
11064 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11065 echo "$ac_t""yes" 1>&6
11066 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11067 cat >> confdefs.h <<EOF
11068 #define $ac_tr_hdr 1
11072 echo "$ac_t""no" 1>&6
11076 for ac_hdr in thread.h synch.h
11078 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11079 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11080 echo "configure:11081: checking for $ac_hdr" >&5
11081 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11082 echo $ac_n "(cached) $ac_c" 1>&6
11084 cat > conftest.$ac_ext <<EOF
11085 #line 11086 "configure"
11086 #include "confdefs.h"
11089 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11090 { (eval echo configure:11091: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11091 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11092 if test -z "$ac_err"; then
11094 eval "ac_cv_header_$ac_safe=yes"
11097 echo "configure: failed program was:" >&5
11098 cat conftest.$ac_ext >&5
11100 eval "ac_cv_header_$ac_safe=no"
11104 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11105 echo "$ac_t""yes" 1>&6
11106 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11107 cat >> confdefs.h <<EOF
11108 #define $ac_tr_hdr 1
11112 echo "$ac_t""no" 1>&6
11118 if test $ol_link_threads != no -a $ol_link_threads != nt ; then
11119 cat >> confdefs.h <<\EOF
11120 #define REENTRANT 1
11123 cat >> confdefs.h <<\EOF
11124 #define _REENTRANT 1
11127 cat >> confdefs.h <<\EOF
11128 #define THREAD_SAFE 1
11131 cat >> confdefs.h <<\EOF
11132 #define _THREAD_SAFE 1
11135 cat >> confdefs.h <<\EOF
11136 #define THREADSAFE 1
11139 cat >> confdefs.h <<\EOF
11140 #define _THREADSAFE 1
11143 cat >> confdefs.h <<\EOF
11144 #define _SGI_MP_SOURCE 1
11148 echo $ac_n "checking for thread specific errno""... $ac_c" 1>&6
11149 echo "configure:11150: checking for thread specific errno" >&5
11150 if eval "test \"\${ol_cv_errno_thread_specific+set}\" = set"; then
11151 echo $ac_n "(cached) $ac_c" 1>&6
11154 cat > conftest.$ac_ext <<EOF
11155 #line 11156 "configure"
11156 #include "confdefs.h"
11162 if { (eval echo configure:11163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11164 ol_cv_errno_thread_specific=yes
11166 echo "configure: failed program was:" >&5
11167 cat conftest.$ac_ext >&5
11169 ol_cv_errno_thread_specific=no
11175 echo "$ac_t""$ol_cv_errno_thread_specific" 1>&6
11177 echo $ac_n "checking for thread specific h_errno""... $ac_c" 1>&6
11178 echo "configure:11179: checking for thread specific h_errno" >&5
11179 if eval "test \"\${ol_cv_h_errno_thread_specific+set}\" = set"; then
11180 echo $ac_n "(cached) $ac_c" 1>&6
11183 cat > conftest.$ac_ext <<EOF
11184 #line 11185 "configure"
11185 #include "confdefs.h"
11191 if { (eval echo configure:11192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11193 ol_cv_h_errno_thread_specific=yes
11195 echo "configure: failed program was:" >&5
11196 cat conftest.$ac_ext >&5
11198 ol_cv_h_errno_thread_specific=no
11204 echo "$ac_t""$ol_cv_h_errno_thread_specific" 1>&6
11206 if test $ol_cv_errno_thread_specific != yes \
11207 -o $ol_cv_h_errno_thread_specific != yes ; then
11208 LIBS="$LTHREAD_LIBS $LIBS"
11214 if test $ol_link_threads = no ; then
11215 if test $ol_with_threads = yes ; then
11216 { echo "configure: error: no suitable thread support" 1>&2; exit 1; }
11219 if test $ol_with_threads = auto ; then
11220 echo "configure: warning: no suitable thread support, disabling threads" 1>&2
11224 cat >> confdefs.h <<\EOF
11225 #define NO_THREADS 1
11231 if test $ol_link_threads != no ; then
11232 cat >> confdefs.h <<\EOF
11233 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
11240 if test $ol_with_ldbm_api = auto \
11241 -o $ol_with_ldbm_api = berkeley \
11242 -o $ol_with_ldbm_api = bcompat ; then
11244 if test $ol_with_ldbm_api = bcompat; then \
11245 ol_cv_berkeley_db=no
11246 for ac_hdr in db_185.h db.h
11248 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11249 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11250 echo "configure:11251: checking for $ac_hdr" >&5
11251 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11252 echo $ac_n "(cached) $ac_c" 1>&6
11254 cat > conftest.$ac_ext <<EOF
11255 #line 11256 "configure"
11256 #include "confdefs.h"
11259 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11260 { (eval echo configure:11261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11261 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11262 if test -z "$ac_err"; then
11264 eval "ac_cv_header_$ac_safe=yes"
11267 echo "configure: failed program was:" >&5
11268 cat conftest.$ac_ext >&5
11270 eval "ac_cv_header_$ac_safe=no"
11274 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11275 echo "$ac_t""yes" 1>&6
11276 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11277 cat >> confdefs.h <<EOF
11278 #define $ac_tr_hdr 1
11282 echo "$ac_t""no" 1>&6
11286 if test $ac_cv_header_db_185_h = yes -o $ac_cv_header_db_h = yes; then
11287 echo $ac_n "checking if Berkeley DB header compatibility""... $ac_c" 1>&6
11288 echo "configure:11289: checking if Berkeley DB header compatibility" >&5
11289 if eval "test \"\${ol_cv_header_db1+set}\" = set"; then
11290 echo $ac_n "(cached) $ac_c" 1>&6
11293 cat > conftest.$ac_ext <<EOF
11294 #line 11295 "configure"
11295 #include "confdefs.h"
11298 # include <db_185.h>
11303 /* this check could be improved */
11304 #ifndef DB_VERSION_MAJOR
11305 # define DB_VERSION_MAJOR 1
11308 #if DB_VERSION_MAJOR == 1
11313 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11314 egrep "__db_version_1" >/dev/null 2>&1; then
11316 ol_cv_header_db1=yes
11319 ol_cv_header_db1=no
11325 echo "$ac_t""$ol_cv_header_db1" 1>&6
11327 if test ol_cv_header_db1=yes ; then
11329 if test $ol_cv_lib_db = no ; then
11330 echo $ac_n "checking for Berkeley DB link (default)""... $ac_c" 1>&6
11331 echo "configure:11332: checking for Berkeley DB link (default)" >&5
11332 if eval "test \"\${ol_cv_db_none+set}\" = set"; then
11333 echo $ac_n "(cached) $ac_c" 1>&6
11338 LIBS="$ol_DB_LIB $LIBS"
11340 cat > conftest.$ac_ext <<EOF
11341 #line 11342 "configure"
11342 #include "confdefs.h"
11344 #ifdef HAVE_DB_185_H
11345 # include <db_185.h>
11350 #ifndef DB_VERSION_MAJOR
11351 # define DB_VERSION_MAJOR 1
11355 #define NULL ((void*)0)
11360 #if DB_VERSION_MAJOR > 2
11361 db_env_create( NULL, 0 );
11362 #elif DB_VERSION_MAJOR > 1
11363 db_appexit( NULL );
11365 (void) dbopen( NULL, 0, 0, 0, NULL);
11370 if { (eval echo configure:11371: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11374 echo "configure: failed program was:" >&5
11375 cat conftest.$ac_ext >&5
11385 echo "$ac_t""$ol_cv_db_none" 1>&6
11387 if test $ol_cv_db_none = yes ; then
11392 if test $ol_cv_lib_db = no ; then
11393 echo $ac_n "checking for Berkeley DB link (-ldb)""... $ac_c" 1>&6
11394 echo "configure:11395: checking for Berkeley DB link (-ldb)" >&5
11395 if eval "test \"\${ol_cv_db_db+set}\" = set"; then
11396 echo $ac_n "(cached) $ac_c" 1>&6
11401 LIBS="$ol_DB_LIB $LIBS"
11403 cat > conftest.$ac_ext <<EOF
11404 #line 11405 "configure"
11405 #include "confdefs.h"
11407 #ifdef HAVE_DB_185_H
11408 # include <db_185.h>
11413 #ifndef DB_VERSION_MAJOR
11414 # define DB_VERSION_MAJOR 1
11418 #define NULL ((void*)0)
11423 #if DB_VERSION_MAJOR > 2
11424 db_env_create( NULL, 0 );
11425 #elif DB_VERSION_MAJOR > 1
11426 db_appexit( NULL );
11428 (void) dbopen( NULL, 0, 0, 0, NULL);
11433 if { (eval echo configure:11434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11437 echo "configure: failed program was:" >&5
11438 cat conftest.$ac_ext >&5
11448 echo "$ac_t""$ol_cv_db_db" 1>&6
11450 if test $ol_cv_db_db = yes ; then
11455 if test $ol_cv_lib_db = no ; then
11456 echo $ac_n "checking for Berkeley DB link (-ldb3)""... $ac_c" 1>&6
11457 echo "configure:11458: checking for Berkeley DB link (-ldb3)" >&5
11458 if eval "test \"\${ol_cv_db_db3+set}\" = set"; then
11459 echo $ac_n "(cached) $ac_c" 1>&6
11464 LIBS="$ol_DB_LIB $LIBS"
11466 cat > conftest.$ac_ext <<EOF
11467 #line 11468 "configure"
11468 #include "confdefs.h"
11470 #ifdef HAVE_DB_185_H
11471 # include <db_185.h>
11476 #ifndef DB_VERSION_MAJOR
11477 # define DB_VERSION_MAJOR 1
11481 #define NULL ((void*)0)
11486 #if DB_VERSION_MAJOR > 2
11487 db_env_create( NULL, 0 );
11488 #elif DB_VERSION_MAJOR > 1
11489 db_appexit( NULL );
11491 (void) dbopen( NULL, 0, 0, 0, NULL);
11496 if { (eval echo configure:11497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11500 echo "configure: failed program was:" >&5
11501 cat conftest.$ac_ext >&5
11511 echo "$ac_t""$ol_cv_db_db3" 1>&6
11513 if test $ol_cv_db_db3 = yes ; then
11518 if test $ol_cv_lib_db = no ; then
11519 echo $ac_n "checking for Berkeley DB link (-ldb2)""... $ac_c" 1>&6
11520 echo "configure:11521: checking for Berkeley DB link (-ldb2)" >&5
11521 if eval "test \"\${ol_cv_db_db2+set}\" = set"; then
11522 echo $ac_n "(cached) $ac_c" 1>&6
11527 LIBS="$ol_DB_LIB $LIBS"
11529 cat > conftest.$ac_ext <<EOF
11530 #line 11531 "configure"
11531 #include "confdefs.h"
11533 #ifdef HAVE_DB_185_H
11534 # include <db_185.h>
11539 #ifndef DB_VERSION_MAJOR
11540 # define DB_VERSION_MAJOR 1
11544 #define NULL ((void*)0)
11549 #if DB_VERSION_MAJOR > 2
11550 db_env_create( NULL, 0 );
11551 #elif DB_VERSION_MAJOR > 1
11552 db_appexit( NULL );
11554 (void) dbopen( NULL, 0, 0, 0, NULL);
11559 if { (eval echo configure:11560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11563 echo "configure: failed program was:" >&5
11564 cat conftest.$ac_ext >&5
11574 echo "$ac_t""$ol_cv_db_db2" 1>&6
11576 if test $ol_cv_db_db2 = yes ; then
11581 if test $ol_cv_lib_db = no ; then
11582 echo $ac_n "checking for Berkeley DB link (-ldb1)""... $ac_c" 1>&6
11583 echo "configure:11584: checking for Berkeley DB link (-ldb1)" >&5
11584 if eval "test \"\${ol_cv_db_db1+set}\" = set"; then
11585 echo $ac_n "(cached) $ac_c" 1>&6
11590 LIBS="$ol_DB_LIB $LIBS"
11592 cat > conftest.$ac_ext <<EOF
11593 #line 11594 "configure"
11594 #include "confdefs.h"
11596 #ifdef HAVE_DB_185_H
11597 # include <db_185.h>
11602 #ifndef DB_VERSION_MAJOR
11603 # define DB_VERSION_MAJOR 1
11607 #define NULL ((void*)0)
11612 #if DB_VERSION_MAJOR > 2
11613 db_env_create( NULL, 0 );
11614 #elif DB_VERSION_MAJOR > 1
11615 db_appexit( NULL );
11617 (void) dbopen( NULL, 0, 0, 0, NULL);
11622 if { (eval echo configure:11623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11626 echo "configure: failed program was:" >&5
11627 cat conftest.$ac_ext >&5
11637 echo "$ac_t""$ol_cv_db_db1" 1>&6
11639 if test $ol_cv_db_db1 = yes ; then
11645 if test "$ol_cv_lib_db" != no ; then
11646 ol_cv_berkeley_db=yes
11652 ol_cv_berkeley_db=no
11655 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
11656 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
11657 echo "configure:11658: checking for $ac_hdr" >&5
11658 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
11659 echo $ac_n "(cached) $ac_c" 1>&6
11661 cat > conftest.$ac_ext <<EOF
11662 #line 11663 "configure"
11663 #include "confdefs.h"
11666 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
11667 { (eval echo configure:11668: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
11668 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
11669 if test -z "$ac_err"; then
11671 eval "ac_cv_header_$ac_safe=yes"
11674 echo "configure: failed program was:" >&5
11675 cat conftest.$ac_ext >&5
11677 eval "ac_cv_header_$ac_safe=no"
11681 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
11682 echo "$ac_t""yes" 1>&6
11683 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
11684 cat >> confdefs.h <<EOF
11685 #define $ac_tr_hdr 1
11689 echo "$ac_t""no" 1>&6
11693 if test $ac_cv_header_db_h = yes; then
11695 if test $ol_cv_lib_db = no ; then
11696 echo $ac_n "checking for Berkeley DB link (default)""... $ac_c" 1>&6
11697 echo "configure:11698: checking for Berkeley DB link (default)" >&5
11698 if eval "test \"\${ol_cv_db_none+set}\" = set"; then
11699 echo $ac_n "(cached) $ac_c" 1>&6
11704 LIBS="$ol_DB_LIB $LIBS"
11706 cat > conftest.$ac_ext <<EOF
11707 #line 11708 "configure"
11708 #include "confdefs.h"
11710 #ifdef HAVE_DB_185_H
11711 # include <db_185.h>
11716 #ifndef DB_VERSION_MAJOR
11717 # define DB_VERSION_MAJOR 1
11721 #define NULL ((void*)0)
11726 #if DB_VERSION_MAJOR > 2
11727 db_env_create( NULL, 0 );
11728 #elif DB_VERSION_MAJOR > 1
11729 db_appexit( NULL );
11731 (void) dbopen( NULL, 0, 0, 0, NULL);
11736 if { (eval echo configure:11737: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11740 echo "configure: failed program was:" >&5
11741 cat conftest.$ac_ext >&5
11751 echo "$ac_t""$ol_cv_db_none" 1>&6
11753 if test $ol_cv_db_none = yes ; then
11758 if test $ol_cv_lib_db = no ; then
11759 echo $ac_n "checking for Berkeley DB link (-ldb)""... $ac_c" 1>&6
11760 echo "configure:11761: checking for Berkeley DB link (-ldb)" >&5
11761 if eval "test \"\${ol_cv_db_db+set}\" = set"; then
11762 echo $ac_n "(cached) $ac_c" 1>&6
11767 LIBS="$ol_DB_LIB $LIBS"
11769 cat > conftest.$ac_ext <<EOF
11770 #line 11771 "configure"
11771 #include "confdefs.h"
11773 #ifdef HAVE_DB_185_H
11774 # include <db_185.h>
11779 #ifndef DB_VERSION_MAJOR
11780 # define DB_VERSION_MAJOR 1
11784 #define NULL ((void*)0)
11789 #if DB_VERSION_MAJOR > 2
11790 db_env_create( NULL, 0 );
11791 #elif DB_VERSION_MAJOR > 1
11792 db_appexit( NULL );
11794 (void) dbopen( NULL, 0, 0, 0, NULL);
11799 if { (eval echo configure:11800: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11803 echo "configure: failed program was:" >&5
11804 cat conftest.$ac_ext >&5
11814 echo "$ac_t""$ol_cv_db_db" 1>&6
11816 if test $ol_cv_db_db = yes ; then
11821 if test $ol_cv_lib_db = no ; then
11822 echo $ac_n "checking for Berkeley DB link (-ldb3)""... $ac_c" 1>&6
11823 echo "configure:11824: checking for Berkeley DB link (-ldb3)" >&5
11824 if eval "test \"\${ol_cv_db_db3+set}\" = set"; then
11825 echo $ac_n "(cached) $ac_c" 1>&6
11830 LIBS="$ol_DB_LIB $LIBS"
11832 cat > conftest.$ac_ext <<EOF
11833 #line 11834 "configure"
11834 #include "confdefs.h"
11836 #ifdef HAVE_DB_185_H
11837 # include <db_185.h>
11842 #ifndef DB_VERSION_MAJOR
11843 # define DB_VERSION_MAJOR 1
11847 #define NULL ((void*)0)
11852 #if DB_VERSION_MAJOR > 2
11853 db_env_create( NULL, 0 );
11854 #elif DB_VERSION_MAJOR > 1
11855 db_appexit( NULL );
11857 (void) dbopen( NULL, 0, 0, 0, NULL);
11862 if { (eval echo configure:11863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11866 echo "configure: failed program was:" >&5
11867 cat conftest.$ac_ext >&5
11877 echo "$ac_t""$ol_cv_db_db3" 1>&6
11879 if test $ol_cv_db_db3 = yes ; then
11884 if test $ol_cv_lib_db = no ; then
11885 echo $ac_n "checking for Berkeley DB link (-ldb2)""... $ac_c" 1>&6
11886 echo "configure:11887: checking for Berkeley DB link (-ldb2)" >&5
11887 if eval "test \"\${ol_cv_db_db2+set}\" = set"; then
11888 echo $ac_n "(cached) $ac_c" 1>&6
11893 LIBS="$ol_DB_LIB $LIBS"
11895 cat > conftest.$ac_ext <<EOF
11896 #line 11897 "configure"
11897 #include "confdefs.h"
11899 #ifdef HAVE_DB_185_H
11900 # include <db_185.h>
11905 #ifndef DB_VERSION_MAJOR
11906 # define DB_VERSION_MAJOR 1
11910 #define NULL ((void*)0)
11915 #if DB_VERSION_MAJOR > 2
11916 db_env_create( NULL, 0 );
11917 #elif DB_VERSION_MAJOR > 1
11918 db_appexit( NULL );
11920 (void) dbopen( NULL, 0, 0, 0, NULL);
11925 if { (eval echo configure:11926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11929 echo "configure: failed program was:" >&5
11930 cat conftest.$ac_ext >&5
11940 echo "$ac_t""$ol_cv_db_db2" 1>&6
11942 if test $ol_cv_db_db2 = yes ; then
11947 if test $ol_cv_lib_db = no ; then
11948 echo $ac_n "checking for Berkeley DB link (-ldb1)""... $ac_c" 1>&6
11949 echo "configure:11950: checking for Berkeley DB link (-ldb1)" >&5
11950 if eval "test \"\${ol_cv_db_db1+set}\" = set"; then
11951 echo $ac_n "(cached) $ac_c" 1>&6
11956 LIBS="$ol_DB_LIB $LIBS"
11958 cat > conftest.$ac_ext <<EOF
11959 #line 11960 "configure"
11960 #include "confdefs.h"
11962 #ifdef HAVE_DB_185_H
11963 # include <db_185.h>
11968 #ifndef DB_VERSION_MAJOR
11969 # define DB_VERSION_MAJOR 1
11973 #define NULL ((void*)0)
11978 #if DB_VERSION_MAJOR > 2
11979 db_env_create( NULL, 0 );
11980 #elif DB_VERSION_MAJOR > 1
11981 db_appexit( NULL );
11983 (void) dbopen( NULL, 0, 0, 0, NULL);
11988 if { (eval echo configure:11989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
11992 echo "configure: failed program was:" >&5
11993 cat conftest.$ac_ext >&5
12003 echo "$ac_t""$ol_cv_db_db1" 1>&6
12005 if test $ol_cv_db_db1 = yes ; then
12011 if test "$ol_cv_lib_db" != no ; then
12012 ol_cv_berkeley_db=yes
12013 echo $ac_n "checking for Berkeley DB thread support""... $ac_c" 1>&6
12014 echo "configure:12015: checking for Berkeley DB thread support" >&5
12015 if eval "test \"\${ol_cv_berkeley_db_thread+set}\" = set"; then
12016 echo $ac_n "(cached) $ac_c" 1>&6
12020 if test $ol_cv_lib_db != yes ; then
12021 LIBS="$ol_cv_lib_db"
12024 if test "$cross_compiling" = yes; then
12025 ol_cv_berkeley_db_thread=cross
12027 cat > conftest.$ac_ext <<EOF
12028 #line 12029 "configure"
12029 #include "confdefs.h"
12031 #ifdef HAVE_DB_185_H
12037 #define NULL ((void *)0)
12042 u_int32_t flags = DB_CREATE | DB_THREAD;
12044 #if DB_VERSION_MAJOR > 2
12045 DB_ENV *env = NULL;
12047 rc = db_env_create( &env, 0 );
12050 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
12051 rc = env->open( env, NULL, flags, 0 );
12053 rc = env->open( env, NULL, NULL, flags, 0 );
12059 memset( &env, '\0', sizeof(env) );
12061 rc = db_appinit( NULL, NULL, &env, flags );
12064 db_appexit( &env );
12067 #if DB_VERSION_MAJOR > 2
12068 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
12069 env->remove( env, NULL, DB_FORCE);
12071 env->remove( env, NULL, NULL, DB_FORCE);
12078 if { (eval echo configure:12079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
12080 ol_cv_berkeley_db_thread=yes
12082 echo "configure: failed program was:" >&5
12083 cat conftest.$ac_ext >&5
12085 ol_cv_berkeley_db_thread=no
12093 if test $ol_cv_berkeley_db_thread != no ; then
12094 cat >> confdefs.h <<\EOF
12095 #define HAVE_BERKELEY_DB_THREAD 1
12102 echo "$ac_t""$ol_cv_berkeley_db_thread" 1>&6
12108 if test $ol_cv_berkeley_db != no ; then
12109 cat >> confdefs.h <<\EOF
12110 #define HAVE_BERKELEY_DB 1
12114 ol_link_ldbm=berkeley
12115 ol_with_ldbm_api=db
12117 if test $ol_with_ldbm_type = hash ; then
12118 cat >> confdefs.h <<\EOF
12119 #define LDBM_USE_DBHASH 1
12123 cat >> confdefs.h <<\EOF
12124 #define LDBM_USE_DBBTREE 1
12129 if test $ol_cv_lib_db != yes ; then
12130 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_db"
12135 if test $ol_link_ldbm = no -a $ol_with_ldbm_type = btree ; then
12136 echo "configure: warning: Could not find LDBM with BTREE support" 1>&2
12137 ol_with_ldbm_api=none
12140 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = mdbm ; then
12141 echo $ac_n "checking for MDBM library""... $ac_c" 1>&6
12142 echo "configure:12143: checking for MDBM library" >&5
12143 if eval "test \"\${ol_cv_lib_mdbm+set}\" = set"; then
12144 echo $ac_n "(cached) $ac_c" 1>&6
12147 echo $ac_n "checking for mdbm_set_chain""... $ac_c" 1>&6
12148 echo "configure:12149: checking for mdbm_set_chain" >&5
12149 if eval "test \"\${ac_cv_func_mdbm_set_chain+set}\" = set"; then
12150 echo $ac_n "(cached) $ac_c" 1>&6
12152 cat > conftest.$ac_ext <<EOF
12153 #line 12154 "configure"
12154 #include "confdefs.h"
12155 /* System header to define __stub macros and hopefully few prototypes,
12156 which can conflict with char mdbm_set_chain(); below. */
12157 #include <assert.h>
12158 /* Override any gcc2 internal prototype to avoid an error. */
12159 /* We use char because int might match the return type of a gcc2
12160 builtin and then its argument prototype would still apply. */
12161 char mdbm_set_chain();
12166 /* The GNU C library defines this for functions which it implements
12167 to always fail with ENOSYS. Some functions are actually named
12168 something starting with __ and the normal name is an alias. */
12169 #if defined (__stub_mdbm_set_chain) || defined (__stub___mdbm_set_chain)
12172 f = mdbm_set_chain;
12177 if { (eval echo configure:12178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12179 eval "ac_cv_func_mdbm_set_chain=yes"
12181 echo "configure: failed program was:" >&5
12182 cat conftest.$ac_ext >&5
12184 eval "ac_cv_func_mdbm_set_chain=no"
12189 if eval "test \"`echo '$ac_cv_func_'mdbm_set_chain`\" = yes"; then
12190 echo "$ac_t""yes" 1>&6
12193 echo "$ac_t""no" 1>&6
12195 echo $ac_n "checking for mdbm_set_chain in -lmdbm""... $ac_c" 1>&6
12196 echo "configure:12197: checking for mdbm_set_chain in -lmdbm" >&5
12197 ac_lib_var=`echo mdbm'_'mdbm_set_chain | sed 'y%./+-:%__p__%'`
12198 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12199 echo $ac_n "(cached) $ac_c" 1>&6
12201 ac_save_LIBS="$LIBS"
12202 LIBS="-lmdbm $LIBS"
12203 cat > conftest.$ac_ext <<EOF
12204 #line 12205 "configure"
12205 #include "confdefs.h"
12206 /* Override any gcc2 internal prototype to avoid an error. */
12207 /* We use char because int might match the return type of a gcc2
12208 builtin and then its argument prototype would still apply. */
12209 char mdbm_set_chain();
12215 if { (eval echo configure:12216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12217 eval "ac_cv_lib_$ac_lib_var=yes"
12219 echo "configure: failed program was:" >&5
12220 cat conftest.$ac_ext >&5
12222 eval "ac_cv_lib_$ac_lib_var=no"
12225 LIBS="$ac_save_LIBS"
12228 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12229 echo "$ac_t""yes" 1>&6
12230 ol_cv_lib_mdbm=-lmdbm
12232 echo "$ac_t""no" 1>&6
12243 echo "$ac_t""$ol_cv_lib_mdbm" 1>&6
12246 for ac_hdr in mdbm.h
12248 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12249 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12250 echo "configure:12251: checking for $ac_hdr" >&5
12251 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12252 echo $ac_n "(cached) $ac_c" 1>&6
12254 cat > conftest.$ac_ext <<EOF
12255 #line 12256 "configure"
12256 #include "confdefs.h"
12259 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12260 { (eval echo configure:12261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12261 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12262 if test -z "$ac_err"; then
12264 eval "ac_cv_header_$ac_safe=yes"
12267 echo "configure: failed program was:" >&5
12268 cat conftest.$ac_ext >&5
12270 eval "ac_cv_header_$ac_safe=no"
12274 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12275 echo "$ac_t""yes" 1>&6
12276 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12277 cat >> confdefs.h <<EOF
12278 #define $ac_tr_hdr 1
12282 echo "$ac_t""no" 1>&6
12286 echo $ac_n "checking for db""... $ac_c" 1>&6
12287 echo "configure:12288: checking for db" >&5
12288 if eval "test \"\${ol_cv_mdbm+set}\" = set"; then
12289 echo $ac_n "(cached) $ac_c" 1>&6
12292 if test $ol_cv_lib_mdbm = no -o $ac_cv_header_mdbm_h = no ; then
12300 echo "$ac_t""$ol_cv_mdbm" 1>&6
12301 if test $ol_cv_mdbm = yes ; then
12302 cat >> confdefs.h <<\EOF
12303 #define HAVE_MDBM 1
12309 if test $ol_cv_mdbm = yes ; then
12311 ol_with_ldbm_api=mdbm
12312 if test $ol_cv_lib_mdbm != yes ; then
12313 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_mdbm"
12318 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = gdbm ; then
12319 echo $ac_n "checking for GDBM library""... $ac_c" 1>&6
12320 echo "configure:12321: checking for GDBM library" >&5
12321 if eval "test \"\${ol_cv_lib_gdbm+set}\" = set"; then
12322 echo $ac_n "(cached) $ac_c" 1>&6
12325 echo $ac_n "checking for gdbm_open""... $ac_c" 1>&6
12326 echo "configure:12327: checking for gdbm_open" >&5
12327 if eval "test \"\${ac_cv_func_gdbm_open+set}\" = set"; then
12328 echo $ac_n "(cached) $ac_c" 1>&6
12330 cat > conftest.$ac_ext <<EOF
12331 #line 12332 "configure"
12332 #include "confdefs.h"
12333 /* System header to define __stub macros and hopefully few prototypes,
12334 which can conflict with char gdbm_open(); below. */
12335 #include <assert.h>
12336 /* Override any gcc2 internal prototype to avoid an error. */
12337 /* We use char because int might match the return type of a gcc2
12338 builtin and then its argument prototype would still apply. */
12344 /* The GNU C library defines this for functions which it implements
12345 to always fail with ENOSYS. Some functions are actually named
12346 something starting with __ and the normal name is an alias. */
12347 #if defined (__stub_gdbm_open) || defined (__stub___gdbm_open)
12355 if { (eval echo configure:12356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12357 eval "ac_cv_func_gdbm_open=yes"
12359 echo "configure: failed program was:" >&5
12360 cat conftest.$ac_ext >&5
12362 eval "ac_cv_func_gdbm_open=no"
12367 if eval "test \"`echo '$ac_cv_func_'gdbm_open`\" = yes"; then
12368 echo "$ac_t""yes" 1>&6
12371 echo "$ac_t""no" 1>&6
12373 echo $ac_n "checking for gdbm_open in -lgdbm""... $ac_c" 1>&6
12374 echo "configure:12375: checking for gdbm_open in -lgdbm" >&5
12375 ac_lib_var=`echo gdbm'_'gdbm_open | sed 'y%./+-:%__p__%'`
12376 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12377 echo $ac_n "(cached) $ac_c" 1>&6
12379 ac_save_LIBS="$LIBS"
12380 LIBS="-lgdbm $LIBS"
12381 cat > conftest.$ac_ext <<EOF
12382 #line 12383 "configure"
12383 #include "confdefs.h"
12384 /* Override any gcc2 internal prototype to avoid an error. */
12385 /* We use char because int might match the return type of a gcc2
12386 builtin and then its argument prototype would still apply. */
12393 if { (eval echo configure:12394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12395 eval "ac_cv_lib_$ac_lib_var=yes"
12397 echo "configure: failed program was:" >&5
12398 cat conftest.$ac_ext >&5
12400 eval "ac_cv_lib_$ac_lib_var=no"
12403 LIBS="$ac_save_LIBS"
12406 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12407 echo "$ac_t""yes" 1>&6
12408 ol_cv_lib_gdbm=-lgdbm
12410 echo "$ac_t""no" 1>&6
12421 echo "$ac_t""$ol_cv_lib_gdbm" 1>&6
12424 for ac_hdr in gdbm.h
12426 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12427 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12428 echo "configure:12429: checking for $ac_hdr" >&5
12429 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12430 echo $ac_n "(cached) $ac_c" 1>&6
12432 cat > conftest.$ac_ext <<EOF
12433 #line 12434 "configure"
12434 #include "confdefs.h"
12437 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12438 { (eval echo configure:12439: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12439 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12440 if test -z "$ac_err"; then
12442 eval "ac_cv_header_$ac_safe=yes"
12445 echo "configure: failed program was:" >&5
12446 cat conftest.$ac_ext >&5
12448 eval "ac_cv_header_$ac_safe=no"
12452 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12453 echo "$ac_t""yes" 1>&6
12454 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12455 cat >> confdefs.h <<EOF
12456 #define $ac_tr_hdr 1
12460 echo "$ac_t""no" 1>&6
12464 echo $ac_n "checking for db""... $ac_c" 1>&6
12465 echo "configure:12466: checking for db" >&5
12466 if eval "test \"\${ol_cv_gdbm+set}\" = set"; then
12467 echo $ac_n "(cached) $ac_c" 1>&6
12470 if test $ol_cv_lib_gdbm = no -o $ac_cv_header_gdbm_h = no ; then
12478 echo "$ac_t""$ol_cv_gdbm" 1>&6
12479 if test $ol_cv_gdbm = yes ; then
12480 cat >> confdefs.h <<\EOF
12481 #define HAVE_GDBM 1
12487 if test $ol_cv_gdbm = yes ; then
12489 ol_with_ldbm_api=gdbm
12491 if test $ol_cv_lib_gdbm != yes ; then
12492 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_gdbm"
12497 if test $ol_with_ldbm_api = ndbm ; then
12498 echo $ac_n "checking for NDBM library""... $ac_c" 1>&6
12499 echo "configure:12500: checking for NDBM library" >&5
12500 if eval "test \"\${ol_cv_lib_ndbm+set}\" = set"; then
12501 echo $ac_n "(cached) $ac_c" 1>&6
12504 echo $ac_n "checking for dbm_open""... $ac_c" 1>&6
12505 echo "configure:12506: checking for dbm_open" >&5
12506 if eval "test \"\${ac_cv_func_dbm_open+set}\" = set"; then
12507 echo $ac_n "(cached) $ac_c" 1>&6
12509 cat > conftest.$ac_ext <<EOF
12510 #line 12511 "configure"
12511 #include "confdefs.h"
12512 /* System header to define __stub macros and hopefully few prototypes,
12513 which can conflict with char dbm_open(); below. */
12514 #include <assert.h>
12515 /* Override any gcc2 internal prototype to avoid an error. */
12516 /* We use char because int might match the return type of a gcc2
12517 builtin and then its argument prototype would still apply. */
12523 /* The GNU C library defines this for functions which it implements
12524 to always fail with ENOSYS. Some functions are actually named
12525 something starting with __ and the normal name is an alias. */
12526 #if defined (__stub_dbm_open) || defined (__stub___dbm_open)
12534 if { (eval echo configure:12535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12536 eval "ac_cv_func_dbm_open=yes"
12538 echo "configure: failed program was:" >&5
12539 cat conftest.$ac_ext >&5
12541 eval "ac_cv_func_dbm_open=no"
12546 if eval "test \"`echo '$ac_cv_func_'dbm_open`\" = yes"; then
12547 echo "$ac_t""yes" 1>&6
12550 echo "$ac_t""no" 1>&6
12552 echo $ac_n "checking for dbm_open in -lndbm""... $ac_c" 1>&6
12553 echo "configure:12554: checking for dbm_open in -lndbm" >&5
12554 ac_lib_var=`echo ndbm'_'dbm_open | sed 'y%./+-:%__p__%'`
12555 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12556 echo $ac_n "(cached) $ac_c" 1>&6
12558 ac_save_LIBS="$LIBS"
12559 LIBS="-lndbm $LIBS"
12560 cat > conftest.$ac_ext <<EOF
12561 #line 12562 "configure"
12562 #include "confdefs.h"
12563 /* Override any gcc2 internal prototype to avoid an error. */
12564 /* We use char because int might match the return type of a gcc2
12565 builtin and then its argument prototype would still apply. */
12572 if { (eval echo configure:12573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12574 eval "ac_cv_lib_$ac_lib_var=yes"
12576 echo "configure: failed program was:" >&5
12577 cat conftest.$ac_ext >&5
12579 eval "ac_cv_lib_$ac_lib_var=no"
12582 LIBS="$ac_save_LIBS"
12585 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12586 echo "$ac_t""yes" 1>&6
12587 ol_cv_lib_ndbm=-lndbm
12589 echo "$ac_t""no" 1>&6
12591 echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6
12592 echo "configure:12593: checking for dbm_open in -ldbm" >&5
12593 ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-:%__p__%'`
12594 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12595 echo $ac_n "(cached) $ac_c" 1>&6
12597 ac_save_LIBS="$LIBS"
12599 cat > conftest.$ac_ext <<EOF
12600 #line 12601 "configure"
12601 #include "confdefs.h"
12602 /* Override any gcc2 internal prototype to avoid an error. */
12603 /* We use char because int might match the return type of a gcc2
12604 builtin and then its argument prototype would still apply. */
12611 if { (eval echo configure:12612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12613 eval "ac_cv_lib_$ac_lib_var=yes"
12615 echo "configure: failed program was:" >&5
12616 cat conftest.$ac_ext >&5
12618 eval "ac_cv_lib_$ac_lib_var=no"
12621 LIBS="$ac_save_LIBS"
12624 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12625 echo "$ac_t""yes" 1>&6
12626 ol_cv_lib_ndbm=-ldbm
12628 echo "$ac_t""no" 1>&6
12641 echo "$ac_t""$ol_cv_lib_ndbm" 1>&6
12644 for ac_hdr in ndbm.h
12646 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12647 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12648 echo "configure:12649: checking for $ac_hdr" >&5
12649 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12650 echo $ac_n "(cached) $ac_c" 1>&6
12652 cat > conftest.$ac_ext <<EOF
12653 #line 12654 "configure"
12654 #include "confdefs.h"
12657 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12658 { (eval echo configure:12659: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12659 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12660 if test -z "$ac_err"; then
12662 eval "ac_cv_header_$ac_safe=yes"
12665 echo "configure: failed program was:" >&5
12666 cat conftest.$ac_ext >&5
12668 eval "ac_cv_header_$ac_safe=no"
12672 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12673 echo "$ac_t""yes" 1>&6
12674 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12675 cat >> confdefs.h <<EOF
12676 #define $ac_tr_hdr 1
12680 echo "$ac_t""no" 1>&6
12684 echo $ac_n "checking for db""... $ac_c" 1>&6
12685 echo "configure:12686: checking for db" >&5
12686 if eval "test \"\${ol_cv_ndbm+set}\" = set"; then
12687 echo $ac_n "(cached) $ac_c" 1>&6
12690 if test $ol_cv_lib_ndbm = no -o $ac_cv_header_ndbm_h = no ; then
12698 echo "$ac_t""$ol_cv_ndbm" 1>&6
12699 if test $ol_cv_ndbm = yes ; then
12700 cat >> confdefs.h <<\EOF
12701 #define HAVE_NDBM 1
12707 if test $ol_cv_ndbm = yes ; then
12709 ol_with_ldbm_api=ndbm
12711 if test $ol_cv_lib_ndbm != yes ; then
12712 LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_ndbm"
12717 if test $ol_link_ldbm = no -a $ol_enable_ldbm != no ; then
12718 echo "configure: warning: could not find suitable LDBM backend" 1>&2
12719 if test $ol_enable_ldbm = yes ; then
12720 { echo "configure: error: select appropriate LDBM options or disable" 1>&2; exit 1; }
12723 echo "configure: warning: disabling LDBM" 1>&2
12727 if test $ol_enable_dynamic = yes -a $enable_shared = yes ; then
12728 LINK_BINS_DYNAMIC="yes"
12730 LINK_BINS_DYNAMIC="no"
12733 if test $ol_enable_wrappers != no ; then
12734 for ac_hdr in tcpd.h
12736 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
12737 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
12738 echo "configure:12739: checking for $ac_hdr" >&5
12739 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
12740 echo $ac_n "(cached) $ac_c" 1>&6
12742 cat > conftest.$ac_ext <<EOF
12743 #line 12744 "configure"
12744 #include "confdefs.h"
12747 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
12748 { (eval echo configure:12749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
12749 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
12750 if test -z "$ac_err"; then
12752 eval "ac_cv_header_$ac_safe=yes"
12755 echo "configure: failed program was:" >&5
12756 cat conftest.$ac_ext >&5
12758 eval "ac_cv_header_$ac_safe=no"
12762 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
12763 echo "$ac_t""yes" 1>&6
12764 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
12765 cat >> confdefs.h <<EOF
12766 #define $ac_tr_hdr 1
12770 echo "$ac_t""no" 1>&6
12775 if test $ac_cv_header_tcpd_h != yes ; then
12778 cat > conftest.$ac_ext <<EOF
12779 #line 12780 "configure"
12780 #include "confdefs.h"
12782 int allow_severity = 0;
12783 int deny_severity = 0;
12789 if { (eval echo configure:12790: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
12793 echo "configure: failed program was:" >&5
12794 cat conftest.$ac_ext >&5
12801 if test $have_wrappers = yes ; then
12802 cat >> confdefs.h <<\EOF
12803 #define HAVE_TCPD 1
12808 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
12809 echo "configure:12810: checking for main in -lnsl" >&5
12810 ac_lib_var=`echo nsl'_'main | sed 'y%./+-:%__p__%'`
12811 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12812 echo $ac_n "(cached) $ac_c" 1>&6
12814 ac_save_LIBS="$LIBS"
12816 cat > conftest.$ac_ext <<EOF
12817 #line 12818 "configure"
12818 #include "confdefs.h"
12824 if { (eval echo configure:12825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12826 eval "ac_cv_lib_$ac_lib_var=yes"
12828 echo "configure: failed program was:" >&5
12829 cat conftest.$ac_ext >&5
12831 eval "ac_cv_lib_$ac_lib_var=no"
12834 LIBS="$ac_save_LIBS"
12837 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12838 echo "$ac_t""yes" 1>&6
12839 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
12840 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
12841 cat >> confdefs.h <<EOF
12842 #define $ac_tr_lib 1
12848 echo "$ac_t""no" 1>&6
12852 echo "configure: warning: could not find -lwrap" 1>&2
12853 if test $ol_enable_wrappers = yes ; then
12854 { echo "configure: error: could not find wrappers" 1>&2; exit 1; }
12857 echo "configure: warning: disabling wrappers support" 1>&2
12858 ol_enable_wrappers=no
12863 if test $ol_enable_syslog != no ; then
12864 echo $ac_n "checking for openlog""... $ac_c" 1>&6
12865 echo "configure:12866: checking for openlog" >&5
12866 if eval "test \"\${ac_cv_func_openlog+set}\" = set"; then
12867 echo $ac_n "(cached) $ac_c" 1>&6
12869 cat > conftest.$ac_ext <<EOF
12870 #line 12871 "configure"
12871 #include "confdefs.h"
12872 /* System header to define __stub macros and hopefully few prototypes,
12873 which can conflict with char openlog(); below. */
12874 #include <assert.h>
12875 /* Override any gcc2 internal prototype to avoid an error. */
12876 /* We use char because int might match the return type of a gcc2
12877 builtin and then its argument prototype would still apply. */
12883 /* The GNU C library defines this for functions which it implements
12884 to always fail with ENOSYS. Some functions are actually named
12885 something starting with __ and the normal name is an alias. */
12886 #if defined (__stub_openlog) || defined (__stub___openlog)
12894 if { (eval echo configure:12895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12896 eval "ac_cv_func_openlog=yes"
12898 echo "configure: failed program was:" >&5
12899 cat conftest.$ac_ext >&5
12901 eval "ac_cv_func_openlog=no"
12906 if eval "test \"`echo '$ac_cv_func_'openlog`\" = yes"; then
12907 echo "$ac_t""yes" 1>&6
12910 echo "$ac_t""no" 1>&6
12913 if test $ac_cv_func_openlog = no -a $ol_enable_syslog = yes; then
12914 { echo "configure: error: could not find syslog" 1>&2; exit 1; }
12916 ol_enable_syslog=$ac_cv_func_openlog
12920 if test $ol_enable_sql != no ; then
12921 echo $ac_n "checking for SQLDriverConnect in -liodbc""... $ac_c" 1>&6
12922 echo "configure:12923: checking for SQLDriverConnect in -liodbc" >&5
12923 ac_lib_var=`echo iodbc'_'SQLDriverConnect | sed 'y%./+-:%__p__%'`
12924 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12925 echo $ac_n "(cached) $ac_c" 1>&6
12927 ac_save_LIBS="$LIBS"
12928 LIBS="-liodbc $LIBS"
12929 cat > conftest.$ac_ext <<EOF
12930 #line 12931 "configure"
12931 #include "confdefs.h"
12932 /* Override any gcc2 internal prototype to avoid an error. */
12933 /* We use char because int might match the return type of a gcc2
12934 builtin and then its argument prototype would still apply. */
12935 char SQLDriverConnect();
12941 if { (eval echo configure:12942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12943 eval "ac_cv_lib_$ac_lib_var=yes"
12945 echo "configure: failed program was:" >&5
12946 cat conftest.$ac_ext >&5
12948 eval "ac_cv_lib_$ac_lib_var=no"
12951 LIBS="$ac_save_LIBS"
12954 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12955 echo "$ac_t""yes" 1>&6
12958 echo "$ac_t""no" 1>&6
12962 if test $have_iodbc = yes ; then
12963 ol_link_sql="-liodbc"
12965 echo $ac_n "checking for SQLDriverConnect in -lodbc""... $ac_c" 1>&6
12966 echo "configure:12967: checking for SQLDriverConnect in -lodbc" >&5
12967 ac_lib_var=`echo odbc'_'SQLDriverConnect | sed 'y%./+-:%__p__%'`
12968 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
12969 echo $ac_n "(cached) $ac_c" 1>&6
12971 ac_save_LIBS="$LIBS"
12972 LIBS="-lodbc $LIBS"
12973 cat > conftest.$ac_ext <<EOF
12974 #line 12975 "configure"
12975 #include "confdefs.h"
12976 /* Override any gcc2 internal prototype to avoid an error. */
12977 /* We use char because int might match the return type of a gcc2
12978 builtin and then its argument prototype would still apply. */
12979 char SQLDriverConnect();
12985 if { (eval echo configure:12986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
12987 eval "ac_cv_lib_$ac_lib_var=yes"
12989 echo "configure: failed program was:" >&5
12990 cat conftest.$ac_ext >&5
12992 eval "ac_cv_lib_$ac_lib_var=no"
12995 LIBS="$ac_save_LIBS"
12998 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
12999 echo "$ac_t""yes" 1>&6
13002 echo "$ac_t""no" 1>&6
13006 if test $have_odbc = yes ; then
13007 ol_link_sql="-lodbc"
13011 if test $ol_link_sql != no ; then
13012 SLAPD_SQL_LIBS="$ol_link_sql"
13014 elif test $ol_enable_sql != auto ; then
13015 { echo "configure: error: could not locate suitable ODBC library" 1>&2; exit 1; }
13020 for ac_hdr in termcap.h ncurses.h
13022 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13023 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13024 echo "configure:13025: checking for $ac_hdr" >&5
13025 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13026 echo $ac_n "(cached) $ac_c" 1>&6
13028 cat > conftest.$ac_ext <<EOF
13029 #line 13030 "configure"
13030 #include "confdefs.h"
13033 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13034 { (eval echo configure:13035: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13035 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13036 if test -z "$ac_err"; then
13038 eval "ac_cv_header_$ac_safe=yes"
13041 echo "configure: failed program was:" >&5
13042 cat conftest.$ac_ext >&5
13044 eval "ac_cv_header_$ac_safe=no"
13048 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13049 echo "$ac_t""yes" 1>&6
13050 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13051 cat >> confdefs.h <<EOF
13052 #define $ac_tr_hdr 1
13056 echo "$ac_t""no" 1>&6
13061 if test $ol_link_termcap = no ; then
13062 echo $ac_n "checking for tputs in -ltermcap""... $ac_c" 1>&6
13063 echo "configure:13064: checking for tputs in -ltermcap" >&5
13064 ac_lib_var=`echo termcap'_'tputs | sed 'y%./+-:%__p__%'`
13065 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13066 echo $ac_n "(cached) $ac_c" 1>&6
13068 ac_save_LIBS="$LIBS"
13069 LIBS="-ltermcap $LIBS"
13070 cat > conftest.$ac_ext <<EOF
13071 #line 13072 "configure"
13072 #include "confdefs.h"
13073 /* Override any gcc2 internal prototype to avoid an error. */
13074 /* We use char because int might match the return type of a gcc2
13075 builtin and then its argument prototype would still apply. */
13082 if { (eval echo configure:13083: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13084 eval "ac_cv_lib_$ac_lib_var=yes"
13086 echo "configure: failed program was:" >&5
13087 cat conftest.$ac_ext >&5
13089 eval "ac_cv_lib_$ac_lib_var=no"
13092 LIBS="$ac_save_LIBS"
13095 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13096 echo "$ac_t""yes" 1>&6
13099 echo "$ac_t""no" 1>&6
13103 if test $have_termcap = yes ; then
13104 cat >> confdefs.h <<\EOF
13105 #define HAVE_TERMCAP 1
13108 ol_link_termcap=yes
13109 TERMCAP_LIBS=-ltermcap
13113 if test $ol_link_termcap = no ; then
13114 echo $ac_n "checking for initscr in -lncurses""... $ac_c" 1>&6
13115 echo "configure:13116: checking for initscr in -lncurses" >&5
13116 ac_lib_var=`echo ncurses'_'initscr | sed 'y%./+-:%__p__%'`
13117 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13118 echo $ac_n "(cached) $ac_c" 1>&6
13120 ac_save_LIBS="$LIBS"
13121 LIBS="-lncurses $LIBS"
13122 cat > conftest.$ac_ext <<EOF
13123 #line 13124 "configure"
13124 #include "confdefs.h"
13125 /* Override any gcc2 internal prototype to avoid an error. */
13126 /* We use char because int might match the return type of a gcc2
13127 builtin and then its argument prototype would still apply. */
13134 if { (eval echo configure:13135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13136 eval "ac_cv_lib_$ac_lib_var=yes"
13138 echo "configure: failed program was:" >&5
13139 cat conftest.$ac_ext >&5
13141 eval "ac_cv_lib_$ac_lib_var=no"
13144 LIBS="$ac_save_LIBS"
13147 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13148 echo "$ac_t""yes" 1>&6
13151 echo "$ac_t""no" 1>&6
13155 if test $have_ncurses = yes ; then
13156 cat >> confdefs.h <<\EOF
13157 #define HAVE_NCURSES 1
13160 ol_link_termcap=yes
13161 TERMCAP_LIBS=-lncurses
13165 if test $ol_link_termcap = no ; then
13166 cat >> confdefs.h <<\EOF
13167 #define NO_TERMCAP 1
13175 if test $ol_with_cyrus_sasl != no ; then
13176 for ac_hdr in sasl.h
13178 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13179 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13180 echo "configure:13181: checking for $ac_hdr" >&5
13181 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13182 echo $ac_n "(cached) $ac_c" 1>&6
13184 cat > conftest.$ac_ext <<EOF
13185 #line 13186 "configure"
13186 #include "confdefs.h"
13189 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13190 { (eval echo configure:13191: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13191 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13192 if test -z "$ac_err"; then
13194 eval "ac_cv_header_$ac_safe=yes"
13197 echo "configure: failed program was:" >&5
13198 cat conftest.$ac_ext >&5
13200 eval "ac_cv_header_$ac_safe=no"
13204 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13205 echo "$ac_t""yes" 1>&6
13206 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13207 cat >> confdefs.h <<EOF
13208 #define $ac_tr_hdr 1
13212 echo "$ac_t""no" 1>&6
13217 if test $ac_cv_header_sasl_h = yes ; then
13218 echo $ac_n "checking for sasl_client_init in -lsasl""... $ac_c" 1>&6
13219 echo "configure:13220: checking for sasl_client_init in -lsasl" >&5
13220 ac_lib_var=`echo sasl'_'sasl_client_init | sed 'y%./+-:%__p__%'`
13221 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13222 echo $ac_n "(cached) $ac_c" 1>&6
13224 ac_save_LIBS="$LIBS"
13225 LIBS="-lsasl $LIBS"
13226 cat > conftest.$ac_ext <<EOF
13227 #line 13228 "configure"
13228 #include "confdefs.h"
13229 /* Override any gcc2 internal prototype to avoid an error. */
13230 /* We use char because int might match the return type of a gcc2
13231 builtin and then its argument prototype would still apply. */
13232 char sasl_client_init();
13238 if { (eval echo configure:13239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13240 eval "ac_cv_lib_$ac_lib_var=yes"
13242 echo "configure: failed program was:" >&5
13243 cat conftest.$ac_ext >&5
13245 eval "ac_cv_lib_$ac_lib_var=no"
13248 LIBS="$ac_save_LIBS"
13251 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13252 echo "$ac_t""yes" 1>&6
13253 have_cyrus_sasl=yes
13255 echo "$ac_t""no" 1>&6
13260 if test $have_cyrus_sasl != no ; then
13262 cat >> confdefs.h <<\EOF
13263 #define HAVE_CYRUS_SASL 1
13270 if test $ol_link_sasl = no ; then
13271 if test $ol_with_cyrus_sasl != auto ; then
13272 { echo "configure: error: Could not locate Cyrus SASL" 1>&2; exit 1; }
13274 echo "configure: warning: Could not locate Cyrus SASL" 1>&2
13275 echo "configure: warning: SASL authentication not supported!" 1>&2
13276 if test $ol_link_tls = no ; then
13277 echo "configure: warning: Strong authentication not supported!" 1>&2
13282 echo "configure: warning: SASL authentication not supported!" 1>&2
13283 if test $ol_link_tls = no ; then
13284 echo "configure: warning: Strong authentication not supported!" 1>&2
13288 if test $cross_compiling != yes ; then
13290 if test -r /dev/urandom ; then
13291 dev="/dev/urandom";
13292 elif test -r /idev/urandom ; then
13293 dev="/idev/urandom";
13294 elif test -r /dev/srandom ; then
13295 dev="/dev/srandom";
13296 elif test -r /dev/random ; then
13298 elif test -r /idev/random ; then
13299 dev="/idev/random";
13302 if test $dev != no ; then
13303 cat >> confdefs.h <<EOF
13304 #define URANDOM_DEVICE "$dev"
13311 if test $ol_with_fetch != no ; then
13313 LIBS="-lfetch -lcom_err $LIBS"
13314 echo $ac_n "checking fetch(3) library""... $ac_c" 1>&6
13315 echo "configure:13316: checking fetch(3) library" >&5
13316 if eval "test \"\${ol_cv_lib_fetch+set}\" = set"; then
13317 echo $ac_n "(cached) $ac_c" 1>&6
13320 cat > conftest.$ac_ext <<EOF
13321 #line 13322 "configure"
13322 #include "confdefs.h"
13324 #include <sys/param.h>
13328 struct url *u = fetchParseURL("file:///");
13331 if { (eval echo configure:13332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13333 ol_cv_lib_fetch=yes
13335 echo "configure: failed program was:" >&5
13336 cat conftest.$ac_ext >&5
13343 echo "$ac_t""$ol_cv_lib_fetch" 1>&6
13345 if test $ol_cv_lib_fetch != no ; then
13346 ol_link_fetch="-lfetch -lcom_err"
13347 cat >> confdefs.h <<\EOF
13348 #define HAVE_FETCH 1
13354 if test $ol_cv_lib_fetch != no ; then
13355 LDIF_LIBS="$LDIF_LIBS $ol_link_fetch"
13356 ol_link_fetch=freebsd
13358 elif test $ol_with_fetch != auto ; then
13359 { echo "configure: error: no suitable API for --with-fetch=$ol_with_fetch" 1>&2; exit 1; }
13363 ol_link_readline=no
13364 if test $ol_with_readline != no ; then
13365 for ac_hdr in readline/readline.h readline/history.h
13367 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
13368 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
13369 echo "configure:13370: checking for $ac_hdr" >&5
13370 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then
13371 echo $ac_n "(cached) $ac_c" 1>&6
13373 cat > conftest.$ac_ext <<EOF
13374 #line 13375 "configure"
13375 #include "confdefs.h"
13378 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13379 { (eval echo configure:13380: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13380 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13381 if test -z "$ac_err"; then
13383 eval "ac_cv_header_$ac_safe=yes"
13386 echo "configure: failed program was:" >&5
13387 cat conftest.$ac_ext >&5
13389 eval "ac_cv_header_$ac_safe=no"
13393 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
13394 echo "$ac_t""yes" 1>&6
13395 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
13396 cat >> confdefs.h <<EOF
13397 #define $ac_tr_hdr 1
13401 echo "$ac_t""no" 1>&6
13406 if test $ac_cv_header_readline_readline_h = yes ; then
13408 LIBS="$TERMCAP_LIBS $LIBS"
13409 echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
13410 echo "configure:13411: checking for readline in -lreadline" >&5
13411 ac_lib_var=`echo readline'_'readline | sed 'y%./+-:%__p__%'`
13412 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13413 echo $ac_n "(cached) $ac_c" 1>&6
13415 ac_save_LIBS="$LIBS"
13416 LIBS="-lreadline $LIBS"
13417 cat > conftest.$ac_ext <<EOF
13418 #line 13419 "configure"
13419 #include "confdefs.h"
13420 /* Override any gcc2 internal prototype to avoid an error. */
13421 /* We use char because int might match the return type of a gcc2
13422 builtin and then its argument prototype would still apply. */
13429 if { (eval echo configure:13430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13431 eval "ac_cv_lib_$ac_lib_var=yes"
13433 echo "configure: failed program was:" >&5
13434 cat conftest.$ac_ext >&5
13436 eval "ac_cv_lib_$ac_lib_var=no"
13439 LIBS="$ac_save_LIBS"
13442 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13443 echo "$ac_t""yes" 1>&6
13446 echo "$ac_t""no" 1>&6
13452 if test $have_readline = yes ; then
13453 ol_with_readline=found
13454 ol_link_readline=yes
13456 READLINE_LIBS="-lreadline"
13461 if test $ol_link_readline = yes ; then
13462 cat >> confdefs.h <<\EOF
13463 #define HAVE_READLINE 1
13469 if test $ol_enable_crypt != no ; then
13470 echo $ac_n "checking for crypt""... $ac_c" 1>&6
13471 echo "configure:13472: checking for crypt" >&5
13472 if eval "test \"\${ac_cv_func_crypt+set}\" = set"; then
13473 echo $ac_n "(cached) $ac_c" 1>&6
13475 cat > conftest.$ac_ext <<EOF
13476 #line 13477 "configure"
13477 #include "confdefs.h"
13478 /* System header to define __stub macros and hopefully few prototypes,
13479 which can conflict with char crypt(); below. */
13480 #include <assert.h>
13481 /* Override any gcc2 internal prototype to avoid an error. */
13482 /* We use char because int might match the return type of a gcc2
13483 builtin and then its argument prototype would still apply. */
13489 /* The GNU C library defines this for functions which it implements
13490 to always fail with ENOSYS. Some functions are actually named
13491 something starting with __ and the normal name is an alias. */
13492 #if defined (__stub_crypt) || defined (__stub___crypt)
13500 if { (eval echo configure:13501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13502 eval "ac_cv_func_crypt=yes"
13504 echo "configure: failed program was:" >&5
13505 cat conftest.$ac_ext >&5
13507 eval "ac_cv_func_crypt=no"
13512 if eval "test \"`echo '$ac_cv_func_'crypt`\" = yes"; then
13513 echo "$ac_t""yes" 1>&6
13516 echo "$ac_t""no" 1>&6
13518 echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
13519 echo "configure:13520: checking for crypt in -lcrypt" >&5
13520 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-:%__p__%'`
13521 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13522 echo $ac_n "(cached) $ac_c" 1>&6
13524 ac_save_LIBS="$LIBS"
13525 LIBS="-lcrypt $LIBS"
13526 cat > conftest.$ac_ext <<EOF
13527 #line 13528 "configure"
13528 #include "confdefs.h"
13529 /* Override any gcc2 internal prototype to avoid an error. */
13530 /* We use char because int might match the return type of a gcc2
13531 builtin and then its argument prototype would still apply. */
13538 if { (eval echo configure:13539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13540 eval "ac_cv_lib_$ac_lib_var=yes"
13542 echo "configure: failed program was:" >&5
13543 cat conftest.$ac_ext >&5
13545 eval "ac_cv_lib_$ac_lib_var=no"
13548 LIBS="$ac_save_LIBS"
13551 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13552 echo "$ac_t""yes" 1>&6
13553 LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
13556 echo "$ac_t""no" 1>&6
13563 if test $have_crypt = yes ; then
13564 cat >> confdefs.h <<\EOF
13565 #define HAVE_CRYPT 1
13569 echo "configure: warning: could not find crypt" 1>&2
13570 if test $ol_enable_crypt = yes ; then
13571 { echo "configure: error: could not find crypt" 1>&2; exit 1; }
13574 echo "configure: warning: disabling crypt support" 1>&2
13579 if test $ol_enable_proctitle != no ; then
13580 echo $ac_n "checking for setproctitle""... $ac_c" 1>&6
13581 echo "configure:13582: checking for setproctitle" >&5
13582 if eval "test \"\${ac_cv_func_setproctitle+set}\" = set"; then
13583 echo $ac_n "(cached) $ac_c" 1>&6
13585 cat > conftest.$ac_ext <<EOF
13586 #line 13587 "configure"
13587 #include "confdefs.h"
13588 /* System header to define __stub macros and hopefully few prototypes,
13589 which can conflict with char setproctitle(); below. */
13590 #include <assert.h>
13591 /* Override any gcc2 internal prototype to avoid an error. */
13592 /* We use char because int might match the return type of a gcc2
13593 builtin and then its argument prototype would still apply. */
13594 char setproctitle();
13599 /* The GNU C library defines this for functions which it implements
13600 to always fail with ENOSYS. Some functions are actually named
13601 something starting with __ and the normal name is an alias. */
13602 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
13610 if { (eval echo configure:13611: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13612 eval "ac_cv_func_setproctitle=yes"
13614 echo "configure: failed program was:" >&5
13615 cat conftest.$ac_ext >&5
13617 eval "ac_cv_func_setproctitle=no"
13622 if eval "test \"`echo '$ac_cv_func_'setproctitle`\" = yes"; then
13623 echo "$ac_t""yes" 1>&6
13624 have_setproctitle=yes
13626 echo "$ac_t""no" 1>&6
13628 echo $ac_n "checking for setproctitle in -lutil""... $ac_c" 1>&6
13629 echo "configure:13630: checking for setproctitle in -lutil" >&5
13630 ac_lib_var=`echo util'_'setproctitle | sed 'y%./+-:%__p__%'`
13631 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
13632 echo $ac_n "(cached) $ac_c" 1>&6
13634 ac_save_LIBS="$LIBS"
13635 LIBS="-lutil $LIBS"
13636 cat > conftest.$ac_ext <<EOF
13637 #line 13638 "configure"
13638 #include "confdefs.h"
13639 /* Override any gcc2 internal prototype to avoid an error. */
13640 /* We use char because int might match the return type of a gcc2
13641 builtin and then its argument prototype would still apply. */
13642 char setproctitle();
13648 if { (eval echo configure:13649: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
13650 eval "ac_cv_lib_$ac_lib_var=yes"
13652 echo "configure: failed program was:" >&5
13653 cat conftest.$ac_ext >&5
13655 eval "ac_cv_lib_$ac_lib_var=no"
13658 LIBS="$ac_save_LIBS"
13661 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
13662 echo "$ac_t""yes" 1>&6
13663 have_setproctitle=yes
13664 LUTIL_LIBS="$LUTIL_LIBS -lutil"
13666 echo "$ac_t""no" 1>&6
13667 have_setproctitle=no
13668 LIBOBJS="$LIBOBJS setproctitle.o"
13669 LIBSRCS="$LIBSRCS setproctitle.c"
13675 if test $have_setproctitle = yes ; then
13676 cat >> confdefs.h <<\EOF
13677 #define HAVE_SETPROCTITLE 1
13683 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
13684 echo "configure:13685: checking for ANSI C header files" >&5
13685 if eval "test \"\${ac_cv_header_stdc+set}\" = set"; then
13686 echo $ac_n "(cached) $ac_c" 1>&6
13688 cat > conftest.$ac_ext <<EOF
13689 #line 13690 "configure"
13690 #include "confdefs.h"
13691 #include <stdlib.h>
13692 #include <stdarg.h>
13693 #include <string.h>
13696 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
13697 { (eval echo configure:13698: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
13698 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
13699 if test -z "$ac_err"; then
13701 ac_cv_header_stdc=yes
13704 echo "configure: failed program was:" >&5
13705 cat conftest.$ac_ext >&5
13707 ac_cv_header_stdc=no
13711 if test $ac_cv_header_stdc = yes; then
13712 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13713 cat > conftest.$ac_ext <<EOF
13714 #line 13715 "configure"
13715 #include "confdefs.h"
13716 #include <string.h>
13718 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13719 egrep "memchr" >/dev/null 2>&1; then
13723 ac_cv_header_stdc=no
13729 if test $ac_cv_header_stdc = yes; then
13730 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13731 cat > conftest.$ac_ext <<EOF
13732 #line 13733 "configure"
13733 #include "confdefs.h"
13734 #include <stdlib.h>
13736 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13737 egrep "free" >/dev/null 2>&1; then
13741 ac_cv_header_stdc=no
13747 if test $ac_cv_header_stdc = yes; then
13748 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13749 if test "$cross_compiling" = yes; then
13752 cat > conftest.$ac_ext <<EOF
13753 #line 13754 "configure"
13754 #include "confdefs.h"
13756 #if ((' ' & 0x0FF) == 0x020)
13757 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13758 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13760 #define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13761 || ('j' <= (c) && (c) <= 'r') \
13762 || ('s' <= (c) && (c) <= 'z'))
13763 #define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13765 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13766 int main () { int i; for (i = 0; i < 256; i++)
13767 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13771 if { (eval echo configure:13772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
13775 echo "configure: failed program was:" >&5
13776 cat conftest.$ac_ext >&5
13778 ac_cv_header_stdc=no
13786 echo "$ac_t""$ac_cv_header_stdc" 1>&6
13787 if test $ac_cv_header_stdc = yes; then
13788 cat >> confdefs.h <<\EOF
13789 #define STDC_HEADERS 1
13794 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
13795 echo "configure:13796: checking for mode_t" >&5
13796 if eval "test \"\${ac_cv_type_mode_t+set}\" = set"; then
13797 echo $ac_n "(cached) $ac_c" 1>&6
13799 cat > conftest.$ac_ext <<EOF
13800 #line 13801 "configure"
13801 #include "confdefs.h"
13802 #include <sys/types.h>
13804 #include <stdlib.h>
13805 #include <stddef.h>
13809 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13810 egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13812 eval "ac_cv_type_mode_t=yes"
13815 eval "ac_cv_type_mode_t=no"
13820 if eval "test \"`echo '$ac_cv_type_'mode_t`\" = yes"; then
13821 echo "$ac_t""yes" 1>&6
13823 echo "$ac_t""no" 1>&6
13824 cat >> confdefs.h <<EOF
13830 echo $ac_n "checking for off_t""... $ac_c" 1>&6
13831 echo "configure:13832: checking for off_t" >&5
13832 if eval "test \"\${ac_cv_type_off_t+set}\" = set"; then
13833 echo $ac_n "(cached) $ac_c" 1>&6
13835 cat > conftest.$ac_ext <<EOF
13836 #line 13837 "configure"
13837 #include "confdefs.h"
13838 #include <sys/types.h>
13840 #include <stdlib.h>
13841 #include <stddef.h>
13845 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13846 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13848 eval "ac_cv_type_off_t=yes"
13851 eval "ac_cv_type_off_t=no"
13856 if eval "test \"`echo '$ac_cv_type_'off_t`\" = yes"; then
13857 echo "$ac_t""yes" 1>&6
13859 echo "$ac_t""no" 1>&6
13860 cat >> confdefs.h <<EOF
13866 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
13867 echo "configure:13868: checking for pid_t" >&5
13868 if eval "test \"\${ac_cv_type_pid_t+set}\" = set"; then
13869 echo $ac_n "(cached) $ac_c" 1>&6
13871 cat > conftest.$ac_ext <<EOF
13872 #line 13873 "configure"
13873 #include "confdefs.h"
13874 #include <sys/types.h>
13876 #include <stdlib.h>
13877 #include <stddef.h>
13881 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13882 egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13884 eval "ac_cv_type_pid_t=yes"
13887 eval "ac_cv_type_pid_t=no"
13892 if eval "test \"`echo '$ac_cv_type_'pid_t`\" = yes"; then
13893 echo "$ac_t""yes" 1>&6
13895 echo "$ac_t""no" 1>&6
13896 cat >> confdefs.h <<EOF
13902 echo $ac_n "checking for ptrdiff_t""... $ac_c" 1>&6
13903 echo "configure:13904: checking for ptrdiff_t" >&5
13904 if eval "test \"\${am_cv_type_ptrdiff_t+set}\" = set"; then
13905 echo $ac_n "(cached) $ac_c" 1>&6
13907 cat > conftest.$ac_ext <<EOF
13908 #line 13909 "configure"
13909 #include "confdefs.h"
13910 #include <stddef.h>
13915 if { (eval echo configure:13916: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
13917 am_cv_type_ptrdiff_t=yes
13919 echo "configure: failed program was:" >&5
13920 cat conftest.$ac_ext >&5
13922 am_cv_type_ptrdiff_t=no
13927 echo "$ac_t""$am_cv_type_ptrdiff_t" 1>&6
13928 if test $am_cv_type_ptrdiff_t = yes; then
13929 cat >> confdefs.h <<\EOF
13930 #define HAVE_PTRDIFF_T 1
13935 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
13936 echo "configure:13937: checking return type of signal handlers" >&5
13937 if eval "test \"\${ac_cv_type_signal+set}\" = set"; then
13938 echo $ac_n "(cached) $ac_c" 1>&6
13940 cat > conftest.$ac_ext <<EOF
13941 #line 13942 "configure"
13942 #include "confdefs.h"
13943 #include <sys/types.h>
13944 #include <signal.h>
13949 extern "C" void (*signal (int, void (*)(int)))(int);
13951 void (*signal ()) ();
13958 if { (eval echo configure:13959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
13960 ac_cv_type_signal=void
13962 echo "configure: failed program was:" >&5
13963 cat conftest.$ac_ext >&5
13965 ac_cv_type_signal=int
13970 echo "$ac_t""$ac_cv_type_signal" 1>&6
13971 cat >> confdefs.h <<EOF
13972 #define RETSIGTYPE $ac_cv_type_signal
13976 echo $ac_n "checking for size_t""... $ac_c" 1>&6
13977 echo "configure:13978: checking for size_t" >&5
13978 if eval "test \"\${ac_cv_type_size_t+set}\" = set"; then
13979 echo $ac_n "(cached) $ac_c" 1>&6
13981 cat > conftest.$ac_ext <<EOF
13982 #line 13983 "configure"
13983 #include "confdefs.h"
13984 #include <sys/types.h>
13986 #include <stdlib.h>
13987 #include <stddef.h>
13991 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13992 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
13994 eval "ac_cv_type_size_t=yes"
13997 eval "ac_cv_type_size_t=no"
14002 if eval "test \"`echo '$ac_cv_type_'size_t`\" = yes"; then
14003 echo "$ac_t""yes" 1>&6
14005 echo "$ac_t""no" 1>&6
14006 cat >> confdefs.h <<EOF
14007 #define size_t unsigned
14013 echo $ac_n "checking for ssize_t""... $ac_c" 1>&6
14014 echo "configure:14015: checking for ssize_t" >&5
14015 if eval "test \"\${ac_cv_type_ssize_t+set}\" = set"; then
14016 echo $ac_n "(cached) $ac_c" 1>&6
14018 cat > conftest.$ac_ext <<EOF
14019 #line 14020 "configure"
14020 #include "confdefs.h"
14021 #include <sys/types.h>
14023 #include <stdlib.h>
14024 #include <stddef.h>
14028 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14029 egrep "(^|[^a-zA-Z_0-9])ssize_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
14031 eval "ac_cv_type_ssize_t=yes"
14034 eval "ac_cv_type_ssize_t=no"
14039 if eval "test \"`echo '$ac_cv_type_'ssize_t`\" = yes"; then
14040 echo "$ac_t""yes" 1>&6
14042 echo "$ac_t""no" 1>&6
14043 cat >> confdefs.h <<EOF
14044 #define ssize_t signed int
14049 echo $ac_n "checking for caddr_t""... $ac_c" 1>&6
14050 echo "configure:14051: checking for caddr_t" >&5
14051 if eval "test \"\${ac_cv_type_caddr_t+set}\" = set"; then
14052 echo $ac_n "(cached) $ac_c" 1>&6
14054 cat > conftest.$ac_ext <<EOF
14055 #line 14056 "configure"
14056 #include "confdefs.h"
14057 #include <sys/types.h>
14059 #include <stdlib.h>
14060 #include <stddef.h>
14064 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14065 egrep "(^|[^a-zA-Z_0-9])caddr_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
14067 eval "ac_cv_type_caddr_t=yes"
14070 eval "ac_cv_type_caddr_t=no"
14075 if eval "test \"`echo '$ac_cv_type_'caddr_t`\" = yes"; then
14076 echo "$ac_t""yes" 1>&6
14078 echo "$ac_t""no" 1>&6
14079 cat >> confdefs.h <<EOF
14080 #define caddr_t char *
14086 echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
14087 echo "configure:14088: checking for socklen_t" >&5
14088 if eval "test \"\${ol_cv_type_socklen_t+set}\" = set"; then
14089 echo $ac_n "(cached) $ac_c" 1>&6
14091 cat > conftest.$ac_ext <<EOF
14092 #line 14093 "configure"
14093 #include "confdefs.h"
14095 #ifdef HAVE_SYS_TYPES_H
14096 #include <sys/types.h>
14098 #ifdef HAVE_SYS_SOCKET_H
14099 #include <sys/socket.h>
14106 if { (eval echo configure:14107: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14108 ol_cv_type_socklen_t=yes
14110 echo "configure: failed program was:" >&5
14111 cat conftest.$ac_ext >&5
14113 ol_cv_type_socklen_t=no
14118 echo "$ac_t""$ol_cv_type_socklen_t" 1>&6
14119 if test $ol_cv_type_socklen_t = no; then
14120 cat >> confdefs.h <<\EOF
14121 #define socklen_t int
14126 echo $ac_n "checking for member st_blksize in aggregate type struct stat""... $ac_c" 1>&6
14127 echo "configure:14128: checking for member st_blksize in aggregate type struct stat" >&5
14128 if eval "test \"\${ac_cv_c_struct_member_st_blksize+set}\" = set"; then
14129 echo $ac_n "(cached) $ac_c" 1>&6
14131 cat > conftest.$ac_ext <<EOF
14132 #line 14133 "configure"
14133 #include "confdefs.h"
14134 #include <sys/types.h>
14135 #include <sys/stat.h>
14137 struct stat foo; foo.st_blksize;
14140 if { (eval echo configure:14141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14142 ac_cv_c_struct_member_st_blksize=yes
14144 echo "configure: failed program was:" >&5
14145 cat conftest.$ac_ext >&5
14147 ac_cv_c_struct_member_st_blksize=no
14152 echo "$ac_t""$ac_cv_c_struct_member_st_blksize" 1>&6
14153 st_blksize="$ac_cv_c_struct_member_st_blksize"
14154 if test $ac_cv_c_struct_member_st_blksize = yes; then
14155 cat >> confdefs.h <<\EOF
14156 #define HAVE_ST_BLKSIZE 1
14161 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
14162 echo "configure:14163: checking whether time.h and sys/time.h may both be included" >&5
14163 if eval "test \"\${ac_cv_header_time+set}\" = set"; then
14164 echo $ac_n "(cached) $ac_c" 1>&6
14166 cat > conftest.$ac_ext <<EOF
14167 #line 14168 "configure"
14168 #include "confdefs.h"
14169 #include <sys/types.h>
14170 #include <sys/time.h>
14176 if { (eval echo configure:14177: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14178 ac_cv_header_time=yes
14180 echo "configure: failed program was:" >&5
14181 cat conftest.$ac_ext >&5
14183 ac_cv_header_time=no
14188 echo "$ac_t""$ac_cv_header_time" 1>&6
14189 if test $ac_cv_header_time = yes; then
14190 cat >> confdefs.h <<\EOF
14191 #define TIME_WITH_SYS_TIME 1
14196 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
14197 echo "configure:14198: checking whether struct tm is in sys/time.h or time.h" >&5
14198 if eval "test \"\${ac_cv_struct_tm+set}\" = set"; then
14199 echo $ac_n "(cached) $ac_c" 1>&6
14201 cat > conftest.$ac_ext <<EOF
14202 #line 14203 "configure"
14203 #include "confdefs.h"
14204 #include <sys/types.h>
14207 struct tm *tp; tp->tm_sec;
14210 if { (eval echo configure:14211: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14212 ac_cv_struct_tm=time.h
14214 echo "configure: failed program was:" >&5
14215 cat conftest.$ac_ext >&5
14217 ac_cv_struct_tm=sys/time.h
14222 echo "$ac_t""$ac_cv_struct_tm" 1>&6
14223 if test $ac_cv_struct_tm = sys/time.h; then
14224 cat >> confdefs.h <<\EOF
14225 #define TM_IN_SYS_TIME 1
14230 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
14231 echo "configure:14232: checking for uid_t in sys/types.h" >&5
14232 if eval "test \"\${ac_cv_type_uid_t+set}\" = set"; then
14233 echo $ac_n "(cached) $ac_c" 1>&6
14235 cat > conftest.$ac_ext <<EOF
14236 #line 14237 "configure"
14237 #include "confdefs.h"
14238 #include <sys/types.h>
14240 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14241 egrep "uid_t" >/dev/null 2>&1; then
14243 ac_cv_type_uid_t=yes
14246 ac_cv_type_uid_t=no
14252 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
14253 if test $ac_cv_type_uid_t = no; then
14254 cat >> confdefs.h <<\EOF
14258 cat >> confdefs.h <<\EOF
14264 echo $ac_n "checking for sig_atomic_t""... $ac_c" 1>&6
14265 echo "configure:14266: checking for sig_atomic_t" >&5
14266 if eval "test \"\${ol_cv_type_sig_atomic_t+set}\" = set"; then
14267 echo $ac_n "(cached) $ac_c" 1>&6
14269 cat > conftest.$ac_ext <<EOF
14270 #line 14271 "configure"
14271 #include "confdefs.h"
14272 #include <signal.h>
14274 sig_atomic_t atomic;
14277 if { (eval echo configure:14278: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14279 ol_cv_type_sig_atomic_t=yes
14281 echo "configure: failed program was:" >&5
14282 cat conftest.$ac_ext >&5
14284 ol_cv_type_sig_atomic_t=no
14289 echo "$ac_t""$ol_cv_type_sig_atomic_t" 1>&6
14290 if test $ol_cv_type_sig_atomic_t = no; then
14291 cat >> confdefs.h <<\EOF
14292 #define sig_atomic_t int
14299 # test for pw_gecos in struct passwd
14300 echo $ac_n "checking struct passwd for pw_gecos""... $ac_c" 1>&6
14301 echo "configure:14302: checking struct passwd for pw_gecos" >&5
14302 if eval "test \"\${ol_cv_struct_passwd_pw_gecos+set}\" = set"; then
14303 echo $ac_n "(cached) $ac_c" 1>&6
14306 cat > conftest.$ac_ext <<EOF
14307 #line 14308 "configure"
14308 #include "confdefs.h"
14313 pwd.pw_gecos = pwd.pw_name;
14317 if { (eval echo configure:14318: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14319 ol_cv_struct_passwd_pw_gecos=yes
14321 echo "configure: failed program was:" >&5
14322 cat conftest.$ac_ext >&5
14324 ol_cv_struct_passwd_pw_gecos=no
14329 echo "$ac_t""$ol_cv_struct_passwd_pw_gecos" 1>&6
14330 if test $ol_cv_struct_passwd_pw_gecos = yes ; then
14331 cat >> confdefs.h <<\EOF
14332 #define HAVE_PW_GECOS 1
14337 # test for pw_passwd in struct passwd
14338 echo $ac_n "checking struct passwd for pw_passwd""... $ac_c" 1>&6
14339 echo "configure:14340: checking struct passwd for pw_passwd" >&5
14340 if eval "test \"\${ol_cv_struct_passwd_pw_passwd+set}\" = set"; then
14341 echo $ac_n "(cached) $ac_c" 1>&6
14344 cat > conftest.$ac_ext <<EOF
14345 #line 14346 "configure"
14346 #include "confdefs.h"
14351 pwd.pw_passwd = pwd.pw_name;
14355 if { (eval echo configure:14356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14357 ol_cv_struct_passwd_pw_passwd=yes
14359 echo "configure: failed program was:" >&5
14360 cat conftest.$ac_ext >&5
14362 ol_cv_struct_passwd_pw_passwd=no
14367 echo "$ac_t""$ol_cv_struct_passwd_pw_passwd" 1>&6
14368 if test $ol_cv_struct_passwd_pw_passwd = yes ; then
14369 cat >> confdefs.h <<\EOF
14370 #define HAVE_PW_PASSWD 1
14376 echo $ac_n "checking if toupper() requires islower()""... $ac_c" 1>&6
14377 echo "configure:14378: checking if toupper() requires islower()" >&5
14378 if eval "test \"\${ol_cv_c_upper_lower+set}\" = set"; then
14379 echo $ac_n "(cached) $ac_c" 1>&6
14382 if test "$cross_compiling" = yes; then
14383 ol_cv_c_upper_lower=safe
14385 cat > conftest.$ac_ext <<EOF
14386 #line 14387 "configure"
14387 #include "confdefs.h"
14392 if ('C' == toupper('C'))
14398 if { (eval echo configure:14399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14400 ol_cv_c_upper_lower=no
14402 echo "configure: failed program was:" >&5
14403 cat conftest.$ac_ext >&5
14405 ol_cv_c_upper_lower=yes
14412 echo "$ac_t""$ol_cv_c_upper_lower" 1>&6
14413 if test $ol_cv_c_upper_lower != no ; then
14414 cat >> confdefs.h <<\EOF
14415 #define C_UPPER_LOWER 1
14420 echo $ac_n "checking for working const""... $ac_c" 1>&6
14421 echo "configure:14422: checking for working const" >&5
14422 if eval "test \"\${ac_cv_c_const+set}\" = set"; then
14423 echo $ac_n "(cached) $ac_c" 1>&6
14425 cat > conftest.$ac_ext <<EOF
14426 #line 14427 "configure"
14427 #include "confdefs.h"
14431 /* Ultrix mips cc rejects this. */
14432 typedef int charset[2]; const charset x;
14433 /* SunOS 4.1.1 cc rejects this. */
14434 char const *const *ccp;
14436 /* NEC SVR4.0.2 mips cc rejects this. */
14437 struct point {int x, y;};
14438 static struct point const zero = {0,0};
14439 /* AIX XL C 1.02.0.0 rejects this.
14440 It does not let you subtract one const X* pointer from another in an arm
14441 of an if-expression whose if-part is not a constant expression */
14442 const char *g = "string";
14443 ccp = &g + (g ? g-g : 0);
14444 /* HPUX 7.0 cc rejects these. */
14447 ccp = (char const *const *) p;
14448 { /* SCO 3.2v4 cc rejects this. */
14450 char const *s = 0 ? (char *) 0 : (char const *) 0;
14454 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
14455 int x[] = {25, 17};
14456 const int *foo = &x[0];
14459 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14460 typedef const int *iptr;
14464 { /* AIX XL C 1.02.0.0 rejects this saying
14465 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14466 struct s { int j; const int *ap[3]; };
14467 struct s *b; b->j = 5;
14469 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14470 const int foo = 10;
14475 if { (eval echo configure:14476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14479 echo "configure: failed program was:" >&5
14480 cat conftest.$ac_ext >&5
14487 echo "$ac_t""$ac_cv_c_const" 1>&6
14488 if test $ac_cv_c_const = no; then
14489 cat >> confdefs.h <<\EOF
14495 echo $ac_n "checking if compiler understands volatile""... $ac_c" 1>&6
14496 echo "configure:14497: checking if compiler understands volatile" >&5
14497 if eval "test \"\${ol_cv_c_volatile+set}\" = set"; then
14498 echo $ac_n "(cached) $ac_c" 1>&6
14500 cat > conftest.$ac_ext <<EOF
14501 #line 14502 "configure"
14502 #include "confdefs.h"
14505 volatile int a; int * volatile b = x ? &y : &z;
14506 /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
14510 if { (eval echo configure:14511: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14512 ol_cv_c_volatile=yes
14514 echo "configure: failed program was:" >&5
14515 cat conftest.$ac_ext >&5
14517 ol_cv_c_volatile=no
14522 echo "$ac_t""$ol_cv_c_volatile" 1>&6
14523 if test $ol_cv_c_volatile = yes; then
14526 cat >> confdefs.h <<\EOF
14533 if test $cross_compiling = yes ; then
14534 cat >> confdefs.h <<\EOF
14535 #define CROSS_COMPILING 1
14539 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
14540 echo "configure:14541: checking whether byte ordering is bigendian" >&5
14541 if eval "test \"\${ac_cv_c_bigendian+set}\" = set"; then
14542 echo $ac_n "(cached) $ac_c" 1>&6
14544 ac_cv_c_bigendian=unknown
14545 # See if sys/param.h defines the BYTE_ORDER macro.
14546 cat > conftest.$ac_ext <<EOF
14547 #line 14548 "configure"
14548 #include "confdefs.h"
14549 #include <sys/types.h>
14550 #include <sys/param.h>
14553 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
14554 bogus endian macros
14558 if { (eval echo configure:14559: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14560 # It does; now see whether it defined to BIG_ENDIAN or not.
14561 cat > conftest.$ac_ext <<EOF
14562 #line 14563 "configure"
14563 #include "confdefs.h"
14564 #include <sys/types.h>
14565 #include <sys/param.h>
14568 #if BYTE_ORDER != BIG_ENDIAN
14573 if { (eval echo configure:14574: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14575 ac_cv_c_bigendian=yes
14577 echo "configure: failed program was:" >&5
14578 cat conftest.$ac_ext >&5
14580 ac_cv_c_bigendian=no
14584 echo "configure: failed program was:" >&5
14585 cat conftest.$ac_ext >&5
14588 if test $ac_cv_c_bigendian = unknown; then
14589 if test "$cross_compiling" = yes; then
14590 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
14592 cat > conftest.$ac_ext <<EOF
14593 #line 14594 "configure"
14594 #include "confdefs.h"
14596 /* Are we little or big endian? From Harbison&Steele. */
14600 char c[sizeof (long)];
14603 exit (u.c[sizeof (long) - 1] == 1);
14606 if { (eval echo configure:14607: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14608 ac_cv_c_bigendian=no
14610 echo "configure: failed program was:" >&5
14611 cat conftest.$ac_ext >&5
14613 ac_cv_c_bigendian=yes
14621 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
14622 if test $ac_cv_c_bigendian = yes; then
14623 cat >> confdefs.h <<\EOF
14624 #define WORDS_BIGENDIAN 1
14631 echo $ac_n "checking size of short""... $ac_c" 1>&6
14632 echo "configure:14633: checking size of short" >&5
14633 if eval "test \"\${ac_cv_sizeof_short+set}\" = set"; then
14634 echo $ac_n "(cached) $ac_c" 1>&6
14636 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14637 cat > conftest.$ac_ext <<EOF
14638 #line 14639 "configure"
14639 #include "confdefs.h"
14640 #include "confdefs.h"
14641 #include <sys/types.h>
14645 switch (0) case 0: case (sizeof (short) == $ac_size):;
14648 if { (eval echo configure:14649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14650 ac_cv_sizeof_short=$ac_size
14652 echo "configure: failed program was:" >&5
14653 cat conftest.$ac_ext >&5
14656 if test x$ac_cv_sizeof_short != x ; then break; fi
14661 if test x$ac_cv_sizeof_short = x ; then
14662 { echo "configure: error: cannot determine a size for short" 1>&2; exit 1; }
14664 echo "$ac_t""$ac_cv_sizeof_short" 1>&6
14665 cat >> confdefs.h <<EOF
14666 #define SIZEOF_SHORT $ac_cv_sizeof_short
14670 echo $ac_n "checking size of int""... $ac_c" 1>&6
14671 echo "configure:14672: checking size of int" >&5
14672 if eval "test \"\${ac_cv_sizeof_int+set}\" = set"; then
14673 echo $ac_n "(cached) $ac_c" 1>&6
14675 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14676 cat > conftest.$ac_ext <<EOF
14677 #line 14678 "configure"
14678 #include "confdefs.h"
14679 #include "confdefs.h"
14680 #include <sys/types.h>
14684 switch (0) case 0: case (sizeof (int) == $ac_size):;
14687 if { (eval echo configure:14688: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14689 ac_cv_sizeof_int=$ac_size
14691 echo "configure: failed program was:" >&5
14692 cat conftest.$ac_ext >&5
14695 if test x$ac_cv_sizeof_int != x ; then break; fi
14700 if test x$ac_cv_sizeof_int = x ; then
14701 { echo "configure: error: cannot determine a size for int" 1>&2; exit 1; }
14703 echo "$ac_t""$ac_cv_sizeof_int" 1>&6
14704 cat >> confdefs.h <<EOF
14705 #define SIZEOF_INT $ac_cv_sizeof_int
14709 echo $ac_n "checking size of long""... $ac_c" 1>&6
14710 echo "configure:14711: checking size of long" >&5
14711 if eval "test \"\${ac_cv_sizeof_long+set}\" = set"; then
14712 echo $ac_n "(cached) $ac_c" 1>&6
14714 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
14715 cat > conftest.$ac_ext <<EOF
14716 #line 14717 "configure"
14717 #include "confdefs.h"
14718 #include "confdefs.h"
14719 #include <sys/types.h>
14723 switch (0) case 0: case (sizeof (long) == $ac_size):;
14726 if { (eval echo configure:14727: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
14728 ac_cv_sizeof_long=$ac_size
14730 echo "configure: failed program was:" >&5
14731 cat conftest.$ac_ext >&5
14734 if test x$ac_cv_sizeof_long != x ; then break; fi
14739 if test x$ac_cv_sizeof_long = x ; then
14740 { echo "configure: error: cannot determine a size for long" 1>&2; exit 1; }
14742 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
14743 cat >> confdefs.h <<EOF
14744 #define SIZEOF_LONG $ac_cv_sizeof_long
14749 if test "$ac_cv_sizeof_int" -lt 4 ; then
14750 echo "configure: warning: OpenLDAP requires 'int' to be 32 bits or greater." 1>&2
14752 cat >> confdefs.h <<\EOF
14753 #define LBER_INT_T long
14757 cat >> confdefs.h <<\EOF
14758 #define LBER_INT_T int
14763 cat >> confdefs.h <<\EOF
14764 #define LBER_LEN_T long
14767 cat >> confdefs.h <<\EOF
14768 #define LBER_SOCKET_T int
14771 cat >> confdefs.h <<\EOF
14772 #define LBER_TAG_T long
14776 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
14777 echo "configure:14778: checking for 8-bit clean memcmp" >&5
14778 if eval "test \"\${ac_cv_func_memcmp_clean+set}\" = set"; then
14779 echo $ac_n "(cached) $ac_c" 1>&6
14781 if test "$cross_compiling" = yes; then
14782 ac_cv_func_memcmp_clean=no
14784 cat > conftest.$ac_ext <<EOF
14785 #line 14786 "configure"
14786 #include "confdefs.h"
14790 char c0 = 0x40, c1 = 0x80, c2 = 0x81;
14791 exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
14795 if { (eval echo configure:14796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
14797 ac_cv_func_memcmp_clean=yes
14799 echo "configure: failed program was:" >&5
14800 cat conftest.$ac_ext >&5
14802 ac_cv_func_memcmp_clean=no
14809 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
14810 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
14812 echo $ac_n "checking for strftime""... $ac_c" 1>&6
14813 echo "configure:14814: checking for strftime" >&5
14814 if eval "test \"\${ac_cv_func_strftime+set}\" = set"; then
14815 echo $ac_n "(cached) $ac_c" 1>&6
14817 cat > conftest.$ac_ext <<EOF
14818 #line 14819 "configure"
14819 #include "confdefs.h"
14820 /* System header to define __stub macros and hopefully few prototypes,
14821 which can conflict with char strftime(); below. */
14822 #include <assert.h>
14823 /* Override any gcc2 internal prototype to avoid an error. */
14824 /* We use char because int might match the return type of a gcc2
14825 builtin and then its argument prototype would still apply. */
14831 /* The GNU C library defines this for functions which it implements
14832 to always fail with ENOSYS. Some functions are actually named
14833 something starting with __ and the normal name is an alias. */
14834 #if defined (__stub_strftime) || defined (__stub___strftime)
14842 if { (eval echo configure:14843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14844 eval "ac_cv_func_strftime=yes"
14846 echo "configure: failed program was:" >&5
14847 cat conftest.$ac_ext >&5
14849 eval "ac_cv_func_strftime=no"
14854 if eval "test \"`echo '$ac_cv_func_'strftime`\" = yes"; then
14855 echo "$ac_t""yes" 1>&6
14856 cat >> confdefs.h <<\EOF
14857 #define HAVE_STRFTIME 1
14861 echo "$ac_t""no" 1>&6
14862 # strftime is in -lintl on SCO UNIX.
14863 echo $ac_n "checking for strftime in -lintl""... $ac_c" 1>&6
14864 echo "configure:14865: checking for strftime in -lintl" >&5
14865 ac_lib_var=`echo intl'_'strftime | sed 'y%./+-:%__p__%'`
14866 if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
14867 echo $ac_n "(cached) $ac_c" 1>&6
14869 ac_save_LIBS="$LIBS"
14870 LIBS="-lintl $LIBS"
14871 cat > conftest.$ac_ext <<EOF
14872 #line 14873 "configure"
14873 #include "confdefs.h"
14874 /* Override any gcc2 internal prototype to avoid an error. */
14875 /* We use char because int might match the return type of a gcc2
14876 builtin and then its argument prototype would still apply. */
14883 if { (eval echo configure:14884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14885 eval "ac_cv_lib_$ac_lib_var=yes"
14887 echo "configure: failed program was:" >&5
14888 cat conftest.$ac_ext >&5
14890 eval "ac_cv_lib_$ac_lib_var=no"
14893 LIBS="$ac_save_LIBS"
14896 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
14897 echo "$ac_t""yes" 1>&6
14898 cat >> confdefs.h <<\EOF
14899 #define HAVE_STRFTIME 1
14902 LIBS="-lintl $LIBS"
14904 echo "$ac_t""no" 1>&6
14910 echo $ac_n "checking for inet_aton()""... $ac_c" 1>&6
14911 echo "configure:14912: checking for inet_aton()" >&5
14912 if eval "test \"\${ol_cv_func_inet_aton+set}\" = set"; then
14913 echo $ac_n "(cached) $ac_c" 1>&6
14915 cat > conftest.$ac_ext <<EOF
14916 #line 14917 "configure"
14917 #include "confdefs.h"
14919 #ifdef HAVE_SYS_TYPES_H
14920 # include <sys/types.h>
14922 #ifdef HAVE_SYS_SOCKET_H
14923 # include <sys/socket.h>
14924 # ifdef HAVE_SYS_SELECT_H
14925 # include <sys/select.h>
14927 # include <netinet/in.h>
14928 # ifdef HAVE_ARPA_INET_H
14929 # include <arpa/inet.h>
14935 int rc = inet_aton( "255.255.255.255", &in );
14938 if { (eval echo configure:14939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14940 ol_cv_func_inet_aton=yes
14942 echo "configure: failed program was:" >&5
14943 cat conftest.$ac_ext >&5
14945 ol_cv_func_inet_aton=no
14950 echo "$ac_t""$ol_cv_func_inet_aton" 1>&6
14951 if test $ol_cv_func_inet_aton != no; then
14952 cat >> confdefs.h <<\EOF
14953 #define HAVE_INET_ATON 1
14959 echo $ac_n "checking for _spawnlp""... $ac_c" 1>&6
14960 echo "configure:14961: checking for _spawnlp" >&5
14961 if eval "test \"\${ac_cv_func__spawnlp+set}\" = set"; then
14962 echo $ac_n "(cached) $ac_c" 1>&6
14964 cat > conftest.$ac_ext <<EOF
14965 #line 14966 "configure"
14966 #include "confdefs.h"
14967 /* System header to define __stub macros and hopefully few prototypes,
14968 which can conflict with char _spawnlp(); below. */
14969 #include <assert.h>
14970 /* Override any gcc2 internal prototype to avoid an error. */
14971 /* We use char because int might match the return type of a gcc2
14972 builtin and then its argument prototype would still apply. */
14978 /* The GNU C library defines this for functions which it implements
14979 to always fail with ENOSYS. Some functions are actually named
14980 something starting with __ and the normal name is an alias. */
14981 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
14989 if { (eval echo configure:14990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
14991 eval "ac_cv_func__spawnlp=yes"
14993 echo "configure: failed program was:" >&5
14994 cat conftest.$ac_ext >&5
14996 eval "ac_cv_func__spawnlp=no"
15001 if eval "test \"`echo '$ac_cv_func_'_spawnlp`\" = yes"; then
15002 echo "$ac_t""yes" 1>&6
15003 cat >> confdefs.h <<\EOF
15004 #define HAVE_SPAWNLP 1
15008 echo "$ac_t""no" 1>&6
15012 echo $ac_n "checking for _snprintf""... $ac_c" 1>&6
15013 echo "configure:15014: checking for _snprintf" >&5
15014 if eval "test \"\${ac_cv_func__snprintf+set}\" = set"; then
15015 echo $ac_n "(cached) $ac_c" 1>&6
15017 cat > conftest.$ac_ext <<EOF
15018 #line 15019 "configure"
15019 #include "confdefs.h"
15020 /* System header to define __stub macros and hopefully few prototypes,
15021 which can conflict with char _snprintf(); below. */
15022 #include <assert.h>
15023 /* Override any gcc2 internal prototype to avoid an error. */
15024 /* We use char because int might match the return type of a gcc2
15025 builtin and then its argument prototype would still apply. */
15031 /* The GNU C library defines this for functions which it implements
15032 to always fail with ENOSYS. Some functions are actually named
15033 something starting with __ and the normal name is an alias. */
15034 #if defined (__stub__snprintf) || defined (__stub____snprintf)
15042 if { (eval echo configure:15043: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15044 eval "ac_cv_func__snprintf=yes"
15046 echo "configure: failed program was:" >&5
15047 cat conftest.$ac_ext >&5
15049 eval "ac_cv_func__snprintf=no"
15054 if eval "test \"`echo '$ac_cv_func_'_snprintf`\" = yes"; then
15055 echo "$ac_t""yes" 1>&6
15056 ac_cv_func_snprintf=yes
15057 cat >> confdefs.h <<\EOF
15058 #define snprintf _snprintf
15063 echo "$ac_t""no" 1>&6
15067 echo $ac_n "checking for _vsnprintf""... $ac_c" 1>&6
15068 echo "configure:15069: checking for _vsnprintf" >&5
15069 if eval "test \"\${ac_cv_func__vsnprintf+set}\" = set"; then
15070 echo $ac_n "(cached) $ac_c" 1>&6
15072 cat > conftest.$ac_ext <<EOF
15073 #line 15074 "configure"
15074 #include "confdefs.h"
15075 /* System header to define __stub macros and hopefully few prototypes,
15076 which can conflict with char _vsnprintf(); below. */
15077 #include <assert.h>
15078 /* Override any gcc2 internal prototype to avoid an error. */
15079 /* We use char because int might match the return type of a gcc2
15080 builtin and then its argument prototype would still apply. */
15086 /* The GNU C library defines this for functions which it implements
15087 to always fail with ENOSYS. Some functions are actually named
15088 something starting with __ and the normal name is an alias. */
15089 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
15097 if { (eval echo configure:15098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15099 eval "ac_cv_func__vsnprintf=yes"
15101 echo "configure: failed program was:" >&5
15102 cat conftest.$ac_ext >&5
15104 eval "ac_cv_func__vsnprintf=no"
15109 if eval "test \"`echo '$ac_cv_func_'_vsnprintf`\" = yes"; then
15110 echo "$ac_t""yes" 1>&6
15111 ac_cv_func_vsnprintf=yes
15112 cat >> confdefs.h <<\EOF
15113 #define vsnprintf _vsnprintf
15118 echo "$ac_t""no" 1>&6
15122 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
15123 echo "configure:15124: checking for vprintf" >&5
15124 if eval "test \"\${ac_cv_func_vprintf+set}\" = set"; then
15125 echo $ac_n "(cached) $ac_c" 1>&6
15127 cat > conftest.$ac_ext <<EOF
15128 #line 15129 "configure"
15129 #include "confdefs.h"
15130 /* System header to define __stub macros and hopefully few prototypes,
15131 which can conflict with char vprintf(); below. */
15132 #include <assert.h>
15133 /* Override any gcc2 internal prototype to avoid an error. */
15134 /* We use char because int might match the return type of a gcc2
15135 builtin and then its argument prototype would still apply. */
15141 /* The GNU C library defines this for functions which it implements
15142 to always fail with ENOSYS. Some functions are actually named
15143 something starting with __ and the normal name is an alias. */
15144 #if defined (__stub_vprintf) || defined (__stub___vprintf)
15152 if { (eval echo configure:15153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15154 eval "ac_cv_func_vprintf=yes"
15156 echo "configure: failed program was:" >&5
15157 cat conftest.$ac_ext >&5
15159 eval "ac_cv_func_vprintf=no"
15164 if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
15165 echo "$ac_t""yes" 1>&6
15166 cat >> confdefs.h <<\EOF
15167 #define HAVE_VPRINTF 1
15171 echo "$ac_t""no" 1>&6
15174 if test "$ac_cv_func_vprintf" != yes; then
15175 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
15176 echo "configure:15177: checking for _doprnt" >&5
15177 if eval "test \"\${ac_cv_func__doprnt+set}\" = set"; then
15178 echo $ac_n "(cached) $ac_c" 1>&6
15180 cat > conftest.$ac_ext <<EOF
15181 #line 15182 "configure"
15182 #include "confdefs.h"
15183 /* System header to define __stub macros and hopefully few prototypes,
15184 which can conflict with char _doprnt(); below. */
15185 #include <assert.h>
15186 /* Override any gcc2 internal prototype to avoid an error. */
15187 /* We use char because int might match the return type of a gcc2
15188 builtin and then its argument prototype would still apply. */
15194 /* The GNU C library defines this for functions which it implements
15195 to always fail with ENOSYS. Some functions are actually named
15196 something starting with __ and the normal name is an alias. */
15197 #if defined (__stub__doprnt) || defined (__stub____doprnt)
15205 if { (eval echo configure:15206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15207 eval "ac_cv_func__doprnt=yes"
15209 echo "configure: failed program was:" >&5
15210 cat conftest.$ac_ext >&5
15212 eval "ac_cv_func__doprnt=no"
15217 if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
15218 echo "$ac_t""yes" 1>&6
15219 cat >> confdefs.h <<\EOF
15220 #define HAVE_DOPRNT 1
15224 echo "$ac_t""no" 1>&6
15230 if test $ac_cv_func_vprintf = yes ; then
15231 for ac_func in vsnprintf vsprintf
15233 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15234 echo "configure:15235: checking for $ac_func" >&5
15235 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15236 echo $ac_n "(cached) $ac_c" 1>&6
15238 cat > conftest.$ac_ext <<EOF
15239 #line 15240 "configure"
15240 #include "confdefs.h"
15241 /* System header to define __stub macros and hopefully few prototypes,
15242 which can conflict with char $ac_func(); below. */
15243 #include <assert.h>
15244 /* Override any gcc2 internal prototype to avoid an error. */
15245 /* We use char because int might match the return type of a gcc2
15246 builtin and then its argument prototype would still apply. */
15252 /* The GNU C library defines this for functions which it implements
15253 to always fail with ENOSYS. Some functions are actually named
15254 something starting with __ and the normal name is an alias. */
15255 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15263 if { (eval echo configure:15264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15265 eval "ac_cv_func_$ac_func=yes"
15267 echo "configure: failed program was:" >&5
15268 cat conftest.$ac_ext >&5
15270 eval "ac_cv_func_$ac_func=no"
15275 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15276 echo "$ac_t""yes" 1>&6
15277 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15278 cat >> confdefs.h <<EOF
15279 #define $ac_tr_func 1
15283 echo "$ac_t""no" 1>&6
15341 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15342 echo "configure:15343: checking for $ac_func" >&5
15343 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15344 echo $ac_n "(cached) $ac_c" 1>&6
15346 cat > conftest.$ac_ext <<EOF
15347 #line 15348 "configure"
15348 #include "confdefs.h"
15349 /* System header to define __stub macros and hopefully few prototypes,
15350 which can conflict with char $ac_func(); below. */
15351 #include <assert.h>
15352 /* Override any gcc2 internal prototype to avoid an error. */
15353 /* We use char because int might match the return type of a gcc2
15354 builtin and then its argument prototype would still apply. */
15360 /* The GNU C library defines this for functions which it implements
15361 to always fail with ENOSYS. Some functions are actually named
15362 something starting with __ and the normal name is an alias. */
15363 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15371 if { (eval echo configure:15372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15373 eval "ac_cv_func_$ac_func=yes"
15375 echo "configure: failed program was:" >&5
15376 cat conftest.$ac_ext >&5
15378 eval "ac_cv_func_$ac_func=no"
15383 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15384 echo "$ac_t""yes" 1>&6
15385 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15386 cat >> confdefs.h <<EOF
15387 #define $ac_tr_func 1
15391 echo "$ac_t""no" 1>&6
15396 for ac_func in getopt tempnam
15398 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
15399 echo "configure:15400: checking for $ac_func" >&5
15400 if eval "test \"\${ac_cv_func_$ac_func+set}\" = set"; then
15401 echo $ac_n "(cached) $ac_c" 1>&6
15403 cat > conftest.$ac_ext <<EOF
15404 #line 15405 "configure"
15405 #include "confdefs.h"
15406 /* System header to define __stub macros and hopefully few prototypes,
15407 which can conflict with char $ac_func(); below. */
15408 #include <assert.h>
15409 /* Override any gcc2 internal prototype to avoid an error. */
15410 /* We use char because int might match the return type of a gcc2
15411 builtin and then its argument prototype would still apply. */
15417 /* The GNU C library defines this for functions which it implements
15418 to always fail with ENOSYS. Some functions are actually named
15419 something starting with __ and the normal name is an alias. */
15420 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15428 if { (eval echo configure:15429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15430 eval "ac_cv_func_$ac_func=yes"
15432 echo "configure: failed program was:" >&5
15433 cat conftest.$ac_ext >&5
15435 eval "ac_cv_func_$ac_func=no"
15440 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
15441 echo "$ac_t""yes" 1>&6
15442 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
15443 cat >> confdefs.h <<EOF
15444 #define $ac_tr_func 1
15448 echo "$ac_t""no" 1>&6
15449 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
15455 if test "$ac_cv_func_getopt" != yes; then
15456 LIBSRCS="$LIBSRCS getopt.c"
15459 if test "$ac_cv_func_tempnam" != yes; then
15460 LIBSRCS="$LIBSRCS tempnam.c"
15463 # Check Configuration
15464 echo $ac_n "checking declaration of sys_errlist""... $ac_c" 1>&6
15465 echo "configure:15466: checking declaration of sys_errlist" >&5
15466 if eval "test \"\${ol_cv_dcl_sys_errlist+set}\" = set"; then
15467 echo $ac_n "(cached) $ac_c" 1>&6
15470 cat > conftest.$ac_ext <<EOF
15471 #line 15472 "configure"
15472 #include "confdefs.h"
15475 #include <sys/types.h>
15478 #include <stdlib.h>
15481 char *c = (char *) *sys_errlist
15484 if { (eval echo configure:15485: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
15486 ol_cv_dcl_sys_errlist=yes
15487 ol_cv_have_sys_errlist=yes
15489 echo "configure: failed program was:" >&5
15490 cat conftest.$ac_ext >&5
15492 ol_cv_dcl_sys_errlist=no
15497 echo "$ac_t""$ol_cv_dcl_sys_errlist" 1>&6
15499 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
15500 if test $ol_cv_dcl_sys_errlist = no ; then
15501 cat >> confdefs.h <<\EOF
15502 #define DECL_SYS_ERRLIST 1
15506 echo $ac_n "checking existence of sys_errlist""... $ac_c" 1>&6
15507 echo "configure:15508: checking existence of sys_errlist" >&5
15508 if eval "test \"\${ol_cv_have_sys_errlist+set}\" = set"; then
15509 echo $ac_n "(cached) $ac_c" 1>&6
15512 cat > conftest.$ac_ext <<EOF
15513 #line 15514 "configure"
15514 #include "confdefs.h"
15517 char *c = (char *) *sys_errlist
15520 if { (eval echo configure:15521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
15522 ol_cv_have_sys_errlist=yes
15524 echo "configure: failed program was:" >&5
15525 cat conftest.$ac_ext >&5
15527 ol_cv_have_sys_errlist=no
15532 echo "$ac_t""$ol_cv_have_sys_errlist" 1>&6
15534 if test $ol_cv_have_sys_errlist = yes ; then
15535 cat >> confdefs.h <<\EOF
15536 #define HAVE_SYS_ERRLIST 1
15543 if test "$ol_enable_debug" != no ; then
15544 cat >> confdefs.h <<\EOF
15545 #define LDAP_DEBUG 1
15549 if test "$ol_enable_syslog" = yes ; then
15550 cat >> confdefs.h <<\EOF
15551 #define LDAP_SYSLOG 1
15555 if test "$ol_enable_libui" = yes ; then
15556 cat >> confdefs.h <<\EOF
15557 #define LDAP_LIBUI 1
15561 if test "$ol_enable_cache" = no ; then
15562 cat >> confdefs.h <<\EOF
15563 #define LDAP_NOCACHE 1
15567 if test "$ol_link_kbind" != no ; then
15568 cat >> confdefs.h <<\EOF
15569 #define LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND LDAP_VENDOR_VERSION
15573 if test "$ol_enable_proctitle" != no ; then
15574 cat >> confdefs.h <<\EOF
15575 #define LDAP_PROCTITLE 1
15579 if test "$ol_enable_referrals" != no ; then
15580 cat >> confdefs.h <<\EOF
15581 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
15585 if test "$ol_enable_local" != no; then
15586 cat >> confdefs.h <<\EOF
15587 #define LDAP_PF_LOCAL 1
15591 if test "$ol_enable_ipv6" != no; then
15592 cat >> confdefs.h <<\EOF
15593 #define LDAP_PF_INET6 1
15597 if test "$ol_enable_cleartext" != no ; then
15598 cat >> confdefs.h <<\EOF
15599 #define SLAPD_CLEARTEXT 1
15603 if test "$ol_enable_crypt" != no ; then
15604 cat >> confdefs.h <<\EOF
15605 #define SLAPD_CRYPT 1
15609 if test "$ol_link_kpasswd" != no ; then
15610 cat >> confdefs.h <<\EOF
15611 #define SLAPD_KPASSWD 1
15615 if test "$ol_link_spasswd" != no ; then
15616 cat >> confdefs.h <<\EOF
15617 #define SLAPD_SPASSWD 1
15621 if test "$ol_enable_multimaster" != no ; then
15622 cat >> confdefs.h <<\EOF
15623 #define SLAPD_MULTIMASTER 1
15627 if test "$ol_enable_phonetic" != no ; then
15628 cat >> confdefs.h <<\EOF
15629 #define SLAPD_PHONETIC 1
15633 if test "$ol_enable_rlookups" != no ; then
15634 cat >> confdefs.h <<\EOF
15635 #define SLAPD_RLOOKUPS 1
15639 if test "$ol_enable_aci" != no ; then
15640 cat >> confdefs.h <<\EOF
15641 #define SLAPD_ACI_ENABLED 1
15646 if test "$ol_link_modules" != no ; then
15647 cat >> confdefs.h <<\EOF
15648 #define SLAPD_MODULES 1
15652 SLAPD_MODULES_LDFLAGS="-dlopen self"
15655 if test "$ol_link_dnssrv" != no ; then
15656 cat >> confdefs.h <<\EOF
15657 #define SLAPD_DNSSRV 1
15662 if test "$ol_with_dnssrv_module" != static ; then
15663 cat >> confdefs.h <<\EOF
15664 #define SLAPD_DNSSRV_DYNAMIC 1
15668 BUILD_DNSSRV_DYNAMIC=shared
15669 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-dnssrv/back_dnssrv.la"
15673 if test "$ol_enable_ldap" != no ; then
15674 cat >> confdefs.h <<\EOF
15675 #define SLAPD_LDAP 1
15680 if test "$ol_with_ldap_module" != static ; then
15681 cat >> confdefs.h <<\EOF
15682 #define SLAPD_LDAP_DYNAMIC 1
15686 BUILD_LDAP_DYNAMIC=shared
15687 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-ldap/back_ldap.la"
15691 if test "$ol_link_ldbm" != no ; then
15692 cat >> confdefs.h <<\EOF
15693 #define SLAPD_LDBM 1
15698 if test "$ol_with_ldbm_module" != static ; then
15699 cat >> confdefs.h <<\EOF
15700 #define SLAPD_LDBM_DYNAMIC 1
15704 BUILD_LDBM_DYNAMIC=shared
15705 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-ldbm/back_ldbm.la"
15709 if test "$ol_enable_passwd" != no ; then
15710 cat >> confdefs.h <<\EOF
15711 #define SLAPD_PASSWD 1
15716 if test "$ol_with_passwd_module" != static ; then
15717 cat >> confdefs.h <<\EOF
15718 #define SLAPD_PASSWD_DYNAMIC 1
15722 BUILD_PASSWD_DYNAMIC=shared
15723 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-passwd/back_passwd.la"
15727 if test "$ol_enable_shell" != no ; then
15728 cat >> confdefs.h <<\EOF
15729 #define SLAPD_SHELL 1
15734 if test "$ol_with_shell_module" != static ; then
15735 cat >> confdefs.h <<\EOF
15736 #define SLAPD_SHELL_DYNAMIC 1
15740 BUILD_SHELL_DYNAMIC=shared
15741 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-shell/back_shell.la"
15745 if test "$ol_enable_sql" != no ; then
15746 cat >> confdefs.h <<\EOF
15747 #define SLAPD_SQL 1
15752 if test "$ol_with_sql_module" != static; then
15753 cat >> confdefs.h <<\EOF
15754 #define SLAPD_SQL_DYNAMIC 1
15758 BUILD_SQL_DYNAMIC=shared
15759 SLAPD_MODULES_LIST="$SLAPD_MODULES_LIST -dlopen \$(SLAP_DIR)back-sql/back_sql.la"
15763 if test "$ol_enable_slurpd" != no -a "$ol_link_threads" != no -a \
15764 $BUILD_SLAPD = yes ; then
15769 if test "$LINK_BINS_DYNAMIC" = yes; then
15771 LT_LIB_LINKAGE=shared
15774 LT_LIB_LINKAGE=static
15777 if test "$ac_cv_mingw32" = yes ; then
15837 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
15839 test "x$prefix" = xNONE && prefix=$ac_default_prefix
15840 # Let make expand exec_prefix.
15841 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15843 # Any assignment to VPATH causes Sun make to only execute
15844 # the first set of double-colon rules, so remove it if not needed.
15845 # If there is a colon in the path, we need to keep it.
15846 if test "x$srcdir" = x.; then
15847 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
15850 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
15852 DEFS=-DHAVE_CONFIG_H
15854 # Without the "./", some shells look in PATH for config.status.
15855 : ${CONFIG_STATUS=./config.status}
15857 echo creating $CONFIG_STATUS
15858 rm -f $CONFIG_STATUS
15859 cat > $CONFIG_STATUS <<EOF
15861 # Generated automatically by configure.
15862 # Run this file to recreate the current configuration.
15863 # This directory was configured as follows,
15864 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
15866 # $0 $ac_configure_args
15868 # Compiler output produced by configure, useful for debugging
15869 # configure, is in ./config.log if it exists.
15871 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
15874 case "\$ac_option" in
15875 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15876 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
15877 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
15878 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
15879 echo "$CONFIG_STATUS generated by autoconf version 2.13.1"
15881 -help | --help | --hel | --he | --h)
15882 echo "\$ac_cs_usage"; exit 0 ;;
15883 *) echo "\$ac_cs_usage"; exit 1 ;;
15887 ac_given_srcdir=$srcdir
15888 ac_given_INSTALL="$INSTALL"
15890 trap 'rm -fr `echo "\
15891 Makefile:build/top.mk:Makefile.in:build/dir.mk \
15892 doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk \
15893 doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk \
15894 doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk \
15895 doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk \
15896 doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk \
15897 doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk \
15898 clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk \
15899 clients/finger/Makefile:build/top.mk:clients/finger/Makefile.in:build/rules.mk \
15900 clients/fax500/Makefile:build/top.mk:clients/fax500/Makefile.in:build/rules.mk \
15901 clients/gopher/Makefile:build/top.mk:clients/gopher/Makefile.in:build/rules.mk \
15902 clients/mail500/Makefile:build/top.mk:clients/mail500/Makefile.in:build/rules.mk \
15903 clients/rcpt500/Makefile:build/top.mk:clients/rcpt500/Makefile.in:build/rules.mk \
15904 clients/ud/Makefile:build/top.mk:clients/ud/Makefile.in:build/rules.mk \
15905 clients/maildap/Makefile:build/top.mk:clients/maildap/Makefile.in:build/rules.mk \
15906 clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk \
15907 include/Makefile:build/top.mk:include/Makefile.in \
15908 libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk \
15909 libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk \
15910 libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk \
15911 libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk \
15912 libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk \
15913 libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk \
15914 libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk \
15915 libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk \
15916 libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk \
15917 servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk \
15918 servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk \
15919 servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk \
15920 servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk \
15921 servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk \
15922 servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk \
15923 servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk \
15924 servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk \
15925 servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk \
15926 servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in \
15927 servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk \
15928 tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk \
15929 tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk \
15930 contrib/Makefile:build/top.mk:contrib/Makefile.in:build/dir.mk \
15931 contrib/saucer/Makefile:build/top.mk:contrib/saucer/Makefile.in:build/rules.mk \
15932 include/portable.h include/ldap_features.h include/lber_types.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
15934 cat >> $CONFIG_STATUS <<EOF
15936 # Protect against being on the right side of a sed subst in config.status.
15937 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
15938 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
15942 s%@CFLAGS@%$CFLAGS%g
15943 s%@CPPFLAGS@%$CPPFLAGS%g
15944 s%@CXXFLAGS@%$CXXFLAGS%g
15945 s%@FFLAGS@%$FFLAGS%g
15947 s%@LDFLAGS@%$LDFLAGS%g
15949 s%@exec_prefix@%$exec_prefix%g
15950 s%@prefix@%$prefix%g
15951 s%@program_transform_name@%$program_transform_name%g
15952 s%@bindir@%$bindir%g
15953 s%@sbindir@%$sbindir%g
15954 s%@libexecdir@%$libexecdir%g
15955 s%@datadir@%$datadir%g
15956 s%@sysconfdir@%$sysconfdir%g
15957 s%@sharedstatedir@%$sharedstatedir%g
15958 s%@localstatedir@%$localstatedir%g
15959 s%@libdir@%$libdir%g
15960 s%@includedir@%$includedir%g
15961 s%@oldincludedir@%$oldincludedir%g
15962 s%@infodir@%$infodir%g
15963 s%@mandir@%$mandir%g
15965 s%@host_alias@%$host_alias%g
15966 s%@host_cpu@%$host_cpu%g
15967 s%@host_vendor@%$host_vendor%g
15968 s%@host_os@%$host_os%g
15969 s%@target@%$target%g
15970 s%@target_alias@%$target_alias%g
15971 s%@target_cpu@%$target_cpu%g
15972 s%@target_vendor@%$target_vendor%g
15973 s%@target_os@%$target_os%g
15975 s%@build_alias@%$build_alias%g
15976 s%@build_cpu@%$build_cpu%g
15977 s%@build_vendor@%$build_vendor%g
15978 s%@build_os@%$build_os%g
15979 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
15980 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
15981 s%@INSTALL_DATA@%$INSTALL_DATA%g
15982 s%@PACKAGE@%$PACKAGE%g
15983 s%@VERSION@%$VERSION%g
15984 s%@ACLOCAL@%$ACLOCAL%g
15985 s%@AUTOCONF@%$AUTOCONF%g
15986 s%@AUTOMAKE@%$AUTOMAKE%g
15987 s%@AUTOHEADER@%$AUTOHEADER%g
15988 s%@MAKEINFO@%$MAKEINFO%g
15989 s%@install_sh@%$install_sh%g
15992 s%@AMTARFLAGS@%$AMTARFLAGS%g
15993 s%@SET_MAKE@%$SET_MAKE%g
15994 s%@top_builddir@%$top_builddir%g
15995 s%@ldap_subdir@%$ldap_subdir%g
15997 s%@RANLIB@%$RANLIB%g
15999 s%@DLLTOOL@%$DLLTOOL%g
16001 s%@OBJDUMP@%$OBJDUMP%g
16002 s%@LIBTOOL@%$LIBTOOL%g
16004 s%@SENDMAIL@%$SENDMAIL%g
16005 s%@EDITOR@%$EDITOR%g
16006 s%@FINGER@%$FINGER%g
16008 s%@EXEEXT@%$EXEEXT%g
16009 s%@OBJEXT@%$OBJEXT%g
16010 s%@OL_MKDEP@%$OL_MKDEP%g
16011 s%@OL_MKDEP_FLAGS@%$OL_MKDEP_FLAGS%g
16012 s%@LIBOBJS@%$LIBOBJS%g
16013 s%@LIBSRCS@%$LIBSRCS%g
16015 s%@LIB_LINKAGE@%$LIB_LINKAGE%g
16016 s%@LT_LIB_LINKAGE@%$LT_LIB_LINKAGE%g
16017 s%@DYN_EXT@%$DYN_EXT%g
16018 s%@BUILD_SLAPD@%$BUILD_SLAPD%g
16019 s%@BUILD_DNSSRV@%$BUILD_DNSSRV%g
16020 s%@BUILD_LDAP@%$BUILD_LDAP%g
16021 s%@BUILD_LDBM@%$BUILD_LDBM%g
16022 s%@BUILD_PASSWD@%$BUILD_PASSWD%g
16023 s%@BUILD_SHELL@%$BUILD_SHELL%g
16024 s%@BUILD_SQL@%$BUILD_SQL%g
16025 s%@BUILD_DNSSRV_DYNAMIC@%$BUILD_DNSSRV_DYNAMIC%g
16026 s%@BUILD_LDAP_DYNAMIC@%$BUILD_LDAP_DYNAMIC%g
16027 s%@BUILD_LDBM_DYNAMIC@%$BUILD_LDBM_DYNAMIC%g
16028 s%@BUILD_PASSWD_DYNAMIC@%$BUILD_PASSWD_DYNAMIC%g
16029 s%@BUILD_SHELL_DYNAMIC@%$BUILD_SHELL_DYNAMIC%g
16030 s%@BUILD_SQL_DYNAMIC@%$BUILD_SQL_DYNAMIC%g
16031 s%@BUILD_SLURPD@%$BUILD_SLURPD%g
16032 s%@LDAP_LIBS@%$LDAP_LIBS%g
16033 s%@LDIF_LIBS@%$LDIF_LIBS%g
16034 s%@SLAPD_LIBS@%$SLAPD_LIBS%g
16035 s%@SLURPD_LIBS@%$SLURPD_LIBS%g
16036 s%@LDBM_LIBS@%$LDBM_LIBS%g
16037 s%@LTHREAD_LIBS@%$LTHREAD_LIBS%g
16038 s%@LUTIL_LIBS@%$LUTIL_LIBS%g
16039 s%@WRAP_LIBS@%$WRAP_LIBS%g
16040 s%@LINK_BINS_DYNAMIC@%$LINK_BINS_DYNAMIC%g
16041 s%@SLAPD_MODULES_CPPFLAGS@%$SLAPD_MODULES_CPPFLAGS%g
16042 s%@SLAPD_MODULES_LDFLAGS@%$SLAPD_MODULES_LDFLAGS%g
16043 s%@SLAPD_MODULES_LIST@%$SLAPD_MODULES_LIST%g
16044 s%@KRB4_LIBS@%$KRB4_LIBS%g
16045 s%@KRB5_LIBS@%$KRB5_LIBS%g
16046 s%@READLINE_LIBS@%$READLINE_LIBS%g
16047 s%@SASL_LIBS@%$SASL_LIBS%g
16048 s%@TERMCAP_LIBS@%$TERMCAP_LIBS%g
16049 s%@TLS_LIBS@%$TLS_LIBS%g
16050 s%@MODULES_LIBS@%$MODULES_LIBS%g
16051 s%@AUTH_LIBS@%$AUTH_LIBS%g
16052 s%@SLAPD_SQL_LDFLAGS@%$SLAPD_SQL_LDFLAGS%g
16053 s%@SLAPD_SQL_LIBS@%$SLAPD_SQL_LIBS%g
16054 s%@SLAPD_SQL_INCLUDES@%$SLAPD_SQL_INCLUDES%g
16059 cat >> $CONFIG_STATUS <<\EOF
16061 # Split the substitutions into bite-sized pieces for seds with
16062 # small command number limits, like on Digital OSF/1 and HP-UX.
16063 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
16064 ac_file=1 # Number of current file.
16065 ac_beg=1 # First line for current file.
16066 ac_end=$ac_max_sed_cmds # Line after last line for current file.
16069 while $ac_more_lines; do
16070 if test $ac_beg -gt 1; then
16071 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
16073 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
16075 if test ! -s conftest.s$ac_file; then
16076 ac_more_lines=false
16077 rm -f conftest.s$ac_file
16079 if test -z "$ac_sed_cmds"; then
16080 ac_sed_cmds="sed -f conftest.s$ac_file"
16082 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
16084 ac_file=`expr $ac_file + 1`
16086 ac_end=`expr $ac_end + $ac_max_sed_cmds`
16089 if test -z "$ac_sed_cmds"; then
16094 cat >> $CONFIG_STATUS <<EOF
16096 CONFIG_FILES=\${CONFIG_FILES-"\
16097 Makefile:build/top.mk:Makefile.in:build/dir.mk \
16098 doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk \
16099 doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk \
16100 doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk \
16101 doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk \
16102 doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk \
16103 doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk \
16104 clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk \
16105 clients/finger/Makefile:build/top.mk:clients/finger/Makefile.in:build/rules.mk \
16106 clients/fax500/Makefile:build/top.mk:clients/fax500/Makefile.in:build/rules.mk \
16107 clients/gopher/Makefile:build/top.mk:clients/gopher/Makefile.in:build/rules.mk \
16108 clients/mail500/Makefile:build/top.mk:clients/mail500/Makefile.in:build/rules.mk \
16109 clients/rcpt500/Makefile:build/top.mk:clients/rcpt500/Makefile.in:build/rules.mk \
16110 clients/ud/Makefile:build/top.mk:clients/ud/Makefile.in:build/rules.mk \
16111 clients/maildap/Makefile:build/top.mk:clients/maildap/Makefile.in:build/rules.mk \
16112 clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk \
16113 include/Makefile:build/top.mk:include/Makefile.in \
16114 libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk \
16115 libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk \
16116 libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk \
16117 libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk \
16118 libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk \
16119 libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk \
16120 libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk \
16121 libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk \
16122 libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk \
16123 servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk \
16124 servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk \
16125 servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk \
16126 servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk \
16127 servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk \
16128 servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk \
16129 servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk \
16130 servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk \
16131 servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk \
16132 servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in \
16133 servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk \
16134 tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk \
16135 tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk \
16136 contrib/Makefile:build/top.mk:contrib/Makefile.in:build/dir.mk \
16137 contrib/saucer/Makefile:build/top.mk:contrib/saucer/Makefile.in:build/rules.mk \
16140 cat >> $CONFIG_STATUS <<\EOF
16141 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
16142 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16144 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
16145 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16146 *) ac_file_in="${ac_file}.in" ;;
16149 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
16151 # Remove last slash and all that follows it. Not all systems have dirname.
16152 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
16153 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16154 # The file is in a subdirectory.
16155 test ! -d "$ac_dir" && mkdir "$ac_dir"
16156 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
16157 # A "../" for each directory in $ac_dir_suffix.
16158 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
16160 ac_dir_suffix= ac_dots=
16163 case "$ac_given_srcdir" in
16165 if test -z "$ac_dots"; then top_srcdir=.
16166 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
16167 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
16168 *) # Relative path.
16169 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
16170 top_srcdir="$ac_dots$ac_given_srcdir" ;;
16173 case "$ac_given_INSTALL" in
16174 [/$]*) INSTALL="$ac_given_INSTALL" ;;
16175 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
16178 echo creating "$ac_file"
16180 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
16182 *[Mm]akefile*) ac_comsub="1i\\
16183 # $configure_input" ;;
16187 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
16189 s%@configure_input@%$configure_input%g
16190 s%@srcdir@%$srcdir%g
16191 s%@top_srcdir@%$top_srcdir%g
16192 s%@INSTALL@%$INSTALL%g
16193 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
16197 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16198 # NAME is the cpp macro being defined and VALUE is the value it is being given.
16200 # ac_d sets the value in "#define NAME VALUE" lines.
16201 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16202 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
16205 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
16206 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16207 ac_uB='\([ ]\)%\1#\2define\3'
16210 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16211 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16212 ac_eB='$%\1#\2define\3'
16216 if test "${CONFIG_HEADERS+set}" != set; then
16218 cat >> $CONFIG_STATUS <<EOF
16219 CONFIG_HEADERS="include/portable.h include/ldap_features.h include/lber_types.h"
16221 cat >> $CONFIG_STATUS <<\EOF
16223 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
16224 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16226 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
16227 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16228 *) ac_file_in="${ac_file}.in" ;;
16231 echo creating $ac_file
16233 rm -f conftest.frag conftest.in conftest.out
16234 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
16235 cat $ac_file_inputs > conftest.in
16239 # Transform confdefs.h into a sed script conftest.vals that substitutes
16240 # the proper values into config.h.in to produce config.h. And first:
16241 # Protect against being on the right side of a sed subst in config.status.
16242 # Protect against being in an unquoted here document in config.status.
16243 rm -f conftest.vals
16244 cat > conftest.hdr <<\EOF
16247 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
16251 sed -n -f conftest.hdr confdefs.h > conftest.vals
16254 # This sed command replaces #undef with comments. This is necessary, for
16255 # example, in the case of _POSIX_SOURCE, which is predefined and required
16256 # on some systems where configure will not decide to define it.
16257 cat >> conftest.vals <<\EOF
16258 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
16261 # Break up conftest.vals because some shells have a limit on
16262 # the size of here documents, and old seds have small limits too.
16264 rm -f conftest.tail
16267 ac_lines=`grep -c . conftest.vals`
16268 # grep -c gives empty output for an empty file on some AIX systems.
16269 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
16270 # Write a limited-size here document to conftest.frag.
16271 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
16272 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
16274 sed -f conftest.frag conftest.in > conftest.out
16276 mv conftest.out conftest.in
16277 ' >> $CONFIG_STATUS
16278 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
16279 rm -f conftest.vals
16280 mv conftest.tail conftest.vals
16282 rm -f conftest.vals
16284 cat >> $CONFIG_STATUS <<\EOF
16285 rm -f conftest.frag conftest.h
16286 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
16287 cat conftest.in >> conftest.h
16289 if cmp -s $ac_file conftest.h 2>/dev/null; then
16290 echo "$ac_file is unchanged"
16293 # Remove last slash and all that follows it. Not all systems have dirname.
16294 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
16295 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
16296 # The file is in a subdirectory.
16297 test ! -d "$ac_dir" && mkdir "$ac_dir"
16300 mv conftest.h $ac_file
16305 cat >> $CONFIG_STATUS <<EOF
16308 cat >> $CONFIG_STATUS <<\EOF
16311 echo Please \"make depend\" to build dependencies
16315 chmod +x $CONFIG_STATUS
16316 rm -fr confdefs* $ac_clean_files
16317 test "$no_create" = yes || $SHELL $CONFIG_STATUS || exit 1