Made it 2.0.0, and removed the changes that are in 1.1.x, as
[freeradius.git] / src / modules / rlm_ldap / configure
1 #! /bin/sh
2 # From configure.in Revision: 1.15 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.59.
5 #
6 # Copyright (C) 2003 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9 ## --------------------- ##
10 ## M4sh Initialization.  ##
11 ## --------------------- ##
12
13 # Be Bourne compatible
14 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
15   emulate sh
16   NULLCMD=:
17   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
18   # is contrary to our usage.  Disable this feature.
19   alias -g '${1+"$@"}'='"$@"'
20 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21   set -o posix
22 fi
23 DUALCASE=1; export DUALCASE # for MKS sh
24
25 # Support unset when possible.
26 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
27   as_unset=unset
28 else
29   as_unset=false
30 fi
31
32
33 # Work around bugs in pre-3.0 UWIN ksh.
34 $as_unset ENV MAIL MAILPATH
35 PS1='$ '
36 PS2='> '
37 PS4='+ '
38
39 # NLS nuisances.
40 for as_var in \
41   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
42   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
43   LC_TELEPHONE LC_TIME
44 do
45   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
46     eval $as_var=C; export $as_var
47   else
48     $as_unset $as_var
49   fi
50 done
51
52 # Required to use basename.
53 if expr a : '\(a\)' >/dev/null 2>&1; then
54   as_expr=expr
55 else
56   as_expr=false
57 fi
58
59 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
60   as_basename=basename
61 else
62   as_basename=false
63 fi
64
65
66 # Name of the executable.
67 as_me=`$as_basename "$0" ||
68 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
69          X"$0" : 'X\(//\)$' \| \
70          X"$0" : 'X\(/\)$' \| \
71          .     : '\(.\)' 2>/dev/null ||
72 echo X/"$0" |
73     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
74           /^X\/\(\/\/\)$/{ s//\1/; q; }
75           /^X\/\(\/\).*/{ s//\1/; q; }
76           s/.*/./; q'`
77
78
79 # PATH needs CR, and LINENO needs CR and PATH.
80 # Avoid depending upon Character Ranges.
81 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
82 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
83 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
84 as_cr_digits='0123456789'
85 as_cr_alnum=$as_cr_Letters$as_cr_digits
86
87 # The user is always right.
88 if test "${PATH_SEPARATOR+set}" != set; then
89   echo "#! /bin/sh" >conf$$.sh
90   echo  "exit 0"   >>conf$$.sh
91   chmod +x conf$$.sh
92   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
93     PATH_SEPARATOR=';'
94   else
95     PATH_SEPARATOR=:
96   fi
97   rm -f conf$$.sh
98 fi
99
100
101   as_lineno_1=$LINENO
102   as_lineno_2=$LINENO
103   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
104   test "x$as_lineno_1" != "x$as_lineno_2" &&
105   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
106   # Find who we are.  Look in the path if we contain no path at all
107   # relative or not.
108   case $0 in
109     *[\\/]* ) as_myself=$0 ;;
110     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
111 for as_dir in $PATH
112 do
113   IFS=$as_save_IFS
114   test -z "$as_dir" && as_dir=.
115   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
116 done
117
118        ;;
119   esac
120   # We did not find ourselves, most probably we were run as `sh COMMAND'
121   # in which case we are not to be found in the path.
122   if test "x$as_myself" = x; then
123     as_myself=$0
124   fi
125   if test ! -f "$as_myself"; then
126     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
127    { (exit 1); exit 1; }; }
128   fi
129   case $CONFIG_SHELL in
130   '')
131     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
132 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
133 do
134   IFS=$as_save_IFS
135   test -z "$as_dir" && as_dir=.
136   for as_base in sh bash ksh sh5; do
137          case $as_dir in
138          /*)
139            if ("$as_dir/$as_base" -c '
140   as_lineno_1=$LINENO
141   as_lineno_2=$LINENO
142   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
143   test "x$as_lineno_1" != "x$as_lineno_2" &&
144   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
145              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
146              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
147              CONFIG_SHELL=$as_dir/$as_base
148              export CONFIG_SHELL
149              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
150            fi;;
151          esac
152        done
153 done
154 ;;
155   esac
156
157   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
158   # uniformly replaced by the line number.  The first 'sed' inserts a
159   # line-number line before each line; the second 'sed' does the real
160   # work.  The second script uses 'N' to pair each line-number line
161   # with the numbered line, and appends trailing '-' during
162   # substitution so that $LINENO is not a special case at line end.
163   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
164   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
165   sed '=' <$as_myself |
166     sed '
167       N
168       s,$,-,
169       : loop
170       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
171       t loop
172       s,-$,,
173       s,^['$as_cr_digits']*\n,,
174     ' >$as_me.lineno &&
175   chmod +x $as_me.lineno ||
176     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
177    { (exit 1); exit 1; }; }
178
179   # Don't try to exec as it changes $[0], causing all sort of problems
180   # (the dirname of $[0] is not the place where we might find the
181   # original and so on.  Autoconf is especially sensible to this).
182   . ./$as_me.lineno
183   # Exit status is that of the last command.
184   exit
185 }
186
187
188 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
189   *c*,-n*) ECHO_N= ECHO_C='
190 ' ECHO_T='      ' ;;
191   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
192   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
193 esac
194
195 if expr a : '\(a\)' >/dev/null 2>&1; then
196   as_expr=expr
197 else
198   as_expr=false
199 fi
200
201 rm -f conf$$ conf$$.exe conf$$.file
202 echo >conf$$.file
203 if ln -s conf$$.file conf$$ 2>/dev/null; then
204   # We could just check for DJGPP; but this test a) works b) is more generic
205   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
206   if test -f conf$$.exe; then
207     # Don't use ln at all; we don't have any links
208     as_ln_s='cp -p'
209   else
210     as_ln_s='ln -s'
211   fi
212 elif ln conf$$.file conf$$ 2>/dev/null; then
213   as_ln_s=ln
214 else
215   as_ln_s='cp -p'
216 fi
217 rm -f conf$$ conf$$.exe conf$$.file
218
219 if mkdir -p . 2>/dev/null; then
220   as_mkdir_p=:
221 else
222   test -d ./-p && rmdir ./-p
223   as_mkdir_p=false
224 fi
225
226 as_executable_p="test -f"
227
228 # Sed expression to map a string onto a valid CPP name.
229 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
230
231 # Sed expression to map a string onto a valid variable name.
232 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
233
234
235 # IFS
236 # We need space, tab and new line, in precisely that order.
237 as_nl='
238 '
239 IFS="   $as_nl"
240
241 # CDPATH.
242 $as_unset CDPATH
243
244
245 # Name of the host.
246 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
247 # so uname gets run too.
248 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
249
250 exec 6>&1
251
252 #
253 # Initializations.
254 #
255 ac_default_prefix=/usr/local
256 ac_config_libobj_dir=.
257 cross_compiling=no
258 subdirs=
259 MFLAGS=
260 MAKEFLAGS=
261 SHELL=${CONFIG_SHELL-/bin/sh}
262
263 # Maximum number of lines to put in a shell here document.
264 # This variable seems obsolete.  It should probably be removed, and
265 # only ac_max_sed_lines should be used.
266 : ${ac_max_here_lines=38}
267
268 # Identity of this package.
269 PACKAGE_NAME=
270 PACKAGE_TARNAME=
271 PACKAGE_VERSION=
272 PACKAGE_STRING=
273 PACKAGE_BUGREPORT=
274
275 ac_unique_file="rlm_ldap.c"
276 ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT edir ldap_ldflags ldap_cflags targetname LIBOBJS LTLIBOBJS'
277 ac_subst_files=''
278
279 # Initialize some variables set by options.
280 ac_init_help=
281 ac_init_version=false
282 # The variables have the same names as the options, with
283 # dashes changed to underlines.
284 cache_file=/dev/null
285 exec_prefix=NONE
286 no_create=
287 no_recursion=
288 prefix=NONE
289 program_prefix=NONE
290 program_suffix=NONE
291 program_transform_name=s,x,x,
292 silent=
293 site=
294 srcdir=
295 verbose=
296 x_includes=NONE
297 x_libraries=NONE
298
299 # Installation directory options.
300 # These are left unexpanded so users can "make install exec_prefix=/foo"
301 # and all the variables that are supposed to be based on exec_prefix
302 # by default will actually change.
303 # Use braces instead of parens because sh, perl, etc. also accept them.
304 bindir='${exec_prefix}/bin'
305 sbindir='${exec_prefix}/sbin'
306 libexecdir='${exec_prefix}/libexec'
307 datadir='${prefix}/share'
308 sysconfdir='${prefix}/etc'
309 sharedstatedir='${prefix}/com'
310 localstatedir='${prefix}/var'
311 libdir='${exec_prefix}/lib'
312 includedir='${prefix}/include'
313 oldincludedir='/usr/include'
314 infodir='${prefix}/info'
315 mandir='${prefix}/man'
316
317 ac_prev=
318 for ac_option
319 do
320   # If the previous option needs an argument, assign it.
321   if test -n "$ac_prev"; then
322     eval "$ac_prev=\$ac_option"
323     ac_prev=
324     continue
325   fi
326
327   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
328
329   # Accept the important Cygnus configure options, so we can diagnose typos.
330
331   case $ac_option in
332
333   -bindir | --bindir | --bindi | --bind | --bin | --bi)
334     ac_prev=bindir ;;
335   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
336     bindir=$ac_optarg ;;
337
338   -build | --build | --buil | --bui | --bu)
339     ac_prev=build_alias ;;
340   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
341     build_alias=$ac_optarg ;;
342
343   -cache-file | --cache-file | --cache-fil | --cache-fi \
344   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
345     ac_prev=cache_file ;;
346   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
347   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
348     cache_file=$ac_optarg ;;
349
350   --config-cache | -C)
351     cache_file=config.cache ;;
352
353   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
354     ac_prev=datadir ;;
355   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
356   | --da=*)
357     datadir=$ac_optarg ;;
358
359   -disable-* | --disable-*)
360     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
361     # Reject names that are not valid shell variable names.
362     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
363       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
364    { (exit 1); exit 1; }; }
365     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
366     eval "enable_$ac_feature=no" ;;
367
368   -enable-* | --enable-*)
369     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
370     # Reject names that are not valid shell variable names.
371     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
372       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
373    { (exit 1); exit 1; }; }
374     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
375     case $ac_option in
376       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
377       *) ac_optarg=yes ;;
378     esac
379     eval "enable_$ac_feature='$ac_optarg'" ;;
380
381   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
382   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
383   | --exec | --exe | --ex)
384     ac_prev=exec_prefix ;;
385   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
386   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
387   | --exec=* | --exe=* | --ex=*)
388     exec_prefix=$ac_optarg ;;
389
390   -gas | --gas | --ga | --g)
391     # Obsolete; use --with-gas.
392     with_gas=yes ;;
393
394   -help | --help | --hel | --he | -h)
395     ac_init_help=long ;;
396   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
397     ac_init_help=recursive ;;
398   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
399     ac_init_help=short ;;
400
401   -host | --host | --hos | --ho)
402     ac_prev=host_alias ;;
403   -host=* | --host=* | --hos=* | --ho=*)
404     host_alias=$ac_optarg ;;
405
406   -includedir | --includedir | --includedi | --included | --include \
407   | --includ | --inclu | --incl | --inc)
408     ac_prev=includedir ;;
409   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
410   | --includ=* | --inclu=* | --incl=* | --inc=*)
411     includedir=$ac_optarg ;;
412
413   -infodir | --infodir | --infodi | --infod | --info | --inf)
414     ac_prev=infodir ;;
415   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
416     infodir=$ac_optarg ;;
417
418   -libdir | --libdir | --libdi | --libd)
419     ac_prev=libdir ;;
420   -libdir=* | --libdir=* | --libdi=* | --libd=*)
421     libdir=$ac_optarg ;;
422
423   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
424   | --libexe | --libex | --libe)
425     ac_prev=libexecdir ;;
426   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
427   | --libexe=* | --libex=* | --libe=*)
428     libexecdir=$ac_optarg ;;
429
430   -localstatedir | --localstatedir | --localstatedi | --localstated \
431   | --localstate | --localstat | --localsta | --localst \
432   | --locals | --local | --loca | --loc | --lo)
433     ac_prev=localstatedir ;;
434   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
435   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
436   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
437     localstatedir=$ac_optarg ;;
438
439   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
440     ac_prev=mandir ;;
441   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
442     mandir=$ac_optarg ;;
443
444   -nfp | --nfp | --nf)
445     # Obsolete; use --without-fp.
446     with_fp=no ;;
447
448   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
449   | --no-cr | --no-c | -n)
450     no_create=yes ;;
451
452   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
453   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
454     no_recursion=yes ;;
455
456   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
457   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
458   | --oldin | --oldi | --old | --ol | --o)
459     ac_prev=oldincludedir ;;
460   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
461   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
462   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
463     oldincludedir=$ac_optarg ;;
464
465   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
466     ac_prev=prefix ;;
467   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
468     prefix=$ac_optarg ;;
469
470   -program-prefix | --program-prefix | --program-prefi | --program-pref \
471   | --program-pre | --program-pr | --program-p)
472     ac_prev=program_prefix ;;
473   -program-prefix=* | --program-prefix=* | --program-prefi=* \
474   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
475     program_prefix=$ac_optarg ;;
476
477   -program-suffix | --program-suffix | --program-suffi | --program-suff \
478   | --program-suf | --program-su | --program-s)
479     ac_prev=program_suffix ;;
480   -program-suffix=* | --program-suffix=* | --program-suffi=* \
481   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
482     program_suffix=$ac_optarg ;;
483
484   -program-transform-name | --program-transform-name \
485   | --program-transform-nam | --program-transform-na \
486   | --program-transform-n | --program-transform- \
487   | --program-transform | --program-transfor \
488   | --program-transfo | --program-transf \
489   | --program-trans | --program-tran \
490   | --progr-tra | --program-tr | --program-t)
491     ac_prev=program_transform_name ;;
492   -program-transform-name=* | --program-transform-name=* \
493   | --program-transform-nam=* | --program-transform-na=* \
494   | --program-transform-n=* | --program-transform-=* \
495   | --program-transform=* | --program-transfor=* \
496   | --program-transfo=* | --program-transf=* \
497   | --program-trans=* | --program-tran=* \
498   | --progr-tra=* | --program-tr=* | --program-t=*)
499     program_transform_name=$ac_optarg ;;
500
501   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
502   | -silent | --silent | --silen | --sile | --sil)
503     silent=yes ;;
504
505   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
506     ac_prev=sbindir ;;
507   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
508   | --sbi=* | --sb=*)
509     sbindir=$ac_optarg ;;
510
511   -sharedstatedir | --sharedstatedir | --sharedstatedi \
512   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
513   | --sharedst | --shareds | --shared | --share | --shar \
514   | --sha | --sh)
515     ac_prev=sharedstatedir ;;
516   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
517   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
518   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
519   | --sha=* | --sh=*)
520     sharedstatedir=$ac_optarg ;;
521
522   -site | --site | --sit)
523     ac_prev=site ;;
524   -site=* | --site=* | --sit=*)
525     site=$ac_optarg ;;
526
527   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
528     ac_prev=srcdir ;;
529   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
530     srcdir=$ac_optarg ;;
531
532   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
533   | --syscon | --sysco | --sysc | --sys | --sy)
534     ac_prev=sysconfdir ;;
535   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
536   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
537     sysconfdir=$ac_optarg ;;
538
539   -target | --target | --targe | --targ | --tar | --ta | --t)
540     ac_prev=target_alias ;;
541   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
542     target_alias=$ac_optarg ;;
543
544   -v | -verbose | --verbose | --verbos | --verbo | --verb)
545     verbose=yes ;;
546
547   -version | --version | --versio | --versi | --vers | -V)
548     ac_init_version=: ;;
549
550   -with-* | --with-*)
551     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
552     # Reject names that are not valid shell variable names.
553     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
554       { echo "$as_me: error: invalid package name: $ac_package" >&2
555    { (exit 1); exit 1; }; }
556     ac_package=`echo $ac_package| sed 's/-/_/g'`
557     case $ac_option in
558       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
559       *) ac_optarg=yes ;;
560     esac
561     eval "with_$ac_package='$ac_optarg'" ;;
562
563   -without-* | --without-*)
564     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
565     # Reject names that are not valid shell variable names.
566     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
567       { echo "$as_me: error: invalid package name: $ac_package" >&2
568    { (exit 1); exit 1; }; }
569     ac_package=`echo $ac_package | sed 's/-/_/g'`
570     eval "with_$ac_package=no" ;;
571
572   --x)
573     # Obsolete; use --with-x.
574     with_x=yes ;;
575
576   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
577   | --x-incl | --x-inc | --x-in | --x-i)
578     ac_prev=x_includes ;;
579   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
580   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
581     x_includes=$ac_optarg ;;
582
583   -x-libraries | --x-libraries | --x-librarie | --x-librari \
584   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
585     ac_prev=x_libraries ;;
586   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
587   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
588     x_libraries=$ac_optarg ;;
589
590   -*) { echo "$as_me: error: unrecognized option: $ac_option
591 Try \`$0 --help' for more information." >&2
592    { (exit 1); exit 1; }; }
593     ;;
594
595   *=*)
596     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
597     # Reject names that are not valid shell variable names.
598     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
599       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
600    { (exit 1); exit 1; }; }
601     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
602     eval "$ac_envvar='$ac_optarg'"
603     export $ac_envvar ;;
604
605   *)
606     # FIXME: should be removed in autoconf 3.0.
607     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
608     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
609       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
610     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
611     ;;
612
613   esac
614 done
615
616 if test -n "$ac_prev"; then
617   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
618   { echo "$as_me: error: missing argument to $ac_option" >&2
619    { (exit 1); exit 1; }; }
620 fi
621
622 # Be sure to have absolute paths.
623 for ac_var in exec_prefix prefix
624 do
625   eval ac_val=$`echo $ac_var`
626   case $ac_val in
627     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
628     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
629    { (exit 1); exit 1; }; };;
630   esac
631 done
632
633 # Be sure to have absolute paths.
634 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
635               localstatedir libdir includedir oldincludedir infodir mandir
636 do
637   eval ac_val=$`echo $ac_var`
638   case $ac_val in
639     [\\/$]* | ?:[\\/]* ) ;;
640     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
641    { (exit 1); exit 1; }; };;
642   esac
643 done
644
645 # There might be people who depend on the old broken behavior: `$host'
646 # used to hold the argument of --host etc.
647 # FIXME: To remove some day.
648 build=$build_alias
649 host=$host_alias
650 target=$target_alias
651
652 # FIXME: To remove some day.
653 if test "x$host_alias" != x; then
654   if test "x$build_alias" = x; then
655     cross_compiling=maybe
656     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
657     If a cross compiler is detected then cross compile mode will be used." >&2
658   elif test "x$build_alias" != "x$host_alias"; then
659     cross_compiling=yes
660   fi
661 fi
662
663 ac_tool_prefix=
664 test -n "$host_alias" && ac_tool_prefix=$host_alias-
665
666 test "$silent" = yes && exec 6>/dev/null
667
668
669 # Find the source files, if location was not specified.
670 if test -z "$srcdir"; then
671   ac_srcdir_defaulted=yes
672   # Try the directory containing this script, then its parent.
673   ac_confdir=`(dirname "$0") 2>/dev/null ||
674 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
675          X"$0" : 'X\(//\)[^/]' \| \
676          X"$0" : 'X\(//\)$' \| \
677          X"$0" : 'X\(/\)' \| \
678          .     : '\(.\)' 2>/dev/null ||
679 echo X"$0" |
680     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
681           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
682           /^X\(\/\/\)$/{ s//\1/; q; }
683           /^X\(\/\).*/{ s//\1/; q; }
684           s/.*/./; q'`
685   srcdir=$ac_confdir
686   if test ! -r $srcdir/$ac_unique_file; then
687     srcdir=..
688   fi
689 else
690   ac_srcdir_defaulted=no
691 fi
692 if test ! -r $srcdir/$ac_unique_file; then
693   if test "$ac_srcdir_defaulted" = yes; then
694     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
695    { (exit 1); exit 1; }; }
696   else
697     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
698    { (exit 1); exit 1; }; }
699   fi
700 fi
701 (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
702   { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
703    { (exit 1); exit 1; }; }
704 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
705 ac_env_build_alias_set=${build_alias+set}
706 ac_env_build_alias_value=$build_alias
707 ac_cv_env_build_alias_set=${build_alias+set}
708 ac_cv_env_build_alias_value=$build_alias
709 ac_env_host_alias_set=${host_alias+set}
710 ac_env_host_alias_value=$host_alias
711 ac_cv_env_host_alias_set=${host_alias+set}
712 ac_cv_env_host_alias_value=$host_alias
713 ac_env_target_alias_set=${target_alias+set}
714 ac_env_target_alias_value=$target_alias
715 ac_cv_env_target_alias_set=${target_alias+set}
716 ac_cv_env_target_alias_value=$target_alias
717 ac_env_CC_set=${CC+set}
718 ac_env_CC_value=$CC
719 ac_cv_env_CC_set=${CC+set}
720 ac_cv_env_CC_value=$CC
721 ac_env_CFLAGS_set=${CFLAGS+set}
722 ac_env_CFLAGS_value=$CFLAGS
723 ac_cv_env_CFLAGS_set=${CFLAGS+set}
724 ac_cv_env_CFLAGS_value=$CFLAGS
725 ac_env_LDFLAGS_set=${LDFLAGS+set}
726 ac_env_LDFLAGS_value=$LDFLAGS
727 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
728 ac_cv_env_LDFLAGS_value=$LDFLAGS
729 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
730 ac_env_CPPFLAGS_value=$CPPFLAGS
731 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
732 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
733
734 #
735 # Report the --help message.
736 #
737 if test "$ac_init_help" = "long"; then
738   # Omit some internal or obsolete options to make the list less imposing.
739   # This message is too long to be a string in the A/UX 3.1 sh.
740   cat <<_ACEOF
741 \`configure' configures this package to adapt to many kinds of systems.
742
743 Usage: $0 [OPTION]... [VAR=VALUE]...
744
745 To assign environment variables (e.g., CC, CFLAGS...), specify them as
746 VAR=VALUE.  See below for descriptions of some of the useful variables.
747
748 Defaults for the options are specified in brackets.
749
750 Configuration:
751   -h, --help              display this help and exit
752       --help=short        display options specific to this package
753       --help=recursive    display the short help of all the included packages
754   -V, --version           display version information and exit
755   -q, --quiet, --silent   do not print \`checking...' messages
756       --cache-file=FILE   cache test results in FILE [disabled]
757   -C, --config-cache      alias for \`--cache-file=config.cache'
758   -n, --no-create         do not create output files
759       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
760
761 _ACEOF
762
763   cat <<_ACEOF
764 Installation directories:
765   --prefix=PREFIX         install architecture-independent files in PREFIX
766                           [$ac_default_prefix]
767   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
768                           [PREFIX]
769
770 By default, \`make install' will install all the files in
771 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
772 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
773 for instance \`--prefix=\$HOME'.
774
775 For better control, use the options below.
776
777 Fine tuning of the installation directories:
778   --bindir=DIR           user executables [EPREFIX/bin]
779   --sbindir=DIR          system admin executables [EPREFIX/sbin]
780   --libexecdir=DIR       program executables [EPREFIX/libexec]
781   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
782   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
783   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
784   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
785   --libdir=DIR           object code libraries [EPREFIX/lib]
786   --includedir=DIR       C header files [PREFIX/include]
787   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
788   --infodir=DIR          info documentation [PREFIX/info]
789   --mandir=DIR           man documentation [PREFIX/man]
790 _ACEOF
791
792   cat <<\_ACEOF
793 _ACEOF
794 fi
795
796 if test -n "$ac_init_help"; then
797
798   cat <<\_ACEOF
799
800 Optional Features:
801   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
802   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
803   --enable-shared[=PKGS]
804                           build shared libraries [default=yes]
805
806 Optional Packages:
807   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
808   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
809   --with-rlm-ldap-lib-dir=DIR       directory for LDAP library files
810   --with-rlm-ldap-include-dir=DIR   directory for LDAP include files
811   --with-threads          use threads, if available. (default=yes)
812   --with-edir             enable Novell eDirectory integration.  (default=no)
813
814 Some influential environment variables:
815   CC          C compiler command
816   CFLAGS      C compiler flags
817   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
818               nonstandard directory <lib dir>
819   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
820               headers in a nonstandard directory <include dir>
821
822 Use these variables to override the choices made by `configure' or to help
823 it to find libraries and programs with nonstandard names/locations.
824
825 _ACEOF
826 fi
827
828 if test "$ac_init_help" = "recursive"; then
829   # If there are subdirs, report their specific --help.
830   ac_popdir=`pwd`
831   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
832     test -d $ac_dir || continue
833     ac_builddir=.
834
835 if test "$ac_dir" != .; then
836   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
837   # A "../" for each directory in $ac_dir_suffix.
838   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
839 else
840   ac_dir_suffix= ac_top_builddir=
841 fi
842
843 case $srcdir in
844   .)  # No --srcdir option.  We are building in place.
845     ac_srcdir=.
846     if test -z "$ac_top_builddir"; then
847        ac_top_srcdir=.
848     else
849        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
850     fi ;;
851   [\\/]* | ?:[\\/]* )  # Absolute path.
852     ac_srcdir=$srcdir$ac_dir_suffix;
853     ac_top_srcdir=$srcdir ;;
854   *) # Relative path.
855     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
856     ac_top_srcdir=$ac_top_builddir$srcdir ;;
857 esac
858
859 # Do not use `cd foo && pwd` to compute absolute paths, because
860 # the directories may not exist.
861 case `pwd` in
862 .) ac_abs_builddir="$ac_dir";;
863 *)
864   case "$ac_dir" in
865   .) ac_abs_builddir=`pwd`;;
866   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
867   *) ac_abs_builddir=`pwd`/"$ac_dir";;
868   esac;;
869 esac
870 case $ac_abs_builddir in
871 .) ac_abs_top_builddir=${ac_top_builddir}.;;
872 *)
873   case ${ac_top_builddir}. in
874   .) ac_abs_top_builddir=$ac_abs_builddir;;
875   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
876   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
877   esac;;
878 esac
879 case $ac_abs_builddir in
880 .) ac_abs_srcdir=$ac_srcdir;;
881 *)
882   case $ac_srcdir in
883   .) ac_abs_srcdir=$ac_abs_builddir;;
884   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
885   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
886   esac;;
887 esac
888 case $ac_abs_builddir in
889 .) ac_abs_top_srcdir=$ac_top_srcdir;;
890 *)
891   case $ac_top_srcdir in
892   .) ac_abs_top_srcdir=$ac_abs_builddir;;
893   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
894   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
895   esac;;
896 esac
897
898     cd $ac_dir
899     # Check for guested configure; otherwise get Cygnus style configure.
900     if test -f $ac_srcdir/configure.gnu; then
901       echo
902       $SHELL $ac_srcdir/configure.gnu  --help=recursive
903     elif test -f $ac_srcdir/configure; then
904       echo
905       $SHELL $ac_srcdir/configure  --help=recursive
906     elif test -f $ac_srcdir/configure.ac ||
907            test -f $ac_srcdir/configure.in; then
908       echo
909       $ac_configure --help
910     else
911       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
912     fi
913     cd "$ac_popdir"
914   done
915 fi
916
917 test -n "$ac_init_help" && exit 0
918 if $ac_init_version; then
919   cat <<\_ACEOF
920
921 Copyright (C) 2003 Free Software Foundation, Inc.
922 This configure script is free software; the Free Software Foundation
923 gives unlimited permission to copy, distribute and modify it.
924 _ACEOF
925   exit 0
926 fi
927 exec 5>config.log
928 cat >&5 <<_ACEOF
929 This file contains any messages produced by compilers while
930 running configure, to aid debugging if configure makes a mistake.
931
932 It was created by $as_me, which was
933 generated by GNU Autoconf 2.59.  Invocation command line was
934
935   $ $0 $@
936
937 _ACEOF
938 {
939 cat <<_ASUNAME
940 ## --------- ##
941 ## Platform. ##
942 ## --------- ##
943
944 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
945 uname -m = `(uname -m) 2>/dev/null || echo unknown`
946 uname -r = `(uname -r) 2>/dev/null || echo unknown`
947 uname -s = `(uname -s) 2>/dev/null || echo unknown`
948 uname -v = `(uname -v) 2>/dev/null || echo unknown`
949
950 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
951 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
952
953 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
954 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
955 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
956 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
957 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
958 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
959 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
960
961 _ASUNAME
962
963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
964 for as_dir in $PATH
965 do
966   IFS=$as_save_IFS
967   test -z "$as_dir" && as_dir=.
968   echo "PATH: $as_dir"
969 done
970
971 } >&5
972
973 cat >&5 <<_ACEOF
974
975
976 ## ----------- ##
977 ## Core tests. ##
978 ## ----------- ##
979
980 _ACEOF
981
982
983 # Keep a trace of the command line.
984 # Strip out --no-create and --no-recursion so they do not pile up.
985 # Strip out --silent because we don't want to record it for future runs.
986 # Also quote any args containing shell meta-characters.
987 # Make two passes to allow for proper duplicate-argument suppression.
988 ac_configure_args=
989 ac_configure_args0=
990 ac_configure_args1=
991 ac_sep=
992 ac_must_keep_next=false
993 for ac_pass in 1 2
994 do
995   for ac_arg
996   do
997     case $ac_arg in
998     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
999     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1000     | -silent | --silent | --silen | --sile | --sil)
1001       continue ;;
1002     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1003       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1004     esac
1005     case $ac_pass in
1006     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1007     2)
1008       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1009       if test $ac_must_keep_next = true; then
1010         ac_must_keep_next=false # Got value, back to normal.
1011       else
1012         case $ac_arg in
1013           *=* | --config-cache | -C | -disable-* | --disable-* \
1014           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1015           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1016           | -with-* | --with-* | -without-* | --without-* | --x)
1017             case "$ac_configure_args0 " in
1018               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1019             esac
1020             ;;
1021           -* ) ac_must_keep_next=true ;;
1022         esac
1023       fi
1024       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1025       # Get rid of the leading space.
1026       ac_sep=" "
1027       ;;
1028     esac
1029   done
1030 done
1031 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1032 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1033
1034 # When interrupted or exit'd, cleanup temporary files, and complete
1035 # config.log.  We remove comments because anyway the quotes in there
1036 # would cause problems or look ugly.
1037 # WARNING: Be sure not to use single quotes in there, as some shells,
1038 # such as our DU 5.0 friend, will then `close' the trap.
1039 trap 'exit_status=$?
1040   # Save into config.log some information that might help in debugging.
1041   {
1042     echo
1043
1044     cat <<\_ASBOX
1045 ## ---------------- ##
1046 ## Cache variables. ##
1047 ## ---------------- ##
1048 _ASBOX
1049     echo
1050     # The following way of writing the cache mishandles newlines in values,
1051 {
1052   (set) 2>&1 |
1053     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1054     *ac_space=\ *)
1055       sed -n \
1056         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1057           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1058       ;;
1059     *)
1060       sed -n \
1061         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1062       ;;
1063     esac;
1064 }
1065     echo
1066
1067     cat <<\_ASBOX
1068 ## ----------------- ##
1069 ## Output variables. ##
1070 ## ----------------- ##
1071 _ASBOX
1072     echo
1073     for ac_var in $ac_subst_vars
1074     do
1075       eval ac_val=$`echo $ac_var`
1076       echo "$ac_var='"'"'$ac_val'"'"'"
1077     done | sort
1078     echo
1079
1080     if test -n "$ac_subst_files"; then
1081       cat <<\_ASBOX
1082 ## ------------- ##
1083 ## Output files. ##
1084 ## ------------- ##
1085 _ASBOX
1086       echo
1087       for ac_var in $ac_subst_files
1088       do
1089         eval ac_val=$`echo $ac_var`
1090         echo "$ac_var='"'"'$ac_val'"'"'"
1091       done | sort
1092       echo
1093     fi
1094
1095     if test -s confdefs.h; then
1096       cat <<\_ASBOX
1097 ## ----------- ##
1098 ## confdefs.h. ##
1099 ## ----------- ##
1100 _ASBOX
1101       echo
1102       sed "/^$/d" confdefs.h | sort
1103       echo
1104     fi
1105     test "$ac_signal" != 0 &&
1106       echo "$as_me: caught signal $ac_signal"
1107     echo "$as_me: exit $exit_status"
1108   } >&5
1109   rm -f core *.core &&
1110   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1111     exit $exit_status
1112      ' 0
1113 for ac_signal in 1 2 13 15; do
1114   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1115 done
1116 ac_signal=0
1117
1118 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1119 rm -rf conftest* confdefs.h
1120 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1121 echo >confdefs.h
1122
1123 # Predefined preprocessor variables.
1124
1125 cat >>confdefs.h <<_ACEOF
1126 #define PACKAGE_NAME "$PACKAGE_NAME"
1127 _ACEOF
1128
1129
1130 cat >>confdefs.h <<_ACEOF
1131 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1132 _ACEOF
1133
1134
1135 cat >>confdefs.h <<_ACEOF
1136 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1137 _ACEOF
1138
1139
1140 cat >>confdefs.h <<_ACEOF
1141 #define PACKAGE_STRING "$PACKAGE_STRING"
1142 _ACEOF
1143
1144
1145 cat >>confdefs.h <<_ACEOF
1146 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1147 _ACEOF
1148
1149
1150 # Let the site file select an alternate cache file if it wants to.
1151 # Prefer explicitly selected file to automatically selected ones.
1152 if test -z "$CONFIG_SITE"; then
1153   if test "x$prefix" != xNONE; then
1154     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1155   else
1156     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1157   fi
1158 fi
1159 for ac_site_file in $CONFIG_SITE; do
1160   if test -r "$ac_site_file"; then
1161     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1162 echo "$as_me: loading site script $ac_site_file" >&6;}
1163     sed 's/^/| /' "$ac_site_file" >&5
1164     . "$ac_site_file"
1165   fi
1166 done
1167
1168 if test -r "$cache_file"; then
1169   # Some versions of bash will fail to source /dev/null (special
1170   # files actually), so we avoid doing that.
1171   if test -f "$cache_file"; then
1172     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1173 echo "$as_me: loading cache $cache_file" >&6;}
1174     case $cache_file in
1175       [\\/]* | ?:[\\/]* ) . $cache_file;;
1176       *)                      . ./$cache_file;;
1177     esac
1178   fi
1179 else
1180   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1181 echo "$as_me: creating cache $cache_file" >&6;}
1182   >$cache_file
1183 fi
1184
1185 # Check that the precious variables saved in the cache have kept the same
1186 # value.
1187 ac_cache_corrupted=false
1188 for ac_var in `(set) 2>&1 |
1189                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1190   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1191   eval ac_new_set=\$ac_env_${ac_var}_set
1192   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1193   eval ac_new_val="\$ac_env_${ac_var}_value"
1194   case $ac_old_set,$ac_new_set in
1195     set,)
1196       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1197 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1198       ac_cache_corrupted=: ;;
1199     ,set)
1200       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1201 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1202       ac_cache_corrupted=: ;;
1203     ,);;
1204     *)
1205       if test "x$ac_old_val" != "x$ac_new_val"; then
1206         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1207 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1208         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1209 echo "$as_me:   former value:  $ac_old_val" >&2;}
1210         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1211 echo "$as_me:   current value: $ac_new_val" >&2;}
1212         ac_cache_corrupted=:
1213       fi;;
1214   esac
1215   # Pass precious variables to config.status.
1216   if test "$ac_new_set" = set; then
1217     case $ac_new_val in
1218     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1219       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1220     *) ac_arg=$ac_var=$ac_new_val ;;
1221     esac
1222     case " $ac_configure_args " in
1223       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1224       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1225     esac
1226   fi
1227 done
1228 if $ac_cache_corrupted; then
1229   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1230 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1231   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1232 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1233    { (exit 1); exit 1; }; }
1234 fi
1235
1236 ac_ext=c
1237 ac_cpp='$CPP $CPPFLAGS'
1238 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1239 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1240 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263 fail=
1264 SMART_LIBS=
1265 SMART_CLFAGS=
1266 if test x$with_rlm_ldap != xno; then
1267
1268                                 ac_ext=c
1269 ac_cpp='$CPP $CPPFLAGS'
1270 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1271 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1272 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1273 if test -n "$ac_tool_prefix"; then
1274   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1275 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1276 echo "$as_me:$LINENO: checking for $ac_word" >&5
1277 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1278 if test "${ac_cv_prog_CC+set}" = set; then
1279   echo $ECHO_N "(cached) $ECHO_C" >&6
1280 else
1281   if test -n "$CC"; then
1282   ac_cv_prog_CC="$CC" # Let the user override the test.
1283 else
1284 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1285 for as_dir in $PATH
1286 do
1287   IFS=$as_save_IFS
1288   test -z "$as_dir" && as_dir=.
1289   for ac_exec_ext in '' $ac_executable_extensions; do
1290   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1291     ac_cv_prog_CC="${ac_tool_prefix}gcc"
1292     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1293     break 2
1294   fi
1295 done
1296 done
1297
1298 fi
1299 fi
1300 CC=$ac_cv_prog_CC
1301 if test -n "$CC"; then
1302   echo "$as_me:$LINENO: result: $CC" >&5
1303 echo "${ECHO_T}$CC" >&6
1304 else
1305   echo "$as_me:$LINENO: result: no" >&5
1306 echo "${ECHO_T}no" >&6
1307 fi
1308
1309 fi
1310 if test -z "$ac_cv_prog_CC"; then
1311   ac_ct_CC=$CC
1312   # Extract the first word of "gcc", so it can be a program name with args.
1313 set dummy gcc; ac_word=$2
1314 echo "$as_me:$LINENO: checking for $ac_word" >&5
1315 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1316 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1317   echo $ECHO_N "(cached) $ECHO_C" >&6
1318 else
1319   if test -n "$ac_ct_CC"; then
1320   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1321 else
1322 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1323 for as_dir in $PATH
1324 do
1325   IFS=$as_save_IFS
1326   test -z "$as_dir" && as_dir=.
1327   for ac_exec_ext in '' $ac_executable_extensions; do
1328   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1329     ac_cv_prog_ac_ct_CC="gcc"
1330     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1331     break 2
1332   fi
1333 done
1334 done
1335
1336 fi
1337 fi
1338 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1339 if test -n "$ac_ct_CC"; then
1340   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1341 echo "${ECHO_T}$ac_ct_CC" >&6
1342 else
1343   echo "$as_me:$LINENO: result: no" >&5
1344 echo "${ECHO_T}no" >&6
1345 fi
1346
1347   CC=$ac_ct_CC
1348 else
1349   CC="$ac_cv_prog_CC"
1350 fi
1351
1352 if test -z "$CC"; then
1353   if test -n "$ac_tool_prefix"; then
1354   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1355 set dummy ${ac_tool_prefix}cc; ac_word=$2
1356 echo "$as_me:$LINENO: checking for $ac_word" >&5
1357 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1358 if test "${ac_cv_prog_CC+set}" = set; then
1359   echo $ECHO_N "(cached) $ECHO_C" >&6
1360 else
1361   if test -n "$CC"; then
1362   ac_cv_prog_CC="$CC" # Let the user override the test.
1363 else
1364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1365 for as_dir in $PATH
1366 do
1367   IFS=$as_save_IFS
1368   test -z "$as_dir" && as_dir=.
1369   for ac_exec_ext in '' $ac_executable_extensions; do
1370   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1371     ac_cv_prog_CC="${ac_tool_prefix}cc"
1372     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1373     break 2
1374   fi
1375 done
1376 done
1377
1378 fi
1379 fi
1380 CC=$ac_cv_prog_CC
1381 if test -n "$CC"; then
1382   echo "$as_me:$LINENO: result: $CC" >&5
1383 echo "${ECHO_T}$CC" >&6
1384 else
1385   echo "$as_me:$LINENO: result: no" >&5
1386 echo "${ECHO_T}no" >&6
1387 fi
1388
1389 fi
1390 if test -z "$ac_cv_prog_CC"; then
1391   ac_ct_CC=$CC
1392   # Extract the first word of "cc", so it can be a program name with args.
1393 set dummy cc; ac_word=$2
1394 echo "$as_me:$LINENO: checking for $ac_word" >&5
1395 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1396 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1397   echo $ECHO_N "(cached) $ECHO_C" >&6
1398 else
1399   if test -n "$ac_ct_CC"; then
1400   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1401 else
1402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1403 for as_dir in $PATH
1404 do
1405   IFS=$as_save_IFS
1406   test -z "$as_dir" && as_dir=.
1407   for ac_exec_ext in '' $ac_executable_extensions; do
1408   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1409     ac_cv_prog_ac_ct_CC="cc"
1410     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1411     break 2
1412   fi
1413 done
1414 done
1415
1416 fi
1417 fi
1418 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1419 if test -n "$ac_ct_CC"; then
1420   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1421 echo "${ECHO_T}$ac_ct_CC" >&6
1422 else
1423   echo "$as_me:$LINENO: result: no" >&5
1424 echo "${ECHO_T}no" >&6
1425 fi
1426
1427   CC=$ac_ct_CC
1428 else
1429   CC="$ac_cv_prog_CC"
1430 fi
1431
1432 fi
1433 if test -z "$CC"; then
1434   # Extract the first word of "cc", so it can be a program name with args.
1435 set dummy cc; ac_word=$2
1436 echo "$as_me:$LINENO: checking for $ac_word" >&5
1437 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1438 if test "${ac_cv_prog_CC+set}" = set; then
1439   echo $ECHO_N "(cached) $ECHO_C" >&6
1440 else
1441   if test -n "$CC"; then
1442   ac_cv_prog_CC="$CC" # Let the user override the test.
1443 else
1444   ac_prog_rejected=no
1445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1446 for as_dir in $PATH
1447 do
1448   IFS=$as_save_IFS
1449   test -z "$as_dir" && as_dir=.
1450   for ac_exec_ext in '' $ac_executable_extensions; do
1451   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1452     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1453        ac_prog_rejected=yes
1454        continue
1455      fi
1456     ac_cv_prog_CC="cc"
1457     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1458     break 2
1459   fi
1460 done
1461 done
1462
1463 if test $ac_prog_rejected = yes; then
1464   # We found a bogon in the path, so make sure we never use it.
1465   set dummy $ac_cv_prog_CC
1466   shift
1467   if test $# != 0; then
1468     # We chose a different compiler from the bogus one.
1469     # However, it has the same basename, so the bogon will be chosen
1470     # first if we set CC to just the basename; use the full file name.
1471     shift
1472     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
1473   fi
1474 fi
1475 fi
1476 fi
1477 CC=$ac_cv_prog_CC
1478 if test -n "$CC"; then
1479   echo "$as_me:$LINENO: result: $CC" >&5
1480 echo "${ECHO_T}$CC" >&6
1481 else
1482   echo "$as_me:$LINENO: result: no" >&5
1483 echo "${ECHO_T}no" >&6
1484 fi
1485
1486 fi
1487 if test -z "$CC"; then
1488   if test -n "$ac_tool_prefix"; then
1489   for ac_prog in cl
1490   do
1491     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1492 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1493 echo "$as_me:$LINENO: checking for $ac_word" >&5
1494 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1495 if test "${ac_cv_prog_CC+set}" = set; then
1496   echo $ECHO_N "(cached) $ECHO_C" >&6
1497 else
1498   if test -n "$CC"; then
1499   ac_cv_prog_CC="$CC" # Let the user override the test.
1500 else
1501 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1502 for as_dir in $PATH
1503 do
1504   IFS=$as_save_IFS
1505   test -z "$as_dir" && as_dir=.
1506   for ac_exec_ext in '' $ac_executable_extensions; do
1507   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1508     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1509     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1510     break 2
1511   fi
1512 done
1513 done
1514
1515 fi
1516 fi
1517 CC=$ac_cv_prog_CC
1518 if test -n "$CC"; then
1519   echo "$as_me:$LINENO: result: $CC" >&5
1520 echo "${ECHO_T}$CC" >&6
1521 else
1522   echo "$as_me:$LINENO: result: no" >&5
1523 echo "${ECHO_T}no" >&6
1524 fi
1525
1526     test -n "$CC" && break
1527   done
1528 fi
1529 if test -z "$CC"; then
1530   ac_ct_CC=$CC
1531   for ac_prog in cl
1532 do
1533   # Extract the first word of "$ac_prog", so it can be a program name with args.
1534 set dummy $ac_prog; ac_word=$2
1535 echo "$as_me:$LINENO: checking for $ac_word" >&5
1536 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1537 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1538   echo $ECHO_N "(cached) $ECHO_C" >&6
1539 else
1540   if test -n "$ac_ct_CC"; then
1541   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1542 else
1543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1544 for as_dir in $PATH
1545 do
1546   IFS=$as_save_IFS
1547   test -z "$as_dir" && as_dir=.
1548   for ac_exec_ext in '' $ac_executable_extensions; do
1549   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1550     ac_cv_prog_ac_ct_CC="$ac_prog"
1551     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1552     break 2
1553   fi
1554 done
1555 done
1556
1557 fi
1558 fi
1559 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1560 if test -n "$ac_ct_CC"; then
1561   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1562 echo "${ECHO_T}$ac_ct_CC" >&6
1563 else
1564   echo "$as_me:$LINENO: result: no" >&5
1565 echo "${ECHO_T}no" >&6
1566 fi
1567
1568   test -n "$ac_ct_CC" && break
1569 done
1570
1571   CC=$ac_ct_CC
1572 fi
1573
1574 fi
1575
1576
1577 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
1578 See \`config.log' for more details." >&5
1579 echo "$as_me: error: no acceptable C compiler found in \$PATH
1580 See \`config.log' for more details." >&2;}
1581    { (exit 1); exit 1; }; }
1582
1583 # Provide some information about the compiler.
1584 echo "$as_me:$LINENO:" \
1585      "checking for C compiler version" >&5
1586 ac_compiler=`set X $ac_compile; echo $2`
1587 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1588   (eval $ac_compiler --version </dev/null >&5) 2>&5
1589   ac_status=$?
1590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1591   (exit $ac_status); }
1592 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1593   (eval $ac_compiler -v </dev/null >&5) 2>&5
1594   ac_status=$?
1595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1596   (exit $ac_status); }
1597 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1598   (eval $ac_compiler -V </dev/null >&5) 2>&5
1599   ac_status=$?
1600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1601   (exit $ac_status); }
1602
1603 cat >conftest.$ac_ext <<_ACEOF
1604 /* confdefs.h.  */
1605 _ACEOF
1606 cat confdefs.h >>conftest.$ac_ext
1607 cat >>conftest.$ac_ext <<_ACEOF
1608 /* end confdefs.h.  */
1609
1610 int
1611 main ()
1612 {
1613
1614   ;
1615   return 0;
1616 }
1617 _ACEOF
1618 ac_clean_files_save=$ac_clean_files
1619 ac_clean_files="$ac_clean_files a.out a.exe b.out"
1620 # Try to create an executable without -o first, disregard a.out.
1621 # It will help us diagnose broken compilers, and finding out an intuition
1622 # of exeext.
1623 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
1624 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
1625 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1626 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1627   (eval $ac_link_default) 2>&5
1628   ac_status=$?
1629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1630   (exit $ac_status); }; then
1631   # Find the output, starting from the most likely.  This scheme is
1632 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1633 # resort.
1634
1635 # Be careful to initialize this variable, since it used to be cached.
1636 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1637 ac_cv_exeext=
1638 # b.out is created by i960 compilers.
1639 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1640 do
1641   test -f "$ac_file" || continue
1642   case $ac_file in
1643     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
1644         ;;
1645     conftest.$ac_ext )
1646         # This is the source file.
1647         ;;
1648     [ab].out )
1649         # We found the default executable, but exeext='' is most
1650         # certainly right.
1651         break;;
1652     *.* )
1653         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1654         # FIXME: I believe we export ac_cv_exeext for Libtool,
1655         # but it would be cool to find out if it's true.  Does anybody
1656         # maintain Libtool? --akim.
1657         export ac_cv_exeext
1658         break;;
1659     * )
1660         break;;
1661   esac
1662 done
1663 else
1664   echo "$as_me: failed program was:" >&5
1665 sed 's/^/| /' conftest.$ac_ext >&5
1666
1667 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
1668 See \`config.log' for more details." >&5
1669 echo "$as_me: error: C compiler cannot create executables
1670 See \`config.log' for more details." >&2;}
1671    { (exit 77); exit 77; }; }
1672 fi
1673
1674 ac_exeext=$ac_cv_exeext
1675 echo "$as_me:$LINENO: result: $ac_file" >&5
1676 echo "${ECHO_T}$ac_file" >&6
1677
1678 # Check the compiler produces executables we can run.  If not, either
1679 # the compiler is broken, or we cross compile.
1680 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
1681 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1682 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1683 # If not cross compiling, check that we can run a simple program.
1684 if test "$cross_compiling" != yes; then
1685   if { ac_try='./$ac_file'
1686   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1687   (eval $ac_try) 2>&5
1688   ac_status=$?
1689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1690   (exit $ac_status); }; }; then
1691     cross_compiling=no
1692   else
1693     if test "$cross_compiling" = maybe; then
1694         cross_compiling=yes
1695     else
1696         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
1697 If you meant to cross compile, use \`--host'.
1698 See \`config.log' for more details." >&5
1699 echo "$as_me: error: cannot run C compiled programs.
1700 If you meant to cross compile, use \`--host'.
1701 See \`config.log' for more details." >&2;}
1702    { (exit 1); exit 1; }; }
1703     fi
1704   fi
1705 fi
1706 echo "$as_me:$LINENO: result: yes" >&5
1707 echo "${ECHO_T}yes" >&6
1708
1709 rm -f a.out a.exe conftest$ac_cv_exeext b.out
1710 ac_clean_files=$ac_clean_files_save
1711 # Check the compiler produces executables we can run.  If not, either
1712 # the compiler is broken, or we cross compile.
1713 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1714 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1715 echo "$as_me:$LINENO: result: $cross_compiling" >&5
1716 echo "${ECHO_T}$cross_compiling" >&6
1717
1718 echo "$as_me:$LINENO: checking for suffix of executables" >&5
1719 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1720 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1721   (eval $ac_link) 2>&5
1722   ac_status=$?
1723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1724   (exit $ac_status); }; then
1725   # If both `conftest.exe' and `conftest' are `present' (well, observable)
1726 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1727 # work properly (i.e., refer to `conftest.exe'), while it won't with
1728 # `rm'.
1729 for ac_file in conftest.exe conftest conftest.*; do
1730   test -f "$ac_file" || continue
1731   case $ac_file in
1732     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
1733     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1734           export ac_cv_exeext
1735           break;;
1736     * ) break;;
1737   esac
1738 done
1739 else
1740   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
1741 See \`config.log' for more details." >&5
1742 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
1743 See \`config.log' for more details." >&2;}
1744    { (exit 1); exit 1; }; }
1745 fi
1746
1747 rm -f conftest$ac_cv_exeext
1748 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1749 echo "${ECHO_T}$ac_cv_exeext" >&6
1750
1751 rm -f conftest.$ac_ext
1752 EXEEXT=$ac_cv_exeext
1753 ac_exeext=$EXEEXT
1754 echo "$as_me:$LINENO: checking for suffix of object files" >&5
1755 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
1756 if test "${ac_cv_objext+set}" = set; then
1757   echo $ECHO_N "(cached) $ECHO_C" >&6
1758 else
1759   cat >conftest.$ac_ext <<_ACEOF
1760 /* confdefs.h.  */
1761 _ACEOF
1762 cat confdefs.h >>conftest.$ac_ext
1763 cat >>conftest.$ac_ext <<_ACEOF
1764 /* end confdefs.h.  */
1765
1766 int
1767 main ()
1768 {
1769
1770   ;
1771   return 0;
1772 }
1773 _ACEOF
1774 rm -f conftest.o conftest.obj
1775 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1776   (eval $ac_compile) 2>&5
1777   ac_status=$?
1778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1779   (exit $ac_status); }; then
1780   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1781   case $ac_file in
1782     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
1783     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1784        break;;
1785   esac
1786 done
1787 else
1788   echo "$as_me: failed program was:" >&5
1789 sed 's/^/| /' conftest.$ac_ext >&5
1790
1791 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
1792 See \`config.log' for more details." >&5
1793 echo "$as_me: error: cannot compute suffix of object files: cannot compile
1794 See \`config.log' for more details." >&2;}
1795    { (exit 1); exit 1; }; }
1796 fi
1797
1798 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1799 fi
1800 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
1801 echo "${ECHO_T}$ac_cv_objext" >&6
1802 OBJEXT=$ac_cv_objext
1803 ac_objext=$OBJEXT
1804 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
1805 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1806 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1807   echo $ECHO_N "(cached) $ECHO_C" >&6
1808 else
1809   cat >conftest.$ac_ext <<_ACEOF
1810 /* confdefs.h.  */
1811 _ACEOF
1812 cat confdefs.h >>conftest.$ac_ext
1813 cat >>conftest.$ac_ext <<_ACEOF
1814 /* end confdefs.h.  */
1815
1816 int
1817 main ()
1818 {
1819 #ifndef __GNUC__
1820        choke me
1821 #endif
1822
1823   ;
1824   return 0;
1825 }
1826 _ACEOF
1827 rm -f conftest.$ac_objext
1828 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1829   (eval $ac_compile) 2>conftest.er1
1830   ac_status=$?
1831   grep -v '^ *+' conftest.er1 >conftest.err
1832   rm -f conftest.er1
1833   cat conftest.err >&5
1834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1835   (exit $ac_status); } &&
1836          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
1837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1838   (eval $ac_try) 2>&5
1839   ac_status=$?
1840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1841   (exit $ac_status); }; } &&
1842          { ac_try='test -s conftest.$ac_objext'
1843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1844   (eval $ac_try) 2>&5
1845   ac_status=$?
1846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1847   (exit $ac_status); }; }; then
1848   ac_compiler_gnu=yes
1849 else
1850   echo "$as_me: failed program was:" >&5
1851 sed 's/^/| /' conftest.$ac_ext >&5
1852
1853 ac_compiler_gnu=no
1854 fi
1855 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1856 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1857
1858 fi
1859 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
1860 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1861 GCC=`test $ac_compiler_gnu = yes && echo yes`
1862 ac_test_CFLAGS=${CFLAGS+set}
1863 ac_save_CFLAGS=$CFLAGS
1864 CFLAGS="-g"
1865 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
1866 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1867 if test "${ac_cv_prog_cc_g+set}" = set; then
1868   echo $ECHO_N "(cached) $ECHO_C" >&6
1869 else
1870   cat >conftest.$ac_ext <<_ACEOF
1871 /* confdefs.h.  */
1872 _ACEOF
1873 cat confdefs.h >>conftest.$ac_ext
1874 cat >>conftest.$ac_ext <<_ACEOF
1875 /* end confdefs.h.  */
1876
1877 int
1878 main ()
1879 {
1880
1881   ;
1882   return 0;
1883 }
1884 _ACEOF
1885 rm -f conftest.$ac_objext
1886 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1887   (eval $ac_compile) 2>conftest.er1
1888   ac_status=$?
1889   grep -v '^ *+' conftest.er1 >conftest.err
1890   rm -f conftest.er1
1891   cat conftest.err >&5
1892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1893   (exit $ac_status); } &&
1894          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
1895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1896   (eval $ac_try) 2>&5
1897   ac_status=$?
1898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1899   (exit $ac_status); }; } &&
1900          { ac_try='test -s conftest.$ac_objext'
1901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1902   (eval $ac_try) 2>&5
1903   ac_status=$?
1904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1905   (exit $ac_status); }; }; then
1906   ac_cv_prog_cc_g=yes
1907 else
1908   echo "$as_me: failed program was:" >&5
1909 sed 's/^/| /' conftest.$ac_ext >&5
1910
1911 ac_cv_prog_cc_g=no
1912 fi
1913 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1914 fi
1915 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
1916 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1917 if test "$ac_test_CFLAGS" = set; then
1918   CFLAGS=$ac_save_CFLAGS
1919 elif test $ac_cv_prog_cc_g = yes; then
1920   if test "$GCC" = yes; then
1921     CFLAGS="-g -O2"
1922   else
1923     CFLAGS="-g"
1924   fi
1925 else
1926   if test "$GCC" = yes; then
1927     CFLAGS="-O2"
1928   else
1929     CFLAGS=
1930   fi
1931 fi
1932 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
1933 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
1934 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1935   echo $ECHO_N "(cached) $ECHO_C" >&6
1936 else
1937   ac_cv_prog_cc_stdc=no
1938 ac_save_CC=$CC
1939 cat >conftest.$ac_ext <<_ACEOF
1940 /* confdefs.h.  */
1941 _ACEOF
1942 cat confdefs.h >>conftest.$ac_ext
1943 cat >>conftest.$ac_ext <<_ACEOF
1944 /* end confdefs.h.  */
1945 #include <stdarg.h>
1946 #include <stdio.h>
1947 #include <sys/types.h>
1948 #include <sys/stat.h>
1949 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
1950 struct buf { int x; };
1951 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1952 static char *e (p, i)
1953      char **p;
1954      int i;
1955 {
1956   return p[i];
1957 }
1958 static char *f (char * (*g) (char **, int), char **p, ...)
1959 {
1960   char *s;
1961   va_list v;
1962   va_start (v,p);
1963   s = g (p, va_arg (v,int));
1964   va_end (v);
1965   return s;
1966 }
1967
1968 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
1969    function prototypes and stuff, but not '\xHH' hex character constants.
1970    These don't provoke an error unfortunately, instead are silently treated
1971    as 'x'.  The following induces an error, until -std1 is added to get
1972    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
1973    array size at least.  It's necessary to write '\x00'==0 to get something
1974    that's true only with -std1.  */
1975 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
1976
1977 int test (int i, double x);
1978 struct s1 {int (*f) (int a);};
1979 struct s2 {int (*f) (double a);};
1980 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1981 int argc;
1982 char **argv;
1983 int
1984 main ()
1985 {
1986 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
1987   ;
1988   return 0;
1989 }
1990 _ACEOF
1991 # Don't try gcc -ansi; that turns off useful extensions and
1992 # breaks some systems' header files.
1993 # AIX                   -qlanglvl=ansi
1994 # Ultrix and OSF/1      -std1
1995 # HP-UX 10.20 and later -Ae
1996 # HP-UX older versions  -Aa -D_HPUX_SOURCE
1997 # SVR4                  -Xc -D__EXTENSIONS__
1998 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1999 do
2000   CC="$ac_save_CC $ac_arg"
2001   rm -f conftest.$ac_objext
2002 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2003   (eval $ac_compile) 2>conftest.er1
2004   ac_status=$?
2005   grep -v '^ *+' conftest.er1 >conftest.err
2006   rm -f conftest.er1
2007   cat conftest.err >&5
2008   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2009   (exit $ac_status); } &&
2010          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2012   (eval $ac_try) 2>&5
2013   ac_status=$?
2014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2015   (exit $ac_status); }; } &&
2016          { ac_try='test -s conftest.$ac_objext'
2017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2018   (eval $ac_try) 2>&5
2019   ac_status=$?
2020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2021   (exit $ac_status); }; }; then
2022   ac_cv_prog_cc_stdc=$ac_arg
2023 break
2024 else
2025   echo "$as_me: failed program was:" >&5
2026 sed 's/^/| /' conftest.$ac_ext >&5
2027
2028 fi
2029 rm -f conftest.err conftest.$ac_objext
2030 done
2031 rm -f conftest.$ac_ext conftest.$ac_objext
2032 CC=$ac_save_CC
2033
2034 fi
2035
2036 case "x$ac_cv_prog_cc_stdc" in
2037   x|xno)
2038     echo "$as_me:$LINENO: result: none needed" >&5
2039 echo "${ECHO_T}none needed" >&6 ;;
2040   *)
2041     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2042 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2043     CC="$CC $ac_cv_prog_cc_stdc" ;;
2044 esac
2045
2046 # Some people use a C++ compiler to compile C.  Since we use `exit',
2047 # in C++ we need to declare it.  In case someone uses the same compiler
2048 # for both compiling C and C++ we need to have the C++ compiler decide
2049 # the declaration of exit, since it's the most demanding environment.
2050 cat >conftest.$ac_ext <<_ACEOF
2051 #ifndef __cplusplus
2052   choke me
2053 #endif
2054 _ACEOF
2055 rm -f conftest.$ac_objext
2056 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2057   (eval $ac_compile) 2>conftest.er1
2058   ac_status=$?
2059   grep -v '^ *+' conftest.er1 >conftest.err
2060   rm -f conftest.er1
2061   cat conftest.err >&5
2062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2063   (exit $ac_status); } &&
2064          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2065   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2066   (eval $ac_try) 2>&5
2067   ac_status=$?
2068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2069   (exit $ac_status); }; } &&
2070          { ac_try='test -s conftest.$ac_objext'
2071   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2072   (eval $ac_try) 2>&5
2073   ac_status=$?
2074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2075   (exit $ac_status); }; }; then
2076   for ac_declaration in \
2077    '' \
2078    'extern "C" void std::exit (int) throw (); using std::exit;' \
2079    'extern "C" void std::exit (int); using std::exit;' \
2080    'extern "C" void exit (int) throw ();' \
2081    'extern "C" void exit (int);' \
2082    'void exit (int);'
2083 do
2084   cat >conftest.$ac_ext <<_ACEOF
2085 /* confdefs.h.  */
2086 _ACEOF
2087 cat confdefs.h >>conftest.$ac_ext
2088 cat >>conftest.$ac_ext <<_ACEOF
2089 /* end confdefs.h.  */
2090 $ac_declaration
2091 #include <stdlib.h>
2092 int
2093 main ()
2094 {
2095 exit (42);
2096   ;
2097   return 0;
2098 }
2099 _ACEOF
2100 rm -f conftest.$ac_objext
2101 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2102   (eval $ac_compile) 2>conftest.er1
2103   ac_status=$?
2104   grep -v '^ *+' conftest.er1 >conftest.err
2105   rm -f conftest.er1
2106   cat conftest.err >&5
2107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2108   (exit $ac_status); } &&
2109          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2111   (eval $ac_try) 2>&5
2112   ac_status=$?
2113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2114   (exit $ac_status); }; } &&
2115          { ac_try='test -s conftest.$ac_objext'
2116   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2117   (eval $ac_try) 2>&5
2118   ac_status=$?
2119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2120   (exit $ac_status); }; }; then
2121   :
2122 else
2123   echo "$as_me: failed program was:" >&5
2124 sed 's/^/| /' conftest.$ac_ext >&5
2125
2126 continue
2127 fi
2128 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2129   cat >conftest.$ac_ext <<_ACEOF
2130 /* confdefs.h.  */
2131 _ACEOF
2132 cat confdefs.h >>conftest.$ac_ext
2133 cat >>conftest.$ac_ext <<_ACEOF
2134 /* end confdefs.h.  */
2135 $ac_declaration
2136 int
2137 main ()
2138 {
2139 exit (42);
2140   ;
2141   return 0;
2142 }
2143 _ACEOF
2144 rm -f conftest.$ac_objext
2145 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2146   (eval $ac_compile) 2>conftest.er1
2147   ac_status=$?
2148   grep -v '^ *+' conftest.er1 >conftest.err
2149   rm -f conftest.er1
2150   cat conftest.err >&5
2151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2152   (exit $ac_status); } &&
2153          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2154   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2155   (eval $ac_try) 2>&5
2156   ac_status=$?
2157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2158   (exit $ac_status); }; } &&
2159          { ac_try='test -s conftest.$ac_objext'
2160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2161   (eval $ac_try) 2>&5
2162   ac_status=$?
2163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2164   (exit $ac_status); }; }; then
2165   break
2166 else
2167   echo "$as_me: failed program was:" >&5
2168 sed 's/^/| /' conftest.$ac_ext >&5
2169
2170 fi
2171 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2172 done
2173 rm -f conftest*
2174 if test -n "$ac_declaration"; then
2175   echo '#ifdef __cplusplus' >>confdefs.h
2176   echo $ac_declaration      >>confdefs.h
2177   echo '#endif'             >>confdefs.h
2178 fi
2179
2180 else
2181   echo "$as_me: failed program was:" >&5
2182 sed 's/^/| /' conftest.$ac_ext >&5
2183
2184 fi
2185 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2186 ac_ext=c
2187 ac_cpp='$CPP $CPPFLAGS'
2188 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2189 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2190 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2191
2192
2193
2194                 rlm_ldap_lib_dir=
2195
2196 # Check whether --with-rlm-ldap-lib-dir or --without-rlm-ldap-lib-dir was given.
2197 if test "${with_rlm_ldap_lib_dir+set}" = set; then
2198   withval="$with_rlm_ldap_lib_dir"
2199    case "$withval" in
2200             no)
2201                 { { echo "$as_me:$LINENO: error: Need rlm-ldap-lib-dir" >&5
2202 echo "$as_me: error: Need rlm-ldap-lib-dir" >&2;}
2203    { (exit 1); exit 1; }; }
2204                 ;;
2205             yes)
2206                 ;;
2207             *)
2208                 rlm_ldap_lib_dir="$withval"
2209                 ;;
2210           esac
2211
2212 fi;
2213
2214                 rlm_ldap_include_dir=
2215
2216 # Check whether --with-rlm-ldap-include-dir or --without-rlm-ldap-include-dir was given.
2217 if test "${with_rlm_ldap_include_dir+set}" = set; then
2218   withval="$with_rlm_ldap_include_dir"
2219    case "$withval" in
2220             no)
2221                 { { echo "$as_me:$LINENO: error: Need rlm-ldap-include-dir" >&5
2222 echo "$as_me: error: Need rlm-ldap-include-dir" >&2;}
2223    { (exit 1); exit 1; }; }
2224                 ;;
2225             yes)
2226                 ;;
2227             *)
2228                 rlm_ldap_include_dir="$withval"
2229                 ;;
2230           esac
2231
2232 fi;
2233
2234                 # Check whether --enable-shared or --disable-shared was given.
2235 if test "${enable_shared+set}" = set; then
2236   enableval="$enable_shared"
2237   p=${PACKAGE-default}
2238     case $enableval in
2239     yes) enable_shared=yes ;;
2240     no) enable_shared=no ;;
2241     *)
2242       enable_shared=no
2243       # Look at the argument we got.  We use all the common list separators.
2244       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2245       for pkg in $enableval; do
2246         IFS="$lt_save_ifs"
2247         if test "X$pkg" = "X$p"; then
2248           enable_shared=yes
2249         fi
2250       done
2251       IFS="$lt_save_ifs"
2252       ;;
2253     esac
2254 else
2255   enable_shared=yes
2256 fi;
2257
2258
2259                                 if test "x$enable_shared" = "xno"; then
2260                 { echo "$as_me:$LINENO: WARNING: Static linking with libldap will probably result in unresolved symbols." >&5
2261 echo "$as_me: WARNING: Static linking with libldap will probably result in unresolved symbols." >&2;}
2262         fi
2263
2264                 rlm_ldap_with_threads=yes
2265
2266 # Check whether --with-threads or --without-threads was given.
2267 if test "${with_threads+set}" = set; then
2268   withval="$with_threads"
2269    case "$withval" in
2270             no)
2271                 rlm_ldap_with_threads=no
2272                 ;;
2273             *)
2274                 ;;
2275             esac
2276 fi;
2277
2278
2279                         if test "x$rlm_ldap_with_threads" = "xyes"; then
2280             echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
2281 echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
2282 if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then
2283   echo $ECHO_N "(cached) $ECHO_C" >&6
2284 else
2285   ac_check_lib_save_LIBS=$LIBS
2286 LIBS="-lpthread  $LIBS"
2287 cat >conftest.$ac_ext <<_ACEOF
2288 /* confdefs.h.  */
2289 _ACEOF
2290 cat confdefs.h >>conftest.$ac_ext
2291 cat >>conftest.$ac_ext <<_ACEOF
2292 /* end confdefs.h.  */
2293
2294 /* Override any gcc2 internal prototype to avoid an error.  */
2295 #ifdef __cplusplus
2296 extern "C"
2297 #endif
2298 /* We use char because int might match the return type of a gcc2
2299    builtin and then its argument prototype would still apply.  */
2300 char pthread_create ();
2301 int
2302 main ()
2303 {
2304 pthread_create ();
2305   ;
2306   return 0;
2307 }
2308 _ACEOF
2309 rm -f conftest.$ac_objext conftest$ac_exeext
2310 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2311   (eval $ac_link) 2>conftest.er1
2312   ac_status=$?
2313   grep -v '^ *+' conftest.er1 >conftest.err
2314   rm -f conftest.er1
2315   cat conftest.err >&5
2316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2317   (exit $ac_status); } &&
2318          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2319   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2320   (eval $ac_try) 2>&5
2321   ac_status=$?
2322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2323   (exit $ac_status); }; } &&
2324          { ac_try='test -s conftest$ac_exeext'
2325   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2326   (eval $ac_try) 2>&5
2327   ac_status=$?
2328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2329   (exit $ac_status); }; }; then
2330   ac_cv_lib_pthread_pthread_create=yes
2331 else
2332   echo "$as_me: failed program was:" >&5
2333 sed 's/^/| /' conftest.$ac_ext >&5
2334
2335 ac_cv_lib_pthread_pthread_create=no
2336 fi
2337 rm -f conftest.err conftest.$ac_objext \
2338       conftest$ac_exeext conftest.$ac_ext
2339 LIBS=$ac_check_lib_save_LIBS
2340 fi
2341 echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5
2342 echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6
2343 if test $ac_cv_lib_pthread_pthread_create = yes; then
2344    LIBS="-lpthread $LIBS"
2345 else
2346   echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
2347 echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6
2348 if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
2349   echo $ECHO_N "(cached) $ECHO_C" >&6
2350 else
2351   ac_check_lib_save_LIBS=$LIBS
2352 LIBS="-lc_r  $LIBS"
2353
2354 cat >conftest.$ac_ext <<_ACEOF
2355 /* confdefs.h.  */
2356 _ACEOF
2357 cat confdefs.h >>conftest.$ac_ext
2358 cat >>conftest.$ac_ext <<_ACEOF
2359 /* end confdefs.h.  */
2360
2361 /* Override any gcc2 internal prototype to avoid an error.  */
2362 #ifdef __cplusplus
2363 extern "C"
2364 #endif
2365 /* We use char because int might match the return type of a gcc2
2366    builtin and then its argument prototype would still apply.  */
2367 char pthread_create ();
2368 int
2369 main ()
2370 {
2371 pthread_create ();
2372   ;
2373   return 0;
2374 }
2375 _ACEOF
2376 rm -f conftest.$ac_objext conftest$ac_exeext
2377 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2378   (eval $ac_link) 2>conftest.er1
2379   ac_status=$?
2380   grep -v '^ *+' conftest.er1 >conftest.err
2381   rm -f conftest.er1
2382   cat conftest.err >&5
2383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2384   (exit $ac_status); } &&
2385          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2387   (eval $ac_try) 2>&5
2388   ac_status=$?
2389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2390   (exit $ac_status); }; } &&
2391          { ac_try='test -s conftest$ac_exeext'
2392   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2393   (eval $ac_try) 2>&5
2394   ac_status=$?
2395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2396   (exit $ac_status); }; }; then
2397   ac_cv_lib_c_r_pthread_create=yes
2398 else
2399   echo "$as_me: failed program was:" >&5
2400 sed 's/^/| /' conftest.$ac_ext >&5
2401
2402 ac_cv_lib_c_r_pthread_create=no
2403 fi
2404 rm -f conftest.err conftest.$ac_objext \
2405       conftest$ac_exeext conftest.$ac_ext
2406 LIBS=$ac_check_lib_save_LIBS
2407 fi
2408 echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
2409 echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6
2410 if test $ac_cv_lib_c_r_pthread_create = yes; then
2411    LIBS="-lc_r $LIBS"
2412 else
2413    rlm_ldap_with_threads="no"
2414
2415 fi
2416
2417
2418 fi
2419
2420         fi
2421
2422                                 smart_try_dir=$rlm_ldap_lib_dir
2423         if test "x$rlm_ldap_with_threads" = "xyes"; then
2424
2425
2426 sm_lib_safe=`echo "ldap_r" | sed 'y%./+-%__p_%'`
2427 sm_func_safe=`echo "ldap_init" | sed 'y%./+-%__p_%'`
2428 echo "$as_me:$LINENO: checking for ldap_init in -lldap_r" >&5
2429 echo $ECHO_N "checking for ldap_init in -lldap_r... $ECHO_C" >&6
2430
2431 old_LIBS="$LIBS"
2432 smart_lib=
2433 smart_lib_dir=
2434
2435 if test "x$smart_try_dir" != "x"; then
2436   for try in $smart_try_dir; do
2437     LIBS="-L$try -lldap_r $old_LIBS"
2438     cat >conftest.$ac_ext <<_ACEOF
2439 /* confdefs.h.  */
2440 _ACEOF
2441 cat confdefs.h >>conftest.$ac_ext
2442 cat >>conftest.$ac_ext <<_ACEOF
2443 /* end confdefs.h.  */
2444 extern char ldap_init();
2445 int
2446 main ()
2447 {
2448  ldap_init()
2449   ;
2450   return 0;
2451 }
2452 _ACEOF
2453 rm -f conftest.$ac_objext conftest$ac_exeext
2454 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2455   (eval $ac_link) 2>conftest.er1
2456   ac_status=$?
2457   grep -v '^ *+' conftest.er1 >conftest.err
2458   rm -f conftest.er1
2459   cat conftest.err >&5
2460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2461   (exit $ac_status); } &&
2462          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2463   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2464   (eval $ac_try) 2>&5
2465   ac_status=$?
2466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2467   (exit $ac_status); }; } &&
2468          { ac_try='test -s conftest$ac_exeext'
2469   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2470   (eval $ac_try) 2>&5
2471   ac_status=$?
2472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2473   (exit $ac_status); }; }; then
2474   smart_lib="-L$try -lldap_r"
2475 else
2476   echo "$as_me: failed program was:" >&5
2477 sed 's/^/| /' conftest.$ac_ext >&5
2478
2479 fi
2480 rm -f conftest.err conftest.$ac_objext \
2481       conftest$ac_exeext conftest.$ac_ext
2482     if test "x$smart_lib" != "x"; then
2483       break;
2484     fi
2485     LIBS="$old_LIBS"
2486   done
2487 fi
2488
2489 if test "x$smart_lib" = "x"; then
2490   LIBS="-lldap_r $old_LIBS"
2491   cat >conftest.$ac_ext <<_ACEOF
2492 /* confdefs.h.  */
2493 _ACEOF
2494 cat confdefs.h >>conftest.$ac_ext
2495 cat >>conftest.$ac_ext <<_ACEOF
2496 /* end confdefs.h.  */
2497 extern char ldap_init();
2498 int
2499 main ()
2500 {
2501  ldap_init()
2502   ;
2503   return 0;
2504 }
2505 _ACEOF
2506 rm -f conftest.$ac_objext conftest$ac_exeext
2507 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2508   (eval $ac_link) 2>conftest.er1
2509   ac_status=$?
2510   grep -v '^ *+' conftest.er1 >conftest.err
2511   rm -f conftest.er1
2512   cat conftest.err >&5
2513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2514   (exit $ac_status); } &&
2515          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2516   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2517   (eval $ac_try) 2>&5
2518   ac_status=$?
2519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2520   (exit $ac_status); }; } &&
2521          { ac_try='test -s conftest$ac_exeext'
2522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2523   (eval $ac_try) 2>&5
2524   ac_status=$?
2525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2526   (exit $ac_status); }; }; then
2527   smart_lib="-lldap_r"
2528 else
2529   echo "$as_me: failed program was:" >&5
2530 sed 's/^/| /' conftest.$ac_ext >&5
2531
2532 fi
2533 rm -f conftest.err conftest.$ac_objext \
2534       conftest$ac_exeext conftest.$ac_ext
2535   LIBS="$old_LIBS"
2536 fi
2537
2538 if test "x$smart_lib" = "x"; then
2539
2540
2541 if test "x$LOCATE" != "x"; then
2542         DIRS=
2543   file=libldap_r${libltdl_cv_shlibext}
2544
2545   for x in `${LOCATE} $file 2>/dev/null`; do
2546                                         base=`echo $x | sed "s%/${file}%%"`
2547     if test "x$x" = "x$base"; then
2548       continue;
2549     fi
2550
2551     dir=`${DIRNAME} $x 2>/dev/null`
2552                 exclude=`echo ${dir} | ${GREP} /home`
2553     if test "x$exclude" != "x"; then
2554       continue
2555     fi
2556
2557                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
2558     if test "x$already" = "x"; then
2559       DIRS="$DIRS $dir"
2560     fi
2561   done
2562 fi
2563
2564 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
2565
2566
2567
2568 if test "x$LOCATE" != "x"; then
2569         DIRS=
2570   file=libldap_r.a
2571
2572   for x in `${LOCATE} $file 2>/dev/null`; do
2573                                         base=`echo $x | sed "s%/${file}%%"`
2574     if test "x$x" = "x$base"; then
2575       continue;
2576     fi
2577
2578     dir=`${DIRNAME} $x 2>/dev/null`
2579                 exclude=`echo ${dir} | ${GREP} /home`
2580     if test "x$exclude" != "x"; then
2581       continue
2582     fi
2583
2584                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
2585     if test "x$already" = "x"; then
2586       DIRS="$DIRS $dir"
2587     fi
2588   done
2589 fi
2590
2591 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
2592
2593
2594   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
2595     LIBS="-L$try -lldap_r $old_LIBS"
2596     cat >conftest.$ac_ext <<_ACEOF
2597 /* confdefs.h.  */
2598 _ACEOF
2599 cat confdefs.h >>conftest.$ac_ext
2600 cat >>conftest.$ac_ext <<_ACEOF
2601 /* end confdefs.h.  */
2602 extern char ldap_init();
2603 int
2604 main ()
2605 {
2606  ldap_init()
2607   ;
2608   return 0;
2609 }
2610 _ACEOF
2611 rm -f conftest.$ac_objext conftest$ac_exeext
2612 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2613   (eval $ac_link) 2>conftest.er1
2614   ac_status=$?
2615   grep -v '^ *+' conftest.er1 >conftest.err
2616   rm -f conftest.er1
2617   cat conftest.err >&5
2618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2619   (exit $ac_status); } &&
2620          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2621   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2622   (eval $ac_try) 2>&5
2623   ac_status=$?
2624   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2625   (exit $ac_status); }; } &&
2626          { ac_try='test -s conftest$ac_exeext'
2627   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2628   (eval $ac_try) 2>&5
2629   ac_status=$?
2630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2631   (exit $ac_status); }; }; then
2632   smart_lib="-L$try -lldap_r"
2633 else
2634   echo "$as_me: failed program was:" >&5
2635 sed 's/^/| /' conftest.$ac_ext >&5
2636
2637 fi
2638 rm -f conftest.err conftest.$ac_objext \
2639       conftest$ac_exeext conftest.$ac_ext
2640     if test "x$smart_lib" != "x"; then
2641       break;
2642     fi
2643     LIBS="$old_LIBS"
2644   done
2645 fi
2646
2647 if test "x$smart_lib" != "x"; then
2648   echo "$as_me:$LINENO: result: yes" >&5
2649 echo "${ECHO_T}yes" >&6
2650   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
2651   LIBS="$smart_lib $old_LIBS"
2652   SMART_LIBS="$smart_lib $SMART_LIBS"
2653 else
2654   echo "$as_me:$LINENO: result: no" >&5
2655 echo "${ECHO_T}no" >&6
2656 fi
2657
2658             if test "x$ac_cv_lib_ldap_r_ldap_init" != "xyes"; then
2659                 fail="$fail libldap_r"
2660             fi
2661         else
2662
2663
2664 sm_lib_safe=`echo "ldap" | sed 'y%./+-%__p_%'`
2665 sm_func_safe=`echo "ldap_init" | sed 'y%./+-%__p_%'`
2666 echo "$as_me:$LINENO: checking for ldap_init in -lldap" >&5
2667 echo $ECHO_N "checking for ldap_init in -lldap... $ECHO_C" >&6
2668
2669 old_LIBS="$LIBS"
2670 smart_lib=
2671 smart_lib_dir=
2672
2673 if test "x$smart_try_dir" != "x"; then
2674   for try in $smart_try_dir; do
2675     LIBS="-L$try -lldap $old_LIBS"
2676     cat >conftest.$ac_ext <<_ACEOF
2677 /* confdefs.h.  */
2678 _ACEOF
2679 cat confdefs.h >>conftest.$ac_ext
2680 cat >>conftest.$ac_ext <<_ACEOF
2681 /* end confdefs.h.  */
2682 extern char ldap_init();
2683 int
2684 main ()
2685 {
2686  ldap_init()
2687   ;
2688   return 0;
2689 }
2690 _ACEOF
2691 rm -f conftest.$ac_objext conftest$ac_exeext
2692 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2693   (eval $ac_link) 2>conftest.er1
2694   ac_status=$?
2695   grep -v '^ *+' conftest.er1 >conftest.err
2696   rm -f conftest.er1
2697   cat conftest.err >&5
2698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2699   (exit $ac_status); } &&
2700          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2702   (eval $ac_try) 2>&5
2703   ac_status=$?
2704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2705   (exit $ac_status); }; } &&
2706          { ac_try='test -s conftest$ac_exeext'
2707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2708   (eval $ac_try) 2>&5
2709   ac_status=$?
2710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2711   (exit $ac_status); }; }; then
2712   smart_lib="-L$try -lldap"
2713 else
2714   echo "$as_me: failed program was:" >&5
2715 sed 's/^/| /' conftest.$ac_ext >&5
2716
2717 fi
2718 rm -f conftest.err conftest.$ac_objext \
2719       conftest$ac_exeext conftest.$ac_ext
2720     if test "x$smart_lib" != "x"; then
2721       break;
2722     fi
2723     LIBS="$old_LIBS"
2724   done
2725 fi
2726
2727 if test "x$smart_lib" = "x"; then
2728   LIBS="-lldap $old_LIBS"
2729   cat >conftest.$ac_ext <<_ACEOF
2730 /* confdefs.h.  */
2731 _ACEOF
2732 cat confdefs.h >>conftest.$ac_ext
2733 cat >>conftest.$ac_ext <<_ACEOF
2734 /* end confdefs.h.  */
2735 extern char ldap_init();
2736 int
2737 main ()
2738 {
2739  ldap_init()
2740   ;
2741   return 0;
2742 }
2743 _ACEOF
2744 rm -f conftest.$ac_objext conftest$ac_exeext
2745 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2746   (eval $ac_link) 2>conftest.er1
2747   ac_status=$?
2748   grep -v '^ *+' conftest.er1 >conftest.err
2749   rm -f conftest.er1
2750   cat conftest.err >&5
2751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2752   (exit $ac_status); } &&
2753          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2754   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2755   (eval $ac_try) 2>&5
2756   ac_status=$?
2757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2758   (exit $ac_status); }; } &&
2759          { ac_try='test -s conftest$ac_exeext'
2760   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2761   (eval $ac_try) 2>&5
2762   ac_status=$?
2763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2764   (exit $ac_status); }; }; then
2765   smart_lib="-lldap"
2766 else
2767   echo "$as_me: failed program was:" >&5
2768 sed 's/^/| /' conftest.$ac_ext >&5
2769
2770 fi
2771 rm -f conftest.err conftest.$ac_objext \
2772       conftest$ac_exeext conftest.$ac_ext
2773   LIBS="$old_LIBS"
2774 fi
2775
2776 if test "x$smart_lib" = "x"; then
2777
2778
2779 if test "x$LOCATE" != "x"; then
2780         DIRS=
2781   file=libldap${libltdl_cv_shlibext}
2782
2783   for x in `${LOCATE} $file 2>/dev/null`; do
2784                                         base=`echo $x | sed "s%/${file}%%"`
2785     if test "x$x" = "x$base"; then
2786       continue;
2787     fi
2788
2789     dir=`${DIRNAME} $x 2>/dev/null`
2790                 exclude=`echo ${dir} | ${GREP} /home`
2791     if test "x$exclude" != "x"; then
2792       continue
2793     fi
2794
2795                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
2796     if test "x$already" = "x"; then
2797       DIRS="$DIRS $dir"
2798     fi
2799   done
2800 fi
2801
2802 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
2803
2804
2805
2806 if test "x$LOCATE" != "x"; then
2807         DIRS=
2808   file=libldap.a
2809
2810   for x in `${LOCATE} $file 2>/dev/null`; do
2811                                         base=`echo $x | sed "s%/${file}%%"`
2812     if test "x$x" = "x$base"; then
2813       continue;
2814     fi
2815
2816     dir=`${DIRNAME} $x 2>/dev/null`
2817                 exclude=`echo ${dir} | ${GREP} /home`
2818     if test "x$exclude" != "x"; then
2819       continue
2820     fi
2821
2822                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
2823     if test "x$already" = "x"; then
2824       DIRS="$DIRS $dir"
2825     fi
2826   done
2827 fi
2828
2829 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
2830
2831
2832   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
2833     LIBS="-L$try -lldap $old_LIBS"
2834     cat >conftest.$ac_ext <<_ACEOF
2835 /* confdefs.h.  */
2836 _ACEOF
2837 cat confdefs.h >>conftest.$ac_ext
2838 cat >>conftest.$ac_ext <<_ACEOF
2839 /* end confdefs.h.  */
2840 extern char ldap_init();
2841 int
2842 main ()
2843 {
2844  ldap_init()
2845   ;
2846   return 0;
2847 }
2848 _ACEOF
2849 rm -f conftest.$ac_objext conftest$ac_exeext
2850 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2851   (eval $ac_link) 2>conftest.er1
2852   ac_status=$?
2853   grep -v '^ *+' conftest.er1 >conftest.err
2854   rm -f conftest.er1
2855   cat conftest.err >&5
2856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2857   (exit $ac_status); } &&
2858          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2860   (eval $ac_try) 2>&5
2861   ac_status=$?
2862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2863   (exit $ac_status); }; } &&
2864          { ac_try='test -s conftest$ac_exeext'
2865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2866   (eval $ac_try) 2>&5
2867   ac_status=$?
2868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2869   (exit $ac_status); }; }; then
2870   smart_lib="-L$try -lldap"
2871 else
2872   echo "$as_me: failed program was:" >&5
2873 sed 's/^/| /' conftest.$ac_ext >&5
2874
2875 fi
2876 rm -f conftest.err conftest.$ac_objext \
2877       conftest$ac_exeext conftest.$ac_ext
2878     if test "x$smart_lib" != "x"; then
2879       break;
2880     fi
2881     LIBS="$old_LIBS"
2882   done
2883 fi
2884
2885 if test "x$smart_lib" != "x"; then
2886   echo "$as_me:$LINENO: result: yes" >&5
2887 echo "${ECHO_T}yes" >&6
2888   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
2889   LIBS="$smart_lib $old_LIBS"
2890   SMART_LIBS="$smart_lib $SMART_LIBS"
2891 else
2892   echo "$as_me:$LINENO: result: no" >&5
2893 echo "${ECHO_T}no" >&6
2894 fi
2895
2896             if test "x$ac_cv_lib_ldap_ldap_init" != "xyes"; then
2897                 fail="$fail libldap"
2898             fi
2899         fi
2900
2901
2902         smart_try_dir=$rlm_ldap_include_dir
2903
2904
2905 ac_safe=`echo "ldap.h" | sed 'y%./+-%__pm%'`
2906 echo "$as_me:$LINENO: checking for ldap.h" >&5
2907 echo $ECHO_N "checking for ldap.h... $ECHO_C" >&6
2908
2909 old_CFLAGS="$CFLAGS"
2910 smart_include=
2911 smart_include_dir=
2912
2913 if test "x$smart_try_dir" != "x"; then
2914   for try in $smart_try_dir; do
2915     CFLAGS="$old_CFLAGS -I$try"
2916     cat >conftest.$ac_ext <<_ACEOF
2917 /* confdefs.h.  */
2918 _ACEOF
2919 cat confdefs.h >>conftest.$ac_ext
2920 cat >>conftest.$ac_ext <<_ACEOF
2921 /* end confdefs.h.  */
2922
2923                     #include <ldap.h>
2924 int
2925 main ()
2926 {
2927  int a = 1;
2928   ;
2929   return 0;
2930 }
2931 _ACEOF
2932 rm -f conftest.$ac_objext
2933 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2934   (eval $ac_compile) 2>conftest.er1
2935   ac_status=$?
2936   grep -v '^ *+' conftest.er1 >conftest.err
2937   rm -f conftest.er1
2938   cat conftest.err >&5
2939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2940   (exit $ac_status); } &&
2941          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2942   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2943   (eval $ac_try) 2>&5
2944   ac_status=$?
2945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2946   (exit $ac_status); }; } &&
2947          { ac_try='test -s conftest.$ac_objext'
2948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2949   (eval $ac_try) 2>&5
2950   ac_status=$?
2951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2952   (exit $ac_status); }; }; then
2953   smart_include="-I$try"
2954 else
2955   echo "$as_me: failed program was:" >&5
2956 sed 's/^/| /' conftest.$ac_ext >&5
2957
2958 smart_include=
2959 fi
2960 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2961     if test "x$smart_include" != "x"; then
2962       break;
2963     fi
2964     CFLAGS="$old_CFLAGS"
2965   done
2966 fi
2967
2968 if test "x$smart_include" = "x"; then
2969   cat >conftest.$ac_ext <<_ACEOF
2970 /* confdefs.h.  */
2971 _ACEOF
2972 cat confdefs.h >>conftest.$ac_ext
2973 cat >>conftest.$ac_ext <<_ACEOF
2974 /* end confdefs.h.  */
2975
2976                   #include <ldap.h>
2977 int
2978 main ()
2979 {
2980  int a = 1;
2981   ;
2982   return 0;
2983 }
2984 _ACEOF
2985 rm -f conftest.$ac_objext
2986 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2987   (eval $ac_compile) 2>conftest.er1
2988   ac_status=$?
2989   grep -v '^ *+' conftest.er1 >conftest.err
2990   rm -f conftest.er1
2991   cat conftest.err >&5
2992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2993   (exit $ac_status); } &&
2994          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
2995   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2996   (eval $ac_try) 2>&5
2997   ac_status=$?
2998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2999   (exit $ac_status); }; } &&
3000          { ac_try='test -s conftest.$ac_objext'
3001   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3002   (eval $ac_try) 2>&5
3003   ac_status=$?
3004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3005   (exit $ac_status); }; }; then
3006   smart_include=" "
3007 else
3008   echo "$as_me: failed program was:" >&5
3009 sed 's/^/| /' conftest.$ac_ext >&5
3010
3011 smart_include=
3012 fi
3013 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3014 fi
3015
3016 if test "x$smart_include" = "x"; then
3017
3018
3019 if test "x$LOCATE" != "x"; then
3020         DIRS=
3021   file=ldap.h
3022
3023   for x in `${LOCATE} $file 2>/dev/null`; do
3024                                         base=`echo $x | sed "s%/${file}%%"`
3025     if test "x$x" = "x$base"; then
3026       continue;
3027     fi
3028
3029     dir=`${DIRNAME} $x 2>/dev/null`
3030                 exclude=`echo ${dir} | ${GREP} /home`
3031     if test "x$exclude" != "x"; then
3032       continue
3033     fi
3034
3035                     already=`echo \$smart_include_dir ${DIRS} | ${GREP} ${dir}`
3036     if test "x$already" = "x"; then
3037       DIRS="$DIRS $dir"
3038     fi
3039   done
3040 fi
3041
3042 eval "smart_include_dir=\"\$smart_include_dir $DIRS\""
3043
3044
3045   for try in $smart_include_dir /usr/local/include /opt/include; do
3046     CFLAGS="$old_CFLAGS -I$try"
3047     cat >conftest.$ac_ext <<_ACEOF
3048 /* confdefs.h.  */
3049 _ACEOF
3050 cat confdefs.h >>conftest.$ac_ext
3051 cat >>conftest.$ac_ext <<_ACEOF
3052 /* end confdefs.h.  */
3053
3054                     #include <ldap.h>
3055 int
3056 main ()
3057 {
3058  int a = 1;
3059   ;
3060   return 0;
3061 }
3062 _ACEOF
3063 rm -f conftest.$ac_objext
3064 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3065   (eval $ac_compile) 2>conftest.er1
3066   ac_status=$?
3067   grep -v '^ *+' conftest.er1 >conftest.err
3068   rm -f conftest.er1
3069   cat conftest.err >&5
3070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3071   (exit $ac_status); } &&
3072          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
3073   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3074   (eval $ac_try) 2>&5
3075   ac_status=$?
3076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3077   (exit $ac_status); }; } &&
3078          { ac_try='test -s conftest.$ac_objext'
3079   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3080   (eval $ac_try) 2>&5
3081   ac_status=$?
3082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3083   (exit $ac_status); }; }; then
3084   smart_include="-I$try"
3085 else
3086   echo "$as_me: failed program was:" >&5
3087 sed 's/^/| /' conftest.$ac_ext >&5
3088
3089 smart_include=
3090 fi
3091 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3092     if test "x$smart_include" != "x"; then
3093       break;
3094     fi
3095     CFLAGS="$old_CFLAGS"
3096   done
3097 fi
3098
3099 if test "x$smart_include" != "x"; then
3100   echo "$as_me:$LINENO: result: yes" >&5
3101 echo "${ECHO_T}yes" >&6
3102   eval "ac_cv_header_$ac_safe=yes"
3103   CFLAGS="$old_CFLAGS $smart_include"
3104   SMART_CFLAGS="$SMART_CFLAGS $smart_include"
3105 else
3106   echo "$as_me:$LINENO: result: no" >&5
3107 echo "${ECHO_T}no" >&6
3108 fi
3109
3110         if test "$ac_cv_header_ldap_h" != "yes"; then
3111           fail="$fail ldap.h"
3112         fi
3113
3114
3115         if test "x$fail" = "x"; then
3116             echo "$as_me:$LINENO: checking for ldap_start_tls_s" >&5
3117 echo $ECHO_N "checking for ldap_start_tls_s... $ECHO_C" >&6
3118 if test "${ac_cv_func_ldap_start_tls_s+set}" = set; then
3119   echo $ECHO_N "(cached) $ECHO_C" >&6
3120 else
3121   cat >conftest.$ac_ext <<_ACEOF
3122 /* confdefs.h.  */
3123 _ACEOF
3124 cat confdefs.h >>conftest.$ac_ext
3125 cat >>conftest.$ac_ext <<_ACEOF
3126 /* end confdefs.h.  */
3127 /* Define ldap_start_tls_s to an innocuous variant, in case <limits.h> declares ldap_start_tls_s.
3128    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3129 #define ldap_start_tls_s innocuous_ldap_start_tls_s
3130
3131 /* System header to define __stub macros and hopefully few prototypes,
3132     which can conflict with char ldap_start_tls_s (); below.
3133     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3134     <limits.h> exists even on freestanding compilers.  */
3135
3136 #ifdef __STDC__
3137 # include <limits.h>
3138 #else
3139 # include <assert.h>
3140 #endif
3141
3142 #undef ldap_start_tls_s
3143
3144 /* Override any gcc2 internal prototype to avoid an error.  */
3145 #ifdef __cplusplus
3146 extern "C"
3147 {
3148 #endif
3149 /* We use char because int might match the return type of a gcc2
3150    builtin and then its argument prototype would still apply.  */
3151 char ldap_start_tls_s ();
3152 /* The GNU C library defines this for functions which it implements
3153     to always fail with ENOSYS.  Some functions are actually named
3154     something starting with __ and the normal name is an alias.  */
3155 #if defined (__stub_ldap_start_tls_s) || defined (__stub___ldap_start_tls_s)
3156 choke me
3157 #else
3158 char (*f) () = ldap_start_tls_s;
3159 #endif
3160 #ifdef __cplusplus
3161 }
3162 #endif
3163
3164 int
3165 main ()
3166 {
3167 return f != ldap_start_tls_s;
3168   ;
3169   return 0;
3170 }
3171 _ACEOF
3172 rm -f conftest.$ac_objext conftest$ac_exeext
3173 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3174   (eval $ac_link) 2>conftest.er1
3175   ac_status=$?
3176   grep -v '^ *+' conftest.er1 >conftest.err
3177   rm -f conftest.er1
3178   cat conftest.err >&5
3179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3180   (exit $ac_status); } &&
3181          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
3182   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3183   (eval $ac_try) 2>&5
3184   ac_status=$?
3185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3186   (exit $ac_status); }; } &&
3187          { ac_try='test -s conftest$ac_exeext'
3188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3189   (eval $ac_try) 2>&5
3190   ac_status=$?
3191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3192   (exit $ac_status); }; }; then
3193   ac_cv_func_ldap_start_tls_s=yes
3194 else
3195   echo "$as_me: failed program was:" >&5
3196 sed 's/^/| /' conftest.$ac_ext >&5
3197
3198 ac_cv_func_ldap_start_tls_s=no
3199 fi
3200 rm -f conftest.err conftest.$ac_objext \
3201       conftest$ac_exeext conftest.$ac_ext
3202 fi
3203 echo "$as_me:$LINENO: result: $ac_cv_func_ldap_start_tls_s" >&5
3204 echo "${ECHO_T}$ac_cv_func_ldap_start_tls_s" >&6
3205 if test $ac_cv_func_ldap_start_tls_s = yes; then
3206    SMART_CFLAGS="$SMART_CFLAGS -DHAVE_LDAP_START_TLS"
3207 fi
3208
3209             echo "$as_me:$LINENO: checking for ldap_initialize" >&5
3210 echo $ECHO_N "checking for ldap_initialize... $ECHO_C" >&6
3211 if test "${ac_cv_func_ldap_initialize+set}" = set; then
3212   echo $ECHO_N "(cached) $ECHO_C" >&6
3213 else
3214   cat >conftest.$ac_ext <<_ACEOF
3215 /* confdefs.h.  */
3216 _ACEOF
3217 cat confdefs.h >>conftest.$ac_ext
3218 cat >>conftest.$ac_ext <<_ACEOF
3219 /* end confdefs.h.  */
3220 /* Define ldap_initialize to an innocuous variant, in case <limits.h> declares ldap_initialize.
3221    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3222 #define ldap_initialize innocuous_ldap_initialize
3223
3224 /* System header to define __stub macros and hopefully few prototypes,
3225     which can conflict with char ldap_initialize (); below.
3226     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3227     <limits.h> exists even on freestanding compilers.  */
3228
3229 #ifdef __STDC__
3230 # include <limits.h>
3231 #else
3232 # include <assert.h>
3233 #endif
3234
3235 #undef ldap_initialize
3236
3237 /* Override any gcc2 internal prototype to avoid an error.  */
3238 #ifdef __cplusplus
3239 extern "C"
3240 {
3241 #endif
3242 /* We use char because int might match the return type of a gcc2
3243    builtin and then its argument prototype would still apply.  */
3244 char ldap_initialize ();
3245 /* The GNU C library defines this for functions which it implements
3246     to always fail with ENOSYS.  Some functions are actually named
3247     something starting with __ and the normal name is an alias.  */
3248 #if defined (__stub_ldap_initialize) || defined (__stub___ldap_initialize)
3249 choke me
3250 #else
3251 char (*f) () = ldap_initialize;
3252 #endif
3253 #ifdef __cplusplus
3254 }
3255 #endif
3256
3257 int
3258 main ()
3259 {
3260 return f != ldap_initialize;
3261   ;
3262   return 0;
3263 }
3264 _ACEOF
3265 rm -f conftest.$ac_objext conftest$ac_exeext
3266 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3267   (eval $ac_link) 2>conftest.er1
3268   ac_status=$?
3269   grep -v '^ *+' conftest.er1 >conftest.err
3270   rm -f conftest.er1
3271   cat conftest.err >&5
3272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3273   (exit $ac_status); } &&
3274          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
3275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3276   (eval $ac_try) 2>&5
3277   ac_status=$?
3278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3279   (exit $ac_status); }; } &&
3280          { ac_try='test -s conftest$ac_exeext'
3281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3282   (eval $ac_try) 2>&5
3283   ac_status=$?
3284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3285   (exit $ac_status); }; }; then
3286   ac_cv_func_ldap_initialize=yes
3287 else
3288   echo "$as_me: failed program was:" >&5
3289 sed 's/^/| /' conftest.$ac_ext >&5
3290
3291 ac_cv_func_ldap_initialize=no
3292 fi
3293 rm -f conftest.err conftest.$ac_objext \
3294       conftest$ac_exeext conftest.$ac_ext
3295 fi
3296 echo "$as_me:$LINENO: result: $ac_cv_func_ldap_initialize" >&5
3297 echo "${ECHO_T}$ac_cv_func_ldap_initialize" >&6
3298 if test $ac_cv_func_ldap_initialize = yes; then
3299    SMART_CFLAGS="$SMART_CFLAGS -DHAVE_LDAP_INITIALIZE"
3300 fi
3301
3302             echo "$as_me:$LINENO: checking for ldap_int_tls_config" >&5
3303 echo $ECHO_N "checking for ldap_int_tls_config... $ECHO_C" >&6
3304 if test "${ac_cv_func_ldap_int_tls_config+set}" = set; then
3305   echo $ECHO_N "(cached) $ECHO_C" >&6
3306 else
3307   cat >conftest.$ac_ext <<_ACEOF
3308 /* confdefs.h.  */
3309 _ACEOF
3310 cat confdefs.h >>conftest.$ac_ext
3311 cat >>conftest.$ac_ext <<_ACEOF
3312 /* end confdefs.h.  */
3313 /* Define ldap_int_tls_config to an innocuous variant, in case <limits.h> declares ldap_int_tls_config.
3314    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3315 #define ldap_int_tls_config innocuous_ldap_int_tls_config
3316
3317 /* System header to define __stub macros and hopefully few prototypes,
3318     which can conflict with char ldap_int_tls_config (); below.
3319     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3320     <limits.h> exists even on freestanding compilers.  */
3321
3322 #ifdef __STDC__
3323 # include <limits.h>
3324 #else
3325 # include <assert.h>
3326 #endif
3327
3328 #undef ldap_int_tls_config
3329
3330 /* Override any gcc2 internal prototype to avoid an error.  */
3331 #ifdef __cplusplus
3332 extern "C"
3333 {
3334 #endif
3335 /* We use char because int might match the return type of a gcc2
3336    builtin and then its argument prototype would still apply.  */
3337 char ldap_int_tls_config ();
3338 /* The GNU C library defines this for functions which it implements
3339     to always fail with ENOSYS.  Some functions are actually named
3340     something starting with __ and the normal name is an alias.  */
3341 #if defined (__stub_ldap_int_tls_config) || defined (__stub___ldap_int_tls_config)
3342 choke me
3343 #else
3344 char (*f) () = ldap_int_tls_config;
3345 #endif
3346 #ifdef __cplusplus
3347 }
3348 #endif
3349
3350 int
3351 main ()
3352 {
3353 return f != ldap_int_tls_config;
3354   ;
3355   return 0;
3356 }
3357 _ACEOF
3358 rm -f conftest.$ac_objext conftest$ac_exeext
3359 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3360   (eval $ac_link) 2>conftest.er1
3361   ac_status=$?
3362   grep -v '^ *+' conftest.er1 >conftest.err
3363   rm -f conftest.er1
3364   cat conftest.err >&5
3365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3366   (exit $ac_status); } &&
3367          { ac_try='test -z "$ac_c_werror_flag"                   || test ! -s conftest.err'
3368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3369   (eval $ac_try) 2>&5
3370   ac_status=$?
3371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3372   (exit $ac_status); }; } &&
3373          { ac_try='test -s conftest$ac_exeext'
3374   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3375   (eval $ac_try) 2>&5
3376   ac_status=$?
3377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3378   (exit $ac_status); }; }; then
3379   ac_cv_func_ldap_int_tls_config=yes
3380 else
3381   echo "$as_me: failed program was:" >&5
3382 sed 's/^/| /' conftest.$ac_ext >&5
3383
3384 ac_cv_func_ldap_int_tls_config=no
3385 fi
3386 rm -f conftest.err conftest.$ac_objext \
3387       conftest$ac_exeext conftest.$ac_ext
3388 fi
3389 echo "$as_me:$LINENO: result: $ac_cv_func_ldap_int_tls_config" >&5
3390 echo "${ECHO_T}$ac_cv_func_ldap_int_tls_config" >&6
3391 if test $ac_cv_func_ldap_int_tls_config = yes; then
3392    SMART_CFLAGS="$SMART_CFLAGS -DHAVE_LDAP_INT_TLS_CONFIG"
3393 fi
3394
3395         fi
3396
3397         targetname=rlm_ldap
3398 else
3399         targetname=
3400         echo \*\*\* module rlm_ldap is disabled.
3401 fi
3402
3403 if test x"$fail" != x""; then
3404         if test x"${enable_strict_dependencies}" = x"yes"; then
3405                 { { echo "$as_me:$LINENO: error: set --without-rlm_ldap to disable it explicitly." >&5
3406 echo "$as_me: error: set --without-rlm_ldap to disable it explicitly." >&2;}
3407    { (exit 1); exit 1; }; }
3408         else
3409                 { echo "$as_me:$LINENO: WARNING: silently not building rlm_ldap." >&5
3410 echo "$as_me: WARNING: silently not building rlm_ldap." >&2;}
3411                 { echo "$as_me:$LINENO: WARNING: FAILURE: rlm_ldap requires: $fail." >&5
3412 echo "$as_me: WARNING: FAILURE: rlm_ldap requires: $fail." >&2;}
3413                 if test x"$headersuggestion" != x; then
3414                         { echo "$as_me:$LINENO: WARNING: $headersuggestion" >&5
3415 echo "$as_me: WARNING: $headersuggestion" >&2;}
3416                 fi
3417                 if test x"$libsuggestion" != x; then
3418                         { echo "$as_me:$LINENO: WARNING: $libsuggestion" >&5
3419 echo "$as_me: WARNING: $libsuggestion" >&2;}
3420                 fi
3421                 targetname=""
3422         fi
3423 fi
3424
3425 WITH_EDIRECTORY=no
3426
3427 # Check whether --with-edir or --without-edir was given.
3428 if test "${with_edir+set}" = set; then
3429   withval="$with_edir"
3430    case "$withval" in
3431     yes)
3432         SMART_CFLAGS="$SMART_CFLAGS -DNOVELL_UNIVERSAL_PASSWORD"
3433         edir="edir_ldapext.c"
3434         ;;
3435     *)
3436         ;;
3437   esac
3438
3439 fi;
3440
3441 ldap_ldflags=$SMART_LIBS
3442 ldap_cflags=$SMART_CFLAGS
3443
3444
3445
3446
3447           ac_config_files="$ac_config_files Makefile"
3448 cat >confcache <<\_ACEOF
3449 # This file is a shell script that caches the results of configure
3450 # tests run on this system so they can be shared between configure
3451 # scripts and configure runs, see configure's option --config-cache.
3452 # It is not useful on other systems.  If it contains results you don't
3453 # want to keep, you may remove or edit it.
3454 #
3455 # config.status only pays attention to the cache file if you give it
3456 # the --recheck option to rerun configure.
3457 #
3458 # `ac_cv_env_foo' variables (set or unset) will be overridden when
3459 # loading this file, other *unset* `ac_cv_foo' will be assigned the
3460 # following values.
3461
3462 _ACEOF
3463
3464 # The following way of writing the cache mishandles newlines in values,
3465 # but we know of no workaround that is simple, portable, and efficient.
3466 # So, don't put newlines in cache variables' values.
3467 # Ultrix sh set writes to stderr and can't be redirected directly,
3468 # and sets the high bit in the cache file unless we assign to the vars.
3469 {
3470   (set) 2>&1 |
3471     case `(ac_space=' '; set | grep ac_space) 2>&1` in
3472     *ac_space=\ *)
3473       # `set' does not quote correctly, so add quotes (double-quote
3474       # substitution turns \\\\ into \\, and sed turns \\ into \).
3475       sed -n \
3476         "s/'/'\\\\''/g;
3477           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
3478       ;;
3479     *)
3480       # `set' quotes correctly as required by POSIX, so do not add quotes.
3481       sed -n \
3482         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
3483       ;;
3484     esac;
3485 } |
3486   sed '
3487      t clear
3488      : clear
3489      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
3490      t end
3491      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
3492      : end' >>confcache
3493 if diff $cache_file confcache >/dev/null 2>&1; then :; else
3494   if test -w $cache_file; then
3495     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
3496     cat confcache >$cache_file
3497   else
3498     echo "not updating unwritable cache $cache_file"
3499   fi
3500 fi
3501 rm -f confcache
3502
3503 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3504 # Let make expand exec_prefix.
3505 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3506
3507 # VPATH may cause trouble with some makes, so we remove $(srcdir),
3508 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
3509 # trailing colons and then remove the whole line if VPATH becomes empty
3510 # (actually we leave an empty line to preserve line numbers).
3511 if test "x$srcdir" = x.; then
3512   ac_vpsub='/^[  ]*VPATH[        ]*=/{
3513 s/:*\$(srcdir):*/:/;
3514 s/:*\${srcdir}:*/:/;
3515 s/:*@srcdir@:*/:/;
3516 s/^\([^=]*=[     ]*\):*/\1/;
3517 s/:*$//;
3518 s/^[^=]*=[       ]*$//;
3519 }'
3520 fi
3521
3522 # Transform confdefs.h into DEFS.
3523 # Protect against shell expansion while executing Makefile rules.
3524 # Protect against Makefile macro expansion.
3525 #
3526 # If the first sed substitution is executed (which looks for macros that
3527 # take arguments), then we branch to the quote section.  Otherwise,
3528 # look for a macro that doesn't take arguments.
3529 cat >confdef2opt.sed <<\_ACEOF
3530 t clear
3531 : clear
3532 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*([^)]*)\)[   ]*\(.*\),-D\1=\2,g
3533 t quote
3534 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\),-D\1=\2,g
3535 t quote
3536 d
3537 : quote
3538 s,[      `~#$^&*(){}\\|;'"<>?],\\&,g
3539 s,\[,\\&,g
3540 s,\],\\&,g
3541 s,\$,$$,g
3542 p
3543 _ACEOF
3544 # We use echo to avoid assuming a particular line-breaking character.
3545 # The extra dot is to prevent the shell from consuming trailing
3546 # line-breaks from the sub-command output.  A line-break within
3547 # single-quotes doesn't work because, if this script is created in a
3548 # platform that uses two characters for line-breaks (e.g., DOS), tr
3549 # would break.
3550 ac_LF_and_DOT=`echo; echo .`
3551 DEFS=`sed -n -f confdef2opt.sed confdefs.h | tr "$ac_LF_and_DOT" ' .'`
3552 rm -f confdef2opt.sed
3553
3554
3555 ac_libobjs=
3556 ac_ltlibobjs=
3557 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
3558   # 1. Remove the extension, and $U if already installed.
3559   ac_i=`echo "$ac_i" |
3560          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
3561   # 2. Add them.
3562   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
3563   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
3564 done
3565 LIBOBJS=$ac_libobjs
3566
3567 LTLIBOBJS=$ac_ltlibobjs
3568
3569
3570
3571 : ${CONFIG_STATUS=./config.status}
3572 ac_clean_files_save=$ac_clean_files
3573 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
3574 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
3575 echo "$as_me: creating $CONFIG_STATUS" >&6;}
3576 cat >$CONFIG_STATUS <<_ACEOF
3577 #! $SHELL
3578 # Generated by $as_me.
3579 # Run this file to recreate the current configuration.
3580 # Compiler output produced by configure, useful for debugging
3581 # configure, is in config.log if it exists.
3582
3583 debug=false
3584 ac_cs_recheck=false
3585 ac_cs_silent=false
3586 SHELL=\${CONFIG_SHELL-$SHELL}
3587 _ACEOF
3588
3589 cat >>$CONFIG_STATUS <<\_ACEOF
3590 ## --------------------- ##
3591 ## M4sh Initialization.  ##
3592 ## --------------------- ##
3593
3594 # Be Bourne compatible
3595 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
3596   emulate sh
3597   NULLCMD=:
3598   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
3599   # is contrary to our usage.  Disable this feature.
3600   alias -g '${1+"$@"}'='"$@"'
3601 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
3602   set -o posix
3603 fi
3604 DUALCASE=1; export DUALCASE # for MKS sh
3605
3606 # Support unset when possible.
3607 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
3608   as_unset=unset
3609 else
3610   as_unset=false
3611 fi
3612
3613
3614 # Work around bugs in pre-3.0 UWIN ksh.
3615 $as_unset ENV MAIL MAILPATH
3616 PS1='$ '
3617 PS2='> '
3618 PS4='+ '
3619
3620 # NLS nuisances.
3621 for as_var in \
3622   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
3623   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
3624   LC_TELEPHONE LC_TIME
3625 do
3626   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
3627     eval $as_var=C; export $as_var
3628   else
3629     $as_unset $as_var
3630   fi
3631 done
3632
3633 # Required to use basename.
3634 if expr a : '\(a\)' >/dev/null 2>&1; then
3635   as_expr=expr
3636 else
3637   as_expr=false
3638 fi
3639
3640 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
3641   as_basename=basename
3642 else
3643   as_basename=false
3644 fi
3645
3646
3647 # Name of the executable.
3648 as_me=`$as_basename "$0" ||
3649 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
3650          X"$0" : 'X\(//\)$' \| \
3651          X"$0" : 'X\(/\)$' \| \
3652          .     : '\(.\)' 2>/dev/null ||
3653 echo X/"$0" |
3654     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
3655           /^X\/\(\/\/\)$/{ s//\1/; q; }
3656           /^X\/\(\/\).*/{ s//\1/; q; }
3657           s/.*/./; q'`
3658
3659
3660 # PATH needs CR, and LINENO needs CR and PATH.
3661 # Avoid depending upon Character Ranges.
3662 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
3663 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
3664 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
3665 as_cr_digits='0123456789'
3666 as_cr_alnum=$as_cr_Letters$as_cr_digits
3667
3668 # The user is always right.
3669 if test "${PATH_SEPARATOR+set}" != set; then
3670   echo "#! /bin/sh" >conf$$.sh
3671   echo  "exit 0"   >>conf$$.sh
3672   chmod +x conf$$.sh
3673   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
3674     PATH_SEPARATOR=';'
3675   else
3676     PATH_SEPARATOR=:
3677   fi
3678   rm -f conf$$.sh
3679 fi
3680
3681
3682   as_lineno_1=$LINENO
3683   as_lineno_2=$LINENO
3684   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
3685   test "x$as_lineno_1" != "x$as_lineno_2" &&
3686   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
3687   # Find who we are.  Look in the path if we contain no path at all
3688   # relative or not.
3689   case $0 in
3690     *[\\/]* ) as_myself=$0 ;;
3691     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3692 for as_dir in $PATH
3693 do
3694   IFS=$as_save_IFS
3695   test -z "$as_dir" && as_dir=.
3696   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
3697 done
3698
3699        ;;
3700   esac
3701   # We did not find ourselves, most probably we were run as `sh COMMAND'
3702   # in which case we are not to be found in the path.
3703   if test "x$as_myself" = x; then
3704     as_myself=$0
3705   fi
3706   if test ! -f "$as_myself"; then
3707     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
3708 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
3709    { (exit 1); exit 1; }; }
3710   fi
3711   case $CONFIG_SHELL in
3712   '')
3713     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3714 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
3715 do
3716   IFS=$as_save_IFS
3717   test -z "$as_dir" && as_dir=.
3718   for as_base in sh bash ksh sh5; do
3719          case $as_dir in
3720          /*)
3721            if ("$as_dir/$as_base" -c '
3722   as_lineno_1=$LINENO
3723   as_lineno_2=$LINENO
3724   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
3725   test "x$as_lineno_1" != "x$as_lineno_2" &&
3726   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
3727              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
3728              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
3729              CONFIG_SHELL=$as_dir/$as_base
3730              export CONFIG_SHELL
3731              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
3732            fi;;
3733          esac
3734        done
3735 done
3736 ;;
3737   esac
3738
3739   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
3740   # uniformly replaced by the line number.  The first 'sed' inserts a
3741   # line-number line before each line; the second 'sed' does the real
3742   # work.  The second script uses 'N' to pair each line-number line
3743   # with the numbered line, and appends trailing '-' during
3744   # substitution so that $LINENO is not a special case at line end.
3745   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
3746   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
3747   sed '=' <$as_myself |
3748     sed '
3749       N
3750       s,$,-,
3751       : loop
3752       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
3753       t loop
3754       s,-$,,
3755       s,^['$as_cr_digits']*\n,,
3756     ' >$as_me.lineno &&
3757   chmod +x $as_me.lineno ||
3758     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
3759 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
3760    { (exit 1); exit 1; }; }
3761
3762   # Don't try to exec as it changes $[0], causing all sort of problems
3763   # (the dirname of $[0] is not the place where we might find the
3764   # original and so on.  Autoconf is especially sensible to this).
3765   . ./$as_me.lineno
3766   # Exit status is that of the last command.
3767   exit
3768 }
3769
3770
3771 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
3772   *c*,-n*) ECHO_N= ECHO_C='
3773 ' ECHO_T='      ' ;;
3774   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
3775   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
3776 esac
3777
3778 if expr a : '\(a\)' >/dev/null 2>&1; then
3779   as_expr=expr
3780 else
3781   as_expr=false
3782 fi
3783
3784 rm -f conf$$ conf$$.exe conf$$.file
3785 echo >conf$$.file
3786 if ln -s conf$$.file conf$$ 2>/dev/null; then
3787   # We could just check for DJGPP; but this test a) works b) is more generic
3788   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
3789   if test -f conf$$.exe; then
3790     # Don't use ln at all; we don't have any links
3791     as_ln_s='cp -p'
3792   else
3793     as_ln_s='ln -s'
3794   fi
3795 elif ln conf$$.file conf$$ 2>/dev/null; then
3796   as_ln_s=ln
3797 else
3798   as_ln_s='cp -p'
3799 fi
3800 rm -f conf$$ conf$$.exe conf$$.file
3801
3802 if mkdir -p . 2>/dev/null; then
3803   as_mkdir_p=:
3804 else
3805   test -d ./-p && rmdir ./-p
3806   as_mkdir_p=false
3807 fi
3808
3809 as_executable_p="test -f"
3810
3811 # Sed expression to map a string onto a valid CPP name.
3812 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
3813
3814 # Sed expression to map a string onto a valid variable name.
3815 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
3816
3817
3818 # IFS
3819 # We need space, tab and new line, in precisely that order.
3820 as_nl='
3821 '
3822 IFS="   $as_nl"
3823
3824 # CDPATH.
3825 $as_unset CDPATH
3826
3827 exec 6>&1
3828
3829 # Open the log real soon, to keep \$[0] and so on meaningful, and to
3830 # report actual input values of CONFIG_FILES etc. instead of their
3831 # values after options handling.  Logging --version etc. is OK.
3832 exec 5>>config.log
3833 {
3834   echo
3835   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
3836 ## Running $as_me. ##
3837 _ASBOX
3838 } >&5
3839 cat >&5 <<_CSEOF
3840
3841 This file was extended by $as_me, which was
3842 generated by GNU Autoconf 2.59.  Invocation command line was
3843
3844   CONFIG_FILES    = $CONFIG_FILES
3845   CONFIG_HEADERS  = $CONFIG_HEADERS
3846   CONFIG_LINKS    = $CONFIG_LINKS
3847   CONFIG_COMMANDS = $CONFIG_COMMANDS
3848   $ $0 $@
3849
3850 _CSEOF
3851 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
3852 echo >&5
3853 _ACEOF
3854
3855 # Files that config.status was made for.
3856 if test -n "$ac_config_files"; then
3857   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
3858 fi
3859
3860 if test -n "$ac_config_headers"; then
3861   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
3862 fi
3863
3864 if test -n "$ac_config_links"; then
3865   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
3866 fi
3867
3868 if test -n "$ac_config_commands"; then
3869   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
3870 fi
3871
3872 cat >>$CONFIG_STATUS <<\_ACEOF
3873
3874 ac_cs_usage="\
3875 \`$as_me' instantiates files from templates according to the
3876 current configuration.
3877
3878 Usage: $0 [OPTIONS] [FILE]...
3879
3880   -h, --help       print this help, then exit
3881   -V, --version    print version number, then exit
3882   -q, --quiet      do not print progress messages
3883   -d, --debug      don't remove temporary files
3884       --recheck    update $as_me by reconfiguring in the same conditions
3885   --file=FILE[:TEMPLATE]
3886                    instantiate the configuration file FILE
3887
3888 Configuration files:
3889 $config_files
3890
3891 Report bugs to <bug-autoconf@gnu.org>."
3892 _ACEOF
3893
3894 cat >>$CONFIG_STATUS <<_ACEOF
3895 ac_cs_version="\\
3896 config.status
3897 configured by $0, generated by GNU Autoconf 2.59,
3898   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
3899
3900 Copyright (C) 2003 Free Software Foundation, Inc.
3901 This config.status script is free software; the Free Software Foundation
3902 gives unlimited permission to copy, distribute and modify it."
3903 srcdir=$srcdir
3904 _ACEOF
3905
3906 cat >>$CONFIG_STATUS <<\_ACEOF
3907 # If no file are specified by the user, then we need to provide default
3908 # value.  By we need to know if files were specified by the user.
3909 ac_need_defaults=:
3910 while test $# != 0
3911 do
3912   case $1 in
3913   --*=*)
3914     ac_option=`expr "x$1" : 'x\([^=]*\)='`
3915     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
3916     ac_shift=:
3917     ;;
3918   -*)
3919     ac_option=$1
3920     ac_optarg=$2
3921     ac_shift=shift
3922     ;;
3923   *) # This is not an option, so the user has probably given explicit
3924      # arguments.
3925      ac_option=$1
3926      ac_need_defaults=false;;
3927   esac
3928
3929   case $ac_option in
3930   # Handling of the options.
3931 _ACEOF
3932 cat >>$CONFIG_STATUS <<\_ACEOF
3933   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3934     ac_cs_recheck=: ;;
3935   --version | --vers* | -V )
3936     echo "$ac_cs_version"; exit 0 ;;
3937   --he | --h)
3938     # Conflict between --help and --header
3939     { { echo "$as_me:$LINENO: error: ambiguous option: $1
3940 Try \`$0 --help' for more information." >&5
3941 echo "$as_me: error: ambiguous option: $1
3942 Try \`$0 --help' for more information." >&2;}
3943    { (exit 1); exit 1; }; };;
3944   --help | --hel | -h )
3945     echo "$ac_cs_usage"; exit 0 ;;
3946   --debug | --d* | -d )
3947     debug=: ;;
3948   --file | --fil | --fi | --f )
3949     $ac_shift
3950     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
3951     ac_need_defaults=false;;
3952   --header | --heade | --head | --hea )
3953     $ac_shift
3954     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
3955     ac_need_defaults=false;;
3956   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3957   | -silent | --silent | --silen | --sile | --sil | --si | --s)
3958     ac_cs_silent=: ;;
3959
3960   # This is an error.
3961   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
3962 Try \`$0 --help' for more information." >&5
3963 echo "$as_me: error: unrecognized option: $1
3964 Try \`$0 --help' for more information." >&2;}
3965    { (exit 1); exit 1; }; } ;;
3966
3967   *) ac_config_targets="$ac_config_targets $1" ;;
3968
3969   esac
3970   shift
3971 done
3972
3973 ac_configure_extra_args=
3974
3975 if $ac_cs_silent; then
3976   exec 6>/dev/null
3977   ac_configure_extra_args="$ac_configure_extra_args --silent"
3978 fi
3979
3980 _ACEOF
3981 cat >>$CONFIG_STATUS <<_ACEOF
3982 if \$ac_cs_recheck; then
3983   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
3984   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
3985 fi
3986
3987 _ACEOF
3988
3989
3990
3991
3992
3993 cat >>$CONFIG_STATUS <<\_ACEOF
3994 for ac_config_target in $ac_config_targets
3995 do
3996   case "$ac_config_target" in
3997   # Handling of arguments.
3998   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
3999   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
4000 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
4001    { (exit 1); exit 1; }; };;
4002   esac
4003 done
4004
4005 # If the user did not use the arguments to specify the items to instantiate,
4006 # then the envvar interface is used.  Set only those that are not.
4007 # We use the long form for the default assignment because of an extremely
4008 # bizarre bug on SunOS 4.1.3.
4009 if $ac_need_defaults; then
4010   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
4011 fi
4012
4013 # Have a temporary directory for convenience.  Make it in the build tree
4014 # simply because there is no reason to put it here, and in addition,
4015 # creating and moving files from /tmp can sometimes cause problems.
4016 # Create a temporary directory, and hook for its removal unless debugging.
4017 $debug ||
4018 {
4019   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
4020   trap '{ (exit 1); exit 1; }' 1 2 13 15
4021 }
4022
4023 # Create a (secure) tmp directory for tmp files.
4024
4025 {
4026   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
4027   test -n "$tmp" && test -d "$tmp"
4028 }  ||
4029 {
4030   tmp=./confstat$$-$RANDOM
4031   (umask 077 && mkdir $tmp)
4032 } ||
4033 {
4034    echo "$me: cannot create a temporary directory in ." >&2
4035    { (exit 1); exit 1; }
4036 }
4037
4038 _ACEOF
4039
4040 cat >>$CONFIG_STATUS <<_ACEOF
4041
4042 #
4043 # CONFIG_FILES section.
4044 #
4045
4046 # No need to generate the scripts if there are no CONFIG_FILES.
4047 # This happens for instance when ./config.status config.h
4048 if test -n "\$CONFIG_FILES"; then
4049   # Protect against being on the right side of a sed subst in config.status.
4050   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
4051    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
4052 s,@SHELL@,$SHELL,;t t
4053 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
4054 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
4055 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
4056 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
4057 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
4058 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
4059 s,@exec_prefix@,$exec_prefix,;t t
4060 s,@prefix@,$prefix,;t t
4061 s,@program_transform_name@,$program_transform_name,;t t
4062 s,@bindir@,$bindir,;t t
4063 s,@sbindir@,$sbindir,;t t
4064 s,@libexecdir@,$libexecdir,;t t
4065 s,@datadir@,$datadir,;t t
4066 s,@sysconfdir@,$sysconfdir,;t t
4067 s,@sharedstatedir@,$sharedstatedir,;t t
4068 s,@localstatedir@,$localstatedir,;t t
4069 s,@libdir@,$libdir,;t t
4070 s,@includedir@,$includedir,;t t
4071 s,@oldincludedir@,$oldincludedir,;t t
4072 s,@infodir@,$infodir,;t t
4073 s,@mandir@,$mandir,;t t
4074 s,@build_alias@,$build_alias,;t t
4075 s,@host_alias@,$host_alias,;t t
4076 s,@target_alias@,$target_alias,;t t
4077 s,@DEFS@,$DEFS,;t t
4078 s,@ECHO_C@,$ECHO_C,;t t
4079 s,@ECHO_N@,$ECHO_N,;t t
4080 s,@ECHO_T@,$ECHO_T,;t t
4081 s,@LIBS@,$LIBS,;t t
4082 s,@CC@,$CC,;t t
4083 s,@CFLAGS@,$CFLAGS,;t t
4084 s,@LDFLAGS@,$LDFLAGS,;t t
4085 s,@CPPFLAGS@,$CPPFLAGS,;t t
4086 s,@ac_ct_CC@,$ac_ct_CC,;t t
4087 s,@EXEEXT@,$EXEEXT,;t t
4088 s,@OBJEXT@,$OBJEXT,;t t
4089 s,@edir@,$edir,;t t
4090 s,@ldap_ldflags@,$ldap_ldflags,;t t
4091 s,@ldap_cflags@,$ldap_cflags,;t t
4092 s,@targetname@,$targetname,;t t
4093 s,@LIBOBJS@,$LIBOBJS,;t t
4094 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
4095 CEOF
4096
4097 _ACEOF
4098
4099   cat >>$CONFIG_STATUS <<\_ACEOF
4100   # Split the substitutions into bite-sized pieces for seds with
4101   # small command number limits, like on Digital OSF/1 and HP-UX.
4102   ac_max_sed_lines=48
4103   ac_sed_frag=1 # Number of current file.
4104   ac_beg=1 # First line for current file.
4105   ac_end=$ac_max_sed_lines # Line after last line for current file.
4106   ac_more_lines=:
4107   ac_sed_cmds=
4108   while $ac_more_lines; do
4109     if test $ac_beg -gt 1; then
4110       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
4111     else
4112       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
4113     fi
4114     if test ! -s $tmp/subs.frag; then
4115       ac_more_lines=false
4116     else
4117       # The purpose of the label and of the branching condition is to
4118       # speed up the sed processing (if there are no `@' at all, there
4119       # is no need to browse any of the substitutions).
4120       # These are the two extra sed commands mentioned above.
4121       (echo ':t
4122   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
4123       if test -z "$ac_sed_cmds"; then
4124         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
4125       else
4126         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
4127       fi
4128       ac_sed_frag=`expr $ac_sed_frag + 1`
4129       ac_beg=$ac_end
4130       ac_end=`expr $ac_end + $ac_max_sed_lines`
4131     fi
4132   done
4133   if test -z "$ac_sed_cmds"; then
4134     ac_sed_cmds=cat
4135   fi
4136 fi # test -n "$CONFIG_FILES"
4137
4138 _ACEOF
4139 cat >>$CONFIG_STATUS <<\_ACEOF
4140 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
4141   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4142   case $ac_file in
4143   - | *:- | *:-:* ) # input from stdin
4144         cat >$tmp/stdin
4145         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
4146         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
4147   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
4148         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
4149   * )   ac_file_in=$ac_file.in ;;
4150   esac
4151
4152   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
4153   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
4154 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4155          X"$ac_file" : 'X\(//\)[^/]' \| \
4156          X"$ac_file" : 'X\(//\)$' \| \
4157          X"$ac_file" : 'X\(/\)' \| \
4158          .     : '\(.\)' 2>/dev/null ||
4159 echo X"$ac_file" |
4160     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
4161           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
4162           /^X\(\/\/\)$/{ s//\1/; q; }
4163           /^X\(\/\).*/{ s//\1/; q; }
4164           s/.*/./; q'`
4165   { if $as_mkdir_p; then
4166     mkdir -p "$ac_dir"
4167   else
4168     as_dir="$ac_dir"
4169     as_dirs=
4170     while test ! -d "$as_dir"; do
4171       as_dirs="$as_dir $as_dirs"
4172       as_dir=`(dirname "$as_dir") 2>/dev/null ||
4173 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4174          X"$as_dir" : 'X\(//\)[^/]' \| \
4175          X"$as_dir" : 'X\(//\)$' \| \
4176          X"$as_dir" : 'X\(/\)' \| \
4177          .     : '\(.\)' 2>/dev/null ||
4178 echo X"$as_dir" |
4179     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
4180           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
4181           /^X\(\/\/\)$/{ s//\1/; q; }
4182           /^X\(\/\).*/{ s//\1/; q; }
4183           s/.*/./; q'`
4184     done
4185     test ! -n "$as_dirs" || mkdir $as_dirs
4186   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
4187 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
4188    { (exit 1); exit 1; }; }; }
4189
4190   ac_builddir=.
4191
4192 if test "$ac_dir" != .; then
4193   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
4194   # A "../" for each directory in $ac_dir_suffix.
4195   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
4196 else
4197   ac_dir_suffix= ac_top_builddir=
4198 fi
4199
4200 case $srcdir in
4201   .)  # No --srcdir option.  We are building in place.
4202     ac_srcdir=.
4203     if test -z "$ac_top_builddir"; then
4204        ac_top_srcdir=.
4205     else
4206        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
4207     fi ;;
4208   [\\/]* | ?:[\\/]* )  # Absolute path.
4209     ac_srcdir=$srcdir$ac_dir_suffix;
4210     ac_top_srcdir=$srcdir ;;
4211   *) # Relative path.
4212     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
4213     ac_top_srcdir=$ac_top_builddir$srcdir ;;
4214 esac
4215
4216 # Do not use `cd foo && pwd` to compute absolute paths, because
4217 # the directories may not exist.
4218 case `pwd` in
4219 .) ac_abs_builddir="$ac_dir";;
4220 *)
4221   case "$ac_dir" in
4222   .) ac_abs_builddir=`pwd`;;
4223   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
4224   *) ac_abs_builddir=`pwd`/"$ac_dir";;
4225   esac;;
4226 esac
4227 case $ac_abs_builddir in
4228 .) ac_abs_top_builddir=${ac_top_builddir}.;;
4229 *)
4230   case ${ac_top_builddir}. in
4231   .) ac_abs_top_builddir=$ac_abs_builddir;;
4232   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
4233   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
4234   esac;;
4235 esac
4236 case $ac_abs_builddir in
4237 .) ac_abs_srcdir=$ac_srcdir;;
4238 *)
4239   case $ac_srcdir in
4240   .) ac_abs_srcdir=$ac_abs_builddir;;
4241   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
4242   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
4243   esac;;
4244 esac
4245 case $ac_abs_builddir in
4246 .) ac_abs_top_srcdir=$ac_top_srcdir;;
4247 *)
4248   case $ac_top_srcdir in
4249   .) ac_abs_top_srcdir=$ac_abs_builddir;;
4250   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
4251   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
4252   esac;;
4253 esac
4254
4255
4256
4257   # Let's still pretend it is `configure' which instantiates (i.e., don't
4258   # use $as_me), people would be surprised to read:
4259   #    /* config.h.  Generated by config.status.  */
4260   if test x"$ac_file" = x-; then
4261     configure_input=
4262   else
4263     configure_input="$ac_file.  "
4264   fi
4265   configure_input=$configure_input"Generated from `echo $ac_file_in |
4266                                      sed 's,.*/,,'` by configure."
4267
4268   # First look for the input files in the build tree, otherwise in the
4269   # src tree.
4270   ac_file_inputs=`IFS=:
4271     for f in $ac_file_in; do
4272       case $f in
4273       -) echo $tmp/stdin ;;
4274       [\\/$]*)
4275          # Absolute (can't be DOS-style, as IFS=:)
4276          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
4277 echo "$as_me: error: cannot find input file: $f" >&2;}
4278    { (exit 1); exit 1; }; }
4279          echo "$f";;
4280       *) # Relative
4281          if test -f "$f"; then
4282            # Build tree
4283            echo "$f"
4284          elif test -f "$srcdir/$f"; then
4285            # Source tree
4286            echo "$srcdir/$f"
4287          else
4288            # /dev/null tree
4289            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
4290 echo "$as_me: error: cannot find input file: $f" >&2;}
4291    { (exit 1); exit 1; }; }
4292          fi;;
4293       esac
4294     done` || { (exit 1); exit 1; }
4295
4296   if test x"$ac_file" != x-; then
4297     { echo "$as_me:$LINENO: creating $ac_file" >&5
4298 echo "$as_me: creating $ac_file" >&6;}
4299     rm -f "$ac_file"
4300   fi
4301 _ACEOF
4302 cat >>$CONFIG_STATUS <<_ACEOF
4303   sed "$ac_vpsub
4304 $extrasub
4305 _ACEOF
4306 cat >>$CONFIG_STATUS <<\_ACEOF
4307 :t
4308 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
4309 s,@configure_input@,$configure_input,;t t
4310 s,@srcdir@,$ac_srcdir,;t t
4311 s,@abs_srcdir@,$ac_abs_srcdir,;t t
4312 s,@top_srcdir@,$ac_top_srcdir,;t t
4313 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
4314 s,@builddir@,$ac_builddir,;t t
4315 s,@abs_builddir@,$ac_abs_builddir,;t t
4316 s,@top_builddir@,$ac_top_builddir,;t t
4317 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
4318 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
4319   rm -f $tmp/stdin
4320   if test x"$ac_file" != x-; then
4321     mv $tmp/out $ac_file
4322   else
4323     cat $tmp/out
4324     rm -f $tmp/out
4325   fi
4326
4327 done
4328 _ACEOF
4329
4330 cat >>$CONFIG_STATUS <<\_ACEOF
4331
4332 { (exit 0); exit 0; }
4333 _ACEOF
4334 chmod +x $CONFIG_STATUS
4335 ac_clean_files=$ac_clean_files_save
4336
4337
4338 # configure is writing to config.log, and then calls config.status.
4339 # config.status does its own redirection, appending to config.log.
4340 # Unfortunately, on DOS this fails, as config.log is still kept open
4341 # by configure, so config.status won't be able to write to it; its
4342 # output is simply discarded.  So we exec the FD to /dev/null,
4343 # effectively closing config.log, so it can be properly (re)opened and
4344 # appended to by config.status.  When coming back to configure, we
4345 # need to make the FD available again.
4346 if test "$no_create" != yes; then
4347   ac_cs_success=:
4348   ac_config_status_args=
4349   test "$silent" = yes &&
4350     ac_config_status_args="$ac_config_status_args --quiet"
4351   exec 5>/dev/null
4352   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
4353   exec 5>>config.log
4354   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
4355   # would make configure fail if this is the last instruction.
4356   $ac_cs_success || { (exit 1); exit 1; }
4357 fi
4358