Link to libcap to determine process capabilities
[freeradius.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for freeradius $Id$.
4 #
5 # Report bugs to <http://bugs.freeradius.org>.
6 #
7 #
8 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9 #
10 #
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20   emulate sh
21   NULLCMD=:
22   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23   # is contrary to our usage.  Disable this feature.
24   alias -g '${1+"$@"}'='"$@"'
25   setopt NO_GLOB_SUBST
26 else
27   case `(set -o) 2>/dev/null` in #(
28   *posix*) :
29     set -o posix ;; #(
30   *) :
31      ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47   as_echo='print -r --'
48   as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50   as_echo='printf %s\n'
51   as_echo_n='printf %s'
52 else
53   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55     as_echo_n='/usr/ucb/echo -n'
56   else
57     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58     as_echo_n_body='eval
59       arg=$1;
60       case $arg in #(
61       *"$as_nl"*)
62         expr "X$arg" : "X\\(.*\\)$as_nl";
63         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64       esac;
65       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66     '
67     export as_echo_n_body
68     as_echo_n='sh -c $as_echo_n_body as_echo'
69   fi
70   export as_echo_body
71   as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76   PATH_SEPARATOR=:
77   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79       PATH_SEPARATOR=';'
80   }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order.  Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" ""        $as_nl"
90
91 # Find who we are.  Look in the path if we contain no directory separator.
92 as_myself=
93 case $0 in #((
94   *[\\/]* ) as_myself=$0 ;;
95   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96 for as_dir in $PATH
97 do
98   IFS=$as_save_IFS
99   test -z "$as_dir" && as_dir=.
100     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101   done
102 IFS=$as_save_IFS
103
104      ;;
105 esac
106 # We did not find ourselves, most probably we were run as `sh COMMAND'
107 # in which case we are not to be found in the path.
108 if test "x$as_myself" = x; then
109   as_myself=$0
110 fi
111 if test ! -f "$as_myself"; then
112   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113   exit 1
114 fi
115
116 # Unset variables that we do not need and which cause bugs (e.g. in
117 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
118 # suppresses any "Segmentation fault" message there.  '((' could
119 # trigger a bug in pdksh 5.2.14.
120 for as_var in BASH_ENV ENV MAIL MAILPATH
121 do eval test x\${$as_var+set} = xset \
122   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123 done
124 PS1='$ '
125 PS2='> '
126 PS4='+ '
127
128 # NLS nuisances.
129 LC_ALL=C
130 export LC_ALL
131 LANGUAGE=C
132 export LANGUAGE
133
134 # CDPATH.
135 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137 # Use a proper internal environment variable to ensure we don't fall
138   # into an infinite loop, continuously re-executing ourselves.
139   if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140     _as_can_reexec=no; export _as_can_reexec;
141     # We cannot yet assume a decent shell, so we have to provide a
142 # neutralization value for shells without unset; and this also
143 # works around shells that cannot unset nonexistent variables.
144 # Preserve -v and -x to the replacement shell.
145 BASH_ENV=/dev/null
146 ENV=/dev/null
147 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148 case $- in # ((((
149   *v*x* | *x*v* ) as_opts=-vx ;;
150   *v* ) as_opts=-v ;;
151   *x* ) as_opts=-x ;;
152   * ) as_opts= ;;
153 esac
154 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155 # Admittedly, this is quite paranoid, since all the known shells bail
156 # out after a failed `exec'.
157 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158 as_fn_exit 255
159   fi
160   # We don't want this to propagate to other subprocesses.
161           { _as_can_reexec=; unset _as_can_reexec;}
162 if test "x$CONFIG_SHELL" = x; then
163   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164   emulate sh
165   NULLCMD=:
166   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167   # is contrary to our usage.  Disable this feature.
168   alias -g '\${1+\"\$@\"}'='\"\$@\"'
169   setopt NO_GLOB_SUBST
170 else
171   case \`(set -o) 2>/dev/null\` in #(
172   *posix*) :
173     set -o posix ;; #(
174   *) :
175      ;;
176 esac
177 fi
178 "
179   as_required="as_fn_return () { (exit \$1); }
180 as_fn_success () { as_fn_return 0; }
181 as_fn_failure () { as_fn_return 1; }
182 as_fn_ret_success () { return 0; }
183 as_fn_ret_failure () { return 1; }
184
185 exitcode=0
186 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192 else
193   exitcode=1; echo positional parameters were not saved.
194 fi
195 test x\$exitcode = x0 || exit 1
196 test -x / || exit 1"
197   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201 test \$(( 1 + 1 )) = 2 || exit 1"
202   if (eval "$as_required") 2>/dev/null; then :
203   as_have_required=yes
204 else
205   as_have_required=no
206 fi
207   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
208
209 else
210   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
211 as_found=false
212 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
213 do
214   IFS=$as_save_IFS
215   test -z "$as_dir" && as_dir=.
216   as_found=:
217   case $as_dir in #(
218          /*)
219            for as_base in sh bash ksh sh5; do
220              # Try only shells that exist, to save several forks.
221              as_shell=$as_dir/$as_base
222              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
223                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
224   CONFIG_SHELL=$as_shell as_have_required=yes
225                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
226   break 2
227 fi
228 fi
229            done;;
230        esac
231   as_found=false
232 done
233 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
234               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
235   CONFIG_SHELL=$SHELL as_have_required=yes
236 fi; }
237 IFS=$as_save_IFS
238
239
240       if test "x$CONFIG_SHELL" != x; then :
241   export CONFIG_SHELL
242              # We cannot yet assume a decent shell, so we have to provide a
243 # neutralization value for shells without unset; and this also
244 # works around shells that cannot unset nonexistent variables.
245 # Preserve -v and -x to the replacement shell.
246 BASH_ENV=/dev/null
247 ENV=/dev/null
248 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
249 case $- in # ((((
250   *v*x* | *x*v* ) as_opts=-vx ;;
251   *v* ) as_opts=-v ;;
252   *x* ) as_opts=-x ;;
253   * ) as_opts= ;;
254 esac
255 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
256 # Admittedly, this is quite paranoid, since all the known shells bail
257 # out after a failed `exec'.
258 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
259 exit 255
260 fi
261
262     if test x$as_have_required = xno; then :
263   $as_echo "$0: This script requires a shell more modern than all"
264   $as_echo "$0: the shells that I found on your system."
265   if test x${ZSH_VERSION+set} = xset ; then
266     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
267     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
268   else
269     $as_echo "$0: Please tell bug-autoconf@gnu.org and
270 $0: http://bugs.freeradius.org about your system, including
271 $0: any error possibly output before this message. Then
272 $0: install a modern shell, or manually run the script
273 $0: under such a shell if you do have one."
274   fi
275   exit 1
276 fi
277 fi
278 fi
279 SHELL=${CONFIG_SHELL-/bin/sh}
280 export SHELL
281 # Unset more variables known to interfere with behavior of common tools.
282 CLICOLOR_FORCE= GREP_OPTIONS=
283 unset CLICOLOR_FORCE GREP_OPTIONS
284
285 ## --------------------- ##
286 ## M4sh Shell Functions. ##
287 ## --------------------- ##
288 # as_fn_unset VAR
289 # ---------------
290 # Portably unset VAR.
291 as_fn_unset ()
292 {
293   { eval $1=; unset $1;}
294 }
295 as_unset=as_fn_unset
296
297 # as_fn_set_status STATUS
298 # -----------------------
299 # Set $? to STATUS, without forking.
300 as_fn_set_status ()
301 {
302   return $1
303 } # as_fn_set_status
304
305 # as_fn_exit STATUS
306 # -----------------
307 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
308 as_fn_exit ()
309 {
310   set +e
311   as_fn_set_status $1
312   exit $1
313 } # as_fn_exit
314
315 # as_fn_mkdir_p
316 # -------------
317 # Create "$as_dir" as a directory, including parents if necessary.
318 as_fn_mkdir_p ()
319 {
320
321   case $as_dir in #(
322   -*) as_dir=./$as_dir;;
323   esac
324   test -d "$as_dir" || eval $as_mkdir_p || {
325     as_dirs=
326     while :; do
327       case $as_dir in #(
328       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
329       *) as_qdir=$as_dir;;
330       esac
331       as_dirs="'$as_qdir' $as_dirs"
332       as_dir=`$as_dirname -- "$as_dir" ||
333 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
334          X"$as_dir" : 'X\(//\)[^/]' \| \
335          X"$as_dir" : 'X\(//\)$' \| \
336          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
337 $as_echo X"$as_dir" |
338     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
339             s//\1/
340             q
341           }
342           /^X\(\/\/\)[^/].*/{
343             s//\1/
344             q
345           }
346           /^X\(\/\/\)$/{
347             s//\1/
348             q
349           }
350           /^X\(\/\).*/{
351             s//\1/
352             q
353           }
354           s/.*/./; q'`
355       test -d "$as_dir" && break
356     done
357     test -z "$as_dirs" || eval "mkdir $as_dirs"
358   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
359
360
361 } # as_fn_mkdir_p
362
363 # as_fn_executable_p FILE
364 # -----------------------
365 # Test if FILE is an executable regular file.
366 as_fn_executable_p ()
367 {
368   test -f "$1" && test -x "$1"
369 } # as_fn_executable_p
370 # as_fn_append VAR VALUE
371 # ----------------------
372 # Append the text in VALUE to the end of the definition contained in VAR. Take
373 # advantage of any shell optimizations that allow amortized linear growth over
374 # repeated appends, instead of the typical quadratic growth present in naive
375 # implementations.
376 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
377   eval 'as_fn_append ()
378   {
379     eval $1+=\$2
380   }'
381 else
382   as_fn_append ()
383   {
384     eval $1=\$$1\$2
385   }
386 fi # as_fn_append
387
388 # as_fn_arith ARG...
389 # ------------------
390 # Perform arithmetic evaluation on the ARGs, and store the result in the
391 # global $as_val. Take advantage of shells that can avoid forks. The arguments
392 # must be portable across $(()) and expr.
393 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
394   eval 'as_fn_arith ()
395   {
396     as_val=$(( $* ))
397   }'
398 else
399   as_fn_arith ()
400   {
401     as_val=`expr "$@" || test $? -eq 1`
402   }
403 fi # as_fn_arith
404
405
406 # as_fn_error STATUS ERROR [LINENO LOG_FD]
407 # ----------------------------------------
408 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
409 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
410 # script with STATUS, using 1 if that was 0.
411 as_fn_error ()
412 {
413   as_status=$1; test $as_status -eq 0 && as_status=1
414   if test "$4"; then
415     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
416     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
417   fi
418   $as_echo "$as_me: error: $2" >&2
419   as_fn_exit $as_status
420 } # as_fn_error
421
422 if expr a : '\(a\)' >/dev/null 2>&1 &&
423    test "X`expr 00001 : '.*\(...\)'`" = X001; then
424   as_expr=expr
425 else
426   as_expr=false
427 fi
428
429 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
430   as_basename=basename
431 else
432   as_basename=false
433 fi
434
435 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
436   as_dirname=dirname
437 else
438   as_dirname=false
439 fi
440
441 as_me=`$as_basename -- "$0" ||
442 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
443          X"$0" : 'X\(//\)$' \| \
444          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
445 $as_echo X/"$0" |
446     sed '/^.*\/\([^/][^/]*\)\/*$/{
447             s//\1/
448             q
449           }
450           /^X\/\(\/\/\)$/{
451             s//\1/
452             q
453           }
454           /^X\/\(\/\).*/{
455             s//\1/
456             q
457           }
458           s/.*/./; q'`
459
460 # Avoid depending upon Character Ranges.
461 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
462 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
463 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
464 as_cr_digits='0123456789'
465 as_cr_alnum=$as_cr_Letters$as_cr_digits
466
467
468   as_lineno_1=$LINENO as_lineno_1a=$LINENO
469   as_lineno_2=$LINENO as_lineno_2a=$LINENO
470   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
471   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
472   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
473   sed -n '
474     p
475     /[$]LINENO/=
476   ' <$as_myself |
477     sed '
478       s/[$]LINENO.*/&-/
479       t lineno
480       b
481       :lineno
482       N
483       :loop
484       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
485       t loop
486       s/-\n.*//
487     ' >$as_me.lineno &&
488   chmod +x "$as_me.lineno" ||
489     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
490
491   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
492   # already done that, so ensure we don't try to do so again and fall
493   # in an infinite loop.  This has already happened in practice.
494   _as_can_reexec=no; export _as_can_reexec
495   # Don't try to exec as it changes $[0], causing all sort of problems
496   # (the dirname of $[0] is not the place where we might find the
497   # original and so on.  Autoconf is especially sensitive to this).
498   . "./$as_me.lineno"
499   # Exit status is that of the last command.
500   exit
501 }
502
503 ECHO_C= ECHO_N= ECHO_T=
504 case `echo -n x` in #(((((
505 -n*)
506   case `echo 'xy\c'` in
507   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
508   xy)  ECHO_C='\c';;
509   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
510        ECHO_T=' ';;
511   esac;;
512 *)
513   ECHO_N='-n';;
514 esac
515
516 rm -f conf$$ conf$$.exe conf$$.file
517 if test -d conf$$.dir; then
518   rm -f conf$$.dir/conf$$.file
519 else
520   rm -f conf$$.dir
521   mkdir conf$$.dir 2>/dev/null
522 fi
523 if (echo >conf$$.file) 2>/dev/null; then
524   if ln -s conf$$.file conf$$ 2>/dev/null; then
525     as_ln_s='ln -s'
526     # ... but there are two gotchas:
527     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
528     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
529     # In both cases, we have to default to `cp -pR'.
530     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
531       as_ln_s='cp -pR'
532   elif ln conf$$.file conf$$ 2>/dev/null; then
533     as_ln_s=ln
534   else
535     as_ln_s='cp -pR'
536   fi
537 else
538   as_ln_s='cp -pR'
539 fi
540 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
541 rmdir conf$$.dir 2>/dev/null
542
543 if mkdir -p . 2>/dev/null; then
544   as_mkdir_p='mkdir -p "$as_dir"'
545 else
546   test -d ./-p && rmdir ./-p
547   as_mkdir_p=false
548 fi
549
550 as_test_x='test -x'
551 as_executable_p=as_fn_executable_p
552
553 # Sed expression to map a string onto a valid CPP name.
554 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
555
556 # Sed expression to map a string onto a valid variable name.
557 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
558
559
560 test -n "$DJDIR" || exec 7<&0 </dev/null
561 exec 6>&1
562
563 # Name of the host.
564 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
565 # so uname gets run too.
566 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
567
568 #
569 # Initializations.
570 #
571 ac_default_prefix=/usr/local
572 ac_clean_files=
573 ac_config_libobj_dir=.
574 LIBOBJS=
575 cross_compiling=no
576 subdirs=
577 MFLAGS=
578 MAKEFLAGS=
579
580 # Identity of this package.
581 PACKAGE_NAME='freeradius'
582 PACKAGE_TARNAME='freeradius'
583 PACKAGE_VERSION='$Id$'
584 PACKAGE_STRING='freeradius $Id$'
585 PACKAGE_BUGREPORT='http://bugs.freeradius.org'
586 PACKAGE_URL='http://www.freeradius.org'
587
588 ac_unique_file="src/main/radiusd.c"
589 # Factoring default headers for most tests.
590 ac_includes_default="\
591 #include <stdio.h>
592 #ifdef HAVE_SYS_TYPES_H
593 # include <sys/types.h>
594 #endif
595 #ifdef HAVE_SYS_STAT_H
596 # include <sys/stat.h>
597 #endif
598 #ifdef STDC_HEADERS
599 # include <stdlib.h>
600 # include <stddef.h>
601 #else
602 # ifdef HAVE_STDLIB_H
603 #  include <stdlib.h>
604 # endif
605 #endif
606 #ifdef HAVE_STRING_H
607 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
608 #  include <memory.h>
609 # endif
610 # include <string.h>
611 #endif
612 #ifdef HAVE_STRINGS_H
613 # include <strings.h>
614 #endif
615 #ifdef HAVE_INTTYPES_H
616 # include <inttypes.h>
617 #endif
618 #ifdef HAVE_STDINT_H
619 # include <stdint.h>
620 #endif
621 #ifdef HAVE_UNISTD_H
622 # include <unistd.h>
623 #endif"
624
625 enable_option_checking=no
626 ac_subst_vars='LTLIBOBJS
627 LIBOBJS
628 STATIC_MODULES
629 USE_STATIC_LIBS
630 USE_SHARED_LIBS
631 INSTALLSTRIP
632 MODULES
633 subdirs
634 HOSTINFO
635 CRYPTLIB
636 LIBPREFIX
637 COLLECTDC_LDFLAGS
638 COLLECTDC_LIBS
639 PCAP_LDFLAGS
640 PCAP_LIBS
641 OPENSSL_CPPFLAGS
642 OPENSSL_LDFLAGS
643 OPENSSL_LIBS
644 LIBREADLINE
645 TALLOC_LDFLAGS
646 TALLOC_LIBS
647 DIRNAME
648 LOCATE
649 AUTOHEADER
650 AUTOCONF
651 ACLOCAL
652 RUSERS
653 SNMPWALK
654 SNMPGET
655 PERL
656 openssl_version_check_config
657 modconfdir
658 dictdir
659 raddbdir
660 radacctdir
661 logdir
662 GIT
663 FR_MAKEFLAGS
664 MAKE
665 GMAKE
666 clang_path
667 RANLIB
668 EGREP
669 GREP
670 CPP
671 ac_ct_CXX
672 CXXFLAGS
673 CXX
674 OBJEXT
675 EXEEXT
676 ac_ct_CC
677 CPPFLAGS
678 LDFLAGS
679 CFLAGS
680 CC
681 target_os
682 target_vendor
683 target_cpu
684 target
685 host_os
686 host_vendor
687 host_cpu
688 host
689 build_os
690 build_vendor
691 build_cpu
692 build
693 RADIUSD_VERSION_STRING
694 target_alias
695 host_alias
696 build_alias
697 LIBS
698 ECHO_T
699 ECHO_N
700 ECHO_C
701 DEFS
702 mandir
703 localedir
704 libdir
705 psdir
706 pdfdir
707 dvidir
708 htmldir
709 infodir
710 docdir
711 oldincludedir
712 includedir
713 localstatedir
714 sharedstatedir
715 sysconfdir
716 datadir
717 datarootdir
718 libexecdir
719 sbindir
720 bindir
721 program_transform_name
722 prefix
723 exec_prefix
724 PACKAGE_URL
725 PACKAGE_BUGREPORT
726 PACKAGE_STRING
727 PACKAGE_VERSION
728 PACKAGE_TARNAME
729 PACKAGE_NAME
730 PATH_SEPARATOR
731 SHELL'
732 ac_subst_files=''
733 ac_user_opts='
734 enable_option_checking
735 enable_developer
736 enable_largefile
737 enable_strict_dependencies
738 enable_werror
739 with_docdir
740 with_logdir
741 with_radacctdir
742 with_raddbdir
743 with_dictdir
744 with_ascend_binary
745 with_threads
746 with_tcp
747 with_vmps
748 with_dhcp
749 with_static_modules
750 with_shared_libs
751 with_modules
752 with_experimental_modules
753 with_udpfromto
754 with_rlm_FOO_lib_dir
755 with_rlm_FOO_include_dir
756 with_openssl
757 with_openssl_lib_dir
758 with_openssl_include_dir
759 enable_openssl_version_check
760 with_talloc_lib_dir
761 with_talloc_include_dir
762 with_pcap_lib_dir
763 with_pcap_include_dir
764 with_collectdclient_lib_dir
765 with_collectdclient_include_dir
766 with_cap_lib_dir
767 with_cap_include_dir
768 with_execinfo_lib_dir
769 with_execinfo_include_dir
770 with_pcre_lib_dir
771 with_pcre_include_dir
772 with_regex
773 '
774       ac_precious_vars='build_alias
775 host_alias
776 target_alias
777 CC
778 CFLAGS
779 LDFLAGS
780 LIBS
781 CPPFLAGS
782 CXX
783 CXXFLAGS
784 CCC
785 CPP'
786 ac_subdirs_all='$mysubdirs'
787
788 # Initialize some variables set by options.
789 ac_init_help=
790 ac_init_version=false
791 ac_unrecognized_opts=
792 ac_unrecognized_sep=
793 # The variables have the same names as the options, with
794 # dashes changed to underlines.
795 cache_file=/dev/null
796 exec_prefix=NONE
797 no_create=
798 no_recursion=
799 prefix=NONE
800 program_prefix=NONE
801 program_suffix=NONE
802 program_transform_name=s,x,x,
803 silent=
804 site=
805 srcdir=
806 verbose=
807 x_includes=NONE
808 x_libraries=NONE
809
810 # Installation directory options.
811 # These are left unexpanded so users can "make install exec_prefix=/foo"
812 # and all the variables that are supposed to be based on exec_prefix
813 # by default will actually change.
814 # Use braces instead of parens because sh, perl, etc. also accept them.
815 # (The list follows the same order as the GNU Coding Standards.)
816 bindir='${exec_prefix}/bin'
817 sbindir='${exec_prefix}/sbin'
818 libexecdir='${exec_prefix}/libexec'
819 datarootdir='${prefix}/share'
820 datadir='${datarootdir}'
821 sysconfdir='${prefix}/etc'
822 sharedstatedir='${prefix}/com'
823 localstatedir='${prefix}/var'
824 includedir='${prefix}/include'
825 oldincludedir='/usr/include'
826 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
827 infodir='${datarootdir}/info'
828 htmldir='${docdir}'
829 dvidir='${docdir}'
830 pdfdir='${docdir}'
831 psdir='${docdir}'
832 libdir='${exec_prefix}/lib'
833 localedir='${datarootdir}/locale'
834 mandir='${datarootdir}/man'
835
836 ac_prev=
837 ac_dashdash=
838 for ac_option
839 do
840   # If the previous option needs an argument, assign it.
841   if test -n "$ac_prev"; then
842     eval $ac_prev=\$ac_option
843     ac_prev=
844     continue
845   fi
846
847   case $ac_option in
848   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
849   *=)   ac_optarg= ;;
850   *)    ac_optarg=yes ;;
851   esac
852
853   # Accept the important Cygnus configure options, so we can diagnose typos.
854
855   case $ac_dashdash$ac_option in
856   --)
857     ac_dashdash=yes ;;
858
859   -bindir | --bindir | --bindi | --bind | --bin | --bi)
860     ac_prev=bindir ;;
861   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
862     bindir=$ac_optarg ;;
863
864   -build | --build | --buil | --bui | --bu)
865     ac_prev=build_alias ;;
866   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
867     build_alias=$ac_optarg ;;
868
869   -cache-file | --cache-file | --cache-fil | --cache-fi \
870   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
871     ac_prev=cache_file ;;
872   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
873   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
874     cache_file=$ac_optarg ;;
875
876   --config-cache | -C)
877     cache_file=config.cache ;;
878
879   -datadir | --datadir | --datadi | --datad)
880     ac_prev=datadir ;;
881   -datadir=* | --datadir=* | --datadi=* | --datad=*)
882     datadir=$ac_optarg ;;
883
884   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
885   | --dataroo | --dataro | --datar)
886     ac_prev=datarootdir ;;
887   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
888   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
889     datarootdir=$ac_optarg ;;
890
891   -disable-* | --disable-*)
892     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
893     # Reject names that are not valid shell variable names.
894     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
895       as_fn_error $? "invalid feature name: $ac_useropt"
896     ac_useropt_orig=$ac_useropt
897     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
898     case $ac_user_opts in
899       *"
900 "enable_$ac_useropt"
901 "*) ;;
902       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
903          ac_unrecognized_sep=', ';;
904     esac
905     eval enable_$ac_useropt=no ;;
906
907   -docdir | --docdir | --docdi | --doc | --do)
908     ac_prev=docdir ;;
909   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
910     docdir=$ac_optarg ;;
911
912   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
913     ac_prev=dvidir ;;
914   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
915     dvidir=$ac_optarg ;;
916
917   -enable-* | --enable-*)
918     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
919     # Reject names that are not valid shell variable names.
920     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
921       as_fn_error $? "invalid feature name: $ac_useropt"
922     ac_useropt_orig=$ac_useropt
923     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
924     case $ac_user_opts in
925       *"
926 "enable_$ac_useropt"
927 "*) ;;
928       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
929          ac_unrecognized_sep=', ';;
930     esac
931     eval enable_$ac_useropt=\$ac_optarg ;;
932
933   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
934   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
935   | --exec | --exe | --ex)
936     ac_prev=exec_prefix ;;
937   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
938   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
939   | --exec=* | --exe=* | --ex=*)
940     exec_prefix=$ac_optarg ;;
941
942   -gas | --gas | --ga | --g)
943     # Obsolete; use --with-gas.
944     with_gas=yes ;;
945
946   -help | --help | --hel | --he | -h)
947     ac_init_help=long ;;
948   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
949     ac_init_help=recursive ;;
950   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
951     ac_init_help=short ;;
952
953   -host | --host | --hos | --ho)
954     ac_prev=host_alias ;;
955   -host=* | --host=* | --hos=* | --ho=*)
956     host_alias=$ac_optarg ;;
957
958   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
959     ac_prev=htmldir ;;
960   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
961   | --ht=*)
962     htmldir=$ac_optarg ;;
963
964   -includedir | --includedir | --includedi | --included | --include \
965   | --includ | --inclu | --incl | --inc)
966     ac_prev=includedir ;;
967   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
968   | --includ=* | --inclu=* | --incl=* | --inc=*)
969     includedir=$ac_optarg ;;
970
971   -infodir | --infodir | --infodi | --infod | --info | --inf)
972     ac_prev=infodir ;;
973   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
974     infodir=$ac_optarg ;;
975
976   -libdir | --libdir | --libdi | --libd)
977     ac_prev=libdir ;;
978   -libdir=* | --libdir=* | --libdi=* | --libd=*)
979     libdir=$ac_optarg ;;
980
981   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
982   | --libexe | --libex | --libe)
983     ac_prev=libexecdir ;;
984   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
985   | --libexe=* | --libex=* | --libe=*)
986     libexecdir=$ac_optarg ;;
987
988   -localedir | --localedir | --localedi | --localed | --locale)
989     ac_prev=localedir ;;
990   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
991     localedir=$ac_optarg ;;
992
993   -localstatedir | --localstatedir | --localstatedi | --localstated \
994   | --localstate | --localstat | --localsta | --localst | --locals)
995     ac_prev=localstatedir ;;
996   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
997   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
998     localstatedir=$ac_optarg ;;
999
1000   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1001     ac_prev=mandir ;;
1002   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1003     mandir=$ac_optarg ;;
1004
1005   -nfp | --nfp | --nf)
1006     # Obsolete; use --without-fp.
1007     with_fp=no ;;
1008
1009   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1010   | --no-cr | --no-c | -n)
1011     no_create=yes ;;
1012
1013   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1014   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1015     no_recursion=yes ;;
1016
1017   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1018   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1019   | --oldin | --oldi | --old | --ol | --o)
1020     ac_prev=oldincludedir ;;
1021   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1022   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1023   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1024     oldincludedir=$ac_optarg ;;
1025
1026   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1027     ac_prev=prefix ;;
1028   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1029     prefix=$ac_optarg ;;
1030
1031   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1032   | --program-pre | --program-pr | --program-p)
1033     ac_prev=program_prefix ;;
1034   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1035   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1036     program_prefix=$ac_optarg ;;
1037
1038   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1039   | --program-suf | --program-su | --program-s)
1040     ac_prev=program_suffix ;;
1041   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1042   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1043     program_suffix=$ac_optarg ;;
1044
1045   -program-transform-name | --program-transform-name \
1046   | --program-transform-nam | --program-transform-na \
1047   | --program-transform-n | --program-transform- \
1048   | --program-transform | --program-transfor \
1049   | --program-transfo | --program-transf \
1050   | --program-trans | --program-tran \
1051   | --progr-tra | --program-tr | --program-t)
1052     ac_prev=program_transform_name ;;
1053   -program-transform-name=* | --program-transform-name=* \
1054   | --program-transform-nam=* | --program-transform-na=* \
1055   | --program-transform-n=* | --program-transform-=* \
1056   | --program-transform=* | --program-transfor=* \
1057   | --program-transfo=* | --program-transf=* \
1058   | --program-trans=* | --program-tran=* \
1059   | --progr-tra=* | --program-tr=* | --program-t=*)
1060     program_transform_name=$ac_optarg ;;
1061
1062   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1063     ac_prev=pdfdir ;;
1064   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1065     pdfdir=$ac_optarg ;;
1066
1067   -psdir | --psdir | --psdi | --psd | --ps)
1068     ac_prev=psdir ;;
1069   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1070     psdir=$ac_optarg ;;
1071
1072   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1073   | -silent | --silent | --silen | --sile | --sil)
1074     silent=yes ;;
1075
1076   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1077     ac_prev=sbindir ;;
1078   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1079   | --sbi=* | --sb=*)
1080     sbindir=$ac_optarg ;;
1081
1082   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1083   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1084   | --sharedst | --shareds | --shared | --share | --shar \
1085   | --sha | --sh)
1086     ac_prev=sharedstatedir ;;
1087   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1088   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1089   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1090   | --sha=* | --sh=*)
1091     sharedstatedir=$ac_optarg ;;
1092
1093   -site | --site | --sit)
1094     ac_prev=site ;;
1095   -site=* | --site=* | --sit=*)
1096     site=$ac_optarg ;;
1097
1098   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1099     ac_prev=srcdir ;;
1100   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1101     srcdir=$ac_optarg ;;
1102
1103   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1104   | --syscon | --sysco | --sysc | --sys | --sy)
1105     ac_prev=sysconfdir ;;
1106   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1107   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1108     sysconfdir=$ac_optarg ;;
1109
1110   -target | --target | --targe | --targ | --tar | --ta | --t)
1111     ac_prev=target_alias ;;
1112   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1113     target_alias=$ac_optarg ;;
1114
1115   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1116     verbose=yes ;;
1117
1118   -version | --version | --versio | --versi | --vers | -V)
1119     ac_init_version=: ;;
1120
1121   -with-* | --with-*)
1122     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1123     # Reject names that are not valid shell variable names.
1124     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1125       as_fn_error $? "invalid package name: $ac_useropt"
1126     ac_useropt_orig=$ac_useropt
1127     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1128     case $ac_user_opts in
1129       *"
1130 "with_$ac_useropt"
1131 "*) ;;
1132       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1133          ac_unrecognized_sep=', ';;
1134     esac
1135     eval with_$ac_useropt=\$ac_optarg ;;
1136
1137   -without-* | --without-*)
1138     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1139     # Reject names that are not valid shell variable names.
1140     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1141       as_fn_error $? "invalid package name: $ac_useropt"
1142     ac_useropt_orig=$ac_useropt
1143     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1144     case $ac_user_opts in
1145       *"
1146 "with_$ac_useropt"
1147 "*) ;;
1148       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1149          ac_unrecognized_sep=', ';;
1150     esac
1151     eval with_$ac_useropt=no ;;
1152
1153   --x)
1154     # Obsolete; use --with-x.
1155     with_x=yes ;;
1156
1157   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1158   | --x-incl | --x-inc | --x-in | --x-i)
1159     ac_prev=x_includes ;;
1160   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1161   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1162     x_includes=$ac_optarg ;;
1163
1164   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1165   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1166     ac_prev=x_libraries ;;
1167   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1168   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1169     x_libraries=$ac_optarg ;;
1170
1171   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1172 Try \`$0 --help' for more information"
1173     ;;
1174
1175   *=*)
1176     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1177     # Reject names that are not valid shell variable names.
1178     case $ac_envvar in #(
1179       '' | [0-9]* | *[!_$as_cr_alnum]* )
1180       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1181     esac
1182     eval $ac_envvar=\$ac_optarg
1183     export $ac_envvar ;;
1184
1185   *)
1186     # FIXME: should be removed in autoconf 3.0.
1187     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1188     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1189       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1190     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1191     ;;
1192
1193   esac
1194 done
1195
1196 if test -n "$ac_prev"; then
1197   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1198   as_fn_error $? "missing argument to $ac_option"
1199 fi
1200
1201 if test -n "$ac_unrecognized_opts"; then
1202   case $enable_option_checking in
1203     no) ;;
1204     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1205     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1206   esac
1207 fi
1208
1209 # Check all directory arguments for consistency.
1210 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1211                 datadir sysconfdir sharedstatedir localstatedir includedir \
1212                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1213                 libdir localedir mandir
1214 do
1215   eval ac_val=\$$ac_var
1216   # Remove trailing slashes.
1217   case $ac_val in
1218     */ )
1219       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1220       eval $ac_var=\$ac_val;;
1221   esac
1222   # Be sure to have absolute directory names.
1223   case $ac_val in
1224     [\\/$]* | ?:[\\/]* )  continue;;
1225     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1226   esac
1227   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1228 done
1229
1230 # There might be people who depend on the old broken behavior: `$host'
1231 # used to hold the argument of --host etc.
1232 # FIXME: To remove some day.
1233 build=$build_alias
1234 host=$host_alias
1235 target=$target_alias
1236
1237 # FIXME: To remove some day.
1238 if test "x$host_alias" != x; then
1239   if test "x$build_alias" = x; then
1240     cross_compiling=maybe
1241   elif test "x$build_alias" != "x$host_alias"; then
1242     cross_compiling=yes
1243   fi
1244 fi
1245
1246 ac_tool_prefix=
1247 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1248
1249 test "$silent" = yes && exec 6>/dev/null
1250
1251
1252 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1253 ac_ls_di=`ls -di .` &&
1254 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1255   as_fn_error $? "working directory cannot be determined"
1256 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1257   as_fn_error $? "pwd does not report name of working directory"
1258
1259
1260 # Find the source files, if location was not specified.
1261 if test -z "$srcdir"; then
1262   ac_srcdir_defaulted=yes
1263   # Try the directory containing this script, then the parent directory.
1264   ac_confdir=`$as_dirname -- "$as_myself" ||
1265 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1266          X"$as_myself" : 'X\(//\)[^/]' \| \
1267          X"$as_myself" : 'X\(//\)$' \| \
1268          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1269 $as_echo X"$as_myself" |
1270     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1271             s//\1/
1272             q
1273           }
1274           /^X\(\/\/\)[^/].*/{
1275             s//\1/
1276             q
1277           }
1278           /^X\(\/\/\)$/{
1279             s//\1/
1280             q
1281           }
1282           /^X\(\/\).*/{
1283             s//\1/
1284             q
1285           }
1286           s/.*/./; q'`
1287   srcdir=$ac_confdir
1288   if test ! -r "$srcdir/$ac_unique_file"; then
1289     srcdir=..
1290   fi
1291 else
1292   ac_srcdir_defaulted=no
1293 fi
1294 if test ! -r "$srcdir/$ac_unique_file"; then
1295   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1296   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1297 fi
1298 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1299 ac_abs_confdir=`(
1300         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1301         pwd)`
1302 # When building in place, set srcdir=.
1303 if test "$ac_abs_confdir" = "$ac_pwd"; then
1304   srcdir=.
1305 fi
1306 # Remove unnecessary trailing slashes from srcdir.
1307 # Double slashes in file names in object file debugging info
1308 # mess up M-x gdb in Emacs.
1309 case $srcdir in
1310 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1311 esac
1312 for ac_var in $ac_precious_vars; do
1313   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1314   eval ac_env_${ac_var}_value=\$${ac_var}
1315   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1316   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1317 done
1318
1319 #
1320 # Report the --help message.
1321 #
1322 if test "$ac_init_help" = "long"; then
1323   # Omit some internal or obsolete options to make the list less imposing.
1324   # This message is too long to be a string in the A/UX 3.1 sh.
1325   cat <<_ACEOF
1326 \`configure' configures freeradius $Id$ to adapt to many kinds of systems.
1327
1328 Usage: $0 [OPTION]... [VAR=VALUE]...
1329
1330 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1331 VAR=VALUE.  See below for descriptions of some of the useful variables.
1332
1333 Defaults for the options are specified in brackets.
1334
1335 Configuration:
1336   -h, --help              display this help and exit
1337       --help=short        display options specific to this package
1338       --help=recursive    display the short help of all the included packages
1339   -V, --version           display version information and exit
1340   -q, --quiet, --silent   do not print \`checking ...' messages
1341       --cache-file=FILE   cache test results in FILE [disabled]
1342   -C, --config-cache      alias for \`--cache-file=config.cache'
1343   -n, --no-create         do not create output files
1344       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1345
1346 Installation directories:
1347   --prefix=PREFIX         install architecture-independent files in PREFIX
1348                           [$ac_default_prefix]
1349   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1350                           [PREFIX]
1351
1352 By default, \`make install' will install all the files in
1353 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1354 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1355 for instance \`--prefix=\$HOME'.
1356
1357 For better control, use the options below.
1358
1359 Fine tuning of the installation directories:
1360   --bindir=DIR            user executables [EPREFIX/bin]
1361   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1362   --libexecdir=DIR        program executables [EPREFIX/libexec]
1363   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1364   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1365   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1366   --libdir=DIR            object code libraries [EPREFIX/lib]
1367   --includedir=DIR        C header files [PREFIX/include]
1368   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1369   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1370   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1371   --infodir=DIR           info documentation [DATAROOTDIR/info]
1372   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1373   --mandir=DIR            man documentation [DATAROOTDIR/man]
1374   --docdir=DIR            documentation root [DATAROOTDIR/doc/freeradius]
1375   --htmldir=DIR           html documentation [DOCDIR]
1376   --dvidir=DIR            dvi documentation [DOCDIR]
1377   --pdfdir=DIR            pdf documentation [DOCDIR]
1378   --psdir=DIR             ps documentation [DOCDIR]
1379 _ACEOF
1380
1381   cat <<\_ACEOF
1382
1383 System types:
1384   --build=BUILD     configure for building on BUILD [guessed]
1385   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1386   --target=TARGET   configure for building compilers for TARGET [HOST]
1387 _ACEOF
1388 fi
1389
1390 if test -n "$ac_init_help"; then
1391   case $ac_init_help in
1392      short | recursive ) echo "Configuration of freeradius $Id$:";;
1393    esac
1394   cat <<\_ACEOF
1395
1396 Optional Features:
1397   --disable-option-checking  ignore unrecognized --enable/--with options
1398   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1399   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1400   --enable-developer      enables features of interest to developers.
1401   --disable-largefile     omit support for large files
1402   --enable-strict-dependencies  fail configure on lack of module dependancy.
1403   --enable-werror         causes the build to fail if any warnings are generated.
1404   --disable-openssl-version-check
1405                           disable vulnerable OpenSSL version check
1406
1407
1408 Optional Packages:
1409   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1410   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1411   --with-docdir=DIR       directory for documentation DATADIR/doc/freeradius
1412   --with-logdir=DIR       directory for logfiles LOCALSTATEDIR/log/radius
1413   --with-radacctdir=DIR   directory for detail files LOGDIR/radacct
1414   --with-raddbdir=DIR     directory for config files SYSCONFDIR/raddb
1415   --with-dictdir=DIR      directory for dictionary files DATAROOTDIR/freeradius
1416   --with-ascend-binary    include support for Ascend binary filter attributes (default=yes)
1417   --with-threads          use threads, if available.  (default=yes)
1418   --with-tcp              compile in TCP support. (default=yes)
1419   --with-vmps             compile in VMPS support. (default=yes)
1420   --with-dhcp             compile in DHCP support. (default=yes)
1421   --with-static-modules=QUOTED-MODULE-LIST
1422   --with-shared-libs      build dynamic libraries and link against them.
1423                           (default=yes)
1424   --with-modules=QUOTED-MODULE-LIST
1425   --with-experimental-modules
1426                           use experimental and unstable modules. (default=no,
1427                           unless --enable-developer=yes)
1428   --with-udpfromto        compile in UDPFROMTO support. (default=yes)
1429   --with-rlm-FOO-lib-dir=DIR
1430                           directory in which to look for library files used by
1431                           module FOO
1432   --with-rlm-FOO-include-dir=DIR
1433                           directory in which to look for include files used by
1434                           module FOO
1435   --with-openssl          use OpenSSL. (default=yes)
1436   --with-openssl-lib-dir=DIR
1437                           directory to look for OpenSSL library files
1438   --with-openssl-include-dir=DIR
1439                           directory to look for OpenSSL include files
1440   --with-talloc-lib-dir=DIR
1441                           directory in which to look for talloc library files
1442   --with-talloc-include-dir=DIR
1443                           directory in which to look for talloc include files
1444   --with-pcap-lib-dir=DIR directory in which to look for pcap library files
1445   --with-pcap-include-dir=DIR
1446                           directory in which to look for pcap include files
1447   --with-collectdclient-lib-dir=DIR
1448                           directory in which to look for collectdclient
1449                           library files
1450   --with-collectdclient-include-dir=DIR
1451                           directory in which to look for collectdclient
1452                           include files
1453   --with-cap-lib-dir=DIR  directory in which to look for cap library files
1454   --with-cap-include-dir=DIR
1455                           directory in which to look for cap include files
1456   --with-execinfo-lib-dir=DIR
1457                           directory in which to look for execinfo library
1458                           files
1459   --with-execinfo-include-dir=DIR
1460                           directory in which to look for execinfo include
1461                           files
1462   --with-pcre-lib-dir=DIR directory in which to look for pcre library files
1463   --with-pcre-include-dir=DIR
1464                           directory in which to look for pcre include files
1465   --with-regex            Whether to build with regular expressions
1466                           (default=yes)
1467
1468 Some influential environment variables:
1469   CC          C compiler command
1470   CFLAGS      C compiler flags
1471   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1472               nonstandard directory <lib dir>
1473   LIBS        libraries to pass to the linker, e.g. -l<library>
1474   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1475               you have headers in a nonstandard directory <include dir>
1476   CXX         C++ compiler command
1477   CXXFLAGS    C++ compiler flags
1478   CPP         C preprocessor
1479
1480 Use these variables to override the choices made by `configure' or to help
1481 it to find libraries and programs with nonstandard names/locations.
1482
1483 Report bugs to <http://bugs.freeradius.org>.
1484 freeradius home page: <http://www.freeradius.org>.
1485 _ACEOF
1486 ac_status=$?
1487 fi
1488
1489 if test "$ac_init_help" = "recursive"; then
1490   # If there are subdirs, report their specific --help.
1491   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1492     test -d "$ac_dir" ||
1493       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1494       continue
1495     ac_builddir=.
1496
1497 case "$ac_dir" in
1498 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1499 *)
1500   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1501   # A ".." for each directory in $ac_dir_suffix.
1502   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1503   case $ac_top_builddir_sub in
1504   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1505   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1506   esac ;;
1507 esac
1508 ac_abs_top_builddir=$ac_pwd
1509 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1510 # for backward compatibility:
1511 ac_top_builddir=$ac_top_build_prefix
1512
1513 case $srcdir in
1514   .)  # We are building in place.
1515     ac_srcdir=.
1516     ac_top_srcdir=$ac_top_builddir_sub
1517     ac_abs_top_srcdir=$ac_pwd ;;
1518   [\\/]* | ?:[\\/]* )  # Absolute name.
1519     ac_srcdir=$srcdir$ac_dir_suffix;
1520     ac_top_srcdir=$srcdir
1521     ac_abs_top_srcdir=$srcdir ;;
1522   *) # Relative name.
1523     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1524     ac_top_srcdir=$ac_top_build_prefix$srcdir
1525     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1526 esac
1527 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1528
1529     cd "$ac_dir" || { ac_status=$?; continue; }
1530     # Check for guested configure.
1531     if test -f "$ac_srcdir/configure.gnu"; then
1532       echo &&
1533       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1534     elif test -f "$ac_srcdir/configure"; then
1535       echo &&
1536       $SHELL "$ac_srcdir/configure" --help=recursive
1537     else
1538       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1539     fi || ac_status=$?
1540     cd "$ac_pwd" || { ac_status=$?; break; }
1541   done
1542 fi
1543
1544 test -n "$ac_init_help" && exit $ac_status
1545 if $ac_init_version; then
1546   cat <<\_ACEOF
1547 freeradius configure $Id$
1548 generated by GNU Autoconf 2.69
1549
1550 Copyright (C) 2012 Free Software Foundation, Inc.
1551 This configure script is free software; the Free Software Foundation
1552 gives unlimited permission to copy, distribute and modify it.
1553 _ACEOF
1554   exit
1555 fi
1556
1557 ## ------------------------ ##
1558 ## Autoconf initialization. ##
1559 ## ------------------------ ##
1560
1561 # ac_fn_c_try_compile LINENO
1562 # --------------------------
1563 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1564 ac_fn_c_try_compile ()
1565 {
1566   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1567   rm -f conftest.$ac_objext
1568   if { { ac_try="$ac_compile"
1569 case "(($ac_try" in
1570   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1571   *) ac_try_echo=$ac_try;;
1572 esac
1573 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1574 $as_echo "$ac_try_echo"; } >&5
1575   (eval "$ac_compile") 2>conftest.err
1576   ac_status=$?
1577   if test -s conftest.err; then
1578     grep -v '^ *+' conftest.err >conftest.er1
1579     cat conftest.er1 >&5
1580     mv -f conftest.er1 conftest.err
1581   fi
1582   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1583   test $ac_status = 0; } && {
1584          test -z "$ac_c_werror_flag" ||
1585          test ! -s conftest.err
1586        } && test -s conftest.$ac_objext; then :
1587   ac_retval=0
1588 else
1589   $as_echo "$as_me: failed program was:" >&5
1590 sed 's/^/| /' conftest.$ac_ext >&5
1591
1592         ac_retval=1
1593 fi
1594   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1595   as_fn_set_status $ac_retval
1596
1597 } # ac_fn_c_try_compile
1598
1599 # ac_fn_cxx_try_compile LINENO
1600 # ----------------------------
1601 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1602 ac_fn_cxx_try_compile ()
1603 {
1604   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1605   rm -f conftest.$ac_objext
1606   if { { ac_try="$ac_compile"
1607 case "(($ac_try" in
1608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1609   *) ac_try_echo=$ac_try;;
1610 esac
1611 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1612 $as_echo "$ac_try_echo"; } >&5
1613   (eval "$ac_compile") 2>conftest.err
1614   ac_status=$?
1615   if test -s conftest.err; then
1616     grep -v '^ *+' conftest.err >conftest.er1
1617     cat conftest.er1 >&5
1618     mv -f conftest.er1 conftest.err
1619   fi
1620   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1621   test $ac_status = 0; } && {
1622          test -z "$ac_cxx_werror_flag" ||
1623          test ! -s conftest.err
1624        } && test -s conftest.$ac_objext; then :
1625   ac_retval=0
1626 else
1627   $as_echo "$as_me: failed program was:" >&5
1628 sed 's/^/| /' conftest.$ac_ext >&5
1629
1630         ac_retval=1
1631 fi
1632   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1633   as_fn_set_status $ac_retval
1634
1635 } # ac_fn_cxx_try_compile
1636
1637 # ac_fn_c_try_cpp LINENO
1638 # ----------------------
1639 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1640 ac_fn_c_try_cpp ()
1641 {
1642   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1643   if { { ac_try="$ac_cpp conftest.$ac_ext"
1644 case "(($ac_try" in
1645   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1646   *) ac_try_echo=$ac_try;;
1647 esac
1648 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1649 $as_echo "$ac_try_echo"; } >&5
1650   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1651   ac_status=$?
1652   if test -s conftest.err; then
1653     grep -v '^ *+' conftest.err >conftest.er1
1654     cat conftest.er1 >&5
1655     mv -f conftest.er1 conftest.err
1656   fi
1657   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1658   test $ac_status = 0; } > conftest.i && {
1659          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1660          test ! -s conftest.err
1661        }; then :
1662   ac_retval=0
1663 else
1664   $as_echo "$as_me: failed program was:" >&5
1665 sed 's/^/| /' conftest.$ac_ext >&5
1666
1667     ac_retval=1
1668 fi
1669   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1670   as_fn_set_status $ac_retval
1671
1672 } # ac_fn_c_try_cpp
1673
1674 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1675 # -------------------------------------------------------
1676 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1677 # the include files in INCLUDES and setting the cache variable VAR
1678 # accordingly.
1679 ac_fn_c_check_header_mongrel ()
1680 {
1681   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1682   if eval \${$3+:} false; then :
1683   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1684 $as_echo_n "checking for $2... " >&6; }
1685 if eval \${$3+:} false; then :
1686   $as_echo_n "(cached) " >&6
1687 fi
1688 eval ac_res=\$$3
1689                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1690 $as_echo "$ac_res" >&6; }
1691 else
1692   # Is the header compilable?
1693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1694 $as_echo_n "checking $2 usability... " >&6; }
1695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1696 /* end confdefs.h.  */
1697 $4
1698 #include <$2>
1699 _ACEOF
1700 if ac_fn_c_try_compile "$LINENO"; then :
1701   ac_header_compiler=yes
1702 else
1703   ac_header_compiler=no
1704 fi
1705 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1707 $as_echo "$ac_header_compiler" >&6; }
1708
1709 # Is the header present?
1710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1711 $as_echo_n "checking $2 presence... " >&6; }
1712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1713 /* end confdefs.h.  */
1714 #include <$2>
1715 _ACEOF
1716 if ac_fn_c_try_cpp "$LINENO"; then :
1717   ac_header_preproc=yes
1718 else
1719   ac_header_preproc=no
1720 fi
1721 rm -f conftest.err conftest.i conftest.$ac_ext
1722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1723 $as_echo "$ac_header_preproc" >&6; }
1724
1725 # So?  What about this header?
1726 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1727   yes:no: )
1728     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1729 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1730     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1731 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1732     ;;
1733   no:yes:* )
1734     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1735 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1736     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1737 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1738     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1739 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1740     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1741 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1742     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1743 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1744 ( $as_echo "## ----------------------------------------- ##
1745 ## Report this to http://bugs.freeradius.org ##
1746 ## ----------------------------------------- ##"
1747      ) | sed "s/^/$as_me: WARNING:     /" >&2
1748     ;;
1749 esac
1750   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1751 $as_echo_n "checking for $2... " >&6; }
1752 if eval \${$3+:} false; then :
1753   $as_echo_n "(cached) " >&6
1754 else
1755   eval "$3=\$ac_header_compiler"
1756 fi
1757 eval ac_res=\$$3
1758                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1759 $as_echo "$ac_res" >&6; }
1760 fi
1761   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1762
1763 } # ac_fn_c_check_header_mongrel
1764
1765 # ac_fn_c_try_run LINENO
1766 # ----------------------
1767 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1768 # that executables *can* be run.
1769 ac_fn_c_try_run ()
1770 {
1771   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1772   if { { ac_try="$ac_link"
1773 case "(($ac_try" in
1774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1775   *) ac_try_echo=$ac_try;;
1776 esac
1777 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1778 $as_echo "$ac_try_echo"; } >&5
1779   (eval "$ac_link") 2>&5
1780   ac_status=$?
1781   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1782   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1783   { { case "(($ac_try" in
1784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1785   *) ac_try_echo=$ac_try;;
1786 esac
1787 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1788 $as_echo "$ac_try_echo"; } >&5
1789   (eval "$ac_try") 2>&5
1790   ac_status=$?
1791   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1792   test $ac_status = 0; }; }; then :
1793   ac_retval=0
1794 else
1795   $as_echo "$as_me: program exited with status $ac_status" >&5
1796        $as_echo "$as_me: failed program was:" >&5
1797 sed 's/^/| /' conftest.$ac_ext >&5
1798
1799        ac_retval=$ac_status
1800 fi
1801   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1802   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1803   as_fn_set_status $ac_retval
1804
1805 } # ac_fn_c_try_run
1806
1807 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1808 # -------------------------------------------------------
1809 # Tests whether HEADER exists and can be compiled using the include files in
1810 # INCLUDES, setting the cache variable VAR accordingly.
1811 ac_fn_c_check_header_compile ()
1812 {
1813   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1814   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1815 $as_echo_n "checking for $2... " >&6; }
1816 if eval \${$3+:} false; then :
1817   $as_echo_n "(cached) " >&6
1818 else
1819   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1820 /* end confdefs.h.  */
1821 $4
1822 #include <$2>
1823 _ACEOF
1824 if ac_fn_c_try_compile "$LINENO"; then :
1825   eval "$3=yes"
1826 else
1827   eval "$3=no"
1828 fi
1829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1830 fi
1831 eval ac_res=\$$3
1832                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1833 $as_echo "$ac_res" >&6; }
1834   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1835
1836 } # ac_fn_c_check_header_compile
1837
1838 # ac_fn_c_try_link LINENO
1839 # -----------------------
1840 # Try to link conftest.$ac_ext, and return whether this succeeded.
1841 ac_fn_c_try_link ()
1842 {
1843   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1844   rm -f conftest.$ac_objext conftest$ac_exeext
1845   if { { ac_try="$ac_link"
1846 case "(($ac_try" in
1847   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1848   *) ac_try_echo=$ac_try;;
1849 esac
1850 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1851 $as_echo "$ac_try_echo"; } >&5
1852   (eval "$ac_link") 2>conftest.err
1853   ac_status=$?
1854   if test -s conftest.err; then
1855     grep -v '^ *+' conftest.err >conftest.er1
1856     cat conftest.er1 >&5
1857     mv -f conftest.er1 conftest.err
1858   fi
1859   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1860   test $ac_status = 0; } && {
1861          test -z "$ac_c_werror_flag" ||
1862          test ! -s conftest.err
1863        } && test -s conftest$ac_exeext && {
1864          test "$cross_compiling" = yes ||
1865          test -x conftest$ac_exeext
1866        }; then :
1867   ac_retval=0
1868 else
1869   $as_echo "$as_me: failed program was:" >&5
1870 sed 's/^/| /' conftest.$ac_ext >&5
1871
1872         ac_retval=1
1873 fi
1874   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1875   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1876   # interfere with the next link command; also delete a directory that is
1877   # left behind by Apple's compiler.  We do this before executing the actions.
1878   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1879   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1880   as_fn_set_status $ac_retval
1881
1882 } # ac_fn_c_try_link
1883
1884 # ac_fn_c_check_func LINENO FUNC VAR
1885 # ----------------------------------
1886 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1887 ac_fn_c_check_func ()
1888 {
1889   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1890   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1891 $as_echo_n "checking for $2... " >&6; }
1892 if eval \${$3+:} false; then :
1893   $as_echo_n "(cached) " >&6
1894 else
1895   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1896 /* end confdefs.h.  */
1897 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1898    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
1899 #define $2 innocuous_$2
1900
1901 /* System header to define __stub macros and hopefully few prototypes,
1902     which can conflict with char $2 (); below.
1903     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1904     <limits.h> exists even on freestanding compilers.  */
1905
1906 #ifdef __STDC__
1907 # include <limits.h>
1908 #else
1909 # include <assert.h>
1910 #endif
1911
1912 #undef $2
1913
1914 /* Override any GCC internal prototype to avoid an error.
1915    Use char because int might match the return type of a GCC
1916    builtin and then its argument prototype would still apply.  */
1917 #ifdef __cplusplus
1918 extern "C"
1919 #endif
1920 char $2 ();
1921 /* The GNU C library defines this for functions which it implements
1922     to always fail with ENOSYS.  Some functions are actually named
1923     something starting with __ and the normal name is an alias.  */
1924 #if defined __stub_$2 || defined __stub___$2
1925 choke me
1926 #endif
1927
1928 int
1929 main ()
1930 {
1931 return $2 ();
1932   ;
1933   return 0;
1934 }
1935 _ACEOF
1936 if ac_fn_c_try_link "$LINENO"; then :
1937   eval "$3=yes"
1938 else
1939   eval "$3=no"
1940 fi
1941 rm -f core conftest.err conftest.$ac_objext \
1942     conftest$ac_exeext conftest.$ac_ext
1943 fi
1944 eval ac_res=\$$3
1945                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1946 $as_echo "$ac_res" >&6; }
1947   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1948
1949 } # ac_fn_c_check_func
1950
1951 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1952 # -------------------------------------------
1953 # Tests whether TYPE exists after having included INCLUDES, setting cache
1954 # variable VAR accordingly.
1955 ac_fn_c_check_type ()
1956 {
1957   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1958   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1959 $as_echo_n "checking for $2... " >&6; }
1960 if eval \${$3+:} false; then :
1961   $as_echo_n "(cached) " >&6
1962 else
1963   eval "$3=no"
1964   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1965 /* end confdefs.h.  */
1966 $4
1967 int
1968 main ()
1969 {
1970 if (sizeof ($2))
1971          return 0;
1972   ;
1973   return 0;
1974 }
1975 _ACEOF
1976 if ac_fn_c_try_compile "$LINENO"; then :
1977   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1978 /* end confdefs.h.  */
1979 $4
1980 int
1981 main ()
1982 {
1983 if (sizeof (($2)))
1984             return 0;
1985   ;
1986   return 0;
1987 }
1988 _ACEOF
1989 if ac_fn_c_try_compile "$LINENO"; then :
1990
1991 else
1992   eval "$3=yes"
1993 fi
1994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1995 fi
1996 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1997 fi
1998 eval ac_res=\$$3
1999                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2000 $as_echo "$ac_res" >&6; }
2001   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2002
2003 } # ac_fn_c_check_type
2004
2005 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2006 # ---------------------------------------------
2007 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2008 # accordingly.
2009 ac_fn_c_check_decl ()
2010 {
2011   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2012   as_decl_name=`echo $2|sed 's/ *(.*//'`
2013   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2014   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2015 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2016 if eval \${$3+:} false; then :
2017   $as_echo_n "(cached) " >&6
2018 else
2019   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2020 /* end confdefs.h.  */
2021 $4
2022 int
2023 main ()
2024 {
2025 #ifndef $as_decl_name
2026 #ifdef __cplusplus
2027   (void) $as_decl_use;
2028 #else
2029   (void) $as_decl_name;
2030 #endif
2031 #endif
2032
2033   ;
2034   return 0;
2035 }
2036 _ACEOF
2037 if ac_fn_c_try_compile "$LINENO"; then :
2038   eval "$3=yes"
2039 else
2040   eval "$3=no"
2041 fi
2042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2043 fi
2044 eval ac_res=\$$3
2045                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2046 $as_echo "$ac_res" >&6; }
2047   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2048
2049 } # ac_fn_c_check_decl
2050 cat >config.log <<_ACEOF
2051 This file contains any messages produced by compilers while
2052 running configure, to aid debugging if configure makes a mistake.
2053
2054 It was created by freeradius $as_me $Id$, which was
2055 generated by GNU Autoconf 2.69.  Invocation command line was
2056
2057   $ $0 $@
2058
2059 _ACEOF
2060 exec 5>>config.log
2061 {
2062 cat <<_ASUNAME
2063 ## --------- ##
2064 ## Platform. ##
2065 ## --------- ##
2066
2067 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2068 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2069 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2070 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2071 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2072
2073 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2074 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2075
2076 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2077 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2078 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2079 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2080 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2081 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2082 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2083
2084 _ASUNAME
2085
2086 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2087 for as_dir in $PATH
2088 do
2089   IFS=$as_save_IFS
2090   test -z "$as_dir" && as_dir=.
2091     $as_echo "PATH: $as_dir"
2092   done
2093 IFS=$as_save_IFS
2094
2095 } >&5
2096
2097 cat >&5 <<_ACEOF
2098
2099
2100 ## ----------- ##
2101 ## Core tests. ##
2102 ## ----------- ##
2103
2104 _ACEOF
2105
2106
2107 # Keep a trace of the command line.
2108 # Strip out --no-create and --no-recursion so they do not pile up.
2109 # Strip out --silent because we don't want to record it for future runs.
2110 # Also quote any args containing shell meta-characters.
2111 # Make two passes to allow for proper duplicate-argument suppression.
2112 ac_configure_args=
2113 ac_configure_args0=
2114 ac_configure_args1=
2115 ac_must_keep_next=false
2116 for ac_pass in 1 2
2117 do
2118   for ac_arg
2119   do
2120     case $ac_arg in
2121     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2122     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2123     | -silent | --silent | --silen | --sile | --sil)
2124       continue ;;
2125     *\'*)
2126       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2127     esac
2128     case $ac_pass in
2129     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2130     2)
2131       as_fn_append ac_configure_args1 " '$ac_arg'"
2132       if test $ac_must_keep_next = true; then
2133         ac_must_keep_next=false # Got value, back to normal.
2134       else
2135         case $ac_arg in
2136           *=* | --config-cache | -C | -disable-* | --disable-* \
2137           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2138           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2139           | -with-* | --with-* | -without-* | --without-* | --x)
2140             case "$ac_configure_args0 " in
2141               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2142             esac
2143             ;;
2144           -* ) ac_must_keep_next=true ;;
2145         esac
2146       fi
2147       as_fn_append ac_configure_args " '$ac_arg'"
2148       ;;
2149     esac
2150   done
2151 done
2152 { ac_configure_args0=; unset ac_configure_args0;}
2153 { ac_configure_args1=; unset ac_configure_args1;}
2154
2155 # When interrupted or exit'd, cleanup temporary files, and complete
2156 # config.log.  We remove comments because anyway the quotes in there
2157 # would cause problems or look ugly.
2158 # WARNING: Use '\'' to represent an apostrophe within the trap.
2159 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2160 trap 'exit_status=$?
2161   # Save into config.log some information that might help in debugging.
2162   {
2163     echo
2164
2165     $as_echo "## ---------------- ##
2166 ## Cache variables. ##
2167 ## ---------------- ##"
2168     echo
2169     # The following way of writing the cache mishandles newlines in values,
2170 (
2171   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2172     eval ac_val=\$$ac_var
2173     case $ac_val in #(
2174     *${as_nl}*)
2175       case $ac_var in #(
2176       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2177 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2178       esac
2179       case $ac_var in #(
2180       _ | IFS | as_nl) ;; #(
2181       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2182       *) { eval $ac_var=; unset $ac_var;} ;;
2183       esac ;;
2184     esac
2185   done
2186   (set) 2>&1 |
2187     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2188     *${as_nl}ac_space=\ *)
2189       sed -n \
2190         "s/'\''/'\''\\\\'\'''\''/g;
2191           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2192       ;; #(
2193     *)
2194       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2195       ;;
2196     esac |
2197     sort
2198 )
2199     echo
2200
2201     $as_echo "## ----------------- ##
2202 ## Output variables. ##
2203 ## ----------------- ##"
2204     echo
2205     for ac_var in $ac_subst_vars
2206     do
2207       eval ac_val=\$$ac_var
2208       case $ac_val in
2209       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2210       esac
2211       $as_echo "$ac_var='\''$ac_val'\''"
2212     done | sort
2213     echo
2214
2215     if test -n "$ac_subst_files"; then
2216       $as_echo "## ------------------- ##
2217 ## File substitutions. ##
2218 ## ------------------- ##"
2219       echo
2220       for ac_var in $ac_subst_files
2221       do
2222         eval ac_val=\$$ac_var
2223         case $ac_val in
2224         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2225         esac
2226         $as_echo "$ac_var='\''$ac_val'\''"
2227       done | sort
2228       echo
2229     fi
2230
2231     if test -s confdefs.h; then
2232       $as_echo "## ----------- ##
2233 ## confdefs.h. ##
2234 ## ----------- ##"
2235       echo
2236       cat confdefs.h
2237       echo
2238     fi
2239     test "$ac_signal" != 0 &&
2240       $as_echo "$as_me: caught signal $ac_signal"
2241     $as_echo "$as_me: exit $exit_status"
2242   } >&5
2243   rm -f core *.core core.conftest.* &&
2244     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2245     exit $exit_status
2246 ' 0
2247 for ac_signal in 1 2 13 15; do
2248   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2249 done
2250 ac_signal=0
2251
2252 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2253 rm -f -r conftest* confdefs.h
2254
2255 $as_echo "/* confdefs.h */" > confdefs.h
2256
2257 # Predefined preprocessor variables.
2258
2259 cat >>confdefs.h <<_ACEOF
2260 #define PACKAGE_NAME "$PACKAGE_NAME"
2261 _ACEOF
2262
2263 cat >>confdefs.h <<_ACEOF
2264 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2265 _ACEOF
2266
2267 cat >>confdefs.h <<_ACEOF
2268 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2269 _ACEOF
2270
2271 cat >>confdefs.h <<_ACEOF
2272 #define PACKAGE_STRING "$PACKAGE_STRING"
2273 _ACEOF
2274
2275 cat >>confdefs.h <<_ACEOF
2276 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2277 _ACEOF
2278
2279 cat >>confdefs.h <<_ACEOF
2280 #define PACKAGE_URL "$PACKAGE_URL"
2281 _ACEOF
2282
2283
2284 # Let the site file select an alternate cache file if it wants to.
2285 # Prefer an explicitly selected file to automatically selected ones.
2286 ac_site_file1=NONE
2287 ac_site_file2=NONE
2288 if test -n "$CONFIG_SITE"; then
2289   # We do not want a PATH search for config.site.
2290   case $CONFIG_SITE in #((
2291     -*)  ac_site_file1=./$CONFIG_SITE;;
2292     */*) ac_site_file1=$CONFIG_SITE;;
2293     *)   ac_site_file1=./$CONFIG_SITE;;
2294   esac
2295 elif test "x$prefix" != xNONE; then
2296   ac_site_file1=$prefix/share/config.site
2297   ac_site_file2=$prefix/etc/config.site
2298 else
2299   ac_site_file1=$ac_default_prefix/share/config.site
2300   ac_site_file2=$ac_default_prefix/etc/config.site
2301 fi
2302 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2303 do
2304   test "x$ac_site_file" = xNONE && continue
2305   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2306     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2307 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2308     sed 's/^/| /' "$ac_site_file" >&5
2309     . "$ac_site_file" \
2310       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2311 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2312 as_fn_error $? "failed to load site script $ac_site_file
2313 See \`config.log' for more details" "$LINENO" 5; }
2314   fi
2315 done
2316
2317 if test -r "$cache_file"; then
2318   # Some versions of bash will fail to source /dev/null (special files
2319   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2320   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2321     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2322 $as_echo "$as_me: loading cache $cache_file" >&6;}
2323     case $cache_file in
2324       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2325       *)                      . "./$cache_file";;
2326     esac
2327   fi
2328 else
2329   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2330 $as_echo "$as_me: creating cache $cache_file" >&6;}
2331   >$cache_file
2332 fi
2333
2334 # Check that the precious variables saved in the cache have kept the same
2335 # value.
2336 ac_cache_corrupted=false
2337 for ac_var in $ac_precious_vars; do
2338   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2339   eval ac_new_set=\$ac_env_${ac_var}_set
2340   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2341   eval ac_new_val=\$ac_env_${ac_var}_value
2342   case $ac_old_set,$ac_new_set in
2343     set,)
2344       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2345 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2346       ac_cache_corrupted=: ;;
2347     ,set)
2348       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2349 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2350       ac_cache_corrupted=: ;;
2351     ,);;
2352     *)
2353       if test "x$ac_old_val" != "x$ac_new_val"; then
2354         # differences in whitespace do not lead to failure.
2355         ac_old_val_w=`echo x $ac_old_val`
2356         ac_new_val_w=`echo x $ac_new_val`
2357         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2358           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2359 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2360           ac_cache_corrupted=:
2361         else
2362           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2363 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2364           eval $ac_var=\$ac_old_val
2365         fi
2366         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2367 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2368         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2369 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2370       fi;;
2371   esac
2372   # Pass precious variables to config.status.
2373   if test "$ac_new_set" = set; then
2374     case $ac_new_val in
2375     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2376     *) ac_arg=$ac_var=$ac_new_val ;;
2377     esac
2378     case " $ac_configure_args " in
2379       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2380       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2381     esac
2382   fi
2383 done
2384 if $ac_cache_corrupted; then
2385   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2386 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2387   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2388 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2389   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2390 fi
2391 ## -------------------- ##
2392 ## Main body of script. ##
2393 ## -------------------- ##
2394
2395 ac_ext=c
2396 ac_cpp='$CPP $CPPFLAGS'
2397 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2398 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2399 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2400
2401
2402
2403 ac_config_headers="$ac_config_headers src/include/autoconf.h"
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416 RADIUSD_MAJOR_VERSION=`cat VERSION | sed 's/\..*//'`
2417 RADIUSD_MINOR_VERSION=`cat VERSION | sed 's/^[^\.]*\.//' | sed 's/\..*$//'`
2418 RADIUSD_INCRM_VERSION=`cat VERSION | sed 's/^.*\..*\.//' | sed 's/[\.-].*$//'`
2419
2420 RADIUSD_VERSION=`echo | awk -v major="$RADIUSD_MAJOR_VERSION" \
2421 -v minor="$RADIUSD_MINOR_VERSION" \
2422 -v incrm="$RADIUSD_INCRM_VERSION" \
2423 '{ printf "%02i%02i%02i", major, minor, incrm }'`
2424
2425 RADIUSD_VERSION_STRING=`cat VERSION`
2426
2427
2428
2429
2430 cat >>confdefs.h <<_ACEOF
2431 #define RADIUSD_VERSION ${RADIUSD_VERSION}
2432 _ACEOF
2433
2434
2435 cat >>confdefs.h <<_ACEOF
2436 #define RADIUSD_VERSION_STRING "${RADIUSD_VERSION_STRING}"
2437 _ACEOF
2438
2439
2440
2441 # Check whether --enable-developer was given.
2442 if test "${enable_developer+set}" = set; then :
2443   enableval=$enable_developer;  case "$enableval" in
2444   no)
2445     developer=no
2446     ;;
2447   *)
2448     developer=yes
2449   esac
2450
2451 fi
2452
2453
2454 if test -d $srcdir/.git; then
2455   if test "x$developer" != "xno"; then
2456     { $as_echo "$as_me:${as_lineno-$LINENO}: found .git directory, enabling developer build implicitly, disable with --disable-developer" >&5
2457 $as_echo "$as_me: found .git directory, enabling developer build implicitly, disable with --disable-developer" >&6;}
2458     developer="yes"
2459   fi
2460 fi
2461
2462 if test "x$developer" = "xyes"; then
2463   : ${CFLAGS=-g3}
2464 fi
2465
2466
2467 ac_aux_dir=
2468 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2469   if test -f "$ac_dir/install-sh"; then
2470     ac_aux_dir=$ac_dir
2471     ac_install_sh="$ac_aux_dir/install-sh -c"
2472     break
2473   elif test -f "$ac_dir/install.sh"; then
2474     ac_aux_dir=$ac_dir
2475     ac_install_sh="$ac_aux_dir/install.sh -c"
2476     break
2477   elif test -f "$ac_dir/shtool"; then
2478     ac_aux_dir=$ac_dir
2479     ac_install_sh="$ac_aux_dir/shtool install -c"
2480     break
2481   fi
2482 done
2483 if test -z "$ac_aux_dir"; then
2484   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
2485 fi
2486
2487 # These three variables are undocumented and unsupported,
2488 # and are intended to be withdrawn in a future Autoconf release.
2489 # They can cause serious problems if a builder's source tree is in a directory
2490 # whose full name contains unusual characters.
2491 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2492 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2493 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2494
2495
2496 # Make sure we can run config.sub.
2497 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2498   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2499
2500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2501 $as_echo_n "checking build system type... " >&6; }
2502 if ${ac_cv_build+:} false; then :
2503   $as_echo_n "(cached) " >&6
2504 else
2505   ac_build_alias=$build_alias
2506 test "x$ac_build_alias" = x &&
2507   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2508 test "x$ac_build_alias" = x &&
2509   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2510 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2511   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2512
2513 fi
2514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2515 $as_echo "$ac_cv_build" >&6; }
2516 case $ac_cv_build in
2517 *-*-*) ;;
2518 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2519 esac
2520 build=$ac_cv_build
2521 ac_save_IFS=$IFS; IFS='-'
2522 set x $ac_cv_build
2523 shift
2524 build_cpu=$1
2525 build_vendor=$2
2526 shift; shift
2527 # Remember, the first character of IFS is used to create $*,
2528 # except with old shells:
2529 build_os=$*
2530 IFS=$ac_save_IFS
2531 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2532
2533
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2535 $as_echo_n "checking host system type... " >&6; }
2536 if ${ac_cv_host+:} false; then :
2537   $as_echo_n "(cached) " >&6
2538 else
2539   if test "x$host_alias" = x; then
2540   ac_cv_host=$ac_cv_build
2541 else
2542   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2543     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2544 fi
2545
2546 fi
2547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2548 $as_echo "$ac_cv_host" >&6; }
2549 case $ac_cv_host in
2550 *-*-*) ;;
2551 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2552 esac
2553 host=$ac_cv_host
2554 ac_save_IFS=$IFS; IFS='-'
2555 set x $ac_cv_host
2556 shift
2557 host_cpu=$1
2558 host_vendor=$2
2559 shift; shift
2560 # Remember, the first character of IFS is used to create $*,
2561 # except with old shells:
2562 host_os=$*
2563 IFS=$ac_save_IFS
2564 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2565
2566
2567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
2568 $as_echo_n "checking target system type... " >&6; }
2569 if ${ac_cv_target+:} false; then :
2570   $as_echo_n "(cached) " >&6
2571 else
2572   if test "x$target_alias" = x; then
2573   ac_cv_target=$ac_cv_host
2574 else
2575   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
2576     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
2577 fi
2578
2579 fi
2580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
2581 $as_echo "$ac_cv_target" >&6; }
2582 case $ac_cv_target in
2583 *-*-*) ;;
2584 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
2585 esac
2586 target=$ac_cv_target
2587 ac_save_IFS=$IFS; IFS='-'
2588 set x $ac_cv_target
2589 shift
2590 target_cpu=$1
2591 target_vendor=$2
2592 shift; shift
2593 # Remember, the first character of IFS is used to create $*,
2594 # except with old shells:
2595 target_os=$*
2596 IFS=$ac_save_IFS
2597 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
2598
2599
2600 # The aliases save the names the user supplied, while $host etc.
2601 # will get canonicalized.
2602 test -n "$target_alias" &&
2603   test "$program_prefix$program_suffix$program_transform_name" = \
2604     NONENONEs,x,x, &&
2605   program_prefix=${target_alias}-
2606
2607
2608 ac_ext=c
2609 ac_cpp='$CPP $CPPFLAGS'
2610 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2611 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2612 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2613 if test -n "$ac_tool_prefix"; then
2614   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2615 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2617 $as_echo_n "checking for $ac_word... " >&6; }
2618 if ${ac_cv_prog_CC+:} false; then :
2619   $as_echo_n "(cached) " >&6
2620 else
2621   if test -n "$CC"; then
2622   ac_cv_prog_CC="$CC" # Let the user override the test.
2623 else
2624 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2625 for as_dir in $PATH
2626 do
2627   IFS=$as_save_IFS
2628   test -z "$as_dir" && as_dir=.
2629     for ac_exec_ext in '' $ac_executable_extensions; do
2630   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2631     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2632     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2633     break 2
2634   fi
2635 done
2636   done
2637 IFS=$as_save_IFS
2638
2639 fi
2640 fi
2641 CC=$ac_cv_prog_CC
2642 if test -n "$CC"; then
2643   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2644 $as_echo "$CC" >&6; }
2645 else
2646   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2647 $as_echo "no" >&6; }
2648 fi
2649
2650
2651 fi
2652 if test -z "$ac_cv_prog_CC"; then
2653   ac_ct_CC=$CC
2654   # Extract the first word of "gcc", so it can be a program name with args.
2655 set dummy gcc; ac_word=$2
2656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2657 $as_echo_n "checking for $ac_word... " >&6; }
2658 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2659   $as_echo_n "(cached) " >&6
2660 else
2661   if test -n "$ac_ct_CC"; then
2662   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2663 else
2664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2665 for as_dir in $PATH
2666 do
2667   IFS=$as_save_IFS
2668   test -z "$as_dir" && as_dir=.
2669     for ac_exec_ext in '' $ac_executable_extensions; do
2670   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2671     ac_cv_prog_ac_ct_CC="gcc"
2672     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2673     break 2
2674   fi
2675 done
2676   done
2677 IFS=$as_save_IFS
2678
2679 fi
2680 fi
2681 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2682 if test -n "$ac_ct_CC"; then
2683   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2684 $as_echo "$ac_ct_CC" >&6; }
2685 else
2686   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2687 $as_echo "no" >&6; }
2688 fi
2689
2690   if test "x$ac_ct_CC" = x; then
2691     CC=""
2692   else
2693     case $cross_compiling:$ac_tool_warned in
2694 yes:)
2695 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2696 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2697 ac_tool_warned=yes ;;
2698 esac
2699     CC=$ac_ct_CC
2700   fi
2701 else
2702   CC="$ac_cv_prog_CC"
2703 fi
2704
2705 if test -z "$CC"; then
2706           if test -n "$ac_tool_prefix"; then
2707     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2708 set dummy ${ac_tool_prefix}cc; ac_word=$2
2709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2710 $as_echo_n "checking for $ac_word... " >&6; }
2711 if ${ac_cv_prog_CC+:} false; then :
2712   $as_echo_n "(cached) " >&6
2713 else
2714   if test -n "$CC"; then
2715   ac_cv_prog_CC="$CC" # Let the user override the test.
2716 else
2717 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2718 for as_dir in $PATH
2719 do
2720   IFS=$as_save_IFS
2721   test -z "$as_dir" && as_dir=.
2722     for ac_exec_ext in '' $ac_executable_extensions; do
2723   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2724     ac_cv_prog_CC="${ac_tool_prefix}cc"
2725     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2726     break 2
2727   fi
2728 done
2729   done
2730 IFS=$as_save_IFS
2731
2732 fi
2733 fi
2734 CC=$ac_cv_prog_CC
2735 if test -n "$CC"; then
2736   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2737 $as_echo "$CC" >&6; }
2738 else
2739   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2740 $as_echo "no" >&6; }
2741 fi
2742
2743
2744   fi
2745 fi
2746 if test -z "$CC"; then
2747   # Extract the first word of "cc", so it can be a program name with args.
2748 set dummy cc; ac_word=$2
2749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2750 $as_echo_n "checking for $ac_word... " >&6; }
2751 if ${ac_cv_prog_CC+:} false; then :
2752   $as_echo_n "(cached) " >&6
2753 else
2754   if test -n "$CC"; then
2755   ac_cv_prog_CC="$CC" # Let the user override the test.
2756 else
2757   ac_prog_rejected=no
2758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2759 for as_dir in $PATH
2760 do
2761   IFS=$as_save_IFS
2762   test -z "$as_dir" && as_dir=.
2763     for ac_exec_ext in '' $ac_executable_extensions; do
2764   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2765     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2766        ac_prog_rejected=yes
2767        continue
2768      fi
2769     ac_cv_prog_CC="cc"
2770     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2771     break 2
2772   fi
2773 done
2774   done
2775 IFS=$as_save_IFS
2776
2777 if test $ac_prog_rejected = yes; then
2778   # We found a bogon in the path, so make sure we never use it.
2779   set dummy $ac_cv_prog_CC
2780   shift
2781   if test $# != 0; then
2782     # We chose a different compiler from the bogus one.
2783     # However, it has the same basename, so the bogon will be chosen
2784     # first if we set CC to just the basename; use the full file name.
2785     shift
2786     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2787   fi
2788 fi
2789 fi
2790 fi
2791 CC=$ac_cv_prog_CC
2792 if test -n "$CC"; then
2793   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2794 $as_echo "$CC" >&6; }
2795 else
2796   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2797 $as_echo "no" >&6; }
2798 fi
2799
2800
2801 fi
2802 if test -z "$CC"; then
2803   if test -n "$ac_tool_prefix"; then
2804   for ac_prog in cl.exe
2805   do
2806     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2807 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2809 $as_echo_n "checking for $ac_word... " >&6; }
2810 if ${ac_cv_prog_CC+:} false; then :
2811   $as_echo_n "(cached) " >&6
2812 else
2813   if test -n "$CC"; then
2814   ac_cv_prog_CC="$CC" # Let the user override the test.
2815 else
2816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2817 for as_dir in $PATH
2818 do
2819   IFS=$as_save_IFS
2820   test -z "$as_dir" && as_dir=.
2821     for ac_exec_ext in '' $ac_executable_extensions; do
2822   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2823     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2824     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2825     break 2
2826   fi
2827 done
2828   done
2829 IFS=$as_save_IFS
2830
2831 fi
2832 fi
2833 CC=$ac_cv_prog_CC
2834 if test -n "$CC"; then
2835   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2836 $as_echo "$CC" >&6; }
2837 else
2838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2839 $as_echo "no" >&6; }
2840 fi
2841
2842
2843     test -n "$CC" && break
2844   done
2845 fi
2846 if test -z "$CC"; then
2847   ac_ct_CC=$CC
2848   for ac_prog in cl.exe
2849 do
2850   # Extract the first word of "$ac_prog", so it can be a program name with args.
2851 set dummy $ac_prog; ac_word=$2
2852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2853 $as_echo_n "checking for $ac_word... " >&6; }
2854 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2855   $as_echo_n "(cached) " >&6
2856 else
2857   if test -n "$ac_ct_CC"; then
2858   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2859 else
2860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2861 for as_dir in $PATH
2862 do
2863   IFS=$as_save_IFS
2864   test -z "$as_dir" && as_dir=.
2865     for ac_exec_ext in '' $ac_executable_extensions; do
2866   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2867     ac_cv_prog_ac_ct_CC="$ac_prog"
2868     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2869     break 2
2870   fi
2871 done
2872   done
2873 IFS=$as_save_IFS
2874
2875 fi
2876 fi
2877 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2878 if test -n "$ac_ct_CC"; then
2879   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2880 $as_echo "$ac_ct_CC" >&6; }
2881 else
2882   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2883 $as_echo "no" >&6; }
2884 fi
2885
2886
2887   test -n "$ac_ct_CC" && break
2888 done
2889
2890   if test "x$ac_ct_CC" = x; then
2891     CC=""
2892   else
2893     case $cross_compiling:$ac_tool_warned in
2894 yes:)
2895 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2896 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2897 ac_tool_warned=yes ;;
2898 esac
2899     CC=$ac_ct_CC
2900   fi
2901 fi
2902
2903 fi
2904
2905
2906 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2907 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2908 as_fn_error $? "no acceptable C compiler found in \$PATH
2909 See \`config.log' for more details" "$LINENO" 5; }
2910
2911 # Provide some information about the compiler.
2912 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2913 set X $ac_compile
2914 ac_compiler=$2
2915 for ac_option in --version -v -V -qversion; do
2916   { { ac_try="$ac_compiler $ac_option >&5"
2917 case "(($ac_try" in
2918   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2919   *) ac_try_echo=$ac_try;;
2920 esac
2921 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2922 $as_echo "$ac_try_echo"; } >&5
2923   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
2924   ac_status=$?
2925   if test -s conftest.err; then
2926     sed '10a\
2927 ... rest of stderr output deleted ...
2928          10q' conftest.err >conftest.er1
2929     cat conftest.er1 >&5
2930   fi
2931   rm -f conftest.er1 conftest.err
2932   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2933   test $ac_status = 0; }
2934 done
2935
2936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2937 /* end confdefs.h.  */
2938
2939 int
2940 main ()
2941 {
2942
2943   ;
2944   return 0;
2945 }
2946 _ACEOF
2947 ac_clean_files_save=$ac_clean_files
2948 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2949 # Try to create an executable without -o first, disregard a.out.
2950 # It will help us diagnose broken compilers, and finding out an intuition
2951 # of exeext.
2952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
2953 $as_echo_n "checking whether the C compiler works... " >&6; }
2954 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2955
2956 # The possible output files:
2957 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2958
2959 ac_rmfiles=
2960 for ac_file in $ac_files
2961 do
2962   case $ac_file in
2963     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2964     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2965   esac
2966 done
2967 rm -f $ac_rmfiles
2968
2969 if { { ac_try="$ac_link_default"
2970 case "(($ac_try" in
2971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2972   *) ac_try_echo=$ac_try;;
2973 esac
2974 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2975 $as_echo "$ac_try_echo"; } >&5
2976   (eval "$ac_link_default") 2>&5
2977   ac_status=$?
2978   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2979   test $ac_status = 0; }; then :
2980   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2981 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2982 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
2983 # so that the user can short-circuit this test for compilers unknown to
2984 # Autoconf.
2985 for ac_file in $ac_files ''
2986 do
2987   test -f "$ac_file" || continue
2988   case $ac_file in
2989     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
2990         ;;
2991     [ab].out )
2992         # We found the default executable, but exeext='' is most
2993         # certainly right.
2994         break;;
2995     *.* )
2996         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2997         then :; else
2998            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2999         fi
3000         # We set ac_cv_exeext here because the later test for it is not
3001         # safe: cross compilers may not add the suffix if given an `-o'
3002         # argument, so we may need to know it at that point already.
3003         # Even if this section looks crufty: it has the advantage of
3004         # actually working.
3005         break;;
3006     * )
3007         break;;
3008   esac
3009 done
3010 test "$ac_cv_exeext" = no && ac_cv_exeext=
3011
3012 else
3013   ac_file=''
3014 fi
3015 if test -z "$ac_file"; then :
3016   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3017 $as_echo "no" >&6; }
3018 $as_echo "$as_me: failed program was:" >&5
3019 sed 's/^/| /' conftest.$ac_ext >&5
3020
3021 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3022 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3023 as_fn_error 77 "C compiler cannot create executables
3024 See \`config.log' for more details" "$LINENO" 5; }
3025 else
3026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3027 $as_echo "yes" >&6; }
3028 fi
3029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3030 $as_echo_n "checking for C compiler default output file name... " >&6; }
3031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3032 $as_echo "$ac_file" >&6; }
3033 ac_exeext=$ac_cv_exeext
3034
3035 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3036 ac_clean_files=$ac_clean_files_save
3037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3038 $as_echo_n "checking for suffix of executables... " >&6; }
3039 if { { ac_try="$ac_link"
3040 case "(($ac_try" in
3041   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3042   *) ac_try_echo=$ac_try;;
3043 esac
3044 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3045 $as_echo "$ac_try_echo"; } >&5
3046   (eval "$ac_link") 2>&5
3047   ac_status=$?
3048   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3049   test $ac_status = 0; }; then :
3050   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3051 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3052 # work properly (i.e., refer to `conftest.exe'), while it won't with
3053 # `rm'.
3054 for ac_file in conftest.exe conftest conftest.*; do
3055   test -f "$ac_file" || continue
3056   case $ac_file in
3057     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3058     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3059           break;;
3060     * ) break;;
3061   esac
3062 done
3063 else
3064   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3065 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3066 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3067 See \`config.log' for more details" "$LINENO" 5; }
3068 fi
3069 rm -f conftest conftest$ac_cv_exeext
3070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3071 $as_echo "$ac_cv_exeext" >&6; }
3072
3073 rm -f conftest.$ac_ext
3074 EXEEXT=$ac_cv_exeext
3075 ac_exeext=$EXEEXT
3076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3077 /* end confdefs.h.  */
3078 #include <stdio.h>
3079 int
3080 main ()
3081 {
3082 FILE *f = fopen ("conftest.out", "w");
3083  return ferror (f) || fclose (f) != 0;
3084
3085   ;
3086   return 0;
3087 }
3088 _ACEOF
3089 ac_clean_files="$ac_clean_files conftest.out"
3090 # Check that the compiler produces executables we can run.  If not, either
3091 # the compiler is broken, or we cross compile.
3092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3093 $as_echo_n "checking whether we are cross compiling... " >&6; }
3094 if test "$cross_compiling" != yes; then
3095   { { ac_try="$ac_link"
3096 case "(($ac_try" in
3097   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3098   *) ac_try_echo=$ac_try;;
3099 esac
3100 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3101 $as_echo "$ac_try_echo"; } >&5
3102   (eval "$ac_link") 2>&5
3103   ac_status=$?
3104   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3105   test $ac_status = 0; }
3106   if { ac_try='./conftest$ac_cv_exeext'
3107   { { case "(($ac_try" in
3108   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3109   *) ac_try_echo=$ac_try;;
3110 esac
3111 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3112 $as_echo "$ac_try_echo"; } >&5
3113   (eval "$ac_try") 2>&5
3114   ac_status=$?
3115   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3116   test $ac_status = 0; }; }; then
3117     cross_compiling=no
3118   else
3119     if test "$cross_compiling" = maybe; then
3120         cross_compiling=yes
3121     else
3122         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3123 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3124 as_fn_error $? "cannot run C compiled programs.
3125 If you meant to cross compile, use \`--host'.
3126 See \`config.log' for more details" "$LINENO" 5; }
3127     fi
3128   fi
3129 fi
3130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3131 $as_echo "$cross_compiling" >&6; }
3132
3133 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3134 ac_clean_files=$ac_clean_files_save
3135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3136 $as_echo_n "checking for suffix of object files... " >&6; }
3137 if ${ac_cv_objext+:} false; then :
3138   $as_echo_n "(cached) " >&6
3139 else
3140   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3141 /* end confdefs.h.  */
3142
3143 int
3144 main ()
3145 {
3146
3147   ;
3148   return 0;
3149 }
3150 _ACEOF
3151 rm -f conftest.o conftest.obj
3152 if { { ac_try="$ac_compile"
3153 case "(($ac_try" in
3154   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3155   *) ac_try_echo=$ac_try;;
3156 esac
3157 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3158 $as_echo "$ac_try_echo"; } >&5
3159   (eval "$ac_compile") 2>&5
3160   ac_status=$?
3161   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3162   test $ac_status = 0; }; then :
3163   for ac_file in conftest.o conftest.obj conftest.*; do
3164   test -f "$ac_file" || continue;
3165   case $ac_file in
3166     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3167     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3168        break;;
3169   esac
3170 done
3171 else
3172   $as_echo "$as_me: failed program was:" >&5
3173 sed 's/^/| /' conftest.$ac_ext >&5
3174
3175 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3176 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3177 as_fn_error $? "cannot compute suffix of object files: cannot compile
3178 See \`config.log' for more details" "$LINENO" 5; }
3179 fi
3180 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3181 fi
3182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3183 $as_echo "$ac_cv_objext" >&6; }
3184 OBJEXT=$ac_cv_objext
3185 ac_objext=$OBJEXT
3186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3187 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3188 if ${ac_cv_c_compiler_gnu+:} false; then :
3189   $as_echo_n "(cached) " >&6
3190 else
3191   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3192 /* end confdefs.h.  */
3193
3194 int
3195 main ()
3196 {
3197 #ifndef __GNUC__
3198        choke me
3199 #endif
3200
3201   ;
3202   return 0;
3203 }
3204 _ACEOF
3205 if ac_fn_c_try_compile "$LINENO"; then :
3206   ac_compiler_gnu=yes
3207 else
3208   ac_compiler_gnu=no
3209 fi
3210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3211 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3212
3213 fi
3214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3215 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3216 if test $ac_compiler_gnu = yes; then
3217   GCC=yes
3218 else
3219   GCC=
3220 fi
3221 ac_test_CFLAGS=${CFLAGS+set}
3222 ac_save_CFLAGS=$CFLAGS
3223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3224 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3225 if ${ac_cv_prog_cc_g+:} false; then :
3226   $as_echo_n "(cached) " >&6
3227 else
3228   ac_save_c_werror_flag=$ac_c_werror_flag
3229    ac_c_werror_flag=yes
3230    ac_cv_prog_cc_g=no
3231    CFLAGS="-g"
3232    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3233 /* end confdefs.h.  */
3234
3235 int
3236 main ()
3237 {
3238
3239   ;
3240   return 0;
3241 }
3242 _ACEOF
3243 if ac_fn_c_try_compile "$LINENO"; then :
3244   ac_cv_prog_cc_g=yes
3245 else
3246   CFLAGS=""
3247       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3248 /* end confdefs.h.  */
3249
3250 int
3251 main ()
3252 {
3253
3254   ;
3255   return 0;
3256 }
3257 _ACEOF
3258 if ac_fn_c_try_compile "$LINENO"; then :
3259
3260 else
3261   ac_c_werror_flag=$ac_save_c_werror_flag
3262          CFLAGS="-g"
3263          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3264 /* end confdefs.h.  */
3265
3266 int
3267 main ()
3268 {
3269
3270   ;
3271   return 0;
3272 }
3273 _ACEOF
3274 if ac_fn_c_try_compile "$LINENO"; then :
3275   ac_cv_prog_cc_g=yes
3276 fi
3277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3278 fi
3279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3280 fi
3281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3282    ac_c_werror_flag=$ac_save_c_werror_flag
3283 fi
3284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3285 $as_echo "$ac_cv_prog_cc_g" >&6; }
3286 if test "$ac_test_CFLAGS" = set; then
3287   CFLAGS=$ac_save_CFLAGS
3288 elif test $ac_cv_prog_cc_g = yes; then
3289   if test "$GCC" = yes; then
3290     CFLAGS="-g -O2"
3291   else
3292     CFLAGS="-g"
3293   fi
3294 else
3295   if test "$GCC" = yes; then
3296     CFLAGS="-O2"
3297   else
3298     CFLAGS=
3299   fi
3300 fi
3301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3302 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3303 if ${ac_cv_prog_cc_c89+:} false; then :
3304   $as_echo_n "(cached) " >&6
3305 else
3306   ac_cv_prog_cc_c89=no
3307 ac_save_CC=$CC
3308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3309 /* end confdefs.h.  */
3310 #include <stdarg.h>
3311 #include <stdio.h>
3312 struct stat;
3313 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3314 struct buf { int x; };
3315 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3316 static char *e (p, i)
3317      char **p;
3318      int i;
3319 {
3320   return p[i];
3321 }
3322 static char *f (char * (*g) (char **, int), char **p, ...)
3323 {
3324   char *s;
3325   va_list v;
3326   va_start (v,p);
3327   s = g (p, va_arg (v,int));
3328   va_end (v);
3329   return s;
3330 }
3331
3332 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3333    function prototypes and stuff, but not '\xHH' hex character constants.
3334    These don't provoke an error unfortunately, instead are silently treated
3335    as 'x'.  The following induces an error, until -std is added to get
3336    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3337    array size at least.  It's necessary to write '\x00'==0 to get something
3338    that's true only with -std.  */
3339 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3340
3341 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3342    inside strings and character constants.  */
3343 #define FOO(x) 'x'
3344 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3345
3346 int test (int i, double x);
3347 struct s1 {int (*f) (int a);};
3348 struct s2 {int (*f) (double a);};
3349 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3350 int argc;
3351 char **argv;
3352 int
3353 main ()
3354 {
3355 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3356   ;
3357   return 0;
3358 }
3359 _ACEOF
3360 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3361         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3362 do
3363   CC="$ac_save_CC $ac_arg"
3364   if ac_fn_c_try_compile "$LINENO"; then :
3365   ac_cv_prog_cc_c89=$ac_arg
3366 fi
3367 rm -f core conftest.err conftest.$ac_objext
3368   test "x$ac_cv_prog_cc_c89" != "xno" && break
3369 done
3370 rm -f conftest.$ac_ext
3371 CC=$ac_save_CC
3372
3373 fi
3374 # AC_CACHE_VAL
3375 case "x$ac_cv_prog_cc_c89" in
3376   x)
3377     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3378 $as_echo "none needed" >&6; } ;;
3379   xno)
3380     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3381 $as_echo "unsupported" >&6; } ;;
3382   *)
3383     CC="$CC $ac_cv_prog_cc_c89"
3384     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3385 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3386 esac
3387 if test "x$ac_cv_prog_cc_c89" != xno; then :
3388
3389 fi
3390
3391 ac_ext=c
3392 ac_cpp='$CPP $CPPFLAGS'
3393 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3394 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3395 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3396
3397 ac_ext=cpp
3398 ac_cpp='$CXXCPP $CPPFLAGS'
3399 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3400 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3401 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3402 if test -z "$CXX"; then
3403   if test -n "$CCC"; then
3404     CXX=$CCC
3405   else
3406     if test -n "$ac_tool_prefix"; then
3407   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3408   do
3409     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3410 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3412 $as_echo_n "checking for $ac_word... " >&6; }
3413 if ${ac_cv_prog_CXX+:} false; then :
3414   $as_echo_n "(cached) " >&6
3415 else
3416   if test -n "$CXX"; then
3417   ac_cv_prog_CXX="$CXX" # Let the user override the test.
3418 else
3419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3420 for as_dir in $PATH
3421 do
3422   IFS=$as_save_IFS
3423   test -z "$as_dir" && as_dir=.
3424     for ac_exec_ext in '' $ac_executable_extensions; do
3425   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3426     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3427     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3428     break 2
3429   fi
3430 done
3431   done
3432 IFS=$as_save_IFS
3433
3434 fi
3435 fi
3436 CXX=$ac_cv_prog_CXX
3437 if test -n "$CXX"; then
3438   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3439 $as_echo "$CXX" >&6; }
3440 else
3441   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3442 $as_echo "no" >&6; }
3443 fi
3444
3445
3446     test -n "$CXX" && break
3447   done
3448 fi
3449 if test -z "$CXX"; then
3450   ac_ct_CXX=$CXX
3451   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3452 do
3453   # Extract the first word of "$ac_prog", so it can be a program name with args.
3454 set dummy $ac_prog; ac_word=$2
3455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3456 $as_echo_n "checking for $ac_word... " >&6; }
3457 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3458   $as_echo_n "(cached) " >&6
3459 else
3460   if test -n "$ac_ct_CXX"; then
3461   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3462 else
3463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3464 for as_dir in $PATH
3465 do
3466   IFS=$as_save_IFS
3467   test -z "$as_dir" && as_dir=.
3468     for ac_exec_ext in '' $ac_executable_extensions; do
3469   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3470     ac_cv_prog_ac_ct_CXX="$ac_prog"
3471     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3472     break 2
3473   fi
3474 done
3475   done
3476 IFS=$as_save_IFS
3477
3478 fi
3479 fi
3480 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3481 if test -n "$ac_ct_CXX"; then
3482   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3483 $as_echo "$ac_ct_CXX" >&6; }
3484 else
3485   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3486 $as_echo "no" >&6; }
3487 fi
3488
3489
3490   test -n "$ac_ct_CXX" && break
3491 done
3492
3493   if test "x$ac_ct_CXX" = x; then
3494     CXX="g++"
3495   else
3496     case $cross_compiling:$ac_tool_warned in
3497 yes:)
3498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3499 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3500 ac_tool_warned=yes ;;
3501 esac
3502     CXX=$ac_ct_CXX
3503   fi
3504 fi
3505
3506   fi
3507 fi
3508 # Provide some information about the compiler.
3509 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3510 set X $ac_compile
3511 ac_compiler=$2
3512 for ac_option in --version -v -V -qversion; do
3513   { { ac_try="$ac_compiler $ac_option >&5"
3514 case "(($ac_try" in
3515   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3516   *) ac_try_echo=$ac_try;;
3517 esac
3518 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3519 $as_echo "$ac_try_echo"; } >&5
3520   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3521   ac_status=$?
3522   if test -s conftest.err; then
3523     sed '10a\
3524 ... rest of stderr output deleted ...
3525          10q' conftest.err >conftest.er1
3526     cat conftest.er1 >&5
3527   fi
3528   rm -f conftest.er1 conftest.err
3529   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3530   test $ac_status = 0; }
3531 done
3532
3533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3534 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3535 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3536   $as_echo_n "(cached) " >&6
3537 else
3538   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3539 /* end confdefs.h.  */
3540
3541 int
3542 main ()
3543 {
3544 #ifndef __GNUC__
3545        choke me
3546 #endif
3547
3548   ;
3549   return 0;
3550 }
3551 _ACEOF
3552 if ac_fn_cxx_try_compile "$LINENO"; then :
3553   ac_compiler_gnu=yes
3554 else
3555   ac_compiler_gnu=no
3556 fi
3557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3558 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3559
3560 fi
3561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3562 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3563 if test $ac_compiler_gnu = yes; then
3564   GXX=yes
3565 else
3566   GXX=
3567 fi
3568 ac_test_CXXFLAGS=${CXXFLAGS+set}
3569 ac_save_CXXFLAGS=$CXXFLAGS
3570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3571 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3572 if ${ac_cv_prog_cxx_g+:} false; then :
3573   $as_echo_n "(cached) " >&6
3574 else
3575   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3576    ac_cxx_werror_flag=yes
3577    ac_cv_prog_cxx_g=no
3578    CXXFLAGS="-g"
3579    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3580 /* end confdefs.h.  */
3581
3582 int
3583 main ()
3584 {
3585
3586   ;
3587   return 0;
3588 }
3589 _ACEOF
3590 if ac_fn_cxx_try_compile "$LINENO"; then :
3591   ac_cv_prog_cxx_g=yes
3592 else
3593   CXXFLAGS=""
3594       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3595 /* end confdefs.h.  */
3596
3597 int
3598 main ()
3599 {
3600
3601   ;
3602   return 0;
3603 }
3604 _ACEOF
3605 if ac_fn_cxx_try_compile "$LINENO"; then :
3606
3607 else
3608   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3609          CXXFLAGS="-g"
3610          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3611 /* end confdefs.h.  */
3612
3613 int
3614 main ()
3615 {
3616
3617   ;
3618   return 0;
3619 }
3620 _ACEOF
3621 if ac_fn_cxx_try_compile "$LINENO"; then :
3622   ac_cv_prog_cxx_g=yes
3623 fi
3624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3625 fi
3626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3627 fi
3628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3629    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3630 fi
3631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3632 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3633 if test "$ac_test_CXXFLAGS" = set; then
3634   CXXFLAGS=$ac_save_CXXFLAGS
3635 elif test $ac_cv_prog_cxx_g = yes; then
3636   if test "$GXX" = yes; then
3637     CXXFLAGS="-g -O2"
3638   else
3639     CXXFLAGS="-g"
3640   fi
3641 else
3642   if test "$GXX" = yes; then
3643     CXXFLAGS="-O2"
3644   else
3645     CXXFLAGS=
3646   fi
3647 fi
3648 ac_ext=c
3649 ac_cpp='$CPP $CPPFLAGS'
3650 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3651 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3652 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3653
3654
3655
3656 ac_ext=c
3657 ac_cpp='$CPP $CPPFLAGS'
3658 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3659 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3660 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3662 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3663 # On Suns, sometimes $CPP names a directory.
3664 if test -n "$CPP" && test -d "$CPP"; then
3665   CPP=
3666 fi
3667 if test -z "$CPP"; then
3668   if ${ac_cv_prog_CPP+:} false; then :
3669   $as_echo_n "(cached) " >&6
3670 else
3671       # Double quotes because CPP needs to be expanded
3672     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3673     do
3674       ac_preproc_ok=false
3675 for ac_c_preproc_warn_flag in '' yes
3676 do
3677   # Use a header file that comes with gcc, so configuring glibc
3678   # with a fresh cross-compiler works.
3679   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3680   # <limits.h> exists even on freestanding compilers.
3681   # On the NeXT, cc -E runs the code through the compiler's parser,
3682   # not just through cpp. "Syntax error" is here to catch this case.
3683   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3684 /* end confdefs.h.  */
3685 #ifdef __STDC__
3686 # include <limits.h>
3687 #else
3688 # include <assert.h>
3689 #endif
3690                      Syntax error
3691 _ACEOF
3692 if ac_fn_c_try_cpp "$LINENO"; then :
3693
3694 else
3695   # Broken: fails on valid input.
3696 continue
3697 fi
3698 rm -f conftest.err conftest.i conftest.$ac_ext
3699
3700   # OK, works on sane cases.  Now check whether nonexistent headers
3701   # can be detected and how.
3702   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3703 /* end confdefs.h.  */
3704 #include <ac_nonexistent.h>
3705 _ACEOF
3706 if ac_fn_c_try_cpp "$LINENO"; then :
3707   # Broken: success on invalid input.
3708 continue
3709 else
3710   # Passes both tests.
3711 ac_preproc_ok=:
3712 break
3713 fi
3714 rm -f conftest.err conftest.i conftest.$ac_ext
3715
3716 done
3717 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3718 rm -f conftest.i conftest.err conftest.$ac_ext
3719 if $ac_preproc_ok; then :
3720   break
3721 fi
3722
3723     done
3724     ac_cv_prog_CPP=$CPP
3725
3726 fi
3727   CPP=$ac_cv_prog_CPP
3728 else
3729   ac_cv_prog_CPP=$CPP
3730 fi
3731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3732 $as_echo "$CPP" >&6; }
3733 ac_preproc_ok=false
3734 for ac_c_preproc_warn_flag in '' yes
3735 do
3736   # Use a header file that comes with gcc, so configuring glibc
3737   # with a fresh cross-compiler works.
3738   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3739   # <limits.h> exists even on freestanding compilers.
3740   # On the NeXT, cc -E runs the code through the compiler's parser,
3741   # not just through cpp. "Syntax error" is here to catch this case.
3742   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3743 /* end confdefs.h.  */
3744 #ifdef __STDC__
3745 # include <limits.h>
3746 #else
3747 # include <assert.h>
3748 #endif
3749                      Syntax error
3750 _ACEOF
3751 if ac_fn_c_try_cpp "$LINENO"; then :
3752
3753 else
3754   # Broken: fails on valid input.
3755 continue
3756 fi
3757 rm -f conftest.err conftest.i conftest.$ac_ext
3758
3759   # OK, works on sane cases.  Now check whether nonexistent headers
3760   # can be detected and how.
3761   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3762 /* end confdefs.h.  */
3763 #include <ac_nonexistent.h>
3764 _ACEOF
3765 if ac_fn_c_try_cpp "$LINENO"; then :
3766   # Broken: success on invalid input.
3767 continue
3768 else
3769   # Passes both tests.
3770 ac_preproc_ok=:
3771 break
3772 fi
3773 rm -f conftest.err conftest.i conftest.$ac_ext
3774
3775 done
3776 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3777 rm -f conftest.i conftest.err conftest.$ac_ext
3778 if $ac_preproc_ok; then :
3779
3780 else
3781   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3782 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3783 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3784 See \`config.log' for more details" "$LINENO" 5; }
3785 fi
3786
3787 ac_ext=c
3788 ac_cpp='$CPP $CPPFLAGS'
3789 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3790 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3791 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3792
3793
3794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3795 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3796 if ${ac_cv_path_GREP+:} false; then :
3797   $as_echo_n "(cached) " >&6
3798 else
3799   if test -z "$GREP"; then
3800   ac_path_GREP_found=false
3801   # Loop through the user's path and test for each of PROGNAME-LIST
3802   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3803 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3804 do
3805   IFS=$as_save_IFS
3806   test -z "$as_dir" && as_dir=.
3807     for ac_prog in grep ggrep; do
3808     for ac_exec_ext in '' $ac_executable_extensions; do
3809       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3810       as_fn_executable_p "$ac_path_GREP" || continue
3811 # Check for GNU ac_path_GREP and select it if it is found.
3812   # Check for GNU $ac_path_GREP
3813 case `"$ac_path_GREP" --version 2>&1` in
3814 *GNU*)
3815   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3816 *)
3817   ac_count=0
3818   $as_echo_n 0123456789 >"conftest.in"
3819   while :
3820   do
3821     cat "conftest.in" "conftest.in" >"conftest.tmp"
3822     mv "conftest.tmp" "conftest.in"
3823     cp "conftest.in" "conftest.nl"
3824     $as_echo 'GREP' >> "conftest.nl"
3825     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3826     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3827     as_fn_arith $ac_count + 1 && ac_count=$as_val
3828     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3829       # Best one so far, save it but keep looking for a better one
3830       ac_cv_path_GREP="$ac_path_GREP"
3831       ac_path_GREP_max=$ac_count
3832     fi
3833     # 10*(2^10) chars as input seems more than enough
3834     test $ac_count -gt 10 && break
3835   done
3836   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3837 esac
3838
3839       $ac_path_GREP_found && break 3
3840     done
3841   done
3842   done
3843 IFS=$as_save_IFS
3844   if test -z "$ac_cv_path_GREP"; then
3845     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3846   fi
3847 else
3848   ac_cv_path_GREP=$GREP
3849 fi
3850
3851 fi
3852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3853 $as_echo "$ac_cv_path_GREP" >&6; }
3854  GREP="$ac_cv_path_GREP"
3855
3856
3857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3858 $as_echo_n "checking for egrep... " >&6; }
3859 if ${ac_cv_path_EGREP+:} false; then :
3860   $as_echo_n "(cached) " >&6
3861 else
3862   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3863    then ac_cv_path_EGREP="$GREP -E"
3864    else
3865      if test -z "$EGREP"; then
3866   ac_path_EGREP_found=false
3867   # Loop through the user's path and test for each of PROGNAME-LIST
3868   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3869 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3870 do
3871   IFS=$as_save_IFS
3872   test -z "$as_dir" && as_dir=.
3873     for ac_prog in egrep; do
3874     for ac_exec_ext in '' $ac_executable_extensions; do
3875       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3876       as_fn_executable_p "$ac_path_EGREP" || continue
3877 # Check for GNU ac_path_EGREP and select it if it is found.
3878   # Check for GNU $ac_path_EGREP
3879 case `"$ac_path_EGREP" --version 2>&1` in
3880 *GNU*)
3881   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3882 *)
3883   ac_count=0
3884   $as_echo_n 0123456789 >"conftest.in"
3885   while :
3886   do
3887     cat "conftest.in" "conftest.in" >"conftest.tmp"
3888     mv "conftest.tmp" "conftest.in"
3889     cp "conftest.in" "conftest.nl"
3890     $as_echo 'EGREP' >> "conftest.nl"
3891     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3892     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3893     as_fn_arith $ac_count + 1 && ac_count=$as_val
3894     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3895       # Best one so far, save it but keep looking for a better one
3896       ac_cv_path_EGREP="$ac_path_EGREP"
3897       ac_path_EGREP_max=$ac_count
3898     fi
3899     # 10*(2^10) chars as input seems more than enough
3900     test $ac_count -gt 10 && break
3901   done
3902   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3903 esac
3904
3905       $ac_path_EGREP_found && break 3
3906     done
3907   done
3908   done
3909 IFS=$as_save_IFS
3910   if test -z "$ac_cv_path_EGREP"; then
3911     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3912   fi
3913 else
3914   ac_cv_path_EGREP=$EGREP
3915 fi
3916
3917    fi
3918 fi
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3920 $as_echo "$ac_cv_path_EGREP" >&6; }
3921  EGREP="$ac_cv_path_EGREP"
3922
3923
3924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3925 $as_echo_n "checking for ANSI C header files... " >&6; }
3926 if ${ac_cv_header_stdc+:} false; then :
3927   $as_echo_n "(cached) " >&6
3928 else
3929   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3930 /* end confdefs.h.  */
3931 #include <stdlib.h>
3932 #include <stdarg.h>
3933 #include <string.h>
3934 #include <float.h>
3935
3936 int
3937 main ()
3938 {
3939
3940   ;
3941   return 0;
3942 }
3943 _ACEOF
3944 if ac_fn_c_try_compile "$LINENO"; then :
3945   ac_cv_header_stdc=yes
3946 else
3947   ac_cv_header_stdc=no
3948 fi
3949 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3950
3951 if test $ac_cv_header_stdc = yes; then
3952   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3953   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3954 /* end confdefs.h.  */
3955 #include <string.h>
3956
3957 _ACEOF
3958 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3959   $EGREP "memchr" >/dev/null 2>&1; then :
3960
3961 else
3962   ac_cv_header_stdc=no
3963 fi
3964 rm -f conftest*
3965
3966 fi
3967
3968 if test $ac_cv_header_stdc = yes; then
3969   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3970   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3971 /* end confdefs.h.  */
3972 #include <stdlib.h>
3973
3974 _ACEOF
3975 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3976   $EGREP "free" >/dev/null 2>&1; then :
3977
3978 else
3979   ac_cv_header_stdc=no
3980 fi
3981 rm -f conftest*
3982
3983 fi
3984
3985 if test $ac_cv_header_stdc = yes; then
3986   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3987   if test "$cross_compiling" = yes; then :
3988   :
3989 else
3990   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3991 /* end confdefs.h.  */
3992 #include <ctype.h>
3993 #include <stdlib.h>
3994 #if ((' ' & 0x0FF) == 0x020)
3995 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3996 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3997 #else
3998 # define ISLOWER(c) \
3999                    (('a' <= (c) && (c) <= 'i') \
4000                      || ('j' <= (c) && (c) <= 'r') \
4001                      || ('s' <= (c) && (c) <= 'z'))
4002 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4003 #endif
4004
4005 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4006 int
4007 main ()
4008 {
4009   int i;
4010   for (i = 0; i < 256; i++)
4011     if (XOR (islower (i), ISLOWER (i))
4012         || toupper (i) != TOUPPER (i))
4013       return 2;
4014   return 0;
4015 }
4016 _ACEOF
4017 if ac_fn_c_try_run "$LINENO"; then :
4018
4019 else
4020   ac_cv_header_stdc=no
4021 fi
4022 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4023   conftest.$ac_objext conftest.beam conftest.$ac_ext
4024 fi
4025
4026 fi
4027 fi
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4029 $as_echo "$ac_cv_header_stdc" >&6; }
4030 if test $ac_cv_header_stdc = yes; then
4031
4032 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4033
4034 fi
4035
4036 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4037 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4038                   inttypes.h stdint.h unistd.h
4039 do :
4040   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4041 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4042 "
4043 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4044   cat >>confdefs.h <<_ACEOF
4045 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4046 _ACEOF
4047
4048 fi
4049
4050 done
4051
4052
4053
4054   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4055 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4056   MINIX=yes
4057 else
4058   MINIX=
4059 fi
4060
4061
4062   if test "$MINIX" = yes; then
4063
4064 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4065
4066
4067 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4068
4069
4070 $as_echo "#define _MINIX 1" >>confdefs.h
4071
4072   fi
4073
4074
4075   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4076 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4077 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4078   $as_echo_n "(cached) " >&6
4079 else
4080   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4081 /* end confdefs.h.  */
4082
4083 #         define __EXTENSIONS__ 1
4084           $ac_includes_default
4085 int
4086 main ()
4087 {
4088
4089   ;
4090   return 0;
4091 }
4092 _ACEOF
4093 if ac_fn_c_try_compile "$LINENO"; then :
4094   ac_cv_safe_to_define___extensions__=yes
4095 else
4096   ac_cv_safe_to_define___extensions__=no
4097 fi
4098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4099 fi
4100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4101 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4102   test $ac_cv_safe_to_define___extensions__ = yes &&
4103     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4104
4105   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4106
4107   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4108
4109   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4110
4111   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4112
4113
4114
4115
4116 if test $ac_cv_c_compiler_gnu = yes; then
4117     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
4118 $as_echo_n "checking whether $CC needs -traditional... " >&6; }
4119 if ${ac_cv_prog_gcc_traditional+:} false; then :
4120   $as_echo_n "(cached) " >&6
4121 else
4122     ac_pattern="Autoconf.*'x'"
4123   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4124 /* end confdefs.h.  */
4125 #include <sgtty.h>
4126 Autoconf TIOCGETP
4127 _ACEOF
4128 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4129   $EGREP "$ac_pattern" >/dev/null 2>&1; then :
4130   ac_cv_prog_gcc_traditional=yes
4131 else
4132   ac_cv_prog_gcc_traditional=no
4133 fi
4134 rm -f conftest*
4135
4136
4137   if test $ac_cv_prog_gcc_traditional = no; then
4138     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4139 /* end confdefs.h.  */
4140 #include <termio.h>
4141 Autoconf TCGETA
4142 _ACEOF
4143 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4144   $EGREP "$ac_pattern" >/dev/null 2>&1; then :
4145   ac_cv_prog_gcc_traditional=yes
4146 fi
4147 rm -f conftest*
4148
4149   fi
4150 fi
4151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
4152 $as_echo "$ac_cv_prog_gcc_traditional" >&6; }
4153   if test $ac_cv_prog_gcc_traditional = yes; then
4154     CC="$CC -traditional"
4155   fi
4156 fi
4157
4158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using SUNPro C" >&5
4159 $as_echo_n "checking whether we are using SUNPro C... " >&6; }
4160 if ${ac_cv_prog_suncc+:} false; then :
4161   $as_echo_n "(cached) " >&6
4162 else
4163   cat > conftest.c <<EOF
4164 #ifdef __SUNPRO_C
4165   yes;
4166 #endif
4167 EOF
4168 if { ac_try='${CC-cc} -E conftest.c'
4169   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
4170   (eval $ac_try) 2>&5
4171   ac_status=$?
4172   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4173   test $ac_status = 0; }; } | egrep yes >/dev/null 2>&1; then
4174   ac_cv_prog_suncc=yes
4175 else
4176   ac_cv_prog_suncc=no
4177 fi
4178 fi
4179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_suncc" >&5
4180 $as_echo "$ac_cv_prog_suncc" >&6; }
4181 if test -n "$ac_tool_prefix"; then
4182   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4183 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4185 $as_echo_n "checking for $ac_word... " >&6; }
4186 if ${ac_cv_prog_RANLIB+:} false; then :
4187   $as_echo_n "(cached) " >&6
4188 else
4189   if test -n "$RANLIB"; then
4190   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4191 else
4192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4193 for as_dir in $PATH
4194 do
4195   IFS=$as_save_IFS
4196   test -z "$as_dir" && as_dir=.
4197     for ac_exec_ext in '' $ac_executable_extensions; do
4198   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4199     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4200     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4201     break 2
4202   fi
4203 done
4204   done
4205 IFS=$as_save_IFS
4206
4207 fi
4208 fi
4209 RANLIB=$ac_cv_prog_RANLIB
4210 if test -n "$RANLIB"; then
4211   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4212 $as_echo "$RANLIB" >&6; }
4213 else
4214   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4215 $as_echo "no" >&6; }
4216 fi
4217
4218
4219 fi
4220 if test -z "$ac_cv_prog_RANLIB"; then
4221   ac_ct_RANLIB=$RANLIB
4222   # Extract the first word of "ranlib", so it can be a program name with args.
4223 set dummy ranlib; ac_word=$2
4224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4225 $as_echo_n "checking for $ac_word... " >&6; }
4226 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
4227   $as_echo_n "(cached) " >&6
4228 else
4229   if test -n "$ac_ct_RANLIB"; then
4230   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4231 else
4232 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4233 for as_dir in $PATH
4234 do
4235   IFS=$as_save_IFS
4236   test -z "$as_dir" && as_dir=.
4237     for ac_exec_ext in '' $ac_executable_extensions; do
4238   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4239     ac_cv_prog_ac_ct_RANLIB="ranlib"
4240     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4241     break 2
4242   fi
4243 done
4244   done
4245 IFS=$as_save_IFS
4246
4247 fi
4248 fi
4249 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4250 if test -n "$ac_ct_RANLIB"; then
4251   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4252 $as_echo "$ac_ct_RANLIB" >&6; }
4253 else
4254   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4255 $as_echo "no" >&6; }
4256 fi
4257
4258   if test "x$ac_ct_RANLIB" = x; then
4259     RANLIB=":"
4260   else
4261     case $cross_compiling:$ac_tool_warned in
4262 yes:)
4263 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4264 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4265 ac_tool_warned=yes ;;
4266 esac
4267     RANLIB=$ac_ct_RANLIB
4268   fi
4269 else
4270   RANLIB="$ac_cv_prog_RANLIB"
4271 fi
4272
4273
4274
4275   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is clang" >&5
4276 $as_echo_n "checking if compiler is clang... " >&6; }
4277 if ${ax_cv_cc_clang+:} false; then :
4278   $as_echo_n "(cached) " >&6
4279 else
4280
4281
4282   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4283 /* end confdefs.h.  */
4284
4285 int
4286 main ()
4287 {
4288
4289     #ifndef __clang__
4290          not clang
4291     #endif
4292
4293   ;
4294   return 0;
4295 }
4296 _ACEOF
4297 if ac_fn_c_try_compile "$LINENO"; then :
4298   ax_cv_cc_clang=yes
4299 else
4300   ax_cv_cc_clang=no
4301 fi
4302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4303
4304 fi
4305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cc_clang" >&5
4306 $as_echo "$ax_cv_cc_clang" >&6; }
4307
4308 if test "x$ax_cv_cc_clang" = "xyes"; then
4309   clang_path="$CC"
4310
4311 else
4312   clang_path=""
4313
4314 fi
4315
4316
4317 if test "x$GCC" = "xyes"; then
4318   CFLAGS="$CFLAGS -Wall -std=c99 -D_GNU_SOURCE"
4319 fi
4320
4321
4322   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the compiler flag \"-Qunused-arguments\"" >&5
4323 $as_echo_n "checking for the compiler flag \"-Qunused-arguments\"... " >&6; }
4324 if ${ax_cv_cc_qunused_arguments_flag+:} false; then :
4325   $as_echo_n "(cached) " >&6
4326 else
4327
4328
4329     CFLAGS_SAVED=$CFLAGS
4330     CFLAGS="$CFLAGS -Werror -Qunused-arguments -foobar"
4331
4332     ac_ext=c
4333 ac_cpp='$CPP $CPPFLAGS'
4334 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4335 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4336 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4337
4338     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4339 /* end confdefs.h.  */
4340
4341 int
4342 main ()
4343 {
4344 return 0;
4345   ;
4346   return 0;
4347 }
4348 _ACEOF
4349 if ac_fn_c_try_compile "$LINENO"; then :
4350   ax_cv_cc_qunused_arguments_flag="yes"
4351 else
4352   ax_cv_cc_qunused_arguments_flag="no"
4353 fi
4354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4355     ac_ext=c
4356 ac_cpp='$CPP $CPPFLAGS'
4357 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4358 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4359 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4360
4361
4362     CFLAGS="$CFLAGS_SAVED"
4363
4364 fi
4365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cc_qunused_arguments_flag" >&5
4366 $as_echo "$ax_cv_cc_qunused_arguments_flag" >&6; }
4367
4368 if test "x$ax_cv_cc_qunused_arguments_flag" = "xyes"; then
4369   CFLAGS="$CFLAGS -Qunused-arguments"
4370   LDFLAGS="$LDFLAGS -Qunused-arguments"
4371 fi
4372
4373 # Check whether --enable-largefile was given.
4374 if test "${enable_largefile+set}" = set; then :
4375   enableval=$enable_largefile;
4376 fi
4377
4378 if test "$enable_largefile" != no; then
4379
4380   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4381 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4382 if ${ac_cv_sys_largefile_CC+:} false; then :
4383   $as_echo_n "(cached) " >&6
4384 else
4385   ac_cv_sys_largefile_CC=no
4386      if test "$GCC" != yes; then
4387        ac_save_CC=$CC
4388        while :; do
4389          # IRIX 6.2 and later do not support large files by default,
4390          # so use the C compiler's -n32 option if that helps.
4391          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4392 /* end confdefs.h.  */
4393 #include <sys/types.h>
4394  /* Check that off_t can represent 2**63 - 1 correctly.
4395     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4396     since some C++ compilers masquerading as C compilers
4397     incorrectly reject 9223372036854775807.  */
4398 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
4399   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4400                        && LARGE_OFF_T % 2147483647 == 1)
4401                       ? 1 : -1];
4402 int
4403 main ()
4404 {
4405
4406   ;
4407   return 0;
4408 }
4409 _ACEOF
4410          if ac_fn_c_try_compile "$LINENO"; then :
4411   break
4412 fi
4413 rm -f core conftest.err conftest.$ac_objext
4414          CC="$CC -n32"
4415          if ac_fn_c_try_compile "$LINENO"; then :
4416   ac_cv_sys_largefile_CC=' -n32'; break
4417 fi
4418 rm -f core conftest.err conftest.$ac_objext
4419          break
4420        done
4421        CC=$ac_save_CC
4422        rm -f conftest.$ac_ext
4423     fi
4424 fi
4425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4426 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4427   if test "$ac_cv_sys_largefile_CC" != no; then
4428     CC=$CC$ac_cv_sys_largefile_CC
4429   fi
4430
4431   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4432 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4433 if ${ac_cv_sys_file_offset_bits+:} false; then :
4434   $as_echo_n "(cached) " >&6
4435 else
4436   while :; do
4437   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4438 /* end confdefs.h.  */
4439 #include <sys/types.h>
4440  /* Check that off_t can represent 2**63 - 1 correctly.
4441     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4442     since some C++ compilers masquerading as C compilers
4443     incorrectly reject 9223372036854775807.  */
4444 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
4445   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4446                        && LARGE_OFF_T % 2147483647 == 1)
4447                       ? 1 : -1];
4448 int
4449 main ()
4450 {
4451
4452   ;
4453   return 0;
4454 }
4455 _ACEOF
4456 if ac_fn_c_try_compile "$LINENO"; then :
4457   ac_cv_sys_file_offset_bits=no; break
4458 fi
4459 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4460   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4461 /* end confdefs.h.  */
4462 #define _FILE_OFFSET_BITS 64
4463 #include <sys/types.h>
4464  /* Check that off_t can represent 2**63 - 1 correctly.
4465     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4466     since some C++ compilers masquerading as C compilers
4467     incorrectly reject 9223372036854775807.  */
4468 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
4469   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4470                        && LARGE_OFF_T % 2147483647 == 1)
4471                       ? 1 : -1];
4472 int
4473 main ()
4474 {
4475
4476   ;
4477   return 0;
4478 }
4479 _ACEOF
4480 if ac_fn_c_try_compile "$LINENO"; then :
4481   ac_cv_sys_file_offset_bits=64; break
4482 fi
4483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4484   ac_cv_sys_file_offset_bits=unknown
4485   break
4486 done
4487 fi
4488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4489 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4490 case $ac_cv_sys_file_offset_bits in #(
4491   no | unknown) ;;
4492   *)
4493 cat >>confdefs.h <<_ACEOF
4494 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4495 _ACEOF
4496 ;;
4497 esac
4498 rm -rf conftest*
4499   if test $ac_cv_sys_file_offset_bits = unknown; then
4500     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4501 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4502 if ${ac_cv_sys_large_files+:} false; then :
4503   $as_echo_n "(cached) " >&6
4504 else
4505   while :; do
4506   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4507 /* end confdefs.h.  */
4508 #include <sys/types.h>
4509  /* Check that off_t can represent 2**63 - 1 correctly.
4510     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4511     since some C++ compilers masquerading as C compilers
4512     incorrectly reject 9223372036854775807.  */
4513 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
4514   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4515                        && LARGE_OFF_T % 2147483647 == 1)
4516                       ? 1 : -1];
4517 int
4518 main ()
4519 {
4520
4521   ;
4522   return 0;
4523 }
4524 _ACEOF
4525 if ac_fn_c_try_compile "$LINENO"; then :
4526   ac_cv_sys_large_files=no; break
4527 fi
4528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4529   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4530 /* end confdefs.h.  */
4531 #define _LARGE_FILES 1
4532 #include <sys/types.h>
4533  /* Check that off_t can represent 2**63 - 1 correctly.
4534     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4535     since some C++ compilers masquerading as C compilers
4536     incorrectly reject 9223372036854775807.  */
4537 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
4538   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4539                        && LARGE_OFF_T % 2147483647 == 1)
4540                       ? 1 : -1];
4541 int
4542 main ()
4543 {
4544
4545   ;
4546   return 0;
4547 }
4548 _ACEOF
4549 if ac_fn_c_try_compile "$LINENO"; then :
4550   ac_cv_sys_large_files=1; break
4551 fi
4552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4553   ac_cv_sys_large_files=unknown
4554   break
4555 done
4556 fi
4557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4558 $as_echo "$ac_cv_sys_large_files" >&6; }
4559 case $ac_cv_sys_large_files in #(
4560   no | unknown) ;;
4561   *)
4562 cat >>confdefs.h <<_ACEOF
4563 #define _LARGE_FILES $ac_cv_sys_large_files
4564 _ACEOF
4565 ;;
4566 esac
4567 rm -rf conftest*
4568   fi
4569
4570
4571 fi
4572
4573
4574  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
4575 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
4576 if ${ac_cv_c_bigendian+:} false; then :
4577   $as_echo_n "(cached) " >&6
4578 else
4579   ac_cv_c_bigendian=unknown
4580     # See if we're dealing with a universal compiler.
4581     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4582 /* end confdefs.h.  */
4583 #ifndef __APPLE_CC__
4584                not a universal capable compiler
4585              #endif
4586              typedef int dummy;
4587
4588 _ACEOF
4589 if ac_fn_c_try_compile "$LINENO"; then :
4590
4591         # Check for potential -arch flags.  It is not universal unless
4592         # there are at least two -arch flags with different values.
4593         ac_arch=
4594         ac_prev=
4595         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
4596          if test -n "$ac_prev"; then
4597            case $ac_word in
4598              i?86 | x86_64 | ppc | ppc64)
4599                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
4600                  ac_arch=$ac_word
4601                else
4602                  ac_cv_c_bigendian=universal
4603                  break
4604                fi
4605                ;;
4606            esac
4607            ac_prev=
4608          elif test "x$ac_word" = "x-arch"; then
4609            ac_prev=arch
4610          fi
4611        done
4612 fi
4613 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4614     if test $ac_cv_c_bigendian = unknown; then
4615       # See if sys/param.h defines the BYTE_ORDER macro.
4616       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4617 /* end confdefs.h.  */
4618 #include <sys/types.h>
4619              #include <sys/param.h>
4620
4621 int
4622 main ()
4623 {
4624 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
4625                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
4626                      && LITTLE_ENDIAN)
4627               bogus endian macros
4628              #endif
4629
4630   ;
4631   return 0;
4632 }
4633 _ACEOF
4634 if ac_fn_c_try_compile "$LINENO"; then :
4635   # It does; now see whether it defined to BIG_ENDIAN or not.
4636          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4637 /* end confdefs.h.  */
4638 #include <sys/types.h>
4639                 #include <sys/param.h>
4640
4641 int
4642 main ()
4643 {
4644 #if BYTE_ORDER != BIG_ENDIAN
4645                  not big endian
4646                 #endif
4647
4648   ;
4649   return 0;
4650 }
4651 _ACEOF
4652 if ac_fn_c_try_compile "$LINENO"; then :
4653   ac_cv_c_bigendian=yes
4654 else
4655   ac_cv_c_bigendian=no
4656 fi
4657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4658 fi
4659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4660     fi
4661     if test $ac_cv_c_bigendian = unknown; then
4662       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
4663       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4664 /* end confdefs.h.  */
4665 #include <limits.h>
4666
4667 int
4668 main ()
4669 {
4670 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
4671               bogus endian macros
4672              #endif
4673
4674   ;
4675   return 0;
4676 }
4677 _ACEOF
4678 if ac_fn_c_try_compile "$LINENO"; then :
4679   # It does; now see whether it defined to _BIG_ENDIAN or not.
4680          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4681 /* end confdefs.h.  */
4682 #include <limits.h>
4683
4684 int
4685 main ()
4686 {
4687 #ifndef _BIG_ENDIAN
4688                  not big endian
4689                 #endif
4690
4691   ;
4692   return 0;
4693 }
4694 _ACEOF
4695 if ac_fn_c_try_compile "$LINENO"; then :
4696   ac_cv_c_bigendian=yes
4697 else
4698   ac_cv_c_bigendian=no
4699 fi
4700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4701 fi
4702 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4703     fi
4704     if test $ac_cv_c_bigendian = unknown; then
4705       # Compile a test program.
4706       if test "$cross_compiling" = yes; then :
4707   # Try to guess by grepping values from an object file.
4708          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4709 /* end confdefs.h.  */
4710 short int ascii_mm[] =
4711                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
4712                 short int ascii_ii[] =
4713                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
4714                 int use_ascii (int i) {
4715                   return ascii_mm[i] + ascii_ii[i];
4716                 }
4717                 short int ebcdic_ii[] =
4718                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
4719                 short int ebcdic_mm[] =
4720                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
4721                 int use_ebcdic (int i) {
4722                   return ebcdic_mm[i] + ebcdic_ii[i];
4723                 }
4724                 extern int foo;
4725
4726 int
4727 main ()
4728 {
4729 return use_ascii (foo) == use_ebcdic (foo);
4730   ;
4731   return 0;
4732 }
4733 _ACEOF
4734 if ac_fn_c_try_compile "$LINENO"; then :
4735   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
4736               ac_cv_c_bigendian=yes
4737             fi
4738             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
4739               if test "$ac_cv_c_bigendian" = unknown; then
4740                 ac_cv_c_bigendian=no
4741               else
4742                 # finding both strings is unlikely to happen, but who knows?
4743                 ac_cv_c_bigendian=unknown
4744               fi
4745             fi
4746 fi
4747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4748 else
4749   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4750 /* end confdefs.h.  */
4751 $ac_includes_default
4752 int
4753 main ()
4754 {
4755
4756              /* Are we little or big endian?  From Harbison&Steele.  */
4757              union
4758              {
4759                long int l;
4760                char c[sizeof (long int)];
4761              } u;
4762              u.l = 1;
4763              return u.c[sizeof (long int) - 1] == 1;
4764
4765   ;
4766   return 0;
4767 }
4768 _ACEOF
4769 if ac_fn_c_try_run "$LINENO"; then :
4770   ac_cv_c_bigendian=no
4771 else
4772   ac_cv_c_bigendian=yes
4773 fi
4774 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4775   conftest.$ac_objext conftest.beam conftest.$ac_ext
4776 fi
4777
4778     fi
4779 fi
4780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
4781 $as_echo "$ac_cv_c_bigendian" >&6; }
4782  case $ac_cv_c_bigendian in #(
4783    yes)
4784
4785 $as_echo "#define RADIUS_BIG_ENDIAN 1" >>confdefs.h
4786 ;; #(
4787    no)
4788
4789 $as_echo "#define RADIUS_LITTLE_ENDIAN 1" >>confdefs.h
4790
4791  ;; #(
4792    universal)
4793
4794 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
4795
4796      ;; #(
4797    *)
4798      as_fn_error $? "unknown endianness
4799  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
4800  esac
4801
4802
4803 # Extract the first word of "gmake", so it can be a program name with args.
4804 set dummy gmake; ac_word=$2
4805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4806 $as_echo_n "checking for $ac_word... " >&6; }
4807 if ${ac_cv_prog_GMAKE+:} false; then :
4808   $as_echo_n "(cached) " >&6
4809 else
4810   if test -n "$GMAKE"; then
4811   ac_cv_prog_GMAKE="$GMAKE" # Let the user override the test.
4812 else
4813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4814 for as_dir in $PATH
4815 do
4816   IFS=$as_save_IFS
4817   test -z "$as_dir" && as_dir=.
4818     for ac_exec_ext in '' $ac_executable_extensions; do
4819   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4820     ac_cv_prog_GMAKE="yes"
4821     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4822     break 2
4823   fi
4824 done
4825   done
4826 IFS=$as_save_IFS
4827
4828   test -z "$ac_cv_prog_GMAKE" && ac_cv_prog_GMAKE="no"
4829 fi
4830 fi
4831 GMAKE=$ac_cv_prog_GMAKE
4832 if test -n "$GMAKE"; then
4833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMAKE" >&5
4834 $as_echo "$GMAKE" >&6; }
4835 else
4836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4837 $as_echo "no" >&6; }
4838 fi
4839
4840
4841 if test $GMAKE = no; then
4842   # Extract the first word of "make", so it can be a program name with args.
4843 set dummy make; ac_word=$2
4844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4845 $as_echo_n "checking for $ac_word... " >&6; }
4846 if ${ac_cv_path_MAKE+:} false; then :
4847   $as_echo_n "(cached) " >&6
4848 else
4849   case $MAKE in
4850   [\\/]* | ?:[\\/]*)
4851   ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path.
4852   ;;
4853   *)
4854   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4855 for as_dir in $PATH
4856 do
4857   IFS=$as_save_IFS
4858   test -z "$as_dir" && as_dir=.
4859     for ac_exec_ext in '' $ac_executable_extensions; do
4860   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4861     ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext"
4862     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4863     break 2
4864   fi
4865 done
4866   done
4867 IFS=$as_save_IFS
4868
4869   test -z "$ac_cv_path_MAKE" && ac_cv_path_MAKE="/usr/local/bin/make"
4870   ;;
4871 esac
4872 fi
4873 MAKE=$ac_cv_path_MAKE
4874 if test -n "$MAKE"; then
4875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
4876 $as_echo "$MAKE" >&6; }
4877 else
4878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4879 $as_echo "no" >&6; }
4880 fi
4881
4882
4883 else
4884   # Extract the first word of "gmake", so it can be a program name with args.
4885 set dummy gmake; ac_word=$2
4886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4887 $as_echo_n "checking for $ac_word... " >&6; }
4888 if ${ac_cv_path_MAKE+:} false; then :
4889   $as_echo_n "(cached) " >&6
4890 else
4891   case $MAKE in
4892   [\\/]* | ?:[\\/]*)
4893   ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path.
4894   ;;
4895   *)
4896   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4897 for as_dir in $PATH
4898 do
4899   IFS=$as_save_IFS
4900   test -z "$as_dir" && as_dir=.
4901     for ac_exec_ext in '' $ac_executable_extensions; do
4902   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4903     ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext"
4904     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4905     break 2
4906   fi
4907 done
4908   done
4909 IFS=$as_save_IFS
4910
4911   test -z "$ac_cv_path_MAKE" && ac_cv_path_MAKE="/usr/local/gnu/bin/make"
4912   ;;
4913 esac
4914 fi
4915 MAKE=$ac_cv_path_MAKE
4916 if test -n "$MAKE"; then
4917   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
4918 $as_echo "$MAKE" >&6; }
4919 else
4920   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4921 $as_echo "no" >&6; }
4922 fi
4923
4924
4925 fi
4926 makever=`$ac_cv_path_MAKE --version 2>&1 | grep "GNU Make"`
4927 if test -z "$makever"; then
4928   as_fn_error $? "GNU Make is not installed.  Please download and install it from ftp://prep.ai.mit.edu/pub/gnu/make/ before continuing." "$LINENO" 5
4929 fi
4930
4931
4932   { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of system cores" >&5
4933 $as_echo_n "checking number of system cores... " >&6; }
4934 if ${ax_cv_system_cores+:} false; then :
4935   $as_echo_n "(cached) " >&6
4936 else
4937
4938       ac_ext=c
4939 ac_cpp='$CPP $CPPFLAGS'
4940 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4941 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4942 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4943
4944       if test "$cross_compiling" = yes; then :
4945   ax_cv_system_cores=
4946
4947 else
4948   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4949 /* end confdefs.h.  */
4950
4951           #include <stdio.h>
4952           #include <stdint.h>
4953           #ifdef _WIN32
4954           #  include <windows.h>
4955           #elif MACOS
4956           #  include <sys/param.h>
4957           #  include <sys/sysctl.h>
4958           #else
4959           #  include <unistd.h>
4960           #endif
4961
4962           int main (int argc, char *argv[])
4963           {
4964             uint32_t count;
4965
4966             #ifdef WIN32
4967             SYSTEM_INFO sysinfo;
4968             GetSystemInfo(&sysinfo);
4969
4970             count = sysinfo.dwNumberOfProcessors;
4971
4972             #elif MACOS
4973             int nm[2];
4974             size_t len = 4;
4975
4976             nm[0] = CTL_HW;
4977             nm[1] = HW_AVAILCPU;
4978             sysctl(nm, 2, &count, &len, NULL, 0);
4979
4980             if(count < 1) {
4981               nm[1] = HW_NCPU;
4982               sysctl(nm, 2, &count, &len, NULL, 0);
4983               if(count < 1) {
4984                 count = 1;
4985               }
4986             }
4987
4988             #else
4989             count = sysconf(_SC_NPROCESSORS_ONLN);
4990             #endif
4991
4992             return count;
4993           }
4994
4995 _ACEOF
4996 if ac_fn_c_try_run "$LINENO"; then :
4997   ax_cv_system_cores=$?
4998 else
4999   ax_cv_system_cores=$?
5000 fi
5001 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5002   conftest.$ac_objext conftest.beam conftest.$ac_ext
5003 fi
5004
5005     ac_ext=c
5006 ac_cpp='$CPP $CPPFLAGS'
5007 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5008 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5009 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5010
5011
5012 fi
5013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_system_cores" >&5
5014 $as_echo "$ax_cv_system_cores" >&6; }
5015
5016
5017
5018
5019 # Extract the first word of "git", so it can be a program name with args.
5020 set dummy git; ac_word=$2
5021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5022 $as_echo_n "checking for $ac_word... " >&6; }
5023 if ${ac_cv_prog_GIT+:} false; then :
5024   $as_echo_n "(cached) " >&6
5025 else
5026   if test -n "$GIT"; then
5027   ac_cv_prog_GIT="$GIT" # Let the user override the test.
5028 else
5029 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5030 for as_dir in $PATH
5031 do
5032   IFS=$as_save_IFS
5033   test -z "$as_dir" && as_dir=.
5034     for ac_exec_ext in '' $ac_executable_extensions; do
5035   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5036     ac_cv_prog_GIT="yes"
5037     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5038     break 2
5039   fi
5040 done
5041   done
5042 IFS=$as_save_IFS
5043
5044   test -z "$ac_cv_prog_GIT" && ac_cv_prog_GIT="no"
5045 fi
5046 fi
5047 GIT=$ac_cv_prog_GIT
5048 if test -n "$GIT"; then
5049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GIT" >&5
5050 $as_echo "$GIT" >&6; }
5051 else
5052   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5053 $as_echo "no" >&6; }
5054 fi
5055
5056
5057
5058
5059 # Check whether --enable-strict-dependencies was given.
5060 if test "${enable_strict_dependencies+set}" = set; then :
5061   enableval=$enable_strict_dependencies;
5062 fi
5063
5064
5065 # Check whether --enable-werror was given.
5066 if test "${enable_werror+set}" = set; then :
5067   enableval=$enable_werror;  case "$enableval" in
5068     no)
5069       werror=no
5070     ;;
5071     *)
5072       werror=yes
5073   esac
5074
5075 fi
5076
5077
5078 docdir='${datadir}/doc/freeradius'
5079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking docdir" >&5
5080 $as_echo_n "checking docdir... " >&6; }
5081
5082 # Check whether --with-docdir was given.
5083 if test "${with_docdir+set}" = set; then :
5084   withval=$with_docdir;  case "$withval" in
5085   no)
5086     docdir=no
5087     ;;
5088   yes)
5089     ;;
5090   [\\/$]* | ?:[\\/]* )
5091     docdir="$withval"
5092     ;;
5093   *)
5094     as_fn_error $? "expected an absolute directory name for --with-docdir: $withval" "$LINENO" 5
5095     ;;
5096   esac
5097
5098 fi
5099
5100
5101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $docdir" >&5
5102 $as_echo "$docdir" >&6; }
5103 if test "x$docdir" = xno; then
5104   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Documentation files will NOT be installed." >&5
5105 $as_echo "$as_me: WARNING: Documentation files will NOT be installed." >&2;}
5106 fi
5107
5108 logdir='${localstatedir}/log/radius'
5109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking logdir" >&5
5110 $as_echo_n "checking logdir... " >&6; }
5111
5112 # Check whether --with-logdir was given.
5113 if test "${with_logdir+set}" = set; then :
5114   withval=$with_logdir;  case "$withval" in
5115   no)
5116     as_fn_error $? "Need logdir" "$LINENO" 5
5117     ;;
5118   yes)
5119     ;;
5120   [\\/$]* | ?:[\\/]* )
5121     logdir="$withval"
5122     ;;
5123   *)
5124     as_fn_error $? "expected an absolute directory name for --with-logdir: $withval" "$LINENO" 5
5125     ;;
5126   esac
5127
5128 fi
5129
5130
5131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $logdir" >&5
5132 $as_echo "$logdir" >&6; }
5133
5134 radacctdir='${logdir}/radacct'
5135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking radacctdir" >&5
5136 $as_echo_n "checking radacctdir... " >&6; }
5137
5138 # Check whether --with-radacctdir was given.
5139 if test "${with_radacctdir+set}" = set; then :
5140   withval=$with_radacctdir;  case "$withval" in
5141   no)
5142     as_fn_error $? "Need radacctdir" "$LINENO" 5
5143     ;;
5144   yes)
5145     ;;
5146   [\\/$]* | ?:[\\/]* )
5147     radacctdir="$withval"
5148     ;;
5149   *)
5150     as_fn_error $? "expected an absolute directory name for --with-radacctdir: $withval" "$LINENO" 5
5151     ;;
5152   esac
5153
5154 fi
5155
5156
5157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $radacctdir" >&5
5158 $as_echo "$radacctdir" >&6; }
5159
5160 raddbdir='${sysconfdir}/raddb'
5161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking raddbdir" >&5
5162 $as_echo_n "checking raddbdir... " >&6; }
5163
5164 # Check whether --with-raddbdir was given.
5165 if test "${with_raddbdir+set}" = set; then :
5166   withval=$with_raddbdir;  case "$withval" in
5167   no)
5168     as_fn_error $? "Need raddbdir" "$LINENO" 5
5169     ;;
5170   yes)
5171     ;;
5172   [\\/$]* | ?:[\\/]* )
5173     raddbdir="$withval"
5174     ;;
5175   *)
5176     as_fn_error $? "expected an absolute directory name for --with-raddbdir: $withval" "$LINENO" 5
5177     ;;
5178   esac
5179
5180 fi
5181
5182
5183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $raddbdir" >&5
5184 $as_echo "$raddbdir" >&6; }
5185
5186 dictdir='${datarootdir}/freeradius'
5187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dictdir" >&5
5188 $as_echo_n "checking dictdir... " >&6; }
5189
5190 # Check whether --with-dictdir was given.
5191 if test "${with_dictdir+set}" = set; then :
5192   withval=$with_dictdir;  case "$withval" in
5193   no)
5194     as_fn_error $? "Need dictdir" "$LINENO" 5
5195     ;;
5196   yes)
5197     ;;
5198   [\\/$]* | ?:[\\/]* )
5199     dictdir="$withval"
5200     ;;
5201   *)
5202     as_fn_error $? "expected an absolute directory name for --with-dictdir: $withval" "$LINENO" 5
5203     ;;
5204   esac
5205
5206 fi
5207
5208
5209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dictdir" >&5
5210 $as_echo "$dictdir" >&6; }
5211
5212 modconfdir='${raddbdir}/mods-config'
5213
5214
5215 WITH_ASCEND_BINARY=yes
5216
5217 # Check whether --with-ascend-binary was given.
5218 if test "${with_ascend_binary+set}" = set; then :
5219   withval=$with_ascend_binary;  case "$withval" in
5220   yes)
5221     ;;
5222   *)
5223     WITH_ASCEND_BINARY=no
5224   esac
5225
5226 fi
5227
5228 if test "x$WITH_ASCEND_BINARY" = "xyes"; then
5229
5230 $as_echo "#define WITH_ASCEND_BINARY 1" >>confdefs.h
5231
5232 fi
5233
5234 WITH_THREADS=yes
5235
5236 # Check whether --with-threads was given.
5237 if test "${with_threads+set}" = set; then :
5238   withval=$with_threads;  case "$withval" in
5239   yes)
5240     ;;
5241   *)
5242     WITH_THREADS=no
5243   esac
5244
5245 fi
5246
5247
5248 WITH_TCP=yes
5249
5250 # Check whether --with-tcp was given.
5251 if test "${with_tcp+set}" = set; then :
5252   withval=$with_tcp;  case "$withval" in
5253   yes)
5254     ;;
5255   *)
5256     WITH_TCP=no
5257   esac
5258
5259 fi
5260
5261 if test "x$WITH_TCP" = "xyes"; then
5262
5263 $as_echo "#define WITH_TCP 1" >>confdefs.h
5264
5265 fi
5266
5267 WITH_VMPS=yes
5268
5269 # Check whether --with-vmps was given.
5270 if test "${with_vmps+set}" = set; then :
5271   withval=$with_vmps;  case "$withval" in
5272   yes)
5273     ;;
5274   *)
5275     WITH_VMPS=no
5276   esac
5277
5278 fi
5279
5280 if test "x$WITH_VMPS" = "xyes"; then
5281
5282 $as_echo "#define WITH_VMPS 1" >>confdefs.h
5283
5284 fi
5285
5286 WITH_DHCP=yes
5287
5288 # Check whether --with-dhcp was given.
5289 if test "${with_dhcp+set}" = set; then :
5290   withval=$with_dhcp;  case "$withval" in
5291   yes)
5292     ;;
5293   *)
5294     WITH_DHCP=no
5295   esac
5296
5297 fi
5298
5299 if test "x$WITH_DHCP" = "xyes"; then
5300
5301 $as_echo "#define WITH_DHCP 1" >>confdefs.h
5302
5303 fi
5304
5305 STATIC_MODULES=
5306
5307 # Check whether --with-static_modules was given.
5308 if test "${with_static_modules+set}" = set; then :
5309   withval=$with_static_modules;
5310   for i in $withval; do
5311     STATIC_MODULES="$STATIC_MODULES -dlpreopen ../modules/rlm_$i/rlm_$i.la"
5312   done
5313
5314 fi
5315
5316
5317 USE_SHARED_LIBS=yes
5318
5319 # Check whether --with-shared-libs was given.
5320 if test "${with_shared_libs+set}" = set; then :
5321   withval=$with_shared_libs;  case "$withval" in
5322   no)
5323     USE_SHARED_LIBS=no
5324     ;;
5325   *)
5326   esac
5327
5328 fi
5329
5330
5331 MODULES=
5332
5333 # Check whether --with-modules was given.
5334 if test "${with_modules+set}" = set; then :
5335   withval=$with_modules;
5336  for i in $withval; do
5337    MODULES="$MODULES $i"
5338  done
5339
5340 fi
5341
5342
5343 EXPERIMENTAL=
5344
5345 # Check whether --with-experimental-modules was given.
5346 if test "${with_experimental_modules+set}" = set; then :
5347   withval=$with_experimental_modules;  case "$withval" in
5348   yes)
5349     EXPERIMENTAL=yes
5350     ;;
5351   no)
5352     EXPERIMENTAL=no
5353     ;;
5354   *)
5355   esac
5356
5357 fi
5358
5359
5360 WITH_UDPFROMTO=yes
5361
5362 # Check whether --with-udpfromto was given.
5363 if test "${with_udpfromto+set}" = set; then :
5364   withval=$with_udpfromto;  case "$withval" in
5365   yes)
5366     WITH_UDPFROMTO=yes
5367     ;;
5368   *)
5369     WITH_UDPFROMTO=no
5370   esac
5371
5372 fi
5373
5374
5375 if test "x$WITH_UDPFROMTO" = "xyes"; then
5376
5377 $as_echo "#define WITH_UDPFROMTO /**/" >>confdefs.h
5378
5379 fi
5380
5381
5382
5383 # Check whether --with-rlm-FOO-lib-dir was given.
5384 if test "${with_rlm_FOO_lib_dir+set}" = set; then :
5385   withval=$with_rlm_FOO_lib_dir;  case "$withval" in
5386   *)
5387     ;;
5388   esac
5389
5390 fi
5391
5392
5393
5394 # Check whether --with-rlm-FOO-include-dir was given.
5395 if test "${with_rlm_FOO_include_dir+set}" = set; then :
5396   withval=$with_rlm_FOO_include_dir;  case "$withval" in
5397   *)
5398     ;;
5399   esac
5400
5401 fi
5402
5403
5404 WITH_OPENSSL=yes
5405
5406 # Check whether --with-openssl was given.
5407 if test "${with_openssl+set}" = set; then :
5408   withval=$with_openssl;  case "$withval" in
5409   no)
5410     WITH_OPENSSL=no
5411     ;;
5412   *)
5413     WITH_OPENSSL=yes
5414     ;;
5415   esac
5416
5417 fi
5418
5419
5420 openssl_lib_dir=
5421
5422 # Check whether --with-openssl-lib-dir was given.
5423 if test "${with_openssl_lib_dir+set}" = set; then :
5424   withval=$with_openssl_lib_dir;  case "$withval" in
5425   *) openssl_lib_dir="$withval"
5426     ;;
5427   esac
5428
5429 fi
5430
5431
5432 openssl_include_dir=
5433
5434 # Check whether --with-openssl-include-dir was given.
5435 if test "${with_openssl_include_dir+set}" = set; then :
5436   withval=$with_openssl_include_dir;  case "$withval" in
5437   *) openssl_include_dir="$withval"
5438     ;;
5439   esac
5440
5441 fi
5442
5443
5444 # Check whether --enable-openssl-version-check was given.
5445 if test "${enable_openssl_version_check+set}" = set; then :
5446   enableval=$enable_openssl_version_check;
5447 fi
5448
5449 if test "x$enable_openssl_version_check" != "xno"; then
5450
5451 $as_echo "#define ENABLE_OPENSSL_VERSION_CHECK 1" >>confdefs.h
5452
5453   openssl_version_check_config="\
5454         #
5455         #  allow_vulnerable_openssl: Allow the server to start with
5456         #  versions of OpenSSL known to have critical vulnerabilities.
5457         #
5458         #  This check is based on the version number reported by libssl
5459         #  and may not reflect patches applied to libssl by
5460         #  distribution maintainers.
5461         #
5462         allow_vulnerable_openssl = no"
5463 else
5464   openssl_version_check_config=
5465 fi
5466
5467
5468
5469
5470 CHECKRAD=checkrad
5471 # Extract the first word of "perl", so it can be a program name with args.
5472 set dummy perl; ac_word=$2
5473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5474 $as_echo_n "checking for $ac_word... " >&6; }
5475 if ${ac_cv_path_PERL+:} false; then :
5476   $as_echo_n "(cached) " >&6
5477 else
5478   case $PERL in
5479   [\\/]* | ?:[\\/]*)
5480   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
5481   ;;
5482   *)
5483   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5484 for as_dir in $PATH
5485 do
5486   IFS=$as_save_IFS
5487   test -z "$as_dir" && as_dir=.
5488     for ac_exec_ext in '' $ac_executable_extensions; do
5489   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5490     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
5491     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5492     break 2
5493   fi
5494 done
5495   done
5496 IFS=$as_save_IFS
5497
5498   test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="/usr/local/bin/perl"
5499   ;;
5500 esac
5501 fi
5502 PERL=$ac_cv_path_PERL
5503 if test -n "$PERL"; then
5504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
5505 $as_echo "$PERL" >&6; }
5506 else
5507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5508 $as_echo "no" >&6; }
5509 fi
5510
5511
5512 if test "x$ac_cv_path_PERL" = "x"; then
5513   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: perl not found - Simultaneous-Use and checkrad may not work" >&5
5514 $as_echo "$as_me: WARNING: perl not found - Simultaneous-Use and checkrad may not work" >&2;}
5515 fi
5516 # Extract the first word of "snmpget", so it can be a program name with args.
5517 set dummy snmpget; ac_word=$2
5518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5519 $as_echo_n "checking for $ac_word... " >&6; }
5520 if ${ac_cv_path_SNMPGET+:} false; then :
5521   $as_echo_n "(cached) " >&6
5522 else
5523   case $SNMPGET in
5524   [\\/]* | ?:[\\/]*)
5525   ac_cv_path_SNMPGET="$SNMPGET" # Let the user override the test with a path.
5526   ;;
5527   *)
5528   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5529 for as_dir in $PATH
5530 do
5531   IFS=$as_save_IFS
5532   test -z "$as_dir" && as_dir=.
5533     for ac_exec_ext in '' $ac_executable_extensions; do
5534   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5535     ac_cv_path_SNMPGET="$as_dir/$ac_word$ac_exec_ext"
5536     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5537     break 2
5538   fi
5539 done
5540   done
5541 IFS=$as_save_IFS
5542
5543   ;;
5544 esac
5545 fi
5546 SNMPGET=$ac_cv_path_SNMPGET
5547 if test -n "$SNMPGET"; then
5548   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SNMPGET" >&5
5549 $as_echo "$SNMPGET" >&6; }
5550 else
5551   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5552 $as_echo "no" >&6; }
5553 fi
5554
5555
5556 if test "x$ac_cv_path_SNMPGET" = "x"; then
5557   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: snmpget not found - Simultaneous-Use and checkrad may not work" >&5
5558 $as_echo "$as_me: WARNING: snmpget not found - Simultaneous-Use and checkrad may not work" >&2;}
5559 fi
5560
5561 # Extract the first word of "snmpwalk", so it can be a program name with args.
5562 set dummy snmpwalk; ac_word=$2
5563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5564 $as_echo_n "checking for $ac_word... " >&6; }
5565 if ${ac_cv_path_SNMPWALK+:} false; then :
5566   $as_echo_n "(cached) " >&6
5567 else
5568   case $SNMPWALK in
5569   [\\/]* | ?:[\\/]*)
5570   ac_cv_path_SNMPWALK="$SNMPWALK" # Let the user override the test with a path.
5571   ;;
5572   *)
5573   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5574 for as_dir in $PATH
5575 do
5576   IFS=$as_save_IFS
5577   test -z "$as_dir" && as_dir=.
5578     for ac_exec_ext in '' $ac_executable_extensions; do
5579   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5580     ac_cv_path_SNMPWALK="$as_dir/$ac_word$ac_exec_ext"
5581     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5582     break 2
5583   fi
5584 done
5585   done
5586 IFS=$as_save_IFS
5587
5588   ;;
5589 esac
5590 fi
5591 SNMPWALK=$ac_cv_path_SNMPWALK
5592 if test -n "$SNMPWALK"; then
5593   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SNMPWALK" >&5
5594 $as_echo "$SNMPWALK" >&6; }
5595 else
5596   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5597 $as_echo "no" >&6; }
5598 fi
5599
5600
5601 if test "x$ac_cv_path_SNMPWALK" = "x"; then
5602   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: snmpwalk not found - Simultaneous-Use and checkrad may not work" >&5
5603 $as_echo "$as_me: WARNING: snmpwalk not found - Simultaneous-Use and checkrad may not work" >&2;}
5604 fi
5605
5606 # Extract the first word of "rusers", so it can be a program name with args.
5607 set dummy rusers; ac_word=$2
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5609 $as_echo_n "checking for $ac_word... " >&6; }
5610 if ${ac_cv_path_RUSERS+:} false; then :
5611   $as_echo_n "(cached) " >&6
5612 else
5613   case $RUSERS in
5614   [\\/]* | ?:[\\/]*)
5615   ac_cv_path_RUSERS="$RUSERS" # Let the user override the test with a path.
5616   ;;
5617   *)
5618   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5619 for as_dir in $PATH
5620 do
5621   IFS=$as_save_IFS
5622   test -z "$as_dir" && as_dir=.
5623     for ac_exec_ext in '' $ac_executable_extensions; do
5624   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5625     ac_cv_path_RUSERS="$as_dir/$ac_word$ac_exec_ext"
5626     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5627     break 2
5628   fi
5629 done
5630   done
5631 IFS=$as_save_IFS
5632
5633   test -z "$ac_cv_path_RUSERS" && ac_cv_path_RUSERS="/usr/bin/rusers"
5634   ;;
5635 esac
5636 fi
5637 RUSERS=$ac_cv_path_RUSERS
5638 if test -n "$RUSERS"; then
5639   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUSERS" >&5
5640 $as_echo "$RUSERS" >&6; }
5641 else
5642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5643 $as_echo "no" >&6; }
5644 fi
5645
5646
5647
5648 missing_dir=`cd $ac_aux_dir && pwd`
5649 # expand $ac_aux_dir to an absolute path
5650 am_aux_dir=`cd $ac_aux_dir && pwd`
5651
5652 if test x"${MISSING+set}" != xset; then
5653   case $am_aux_dir in
5654   *\ * | *\     *)
5655     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
5656   *)
5657     MISSING="\${SHELL} $am_aux_dir/missing" ;;
5658   esac
5659 fi
5660 # Use eval to expand $SHELL
5661 if eval "$MISSING --run true"; then
5662   am_missing_run="$MISSING --run "
5663 else
5664   am_missing_run=
5665   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
5666 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
5667 fi
5668
5669
5670 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal"}
5671
5672
5673 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
5674
5675
5676 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
5677
5678
5679 # Extract the first word of "locate", so it can be a program name with args.
5680 set dummy locate; ac_word=$2
5681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5682 $as_echo_n "checking for $ac_word... " >&6; }
5683 if ${ac_cv_path_LOCATE+:} false; then :
5684   $as_echo_n "(cached) " >&6
5685 else
5686   case $LOCATE in
5687   [\\/]* | ?:[\\/]*)
5688   ac_cv_path_LOCATE="$LOCATE" # Let the user override the test with a path.
5689   ;;
5690   *)
5691   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5692 for as_dir in $PATH
5693 do
5694   IFS=$as_save_IFS
5695   test -z "$as_dir" && as_dir=.
5696     for ac_exec_ext in '' $ac_executable_extensions; do
5697   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5698     ac_cv_path_LOCATE="$as_dir/$ac_word$ac_exec_ext"
5699     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5700     break 2
5701   fi
5702 done
5703   done
5704 IFS=$as_save_IFS
5705
5706   ;;
5707 esac
5708 fi
5709 LOCATE=$ac_cv_path_LOCATE
5710 if test -n "$LOCATE"; then
5711   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LOCATE" >&5
5712 $as_echo "$LOCATE" >&6; }
5713 else
5714   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5715 $as_echo "no" >&6; }
5716 fi
5717
5718
5719 # Extract the first word of "dirname", so it can be a program name with args.
5720 set dummy dirname; ac_word=$2
5721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5722 $as_echo_n "checking for $ac_word... " >&6; }
5723 if ${ac_cv_path_DIRNAME+:} false; then :
5724   $as_echo_n "(cached) " >&6
5725 else
5726   case $DIRNAME in
5727   [\\/]* | ?:[\\/]*)
5728   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
5729   ;;
5730   *)
5731   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5732 for as_dir in $PATH
5733 do
5734   IFS=$as_save_IFS
5735   test -z "$as_dir" && as_dir=.
5736     for ac_exec_ext in '' $ac_executable_extensions; do
5737   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5738     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
5739     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5740     break 2
5741   fi
5742 done
5743   done
5744 IFS=$as_save_IFS
5745
5746   ;;
5747 esac
5748 fi
5749 DIRNAME=$ac_cv_path_DIRNAME
5750 if test -n "$DIRNAME"; then
5751   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
5752 $as_echo "$DIRNAME" >&6; }
5753 else
5754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5755 $as_echo "no" >&6; }
5756 fi
5757
5758
5759 # Extract the first word of "grep", so it can be a program name with args.
5760 set dummy grep; ac_word=$2
5761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5762 $as_echo_n "checking for $ac_word... " >&6; }
5763 if ${ac_cv_path_GREP+:} false; then :
5764   $as_echo_n "(cached) " >&6
5765 else
5766   case $GREP in
5767   [\\/]* | ?:[\\/]*)
5768   ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
5769   ;;
5770   *)
5771   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5772 for as_dir in $PATH
5773 do
5774   IFS=$as_save_IFS
5775   test -z "$as_dir" && as_dir=.
5776     for ac_exec_ext in '' $ac_executable_extensions; do
5777   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5778     ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
5779     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5780     break 2
5781   fi
5782 done
5783   done
5784 IFS=$as_save_IFS
5785
5786   ;;
5787 esac
5788 fi
5789 GREP=$ac_cv_path_GREP
5790 if test -n "$GREP"; then
5791   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
5792 $as_echo "$GREP" >&6; }
5793 else
5794   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5795 $as_echo "no" >&6; }
5796 fi
5797
5798
5799
5800
5801 talloc_lib_dir=
5802
5803 # Check whether --with-talloc-lib-dir was given.
5804 if test "${with_talloc_lib_dir+set}" = set; then :
5805   withval=$with_talloc_lib_dir; case "$withval" in
5806     no)
5807       as_fn_error $? "Need talloc-lib-dir" "$LINENO" 5
5808       ;;
5809     yes)
5810       ;;
5811     *)
5812       talloc_lib_dir="$withval"
5813       ;;
5814   esac
5815 fi
5816
5817
5818 talloc_include_dir=
5819
5820 # Check whether --with-talloc-include-dir was given.
5821 if test "${with_talloc_include_dir+set}" = set; then :
5822   withval=$with_talloc_include_dir; case "$withval" in
5823     no)
5824       as_fn_error $? "Need talloc-include-dir" "$LINENO" 5
5825       ;;
5826     yes)
5827       ;;
5828     *)
5829       talloc_include_dir="$withval"
5830       ;;
5831   esac
5832 fi
5833
5834
5835 smart_try_dir="$talloc_lib_dir"
5836
5837
5838 sm_lib_safe=`echo "talloc" | sed 'y%./+-%__p_%'`
5839 sm_func_safe=`echo "_talloc" | sed 'y%./+-%__p_%'`
5840
5841 old_LIBS="$LIBS"
5842 old_CPPFLAGS="$CPPFLAGS"
5843 smart_lib=
5844 smart_ldflags=
5845 smart_lib_dir=
5846
5847 if test "x$smart_try_dir" != "x"; then
5848   for try in $smart_try_dir; do
5849     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _talloc in -ltalloc in $try" >&5
5850 $as_echo_n "checking for _talloc in -ltalloc in $try... " >&6; }
5851     LIBS="-ltalloc $old_LIBS"
5852     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
5853     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5854 /* end confdefs.h.  */
5855 extern char _talloc();
5856 int
5857 main ()
5858 {
5859 _talloc()
5860   ;
5861   return 0;
5862 }
5863 _ACEOF
5864 if ac_fn_c_try_link "$LINENO"; then :
5865
5866                  smart_lib="-ltalloc"
5867                  smart_ldflags="-L$try -Wl,-rpath,$try"
5868                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5869 $as_echo "yes" >&6; }
5870                  break
5871
5872 else
5873   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5874 $as_echo "no" >&6; }
5875 fi
5876 rm -f core conftest.err conftest.$ac_objext \
5877     conftest$ac_exeext conftest.$ac_ext
5878   done
5879   LIBS="$old_LIBS"
5880   CPPFLAGS="$old_CPPFLAGS"
5881 fi
5882
5883 if test "x$smart_lib" = "x"; then
5884   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _talloc in -ltalloc" >&5
5885 $as_echo_n "checking for _talloc in -ltalloc... " >&6; }
5886   LIBS="-ltalloc $old_LIBS"
5887   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5888 /* end confdefs.h.  */
5889 extern char _talloc();
5890 int
5891 main ()
5892 {
5893 _talloc()
5894   ;
5895   return 0;
5896 }
5897 _ACEOF
5898 if ac_fn_c_try_link "$LINENO"; then :
5899
5900                 smart_lib="-ltalloc"
5901                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5902 $as_echo "yes" >&6; }
5903
5904 else
5905   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5906 $as_echo "no" >&6; }
5907 fi
5908 rm -f core conftest.err conftest.$ac_objext \
5909     conftest$ac_exeext conftest.$ac_ext
5910   LIBS="$old_LIBS"
5911 fi
5912
5913 if test "x$smart_lib" = "x"; then
5914
5915
5916 if test "x$LOCATE" != "x"; then
5917         DIRS=
5918   file=libtalloc${libltdl_cv_shlibext}
5919
5920   for x in `${LOCATE} $file 2>/dev/null`; do
5921                                         base=`echo $x | sed "s%/${file}%%"`
5922     if test "x$x" = "x$base"; then
5923       continue;
5924     fi
5925
5926     dir=`${DIRNAME} $x 2>/dev/null`
5927                 exclude=`echo ${dir} | ${GREP} /home`
5928     if test "x$exclude" != "x"; then
5929       continue
5930     fi
5931
5932                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
5933     if test "x$already" = "x"; then
5934       DIRS="$DIRS $dir"
5935     fi
5936   done
5937 fi
5938
5939 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
5940
5941
5942
5943 if test "x$LOCATE" != "x"; then
5944         DIRS=
5945   file=libtalloc.a
5946
5947   for x in `${LOCATE} $file 2>/dev/null`; do
5948                                         base=`echo $x | sed "s%/${file}%%"`
5949     if test "x$x" = "x$base"; then
5950       continue;
5951     fi
5952
5953     dir=`${DIRNAME} $x 2>/dev/null`
5954                 exclude=`echo ${dir} | ${GREP} /home`
5955     if test "x$exclude" != "x"; then
5956       continue
5957     fi
5958
5959                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
5960     if test "x$already" = "x"; then
5961       DIRS="$DIRS $dir"
5962     fi
5963   done
5964 fi
5965
5966 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
5967
5968
5969   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
5970     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _talloc in -ltalloc in $try" >&5
5971 $as_echo_n "checking for _talloc in -ltalloc in $try... " >&6; }
5972     LIBS="-ltalloc $old_LIBS"
5973     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
5974     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5975 /* end confdefs.h.  */
5976 extern char _talloc();
5977 int
5978 main ()
5979 {
5980 _talloc()
5981   ;
5982   return 0;
5983 }
5984 _ACEOF
5985 if ac_fn_c_try_link "$LINENO"; then :
5986
5987                   smart_lib="-ltalloc"
5988                   smart_ldflags="-L$try -Wl,-rpath,$try"
5989                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5990 $as_echo "yes" >&6; }
5991                   break
5992
5993 else
5994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5995 $as_echo "no" >&6; }
5996 fi
5997 rm -f core conftest.err conftest.$ac_objext \
5998     conftest$ac_exeext conftest.$ac_ext
5999   done
6000   LIBS="$old_LIBS"
6001   CPPFLAGS="$old_CPPFLAGS"
6002 fi
6003
6004 if test "x$smart_lib" != "x"; then
6005   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
6006   LIBS="$smart_ldflags $smart_lib $old_LIBS"
6007   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
6008 fi
6009
6010 if test "x$ac_cv_lib_talloc__talloc" != "xyes"; then
6011   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: talloc library not found. Use --with-talloc-lib-dir=<path>." >&5
6012 $as_echo "$as_me: WARNING: talloc library not found. Use --with-talloc-lib-dir=<path>." >&2;}
6013   as_fn_error $? "FreeRADIUS requires libtalloc" "$LINENO" 5
6014 fi
6015
6016 TALLOC_LIBS="${smart_lib}"
6017 TALLOC_LDFLAGS="${smart_ldflags}"
6018
6019
6020 LIBS="$old_LIBS"
6021
6022 old_CFLAGS=$CFLAGS
6023 if test "x$WITH_THREADS" = "xyes"; then
6024   if test $ac_cv_prog_suncc = "yes"; then
6025     CFLAGS="$CFLAGS -mt"
6026   fi
6027
6028   for ac_header in pthread.h
6029 do :
6030   ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
6031 if test "x$ac_cv_header_pthread_h" = xyes; then :
6032   cat >>confdefs.h <<_ACEOF
6033 #define HAVE_PTHREAD_H 1
6034 _ACEOF
6035
6036 else
6037
6038       WITH_THREADS="no"
6039       fail=pthread.h
6040
6041 fi
6042
6043 done
6044
6045
6046                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
6047 $as_echo_n "checking for pthread_create in -lpthread... " >&6; }
6048 if ${ac_cv_lib_pthread_pthread_create+:} false; then :
6049   $as_echo_n "(cached) " >&6
6050 else
6051   ac_check_lib_save_LIBS=$LIBS
6052 LIBS="-lpthread  $LIBS"
6053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6054 /* end confdefs.h.  */
6055
6056 /* Override any GCC internal prototype to avoid an error.
6057    Use char because int might match the return type of a GCC
6058    builtin and then its argument prototype would still apply.  */
6059 #ifdef __cplusplus
6060 extern "C"
6061 #endif
6062 char pthread_create ();
6063 int
6064 main ()
6065 {
6066 return pthread_create ();
6067   ;
6068   return 0;
6069 }
6070 _ACEOF
6071 if ac_fn_c_try_link "$LINENO"; then :
6072   ac_cv_lib_pthread_pthread_create=yes
6073 else
6074   ac_cv_lib_pthread_pthread_create=no
6075 fi
6076 rm -f core conftest.err conftest.$ac_objext \
6077     conftest$ac_exeext conftest.$ac_ext
6078 LIBS=$ac_check_lib_save_LIBS
6079 fi
6080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
6081 $as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
6082 if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then :
6083
6084       CFLAGS="$CFLAGS -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS"
6085       LIBS="-lpthread $LIBS"
6086
6087 else
6088
6089                               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5
6090 $as_echo_n "checking for pthread_create in -lc_r... " >&6; }
6091 if ${ac_cv_lib_c_r_pthread_create+:} false; then :
6092   $as_echo_n "(cached) " >&6
6093 else
6094   ac_check_lib_save_LIBS=$LIBS
6095 LIBS="-lc_r  $LIBS"
6096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6097 /* end confdefs.h.  */
6098
6099 /* Override any GCC internal prototype to avoid an error.
6100    Use char because int might match the return type of a GCC
6101    builtin and then its argument prototype would still apply.  */
6102 #ifdef __cplusplus
6103 extern "C"
6104 #endif
6105 char pthread_create ();
6106 int
6107 main ()
6108 {
6109 return pthread_create ();
6110   ;
6111   return 0;
6112 }
6113 _ACEOF
6114 if ac_fn_c_try_link "$LINENO"; then :
6115   ac_cv_lib_c_r_pthread_create=yes
6116 else
6117   ac_cv_lib_c_r_pthread_create=no
6118 fi
6119 rm -f core conftest.err conftest.$ac_objext \
6120     conftest$ac_exeext conftest.$ac_ext
6121 LIBS=$ac_check_lib_save_LIBS
6122 fi
6123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5
6124 $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; }
6125 if test "x$ac_cv_lib_c_r_pthread_create" = xyes; then :
6126    CFLAGS="$CFLAGS -pthread -D_THREAD_SAFE"
6127 else
6128
6129           WITH_THREADS="no"
6130           fail=-lpthread
6131
6132
6133 fi
6134
6135
6136
6137 fi
6138
6139
6140   if test "x$WITH_THREADS" != "xyes"; then
6141     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: silently not building with thread support." >&5
6142 $as_echo "$as_me: WARNING: silently not building with thread support." >&2;}
6143     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: FAILURE: thread support requires: $fail." >&5
6144 $as_echo "$as_me: WARNING: FAILURE: thread support requires: $fail." >&2;}
6145   else
6146
6147 $as_echo "#define WITH_THREADS 1" >>confdefs.h
6148
6149   fi
6150 fi
6151
6152 if test "x$WITH_THREADS" != "xyes"; then
6153   CFLAGS=$old_CFLAGS
6154   ac_cv_header_pthread_h="no"
6155   WITH_THREADS=no
6156 else
6157
6158   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
6159 $as_echo_n "checking for library containing sem_init... " >&6; }
6160 if ${ac_cv_search_sem_init+:} false; then :
6161   $as_echo_n "(cached) " >&6
6162 else
6163   ac_func_search_save_LIBS=$LIBS
6164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6165 /* end confdefs.h.  */
6166
6167 /* Override any GCC internal prototype to avoid an error.
6168    Use char because int might match the return type of a GCC
6169    builtin and then its argument prototype would still apply.  */
6170 #ifdef __cplusplus
6171 extern "C"
6172 #endif
6173 char sem_init ();
6174 int
6175 main ()
6176 {
6177 return sem_init ();
6178   ;
6179   return 0;
6180 }
6181 _ACEOF
6182 for ac_lib in '' pthread sem posix4 rt semaphore; do
6183   if test -z "$ac_lib"; then
6184     ac_res="none required"
6185   else
6186     ac_res=-l$ac_lib
6187     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6188   fi
6189   if ac_fn_c_try_link "$LINENO"; then :
6190   ac_cv_search_sem_init=$ac_res
6191 fi
6192 rm -f core conftest.err conftest.$ac_objext \
6193     conftest$ac_exeext
6194   if ${ac_cv_search_sem_init+:} false; then :
6195   break
6196 fi
6197 done
6198 if ${ac_cv_search_sem_init+:} false; then :
6199
6200 else
6201   ac_cv_search_sem_init=no
6202 fi
6203 rm conftest.$ac_ext
6204 LIBS=$ac_func_search_save_LIBS
6205 fi
6206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
6207 $as_echo "$ac_cv_search_sem_init" >&6; }
6208 ac_res=$ac_cv_search_sem_init
6209 if test "$ac_res" != no; then :
6210   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6211
6212 else
6213   as_fn_error $? "-lsem not found.  You may want to download it from ftp://ftp.to.gd-es.com/pub/BSDI/libsem.tar.bz2 or ftp://ftp.freeradius.org/pub/radius/contrib/libsem.tar.gz" "$LINENO" 5
6214
6215 fi
6216
6217 fi
6218
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
6220 $as_echo_n "checking for dlopen in -ldl... " >&6; }
6221 if ${ac_cv_lib_dl_dlopen+:} false; then :
6222   $as_echo_n "(cached) " >&6
6223 else
6224   ac_check_lib_save_LIBS=$LIBS
6225 LIBS="-ldl  $LIBS"
6226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6227 /* end confdefs.h.  */
6228
6229 /* Override any GCC internal prototype to avoid an error.
6230    Use char because int might match the return type of a GCC
6231    builtin and then its argument prototype would still apply.  */
6232 #ifdef __cplusplus
6233 extern "C"
6234 #endif
6235 char dlopen ();
6236 int
6237 main ()
6238 {
6239 return dlopen ();
6240   ;
6241   return 0;
6242 }
6243 _ACEOF
6244 if ac_fn_c_try_link "$LINENO"; then :
6245   ac_cv_lib_dl_dlopen=yes
6246 else
6247   ac_cv_lib_dl_dlopen=no
6248 fi
6249 rm -f core conftest.err conftest.$ac_objext \
6250     conftest$ac_exeext conftest.$ac_ext
6251 LIBS=$ac_check_lib_save_LIBS
6252 fi
6253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
6254 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
6255 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
6256   cat >>confdefs.h <<_ACEOF
6257 #define HAVE_LIBDL 1
6258 _ACEOF
6259
6260   LIBS="-ldl $LIBS"
6261
6262 fi
6263
6264
6265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getsockname in -lsocket" >&5
6266 $as_echo_n "checking for getsockname in -lsocket... " >&6; }
6267 if ${ac_cv_lib_socket_getsockname+:} false; then :
6268   $as_echo_n "(cached) " >&6
6269 else
6270   ac_check_lib_save_LIBS=$LIBS
6271 LIBS="-lsocket  $LIBS"
6272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6273 /* end confdefs.h.  */
6274
6275 /* Override any GCC internal prototype to avoid an error.
6276    Use char because int might match the return type of a GCC
6277    builtin and then its argument prototype would still apply.  */
6278 #ifdef __cplusplus
6279 extern "C"
6280 #endif
6281 char getsockname ();
6282 int
6283 main ()
6284 {
6285 return getsockname ();
6286   ;
6287   return 0;
6288 }
6289 _ACEOF
6290 if ac_fn_c_try_link "$LINENO"; then :
6291   ac_cv_lib_socket_getsockname=yes
6292 else
6293   ac_cv_lib_socket_getsockname=no
6294 fi
6295 rm -f core conftest.err conftest.$ac_objext \
6296     conftest$ac_exeext conftest.$ac_ext
6297 LIBS=$ac_check_lib_save_LIBS
6298 fi
6299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getsockname" >&5
6300 $as_echo "$ac_cv_lib_socket_getsockname" >&6; }
6301 if test "x$ac_cv_lib_socket_getsockname" = xyes; then :
6302   cat >>confdefs.h <<_ACEOF
6303 #define HAVE_LIBSOCKET 1
6304 _ACEOF
6305
6306   LIBS="-lsocket $LIBS"
6307
6308 fi
6309
6310
6311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5
6312 $as_echo_n "checking for inet_aton in -lresolv... " >&6; }
6313 if ${ac_cv_lib_resolv_inet_aton+:} false; then :
6314   $as_echo_n "(cached) " >&6
6315 else
6316   ac_check_lib_save_LIBS=$LIBS
6317 LIBS="-lresolv  $LIBS"
6318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6319 /* end confdefs.h.  */
6320
6321 /* Override any GCC internal prototype to avoid an error.
6322    Use char because int might match the return type of a GCC
6323    builtin and then its argument prototype would still apply.  */
6324 #ifdef __cplusplus
6325 extern "C"
6326 #endif
6327 char inet_aton ();
6328 int
6329 main ()
6330 {
6331 return inet_aton ();
6332   ;
6333   return 0;
6334 }
6335 _ACEOF
6336 if ac_fn_c_try_link "$LINENO"; then :
6337   ac_cv_lib_resolv_inet_aton=yes
6338 else
6339   ac_cv_lib_resolv_inet_aton=no
6340 fi
6341 rm -f core conftest.err conftest.$ac_objext \
6342     conftest$ac_exeext conftest.$ac_ext
6343 LIBS=$ac_check_lib_save_LIBS
6344 fi
6345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5
6346 $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; }
6347 if test "x$ac_cv_lib_resolv_inet_aton" = xyes; then :
6348   cat >>confdefs.h <<_ACEOF
6349 #define HAVE_LIBRESOLV 1
6350 _ACEOF
6351
6352   LIBS="-lresolv $LIBS"
6353
6354 fi
6355
6356
6357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lnsl" >&5
6358 $as_echo_n "checking for inet_ntoa in -lnsl... " >&6; }
6359 if ${ac_cv_lib_nsl_inet_ntoa+:} false; then :
6360   $as_echo_n "(cached) " >&6
6361 else
6362   ac_check_lib_save_LIBS=$LIBS
6363 LIBS="-lnsl  $LIBS"
6364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6365 /* end confdefs.h.  */
6366
6367 /* Override any GCC internal prototype to avoid an error.
6368    Use char because int might match the return type of a GCC
6369    builtin and then its argument prototype would still apply.  */
6370 #ifdef __cplusplus
6371 extern "C"
6372 #endif
6373 char inet_ntoa ();
6374 int
6375 main ()
6376 {
6377 return inet_ntoa ();
6378   ;
6379   return 0;
6380 }
6381 _ACEOF
6382 if ac_fn_c_try_link "$LINENO"; then :
6383   ac_cv_lib_nsl_inet_ntoa=yes
6384 else
6385   ac_cv_lib_nsl_inet_ntoa=no
6386 fi
6387 rm -f core conftest.err conftest.$ac_objext \
6388     conftest$ac_exeext conftest.$ac_ext
6389 LIBS=$ac_check_lib_save_LIBS
6390 fi
6391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_inet_ntoa" >&5
6392 $as_echo "$ac_cv_lib_nsl_inet_ntoa" >&6; }
6393 if test "x$ac_cv_lib_nsl_inet_ntoa" = xyes; then :
6394   cat >>confdefs.h <<_ACEOF
6395 #define HAVE_LIBNSL 1
6396 _ACEOF
6397
6398   LIBS="-lnsl $LIBS"
6399
6400 fi
6401
6402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htonl in -lws2_32" >&5
6403 $as_echo_n "checking for htonl in -lws2_32... " >&6; }
6404 if ${ac_cv_lib_ws2_32_htonl+:} false; then :
6405   $as_echo_n "(cached) " >&6
6406 else
6407   ac_check_lib_save_LIBS=$LIBS
6408 LIBS="-lws2_32  $LIBS"
6409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6410 /* end confdefs.h.  */
6411
6412 /* Override any GCC internal prototype to avoid an error.
6413    Use char because int might match the return type of a GCC
6414    builtin and then its argument prototype would still apply.  */
6415 #ifdef __cplusplus
6416 extern "C"
6417 #endif
6418 char htonl ();
6419 int
6420 main ()
6421 {
6422 return htonl ();
6423   ;
6424   return 0;
6425 }
6426 _ACEOF
6427 if ac_fn_c_try_link "$LINENO"; then :
6428   ac_cv_lib_ws2_32_htonl=yes
6429 else
6430   ac_cv_lib_ws2_32_htonl=no
6431 fi
6432 rm -f core conftest.err conftest.$ac_objext \
6433     conftest$ac_exeext conftest.$ac_ext
6434 LIBS=$ac_check_lib_save_LIBS
6435 fi
6436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ws2_32_htonl" >&5
6437 $as_echo "$ac_cv_lib_ws2_32_htonl" >&6; }
6438 if test "x$ac_cv_lib_ws2_32_htonl" = xyes; then :
6439   cat >>confdefs.h <<_ACEOF
6440 #define HAVE_LIBWS2_32 1
6441 _ACEOF
6442
6443   LIBS="-lws2_32 $LIBS"
6444
6445 fi
6446
6447
6448 pcap_lib_dir=
6449
6450 # Check whether --with-pcap-lib-dir was given.
6451 if test "${with_pcap_lib_dir+set}" = set; then :
6452   withval=$with_pcap_lib_dir; case "$withval" in
6453     no)
6454       as_fn_error $? "Need pcap-lib-dir" "$LINENO" 5
6455       ;;
6456     yes)
6457       ;;
6458     *)
6459       pcap_lib_dir="$withval"
6460       ;;
6461   esac
6462 fi
6463
6464
6465 pcap_include_dir=
6466
6467 # Check whether --with-pcap-include-dir was given.
6468 if test "${with_pcap_include_dir+set}" = set; then :
6469   withval=$with_pcap_include_dir; case "$withval" in
6470     no)
6471       as_fn_error $? "Need pcap-include-dir" "$LINENO" 5
6472       ;;
6473     yes)
6474       ;;
6475     *)
6476       pcap_include_dir="$withval"
6477       ;;
6478   esac
6479 fi
6480
6481
6482 smart_try_dir="$pcap_lib_dir"
6483
6484
6485 sm_lib_safe=`echo "pcap" | sed 'y%./+-%__p_%'`
6486 sm_func_safe=`echo "pcap_open_live" | sed 'y%./+-%__p_%'`
6487
6488 old_LIBS="$LIBS"
6489 old_CPPFLAGS="$CPPFLAGS"
6490 smart_lib=
6491 smart_ldflags=
6492 smart_lib_dir=
6493
6494 if test "x$smart_try_dir" != "x"; then
6495   for try in $smart_try_dir; do
6496     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap_open_live in -lpcap in $try" >&5
6497 $as_echo_n "checking for pcap_open_live in -lpcap in $try... " >&6; }
6498     LIBS="-lpcap $old_LIBS"
6499     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
6500     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6501 /* end confdefs.h.  */
6502 extern char pcap_open_live();
6503 int
6504 main ()
6505 {
6506 pcap_open_live()
6507   ;
6508   return 0;
6509 }
6510 _ACEOF
6511 if ac_fn_c_try_link "$LINENO"; then :
6512
6513                  smart_lib="-lpcap"
6514                  smart_ldflags="-L$try -Wl,-rpath,$try"
6515                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6516 $as_echo "yes" >&6; }
6517                  break
6518
6519 else
6520   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6521 $as_echo "no" >&6; }
6522 fi
6523 rm -f core conftest.err conftest.$ac_objext \
6524     conftest$ac_exeext conftest.$ac_ext
6525   done
6526   LIBS="$old_LIBS"
6527   CPPFLAGS="$old_CPPFLAGS"
6528 fi
6529
6530 if test "x$smart_lib" = "x"; then
6531   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap_open_live in -lpcap" >&5
6532 $as_echo_n "checking for pcap_open_live in -lpcap... " >&6; }
6533   LIBS="-lpcap $old_LIBS"
6534   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6535 /* end confdefs.h.  */
6536 extern char pcap_open_live();
6537 int
6538 main ()
6539 {
6540 pcap_open_live()
6541   ;
6542   return 0;
6543 }
6544 _ACEOF
6545 if ac_fn_c_try_link "$LINENO"; then :
6546
6547                 smart_lib="-lpcap"
6548                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6549 $as_echo "yes" >&6; }
6550
6551 else
6552   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6553 $as_echo "no" >&6; }
6554 fi
6555 rm -f core conftest.err conftest.$ac_objext \
6556     conftest$ac_exeext conftest.$ac_ext
6557   LIBS="$old_LIBS"
6558 fi
6559
6560 if test "x$smart_lib" = "x"; then
6561
6562
6563 if test "x$LOCATE" != "x"; then
6564         DIRS=
6565   file=libpcap${libltdl_cv_shlibext}
6566
6567   for x in `${LOCATE} $file 2>/dev/null`; do
6568                                         base=`echo $x | sed "s%/${file}%%"`
6569     if test "x$x" = "x$base"; then
6570       continue;
6571     fi
6572
6573     dir=`${DIRNAME} $x 2>/dev/null`
6574                 exclude=`echo ${dir} | ${GREP} /home`
6575     if test "x$exclude" != "x"; then
6576       continue
6577     fi
6578
6579                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
6580     if test "x$already" = "x"; then
6581       DIRS="$DIRS $dir"
6582     fi
6583   done
6584 fi
6585
6586 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
6587
6588
6589
6590 if test "x$LOCATE" != "x"; then
6591         DIRS=
6592   file=libpcap.a
6593
6594   for x in `${LOCATE} $file 2>/dev/null`; do
6595                                         base=`echo $x | sed "s%/${file}%%"`
6596     if test "x$x" = "x$base"; then
6597       continue;
6598     fi
6599
6600     dir=`${DIRNAME} $x 2>/dev/null`
6601                 exclude=`echo ${dir} | ${GREP} /home`
6602     if test "x$exclude" != "x"; then
6603       continue
6604     fi
6605
6606                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
6607     if test "x$already" = "x"; then
6608       DIRS="$DIRS $dir"
6609     fi
6610   done
6611 fi
6612
6613 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
6614
6615
6616   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
6617     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap_open_live in -lpcap in $try" >&5
6618 $as_echo_n "checking for pcap_open_live in -lpcap in $try... " >&6; }
6619     LIBS="-lpcap $old_LIBS"
6620     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
6621     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6622 /* end confdefs.h.  */
6623 extern char pcap_open_live();
6624 int
6625 main ()
6626 {
6627 pcap_open_live()
6628   ;
6629   return 0;
6630 }
6631 _ACEOF
6632 if ac_fn_c_try_link "$LINENO"; then :
6633
6634                   smart_lib="-lpcap"
6635                   smart_ldflags="-L$try -Wl,-rpath,$try"
6636                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6637 $as_echo "yes" >&6; }
6638                   break
6639
6640 else
6641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6642 $as_echo "no" >&6; }
6643 fi
6644 rm -f core conftest.err conftest.$ac_objext \
6645     conftest$ac_exeext conftest.$ac_ext
6646   done
6647   LIBS="$old_LIBS"
6648   CPPFLAGS="$old_CPPFLAGS"
6649 fi
6650
6651 if test "x$smart_lib" != "x"; then
6652   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
6653   LIBS="$smart_ldflags $smart_lib $old_LIBS"
6654   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
6655 fi
6656
6657 if test "x$ac_cv_lib_pcap_pcap_open_live" != "xyes"; then
6658   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcap library not found, silently disabling the RADIUS sniffer, and ARP listener.  Use --with-pcap-lib-dir=<path>." >&5
6659 $as_echo "$as_me: WARNING: pcap library not found, silently disabling the RADIUS sniffer, and ARP listener.  Use --with-pcap-lib-dir=<path>." >&2;}
6660 else
6661
6662 $as_echo "#define HAVE_LIBPCAP 1" >>confdefs.h
6663
6664
6665   for ac_func in \
6666     pcap_fopen_offline \
6667     pcap_dump_fopen \
6668     pcap_create \
6669     pcap_activate
6670
6671 do :
6672   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6673 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6674 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6675   cat >>confdefs.h <<_ACEOF
6676 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6677 _ACEOF
6678
6679 fi
6680 done
6681
6682
6683   PCAP_LIBS="${smart_lib}"
6684   PCAP_LDFLAGS="${smart_ldflags}"
6685 fi
6686 LIBS="${old_LIBS}"
6687
6688 collectdclient_lib_dir=
6689
6690 # Check whether --with-collectdclient-lib-dir was given.
6691 if test "${with_collectdclient_lib_dir+set}" = set; then :
6692   withval=$with_collectdclient_lib_dir; case "$withval" in
6693     no)
6694       as_fn_error $? "Need collectdclient-lib-dir" "$LINENO" 5
6695       ;;
6696     yes)
6697       ;;
6698     *)
6699       collectdclient_lib_dir="$withval"
6700       ;;
6701   esac
6702 fi
6703
6704
6705 collectdclient_include_dir=
6706
6707 # Check whether --with-collectdclient-include-dir was given.
6708 if test "${with_collectdclient_include_dir+set}" = set; then :
6709   withval=$with_collectdclient_include_dir; case "$withval" in
6710     no)
6711       as_fn_error $? "Need collectdclient-include-dir" "$LINENO" 5
6712       ;;
6713     yes)
6714       ;;
6715     *)
6716       collectdclient_include_dir="$withval"
6717       ;;
6718   esac
6719 fi
6720
6721
6722 smart_try_dir="$collectdclient_lib_dir"
6723
6724
6725 sm_lib_safe=`echo "collectdclient" | sed 'y%./+-%__p_%'`
6726 sm_func_safe=`echo "lcc_connect" | sed 'y%./+-%__p_%'`
6727
6728 old_LIBS="$LIBS"
6729 old_CPPFLAGS="$CPPFLAGS"
6730 smart_lib=
6731 smart_ldflags=
6732 smart_lib_dir=
6733
6734 if test "x$smart_try_dir" != "x"; then
6735   for try in $smart_try_dir; do
6736     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lcc_connect in -lcollectdclient in $try" >&5
6737 $as_echo_n "checking for lcc_connect in -lcollectdclient in $try... " >&6; }
6738     LIBS="-lcollectdclient $old_LIBS"
6739     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
6740     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6741 /* end confdefs.h.  */
6742 extern char lcc_connect();
6743 int
6744 main ()
6745 {
6746 lcc_connect()
6747   ;
6748   return 0;
6749 }
6750 _ACEOF
6751 if ac_fn_c_try_link "$LINENO"; then :
6752
6753                  smart_lib="-lcollectdclient"
6754                  smart_ldflags="-L$try -Wl,-rpath,$try"
6755                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6756 $as_echo "yes" >&6; }
6757                  break
6758
6759 else
6760   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6761 $as_echo "no" >&6; }
6762 fi
6763 rm -f core conftest.err conftest.$ac_objext \
6764     conftest$ac_exeext conftest.$ac_ext
6765   done
6766   LIBS="$old_LIBS"
6767   CPPFLAGS="$old_CPPFLAGS"
6768 fi
6769
6770 if test "x$smart_lib" = "x"; then
6771   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lcc_connect in -lcollectdclient" >&5
6772 $as_echo_n "checking for lcc_connect in -lcollectdclient... " >&6; }
6773   LIBS="-lcollectdclient $old_LIBS"
6774   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6775 /* end confdefs.h.  */
6776 extern char lcc_connect();
6777 int
6778 main ()
6779 {
6780 lcc_connect()
6781   ;
6782   return 0;
6783 }
6784 _ACEOF
6785 if ac_fn_c_try_link "$LINENO"; then :
6786
6787                 smart_lib="-lcollectdclient"
6788                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6789 $as_echo "yes" >&6; }
6790
6791 else
6792   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6793 $as_echo "no" >&6; }
6794 fi
6795 rm -f core conftest.err conftest.$ac_objext \
6796     conftest$ac_exeext conftest.$ac_ext
6797   LIBS="$old_LIBS"
6798 fi
6799
6800 if test "x$smart_lib" = "x"; then
6801
6802
6803 if test "x$LOCATE" != "x"; then
6804         DIRS=
6805   file=libcollectdclient${libltdl_cv_shlibext}
6806
6807   for x in `${LOCATE} $file 2>/dev/null`; do
6808                                         base=`echo $x | sed "s%/${file}%%"`
6809     if test "x$x" = "x$base"; then
6810       continue;
6811     fi
6812
6813     dir=`${DIRNAME} $x 2>/dev/null`
6814                 exclude=`echo ${dir} | ${GREP} /home`
6815     if test "x$exclude" != "x"; then
6816       continue
6817     fi
6818
6819                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
6820     if test "x$already" = "x"; then
6821       DIRS="$DIRS $dir"
6822     fi
6823   done
6824 fi
6825
6826 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
6827
6828
6829
6830 if test "x$LOCATE" != "x"; then
6831         DIRS=
6832   file=libcollectdclient.a
6833
6834   for x in `${LOCATE} $file 2>/dev/null`; do
6835                                         base=`echo $x | sed "s%/${file}%%"`
6836     if test "x$x" = "x$base"; then
6837       continue;
6838     fi
6839
6840     dir=`${DIRNAME} $x 2>/dev/null`
6841                 exclude=`echo ${dir} | ${GREP} /home`
6842     if test "x$exclude" != "x"; then
6843       continue
6844     fi
6845
6846                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
6847     if test "x$already" = "x"; then
6848       DIRS="$DIRS $dir"
6849     fi
6850   done
6851 fi
6852
6853 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
6854
6855
6856   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
6857     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lcc_connect in -lcollectdclient in $try" >&5
6858 $as_echo_n "checking for lcc_connect in -lcollectdclient in $try... " >&6; }
6859     LIBS="-lcollectdclient $old_LIBS"
6860     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
6861     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6862 /* end confdefs.h.  */
6863 extern char lcc_connect();
6864 int
6865 main ()
6866 {
6867 lcc_connect()
6868   ;
6869   return 0;
6870 }
6871 _ACEOF
6872 if ac_fn_c_try_link "$LINENO"; then :
6873
6874                   smart_lib="-lcollectdclient"
6875                   smart_ldflags="-L$try -Wl,-rpath,$try"
6876                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6877 $as_echo "yes" >&6; }
6878                   break
6879
6880 else
6881   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6882 $as_echo "no" >&6; }
6883 fi
6884 rm -f core conftest.err conftest.$ac_objext \
6885     conftest$ac_exeext conftest.$ac_ext
6886   done
6887   LIBS="$old_LIBS"
6888   CPPFLAGS="$old_CPPFLAGS"
6889 fi
6890
6891 if test "x$smart_lib" != "x"; then
6892   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
6893   LIBS="$smart_ldflags $smart_lib $old_LIBS"
6894   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
6895 fi
6896
6897 if test "x$ac_cv_lib_collectdclient_lcc_connect" != "xyes"; then
6898   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: collectdclient library not found. Use --with-collectdclient-lib-dir=<path>." >&5
6899 $as_echo "$as_me: WARNING: collectdclient library not found. Use --with-collectdclient-lib-dir=<path>." >&2;}
6900 else
6901   COLLECTDC_LIBS="${smart_lib}"
6902   COLLECTDC_LDFLAGS="${smart_ldflags}"
6903 fi
6904 LIBS="${old_LIBS}"
6905
6906 cap_lib_dir=
6907
6908 # Check whether --with-cap-lib-dir was given.
6909 if test "${with_cap_lib_dir+set}" = set; then :
6910   withval=$with_cap_lib_dir; case "$withval" in
6911     no)
6912       as_fn_error $? "Need cap-lib-dir" "$LINENO" 5
6913       ;;
6914     yes)
6915       ;;
6916     *)
6917       cap_lib_dir="$withval"
6918       ;;
6919   esac
6920 fi
6921
6922
6923 cap_include_dir=
6924
6925 # Check whether --with-cap-include-dir was given.
6926 if test "${with_cap_include_dir+set}" = set; then :
6927   withval=$with_cap_include_dir; case "$withval" in
6928     no)
6929       as_fn_error $? "Need cap-include-dir" "$LINENO" 5
6930       ;;
6931     yes)
6932       ;;
6933     *)
6934       cap_include_dir="$withval"
6935       ;;
6936   esac
6937 fi
6938
6939
6940 smart_try_dir="$cap_lib_dir"
6941
6942
6943 sm_lib_safe=`echo "cap" | sed 'y%./+-%__p_%'`
6944 sm_func_safe=`echo "cap_get_proc" | sed 'y%./+-%__p_%'`
6945
6946 old_LIBS="$LIBS"
6947 old_CPPFLAGS="$CPPFLAGS"
6948 smart_lib=
6949 smart_ldflags=
6950 smart_lib_dir=
6951
6952 if test "x$smart_try_dir" != "x"; then
6953   for try in $smart_try_dir; do
6954     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cap_get_proc in -lcap in $try" >&5
6955 $as_echo_n "checking for cap_get_proc in -lcap in $try... " >&6; }
6956     LIBS="-lcap $old_LIBS"
6957     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
6958     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6959 /* end confdefs.h.  */
6960 extern char cap_get_proc();
6961 int
6962 main ()
6963 {
6964 cap_get_proc()
6965   ;
6966   return 0;
6967 }
6968 _ACEOF
6969 if ac_fn_c_try_link "$LINENO"; then :
6970
6971                  smart_lib="-lcap"
6972                  smart_ldflags="-L$try -Wl,-rpath,$try"
6973                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6974 $as_echo "yes" >&6; }
6975                  break
6976
6977 else
6978   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6979 $as_echo "no" >&6; }
6980 fi
6981 rm -f core conftest.err conftest.$ac_objext \
6982     conftest$ac_exeext conftest.$ac_ext
6983   done
6984   LIBS="$old_LIBS"
6985   CPPFLAGS="$old_CPPFLAGS"
6986 fi
6987
6988 if test "x$smart_lib" = "x"; then
6989   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cap_get_proc in -lcap" >&5
6990 $as_echo_n "checking for cap_get_proc in -lcap... " >&6; }
6991   LIBS="-lcap $old_LIBS"
6992   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6993 /* end confdefs.h.  */
6994 extern char cap_get_proc();
6995 int
6996 main ()
6997 {
6998 cap_get_proc()
6999   ;
7000   return 0;
7001 }
7002 _ACEOF
7003 if ac_fn_c_try_link "$LINENO"; then :
7004
7005                 smart_lib="-lcap"
7006                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7007 $as_echo "yes" >&6; }
7008
7009 else
7010   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7011 $as_echo "no" >&6; }
7012 fi
7013 rm -f core conftest.err conftest.$ac_objext \
7014     conftest$ac_exeext conftest.$ac_ext
7015   LIBS="$old_LIBS"
7016 fi
7017
7018 if test "x$smart_lib" = "x"; then
7019
7020
7021 if test "x$LOCATE" != "x"; then
7022         DIRS=
7023   file=libcap${libltdl_cv_shlibext}
7024
7025   for x in `${LOCATE} $file 2>/dev/null`; do
7026                                         base=`echo $x | sed "s%/${file}%%"`
7027     if test "x$x" = "x$base"; then
7028       continue;
7029     fi
7030
7031     dir=`${DIRNAME} $x 2>/dev/null`
7032                 exclude=`echo ${dir} | ${GREP} /home`
7033     if test "x$exclude" != "x"; then
7034       continue
7035     fi
7036
7037                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
7038     if test "x$already" = "x"; then
7039       DIRS="$DIRS $dir"
7040     fi
7041   done
7042 fi
7043
7044 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
7045
7046
7047
7048 if test "x$LOCATE" != "x"; then
7049         DIRS=
7050   file=libcap.a
7051
7052   for x in `${LOCATE} $file 2>/dev/null`; do
7053                                         base=`echo $x | sed "s%/${file}%%"`
7054     if test "x$x" = "x$base"; then
7055       continue;
7056     fi
7057
7058     dir=`${DIRNAME} $x 2>/dev/null`
7059                 exclude=`echo ${dir} | ${GREP} /home`
7060     if test "x$exclude" != "x"; then
7061       continue
7062     fi
7063
7064                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
7065     if test "x$already" = "x"; then
7066       DIRS="$DIRS $dir"
7067     fi
7068   done
7069 fi
7070
7071 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
7072
7073
7074   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
7075     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cap_get_proc in -lcap in $try" >&5
7076 $as_echo_n "checking for cap_get_proc in -lcap in $try... " >&6; }
7077     LIBS="-lcap $old_LIBS"
7078     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
7079     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7080 /* end confdefs.h.  */
7081 extern char cap_get_proc();
7082 int
7083 main ()
7084 {
7085 cap_get_proc()
7086   ;
7087   return 0;
7088 }
7089 _ACEOF
7090 if ac_fn_c_try_link "$LINENO"; then :
7091
7092                   smart_lib="-lcap"
7093                   smart_ldflags="-L$try -Wl,-rpath,$try"
7094                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7095 $as_echo "yes" >&6; }
7096                   break
7097
7098 else
7099   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7100 $as_echo "no" >&6; }
7101 fi
7102 rm -f core conftest.err conftest.$ac_objext \
7103     conftest$ac_exeext conftest.$ac_ext
7104   done
7105   LIBS="$old_LIBS"
7106   CPPFLAGS="$old_CPPFLAGS"
7107 fi
7108
7109 if test "x$smart_lib" != "x"; then
7110   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
7111   LIBS="$smart_ldflags $smart_lib $old_LIBS"
7112   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
7113 fi
7114
7115 if test "x$ac_cv_lib_cap_cap_get_proc" != "xyes"; then
7116   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cap library not found, debugger checks will not be enabled. Use --with-cap-lib-dir=<path>." >&5
7117 $as_echo "$as_me: WARNING: cap library not found, debugger checks will not be enabled. Use --with-cap-lib-dir=<path>." >&2;}
7118 else
7119
7120 $as_echo "#define HAVE_LIBCAP 1" >>confdefs.h
7121
7122   HAVE_LIBCAP=1
7123 fi
7124
7125
7126   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a readline compatible library" >&5
7127 $as_echo_n "checking for a readline compatible library... " >&6; }
7128 if ${vl_cv_lib_readline+:} false; then :
7129   $as_echo_n "(cached) " >&6
7130 else
7131
7132     ORIG_LIBS="$LIBS"
7133     for readline_lib in readline edit editline; do
7134       for termcap_lib in "" termcap curses ncurses; do
7135         if test -z "$termcap_lib"; then
7136           TRY_LIB="-l$readline_lib"
7137         else
7138           TRY_LIB="-l$readline_lib -l$termcap_lib"
7139         fi
7140         LIBS="$ORIG_LIBS $TRY_LIB"
7141         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7142 /* end confdefs.h.  */
7143
7144 /* Override any GCC internal prototype to avoid an error.
7145    Use char because int might match the return type of a GCC
7146    builtin and then its argument prototype would still apply.  */
7147 #ifdef __cplusplus
7148 extern "C"
7149 #endif
7150 char readline ();
7151 int
7152 main ()
7153 {
7154 return readline ();
7155   ;
7156   return 0;
7157 }
7158 _ACEOF
7159 if ac_fn_c_try_link "$LINENO"; then :
7160   vl_cv_lib_readline="$TRY_LIB"
7161 fi
7162 rm -f core conftest.err conftest.$ac_objext \
7163     conftest$ac_exeext conftest.$ac_ext
7164         if test -n "$vl_cv_lib_readline"; then
7165           break
7166         fi
7167       done
7168       if test -n "$vl_cv_lib_readline"; then
7169         break
7170       fi
7171     done
7172     if test -z "$vl_cv_lib_readline"; then
7173       vl_cv_lib_readline="no"
7174       LIBS="$ORIG_LIBS"
7175     fi
7176
7177 fi
7178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vl_cv_lib_readline" >&5
7179 $as_echo "$vl_cv_lib_readline" >&6; }
7180
7181   if test "$vl_cv_lib_readline" != "no"; then
7182     LIBREADLINE="$vl_cv_lib_readline"
7183
7184 $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
7185
7186     for ac_header in readline.h readline/readline.h
7187 do :
7188   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7189 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7190 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7191   cat >>confdefs.h <<_ACEOF
7192 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7193 _ACEOF
7194
7195 fi
7196
7197 done
7198
7199     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5
7200 $as_echo_n "checking whether readline supports history... " >&6; }
7201 if ${vl_cv_lib_readline_history+:} false; then :
7202   $as_echo_n "(cached) " >&6
7203 else
7204
7205       vl_cv_lib_readline_history="no"
7206       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7207 /* end confdefs.h.  */
7208
7209 /* Override any GCC internal prototype to avoid an error.
7210    Use char because int might match the return type of a GCC
7211    builtin and then its argument prototype would still apply.  */
7212 #ifdef __cplusplus
7213 extern "C"
7214 #endif
7215 char add_history ();
7216 int
7217 main ()
7218 {
7219 return add_history ();
7220   ;
7221   return 0;
7222 }
7223 _ACEOF
7224 if ac_fn_c_try_link "$LINENO"; then :
7225   vl_cv_lib_readline_history="yes"
7226 fi
7227 rm -f core conftest.err conftest.$ac_objext \
7228     conftest$ac_exeext conftest.$ac_ext
7229
7230 fi
7231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vl_cv_lib_readline_history" >&5
7232 $as_echo "$vl_cv_lib_readline_history" >&6; }
7233     if test "$vl_cv_lib_readline_history" = "yes"; then
7234
7235 $as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h
7236
7237       for ac_header in history.h readline/history.h
7238 do :
7239   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7240 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7241 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7242   cat >>confdefs.h <<_ACEOF
7243 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7244 _ACEOF
7245
7246 fi
7247
7248 done
7249
7250     fi
7251   fi
7252
7253
7254
7255
7256 smart_try_dir="$talloc_include_dir"
7257
7258
7259 ac_safe=`echo "talloc.h" | sed 'y%./+-%__pm%'`
7260 old_CPPFLAGS="$CPPFLAGS"
7261 smart_include=
7262 smart_include_dir="/usr/local/include /opt/include"
7263
7264 _smart_try_dir=
7265 _smart_include_dir=
7266
7267 for _prefix in $smart_prefix ""; do
7268   for _dir in $smart_try_dir; do
7269     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
7270   done
7271
7272   for _dir in $smart_include_dir; do
7273     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
7274   done
7275 done
7276
7277 if test "x$_smart_try_dir" != "x"; then
7278   for try in $_smart_try_dir; do
7279     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for talloc.h in $try" >&5
7280 $as_echo_n "checking for talloc.h in $try... " >&6; }
7281     CPPFLAGS="-isystem $try $old_CPPFLAGS"
7282     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7283 /* end confdefs.h.  */
7284
7285                     #include <talloc.h>
7286 int
7287 main ()
7288 {
7289 int a = 1;
7290   ;
7291   return 0;
7292 }
7293 _ACEOF
7294 if ac_fn_c_try_compile "$LINENO"; then :
7295
7296                      smart_include="-isystem $try"
7297                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7298 $as_echo "yes" >&6; }
7299                      break
7300
7301 else
7302
7303                      smart_include=
7304                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7305 $as_echo "no" >&6; }
7306
7307 fi
7308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7309   done
7310   CPPFLAGS="$old_CPPFLAGS"
7311 fi
7312
7313 if test "x$smart_include" = "x"; then
7314   for _prefix in $smart_prefix; do
7315     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/talloc.h" >&5
7316 $as_echo_n "checking for ${_prefix}/talloc.h... " >&6; }
7317
7318     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7319 /* end confdefs.h.  */
7320
7321                     #include <talloc.h>
7322 int
7323 main ()
7324 {
7325 int a = 1;
7326   ;
7327   return 0;
7328 }
7329 _ACEOF
7330 if ac_fn_c_try_compile "$LINENO"; then :
7331
7332                      smart_include="-isystem ${_prefix}/"
7333                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7334 $as_echo "yes" >&6; }
7335                      break
7336
7337 else
7338
7339                      smart_include=
7340                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7341 $as_echo "no" >&6; }
7342
7343 fi
7344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7345   done
7346 fi
7347
7348 if test "x$smart_include" = "x"; then
7349     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for talloc.h" >&5
7350 $as_echo_n "checking for talloc.h... " >&6; }
7351
7352     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7353 /* end confdefs.h.  */
7354
7355                     #include <talloc.h>
7356 int
7357 main ()
7358 {
7359 int a = 1;
7360   ;
7361   return 0;
7362 }
7363 _ACEOF
7364 if ac_fn_c_try_compile "$LINENO"; then :
7365
7366                      smart_include=" "
7367                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7368 $as_echo "yes" >&6; }
7369                      break
7370
7371 else
7372
7373                      smart_include=
7374                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7375 $as_echo "no" >&6; }
7376
7377 fi
7378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7379 fi
7380
7381 if test "x$smart_include" = "x"; then
7382
7383   for prefix in $smart_prefix; do
7384
7385
7386 if test "x$LOCATE" != "x"; then
7387         DIRS=
7388   file="${_prefix}/${1}"
7389
7390   for x in `${LOCATE} $file 2>/dev/null`; do
7391                                         base=`echo $x | sed "s%/${file}%%"`
7392     if test "x$x" = "x$base"; then
7393       continue;
7394     fi
7395
7396     dir=`${DIRNAME} $x 2>/dev/null`
7397                 exclude=`echo ${dir} | ${GREP} /home`
7398     if test "x$exclude" != "x"; then
7399       continue
7400     fi
7401
7402                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
7403     if test "x$already" = "x"; then
7404       DIRS="$DIRS $dir"
7405     fi
7406   done
7407 fi
7408
7409 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
7410
7411   done
7412
7413
7414 if test "x$LOCATE" != "x"; then
7415         DIRS=
7416   file=talloc.h
7417
7418   for x in `${LOCATE} $file 2>/dev/null`; do
7419                                         base=`echo $x | sed "s%/${file}%%"`
7420     if test "x$x" = "x$base"; then
7421       continue;
7422     fi
7423
7424     dir=`${DIRNAME} $x 2>/dev/null`
7425                 exclude=`echo ${dir} | ${GREP} /home`
7426     if test "x$exclude" != "x"; then
7427       continue
7428     fi
7429
7430                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
7431     if test "x$already" = "x"; then
7432       DIRS="$DIRS $dir"
7433     fi
7434   done
7435 fi
7436
7437 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
7438
7439
7440   for try in $_smart_include_dir; do
7441     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for talloc.h in $try" >&5
7442 $as_echo_n "checking for talloc.h in $try... " >&6; }
7443     CPPFLAGS="-isystem $try $old_CPPFLAGS"
7444     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7445 /* end confdefs.h.  */
7446
7447                     #include <talloc.h>
7448 int
7449 main ()
7450 {
7451 int a = 1;
7452   ;
7453   return 0;
7454 }
7455 _ACEOF
7456 if ac_fn_c_try_compile "$LINENO"; then :
7457
7458                      smart_include="-isystem $try"
7459                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7460 $as_echo "yes" >&6; }
7461                      break
7462
7463 else
7464
7465                      smart_include=
7466                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7467 $as_echo "no" >&6; }
7468
7469 fi
7470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7471   done
7472   CPPFLAGS="$old_CPPFLAGS"
7473 fi
7474
7475 if test "x$smart_include" != "x"; then
7476   eval "ac_cv_header_$ac_safe=yes"
7477   CPPFLAGS="$smart_include $old_CPPFLAGS"
7478   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
7479 fi
7480
7481 smart_prefix=
7482
7483 if test "x$ac_cv_header_talloc_h" != "xyes"; then
7484   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: talloc headers not found. Use --with-talloc-include-dir=<path>." >&5
7485 $as_echo "$as_me: WARNING: talloc headers not found. Use --with-talloc-include-dir=<path>." >&2;}
7486   as_fn_error $? "FreeRADIUS requires libtalloc" "$LINENO" 5
7487 fi
7488
7489 case "$host" in
7490   *-interix*)
7491     CFLAGS="$CFLAGS -D_ALL_SOURCE"
7492     ;;
7493   *-darwin*)
7494     CFLAGS="$CFLAGS -DDARWIN"
7495     LIBS="-framework DirectoryService $LIBS"
7496
7497 $as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h
7498
7499     ;;
7500 esac
7501
7502 ac_header_dirent=no
7503 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
7504   as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
7505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
7506 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
7507 if eval \${$as_ac_Header+:} false; then :
7508   $as_echo_n "(cached) " >&6
7509 else
7510   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7511 /* end confdefs.h.  */
7512 #include <sys/types.h>
7513 #include <$ac_hdr>
7514
7515 int
7516 main ()
7517 {
7518 if ((DIR *) 0)
7519 return 0;
7520   ;
7521   return 0;
7522 }
7523 _ACEOF
7524 if ac_fn_c_try_compile "$LINENO"; then :
7525   eval "$as_ac_Header=yes"
7526 else
7527   eval "$as_ac_Header=no"
7528 fi
7529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7530 fi
7531 eval ac_res=\$$as_ac_Header
7532                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7533 $as_echo "$ac_res" >&6; }
7534 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7535   cat >>confdefs.h <<_ACEOF
7536 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
7537 _ACEOF
7538
7539 ac_header_dirent=$ac_hdr; break
7540 fi
7541
7542 done
7543 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
7544 if test $ac_header_dirent = dirent.h; then
7545   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
7546 $as_echo_n "checking for library containing opendir... " >&6; }
7547 if ${ac_cv_search_opendir+:} false; then :
7548   $as_echo_n "(cached) " >&6
7549 else
7550   ac_func_search_save_LIBS=$LIBS
7551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7552 /* end confdefs.h.  */
7553
7554 /* Override any GCC internal prototype to avoid an error.
7555    Use char because int might match the return type of a GCC
7556    builtin and then its argument prototype would still apply.  */
7557 #ifdef __cplusplus
7558 extern "C"
7559 #endif
7560 char opendir ();
7561 int
7562 main ()
7563 {
7564 return opendir ();
7565   ;
7566   return 0;
7567 }
7568 _ACEOF
7569 for ac_lib in '' dir; do
7570   if test -z "$ac_lib"; then
7571     ac_res="none required"
7572   else
7573     ac_res=-l$ac_lib
7574     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7575   fi
7576   if ac_fn_c_try_link "$LINENO"; then :
7577   ac_cv_search_opendir=$ac_res
7578 fi
7579 rm -f core conftest.err conftest.$ac_objext \
7580     conftest$ac_exeext
7581   if ${ac_cv_search_opendir+:} false; then :
7582   break
7583 fi
7584 done
7585 if ${ac_cv_search_opendir+:} false; then :
7586
7587 else
7588   ac_cv_search_opendir=no
7589 fi
7590 rm conftest.$ac_ext
7591 LIBS=$ac_func_search_save_LIBS
7592 fi
7593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
7594 $as_echo "$ac_cv_search_opendir" >&6; }
7595 ac_res=$ac_cv_search_opendir
7596 if test "$ac_res" != no; then :
7597   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7598
7599 fi
7600
7601 else
7602   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
7603 $as_echo_n "checking for library containing opendir... " >&6; }
7604 if ${ac_cv_search_opendir+:} false; then :
7605   $as_echo_n "(cached) " >&6
7606 else
7607   ac_func_search_save_LIBS=$LIBS
7608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7609 /* end confdefs.h.  */
7610
7611 /* Override any GCC internal prototype to avoid an error.
7612    Use char because int might match the return type of a GCC
7613    builtin and then its argument prototype would still apply.  */
7614 #ifdef __cplusplus
7615 extern "C"
7616 #endif
7617 char opendir ();
7618 int
7619 main ()
7620 {
7621 return opendir ();
7622   ;
7623   return 0;
7624 }
7625 _ACEOF
7626 for ac_lib in '' x; do
7627   if test -z "$ac_lib"; then
7628     ac_res="none required"
7629   else
7630     ac_res=-l$ac_lib
7631     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7632   fi
7633   if ac_fn_c_try_link "$LINENO"; then :
7634   ac_cv_search_opendir=$ac_res
7635 fi
7636 rm -f core conftest.err conftest.$ac_objext \
7637     conftest$ac_exeext
7638   if ${ac_cv_search_opendir+:} false; then :
7639   break
7640 fi
7641 done
7642 if ${ac_cv_search_opendir+:} false; then :
7643
7644 else
7645   ac_cv_search_opendir=no
7646 fi
7647 rm conftest.$ac_ext
7648 LIBS=$ac_func_search_save_LIBS
7649 fi
7650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
7651 $as_echo "$ac_cv_search_opendir" >&6; }
7652 ac_res=$ac_cv_search_opendir
7653 if test "$ac_res" != no; then :
7654   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7655
7656 fi
7657
7658 fi
7659
7660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7661 $as_echo_n "checking for ANSI C header files... " >&6; }
7662 if ${ac_cv_header_stdc+:} false; then :
7663   $as_echo_n "(cached) " >&6
7664 else
7665   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7666 /* end confdefs.h.  */
7667 #include <stdlib.h>
7668 #include <stdarg.h>
7669 #include <string.h>
7670 #include <float.h>
7671
7672 int
7673 main ()
7674 {
7675
7676   ;
7677   return 0;
7678 }
7679 _ACEOF
7680 if ac_fn_c_try_compile "$LINENO"; then :
7681   ac_cv_header_stdc=yes
7682 else
7683   ac_cv_header_stdc=no
7684 fi
7685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7686
7687 if test $ac_cv_header_stdc = yes; then
7688   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7689   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7690 /* end confdefs.h.  */
7691 #include <string.h>
7692
7693 _ACEOF
7694 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7695   $EGREP "memchr" >/dev/null 2>&1; then :
7696
7697 else
7698   ac_cv_header_stdc=no
7699 fi
7700 rm -f conftest*
7701
7702 fi
7703
7704 if test $ac_cv_header_stdc = yes; then
7705   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7706   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7707 /* end confdefs.h.  */
7708 #include <stdlib.h>
7709
7710 _ACEOF
7711 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7712   $EGREP "free" >/dev/null 2>&1; then :
7713
7714 else
7715   ac_cv_header_stdc=no
7716 fi
7717 rm -f conftest*
7718
7719 fi
7720
7721 if test $ac_cv_header_stdc = yes; then
7722   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7723   if test "$cross_compiling" = yes; then :
7724   :
7725 else
7726   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7727 /* end confdefs.h.  */
7728 #include <ctype.h>
7729 #include <stdlib.h>
7730 #if ((' ' & 0x0FF) == 0x020)
7731 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7732 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7733 #else
7734 # define ISLOWER(c) \
7735                    (('a' <= (c) && (c) <= 'i') \
7736                      || ('j' <= (c) && (c) <= 'r') \
7737                      || ('s' <= (c) && (c) <= 'z'))
7738 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7739 #endif
7740
7741 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7742 int
7743 main ()
7744 {
7745   int i;
7746   for (i = 0; i < 256; i++)
7747     if (XOR (islower (i), ISLOWER (i))
7748         || toupper (i) != TOUPPER (i))
7749       return 2;
7750   return 0;
7751 }
7752 _ACEOF
7753 if ac_fn_c_try_run "$LINENO"; then :
7754
7755 else
7756   ac_cv_header_stdc=no
7757 fi
7758 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7759   conftest.$ac_objext conftest.beam conftest.$ac_ext
7760 fi
7761
7762 fi
7763 fi
7764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7765 $as_echo "$ac_cv_header_stdc" >&6; }
7766 if test $ac_cv_header_stdc = yes; then
7767
7768 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
7769
7770 fi
7771
7772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
7773 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
7774 if ${ac_cv_header_time+:} false; then :
7775   $as_echo_n "(cached) " >&6
7776 else
7777   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7778 /* end confdefs.h.  */
7779 #include <sys/types.h>
7780 #include <sys/time.h>
7781 #include <time.h>
7782
7783 int
7784 main ()
7785 {
7786 if ((struct tm *) 0)
7787 return 0;
7788   ;
7789   return 0;
7790 }
7791 _ACEOF
7792 if ac_fn_c_try_compile "$LINENO"; then :
7793   ac_cv_header_time=yes
7794 else
7795   ac_cv_header_time=no
7796 fi
7797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7798 fi
7799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
7800 $as_echo "$ac_cv_header_time" >&6; }
7801 if test $ac_cv_header_time = yes; then
7802
7803 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
7804
7805 fi
7806
7807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
7808 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
7809 if ${ac_cv_header_sys_wait_h+:} false; then :
7810   $as_echo_n "(cached) " >&6
7811 else
7812   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7813 /* end confdefs.h.  */
7814 #include <sys/types.h>
7815 #include <sys/wait.h>
7816 #ifndef WEXITSTATUS
7817 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
7818 #endif
7819 #ifndef WIFEXITED
7820 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
7821 #endif
7822
7823 int
7824 main ()
7825 {
7826   int s;
7827   wait (&s);
7828   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
7829   ;
7830   return 0;
7831 }
7832 _ACEOF
7833 if ac_fn_c_try_compile "$LINENO"; then :
7834   ac_cv_header_sys_wait_h=yes
7835 else
7836   ac_cv_header_sys_wait_h=no
7837 fi
7838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7839 fi
7840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
7841 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
7842 if test $ac_cv_header_sys_wait_h = yes; then
7843
7844 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
7845
7846 fi
7847
7848
7849 for ac_header in \
7850   dlfcn.h \
7851   unistd.h \
7852   crypt.h \
7853   errno.h \
7854   resource.h \
7855   sys/resource.h \
7856   getopt.h \
7857   malloc.h \
7858   utmp.h \
7859   utmpx.h \
7860   signal.h \
7861   sys/select.h \
7862   syslog.h \
7863   inttypes.h \
7864   stdint.h \
7865   stdbool.h \
7866   stdio.h \
7867   netdb.h \
7868   semaphore.h \
7869   arpa/inet.h \
7870   netinet/in.h \
7871   sys/types.h \
7872   sys/socket.h \
7873   winsock.h \
7874   utime.h \
7875   sys/time.h \
7876   sys/wait.h \
7877   sys/security.h \
7878   fcntl.h \
7879   sys/fcntl.h \
7880   sys/prctl.h \
7881   sys/ptrace.h \
7882   sys/un.h \
7883   glob.h \
7884   prot.h \
7885   pwd.h \
7886   grp.h \
7887   stddef.h \
7888   fnmatch.h \
7889   sia.h \
7890   siad.h \
7891   features.h \
7892   limits.h
7893
7894 do :
7895   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7896 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7897 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7898   cat >>confdefs.h <<_ACEOF
7899 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7900 _ACEOF
7901
7902 fi
7903
7904 done
7905
7906
7907 for ac_header in net/if.h
7908 do :
7909   ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
7910     #ifdef HAVE_SYS_SOCKET_H
7911     #  include <sys/socket.h>
7912     #endif
7913
7914
7915 "
7916 if test "x$ac_cv_header_net_if_h" = xyes; then :
7917   cat >>confdefs.h <<_ACEOF
7918 #define HAVE_NET_IF_H 1
7919 _ACEOF
7920
7921 fi
7922
7923 done
7924
7925
7926 if test "x$ac_cv_header_sys_security_h" = "xyes" && test "x$ac_cv_header_prot_h" = "xyes"
7927 then
7928
7929 $as_echo "#define OSFC2 /**/" >>confdefs.h
7930
7931 fi
7932
7933 if test "x$ac_cv_header_sia_h" = "xyes" && test "x$ac_cv_header_siad_h" = "xyes"
7934 then
7935
7936 $as_echo "#define OSFSIA /**/" >>confdefs.h
7937
7938 fi
7939
7940 if test "x$WITH_OPENSSL" = xyes; then
7941   OLD_LIBS="$LIBS"
7942
7943         CFLAGS="$CFLAGS -DOPENSSL_NO_KRB5"
7944
7945         smart_try_dir="$openssl_lib_dir"
7946
7947
7948 sm_lib_safe=`echo "crypto" | sed 'y%./+-%__p_%'`
7949 sm_func_safe=`echo "DH_new" | sed 'y%./+-%__p_%'`
7950
7951 old_LIBS="$LIBS"
7952 old_CPPFLAGS="$CPPFLAGS"
7953 smart_lib=
7954 smart_ldflags=
7955 smart_lib_dir=
7956
7957 if test "x$smart_try_dir" != "x"; then
7958   for try in $smart_try_dir; do
7959     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DH_new in -lcrypto in $try" >&5
7960 $as_echo_n "checking for DH_new in -lcrypto in $try... " >&6; }
7961     LIBS="-lcrypto $old_LIBS"
7962     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
7963     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7964 /* end confdefs.h.  */
7965 extern char DH_new();
7966 int
7967 main ()
7968 {
7969 DH_new()
7970   ;
7971   return 0;
7972 }
7973 _ACEOF
7974 if ac_fn_c_try_link "$LINENO"; then :
7975
7976                  smart_lib="-lcrypto"
7977                  smart_ldflags="-L$try -Wl,-rpath,$try"
7978                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7979 $as_echo "yes" >&6; }
7980                  break
7981
7982 else
7983   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7984 $as_echo "no" >&6; }
7985 fi
7986 rm -f core conftest.err conftest.$ac_objext \
7987     conftest$ac_exeext conftest.$ac_ext
7988   done
7989   LIBS="$old_LIBS"
7990   CPPFLAGS="$old_CPPFLAGS"
7991 fi
7992
7993 if test "x$smart_lib" = "x"; then
7994   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DH_new in -lcrypto" >&5
7995 $as_echo_n "checking for DH_new in -lcrypto... " >&6; }
7996   LIBS="-lcrypto $old_LIBS"
7997   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7998 /* end confdefs.h.  */
7999 extern char DH_new();
8000 int
8001 main ()
8002 {
8003 DH_new()
8004   ;
8005   return 0;
8006 }
8007 _ACEOF
8008 if ac_fn_c_try_link "$LINENO"; then :
8009
8010                 smart_lib="-lcrypto"
8011                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8012 $as_echo "yes" >&6; }
8013
8014 else
8015   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8016 $as_echo "no" >&6; }
8017 fi
8018 rm -f core conftest.err conftest.$ac_objext \
8019     conftest$ac_exeext conftest.$ac_ext
8020   LIBS="$old_LIBS"
8021 fi
8022
8023 if test "x$smart_lib" = "x"; then
8024
8025
8026 if test "x$LOCATE" != "x"; then
8027         DIRS=
8028   file=libcrypto${libltdl_cv_shlibext}
8029
8030   for x in `${LOCATE} $file 2>/dev/null`; do
8031                                         base=`echo $x | sed "s%/${file}%%"`
8032     if test "x$x" = "x$base"; then
8033       continue;
8034     fi
8035
8036     dir=`${DIRNAME} $x 2>/dev/null`
8037                 exclude=`echo ${dir} | ${GREP} /home`
8038     if test "x$exclude" != "x"; then
8039       continue
8040     fi
8041
8042                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
8043     if test "x$already" = "x"; then
8044       DIRS="$DIRS $dir"
8045     fi
8046   done
8047 fi
8048
8049 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
8050
8051
8052
8053 if test "x$LOCATE" != "x"; then
8054         DIRS=
8055   file=libcrypto.a
8056
8057   for x in `${LOCATE} $file 2>/dev/null`; do
8058                                         base=`echo $x | sed "s%/${file}%%"`
8059     if test "x$x" = "x$base"; then
8060       continue;
8061     fi
8062
8063     dir=`${DIRNAME} $x 2>/dev/null`
8064                 exclude=`echo ${dir} | ${GREP} /home`
8065     if test "x$exclude" != "x"; then
8066       continue
8067     fi
8068
8069                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
8070     if test "x$already" = "x"; then
8071       DIRS="$DIRS $dir"
8072     fi
8073   done
8074 fi
8075
8076 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
8077
8078
8079   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
8080     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DH_new in -lcrypto in $try" >&5
8081 $as_echo_n "checking for DH_new in -lcrypto in $try... " >&6; }
8082     LIBS="-lcrypto $old_LIBS"
8083     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
8084     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8085 /* end confdefs.h.  */
8086 extern char DH_new();
8087 int
8088 main ()
8089 {
8090 DH_new()
8091   ;
8092   return 0;
8093 }
8094 _ACEOF
8095 if ac_fn_c_try_link "$LINENO"; then :
8096
8097                   smart_lib="-lcrypto"
8098                   smart_ldflags="-L$try -Wl,-rpath,$try"
8099                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8100 $as_echo "yes" >&6; }
8101                   break
8102
8103 else
8104   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8105 $as_echo "no" >&6; }
8106 fi
8107 rm -f core conftest.err conftest.$ac_objext \
8108     conftest$ac_exeext conftest.$ac_ext
8109   done
8110   LIBS="$old_LIBS"
8111   CPPFLAGS="$old_CPPFLAGS"
8112 fi
8113
8114 if test "x$smart_lib" != "x"; then
8115   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
8116   LIBS="$smart_ldflags $smart_lib $old_LIBS"
8117   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
8118 fi
8119
8120   if test "x$ac_cv_lib_crypto_DH_new" = "xyes"; then
8121
8122 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
8123
8124     OPENSSL_LIBS="$smart_lib"
8125     OPENSSL_LDFLAGS="$smart_ldflags"
8126
8127
8128
8129 sm_lib_safe=`echo "ssl" | sed 'y%./+-%__p_%'`
8130 sm_func_safe=`echo "SSL_new" | sed 'y%./+-%__p_%'`
8131
8132 old_LIBS="$LIBS"
8133 old_CPPFLAGS="$CPPFLAGS"
8134 smart_lib=
8135 smart_ldflags=
8136 smart_lib_dir=
8137
8138 if test "x$smart_try_dir" != "x"; then
8139   for try in $smart_try_dir; do
8140     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl in $try" >&5
8141 $as_echo_n "checking for SSL_new in -lssl in $try... " >&6; }
8142     LIBS="-lssl $old_LIBS"
8143     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
8144     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8145 /* end confdefs.h.  */
8146 extern char SSL_new();
8147 int
8148 main ()
8149 {
8150 SSL_new()
8151   ;
8152   return 0;
8153 }
8154 _ACEOF
8155 if ac_fn_c_try_link "$LINENO"; then :
8156
8157                  smart_lib="-lssl"
8158                  smart_ldflags="-L$try -Wl,-rpath,$try"
8159                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8160 $as_echo "yes" >&6; }
8161                  break
8162
8163 else
8164   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8165 $as_echo "no" >&6; }
8166 fi
8167 rm -f core conftest.err conftest.$ac_objext \
8168     conftest$ac_exeext conftest.$ac_ext
8169   done
8170   LIBS="$old_LIBS"
8171   CPPFLAGS="$old_CPPFLAGS"
8172 fi
8173
8174 if test "x$smart_lib" = "x"; then
8175   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl" >&5
8176 $as_echo_n "checking for SSL_new in -lssl... " >&6; }
8177   LIBS="-lssl $old_LIBS"
8178   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8179 /* end confdefs.h.  */
8180 extern char SSL_new();
8181 int
8182 main ()
8183 {
8184 SSL_new()
8185   ;
8186   return 0;
8187 }
8188 _ACEOF
8189 if ac_fn_c_try_link "$LINENO"; then :
8190
8191                 smart_lib="-lssl"
8192                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8193 $as_echo "yes" >&6; }
8194
8195 else
8196   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8197 $as_echo "no" >&6; }
8198 fi
8199 rm -f core conftest.err conftest.$ac_objext \
8200     conftest$ac_exeext conftest.$ac_ext
8201   LIBS="$old_LIBS"
8202 fi
8203
8204 if test "x$smart_lib" = "x"; then
8205
8206
8207 if test "x$LOCATE" != "x"; then
8208         DIRS=
8209   file=libssl${libltdl_cv_shlibext}
8210
8211   for x in `${LOCATE} $file 2>/dev/null`; do
8212                                         base=`echo $x | sed "s%/${file}%%"`
8213     if test "x$x" = "x$base"; then
8214       continue;
8215     fi
8216
8217     dir=`${DIRNAME} $x 2>/dev/null`
8218                 exclude=`echo ${dir} | ${GREP} /home`
8219     if test "x$exclude" != "x"; then
8220       continue
8221     fi
8222
8223                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
8224     if test "x$already" = "x"; then
8225       DIRS="$DIRS $dir"
8226     fi
8227   done
8228 fi
8229
8230 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
8231
8232
8233
8234 if test "x$LOCATE" != "x"; then
8235         DIRS=
8236   file=libssl.a
8237
8238   for x in `${LOCATE} $file 2>/dev/null`; do
8239                                         base=`echo $x | sed "s%/${file}%%"`
8240     if test "x$x" = "x$base"; then
8241       continue;
8242     fi
8243
8244     dir=`${DIRNAME} $x 2>/dev/null`
8245                 exclude=`echo ${dir} | ${GREP} /home`
8246     if test "x$exclude" != "x"; then
8247       continue
8248     fi
8249
8250                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
8251     if test "x$already" = "x"; then
8252       DIRS="$DIRS $dir"
8253     fi
8254   done
8255 fi
8256
8257 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
8258
8259
8260   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
8261     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl in $try" >&5
8262 $as_echo_n "checking for SSL_new in -lssl in $try... " >&6; }
8263     LIBS="-lssl $old_LIBS"
8264     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
8265     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8266 /* end confdefs.h.  */
8267 extern char SSL_new();
8268 int
8269 main ()
8270 {
8271 SSL_new()
8272   ;
8273   return 0;
8274 }
8275 _ACEOF
8276 if ac_fn_c_try_link "$LINENO"; then :
8277
8278                   smart_lib="-lssl"
8279                   smart_ldflags="-L$try -Wl,-rpath,$try"
8280                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8281 $as_echo "yes" >&6; }
8282                   break
8283
8284 else
8285   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8286 $as_echo "no" >&6; }
8287 fi
8288 rm -f core conftest.err conftest.$ac_objext \
8289     conftest$ac_exeext conftest.$ac_ext
8290   done
8291   LIBS="$old_LIBS"
8292   CPPFLAGS="$old_CPPFLAGS"
8293 fi
8294
8295 if test "x$smart_lib" != "x"; then
8296   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
8297   LIBS="$smart_ldflags $smart_lib $old_LIBS"
8298   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
8299 fi
8300
8301     if test "x$ac_cv_lib_ssl_SSL_new" != "xyes"; then
8302       { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8303 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8304 as_fn_error $? "failed linking to libssl. Use --with-openssl-lib-dir=<path>, or --with-openssl=no (builds without OpenSSL)
8305 See \`config.log' for more details" "$LINENO" 5; }
8306     else
8307
8308 $as_echo "#define HAVE_LIBSSL 1" >>confdefs.h
8309
8310       OPENSSL_LIBS="$OPENSSL_LIBS $smart_lib"
8311
8312       if test "$OPENSSL_LDFLAGS" != "$smart_ldflags"; then
8313         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8314 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8315 as_fn_error $? "\"inconsistent LDFLAGS between -lssl '$smart_ldflags' and -lcrypto '$OPENSSL_LDFLAGS'\"
8316 See \`config.log' for more details" "$LINENO" 5; }
8317       fi
8318     fi
8319   else
8320     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8321 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8322 as_fn_error $? "failed linking to libcrypto. Use --with-openssl-lib-dir=<path>, or --with-openssl=no (builds without OpenSSL)
8323 See \`config.log' for more details" "$LINENO" 5; }
8324   fi
8325
8326   smart_try_dir="$openssl_include_dir"
8327
8328
8329 ac_safe=`echo "openssl/ssl.h" | sed 'y%./+-%__pm%'`
8330 old_CPPFLAGS="$CPPFLAGS"
8331 smart_include=
8332 smart_include_dir="/usr/local/include /opt/include"
8333
8334 _smart_try_dir=
8335 _smart_include_dir=
8336
8337 for _prefix in $smart_prefix ""; do
8338   for _dir in $smart_try_dir; do
8339     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
8340   done
8341
8342   for _dir in $smart_include_dir; do
8343     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
8344   done
8345 done
8346
8347 if test "x$_smart_try_dir" != "x"; then
8348   for try in $_smart_try_dir; do
8349     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl/ssl.h in $try" >&5
8350 $as_echo_n "checking for openssl/ssl.h in $try... " >&6; }
8351     CPPFLAGS="-isystem $try $old_CPPFLAGS"
8352     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8353 /* end confdefs.h.  */
8354
8355                     #include <openssl/ssl.h>
8356 int
8357 main ()
8358 {
8359 int a = 1;
8360   ;
8361   return 0;
8362 }
8363 _ACEOF
8364 if ac_fn_c_try_compile "$LINENO"; then :
8365
8366                      smart_include="-isystem $try"
8367                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8368 $as_echo "yes" >&6; }
8369                      break
8370
8371 else
8372
8373                      smart_include=
8374                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8375 $as_echo "no" >&6; }
8376
8377 fi
8378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8379   done
8380   CPPFLAGS="$old_CPPFLAGS"
8381 fi
8382
8383 if test "x$smart_include" = "x"; then
8384   for _prefix in $smart_prefix; do
8385     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/openssl/ssl.h" >&5
8386 $as_echo_n "checking for ${_prefix}/openssl/ssl.h... " >&6; }
8387
8388     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8389 /* end confdefs.h.  */
8390
8391                     #include <openssl/ssl.h>
8392 int
8393 main ()
8394 {
8395 int a = 1;
8396   ;
8397   return 0;
8398 }
8399 _ACEOF
8400 if ac_fn_c_try_compile "$LINENO"; then :
8401
8402                      smart_include="-isystem ${_prefix}/"
8403                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8404 $as_echo "yes" >&6; }
8405                      break
8406
8407 else
8408
8409                      smart_include=
8410                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8411 $as_echo "no" >&6; }
8412
8413 fi
8414 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8415   done
8416 fi
8417
8418 if test "x$smart_include" = "x"; then
8419     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl/ssl.h" >&5
8420 $as_echo_n "checking for openssl/ssl.h... " >&6; }
8421
8422     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8423 /* end confdefs.h.  */
8424
8425                     #include <openssl/ssl.h>
8426 int
8427 main ()
8428 {
8429 int a = 1;
8430   ;
8431   return 0;
8432 }
8433 _ACEOF
8434 if ac_fn_c_try_compile "$LINENO"; then :
8435
8436                      smart_include=" "
8437                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8438 $as_echo "yes" >&6; }
8439                      break
8440
8441 else
8442
8443                      smart_include=
8444                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8445 $as_echo "no" >&6; }
8446
8447 fi
8448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8449 fi
8450
8451 if test "x$smart_include" = "x"; then
8452
8453   for prefix in $smart_prefix; do
8454
8455
8456 if test "x$LOCATE" != "x"; then
8457         DIRS=
8458   file="${_prefix}/${1}"
8459
8460   for x in `${LOCATE} $file 2>/dev/null`; do
8461                                         base=`echo $x | sed "s%/${file}%%"`
8462     if test "x$x" = "x$base"; then
8463       continue;
8464     fi
8465
8466     dir=`${DIRNAME} $x 2>/dev/null`
8467                 exclude=`echo ${dir} | ${GREP} /home`
8468     if test "x$exclude" != "x"; then
8469       continue
8470     fi
8471
8472                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
8473     if test "x$already" = "x"; then
8474       DIRS="$DIRS $dir"
8475     fi
8476   done
8477 fi
8478
8479 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
8480
8481   done
8482
8483
8484 if test "x$LOCATE" != "x"; then
8485         DIRS=
8486   file=openssl/ssl.h
8487
8488   for x in `${LOCATE} $file 2>/dev/null`; do
8489                                         base=`echo $x | sed "s%/${file}%%"`
8490     if test "x$x" = "x$base"; then
8491       continue;
8492     fi
8493
8494     dir=`${DIRNAME} $x 2>/dev/null`
8495                 exclude=`echo ${dir} | ${GREP} /home`
8496     if test "x$exclude" != "x"; then
8497       continue
8498     fi
8499
8500                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
8501     if test "x$already" = "x"; then
8502       DIRS="$DIRS $dir"
8503     fi
8504   done
8505 fi
8506
8507 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
8508
8509
8510   for try in $_smart_include_dir; do
8511     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl/ssl.h in $try" >&5
8512 $as_echo_n "checking for openssl/ssl.h in $try... " >&6; }
8513     CPPFLAGS="-isystem $try $old_CPPFLAGS"
8514     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8515 /* end confdefs.h.  */
8516
8517                     #include <openssl/ssl.h>
8518 int
8519 main ()
8520 {
8521 int a = 1;
8522   ;
8523   return 0;
8524 }
8525 _ACEOF
8526 if ac_fn_c_try_compile "$LINENO"; then :
8527
8528                      smart_include="-isystem $try"
8529                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8530 $as_echo "yes" >&6; }
8531                      break
8532
8533 else
8534
8535                      smart_include=
8536                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8537 $as_echo "no" >&6; }
8538
8539 fi
8540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8541   done
8542   CPPFLAGS="$old_CPPFLAGS"
8543 fi
8544
8545 if test "x$smart_include" != "x"; then
8546   eval "ac_cv_header_$ac_safe=yes"
8547   CPPFLAGS="$smart_include $old_CPPFLAGS"
8548   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
8549 fi
8550
8551 smart_prefix=
8552
8553   if test "x$ac_cv_header_openssl_ssl_h" = "xyes"; then
8554
8555 $as_echo "#define HAVE_OPENSSL_SSL_H 1" >>confdefs.h
8556
8557
8558     for ac_header in \
8559       openssl/crypto.h \
8560       openssl/err.h \
8561       openssl/evp.h \
8562       openssl/md5.h \
8563       openssl/md4.h \
8564       openssl/sha.h \
8565       openssl/ocsp.h \
8566       openssl/engine.h
8567 do :
8568   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8569 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8570 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8571   cat >>confdefs.h <<_ACEOF
8572 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8573 _ACEOF
8574   OPENSSL_CPPFLAGS="$smart_include"
8575 else
8576
8577         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8578 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8579 as_fn_error $? "failed locating OpenSSL headers. Use --with-openssl-include-dir=<path>, or --with-openssl=no (builds without OpenSSL)
8580 See \`config.log' for more details" "$LINENO" 5; }
8581
8582
8583 fi
8584
8585 done
8586
8587
8588     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL version >= 0.9.7" >&5
8589 $as_echo_n "checking for OpenSSL version >= 0.9.7... " >&6; }
8590     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8591 /* end confdefs.h.  */
8592 #include <openssl/crypto.h>
8593        #if (OPENSSL_VERSION_NUMBER >= 0x00907000L)
8594        yes
8595        #endif
8596
8597 _ACEOF
8598 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8599   $EGREP "yes" >/dev/null 2>&1; then :
8600
8601         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8602 $as_echo "yes" >&6; }
8603
8604 else
8605
8606         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8607 $as_echo "no" >&6; }
8608         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8609 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8610 as_fn_error $? "OpenSSL version too old
8611 See \`config.log' for more details" "$LINENO" 5; }
8612
8613
8614 fi
8615 rm -f conftest*
8616
8617
8618                         old_CPPFLAGS="$CPPFLAGS"
8619     CPPFLAGS="$OPENSSL_CPPFLAGS $CPPFLAGS"
8620
8621                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL library and header version consistency" >&5
8622 $as_echo_n "checking OpenSSL library and header version consistency... " >&6; }
8623     if test "$cross_compiling" = yes; then :
8624   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8625 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8626 as_fn_error $? "cannot run test program while cross compiling
8627 See \`config.log' for more details" "$LINENO" 5; }
8628 else
8629   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8630 /* end confdefs.h.  */
8631
8632           #include <stdio.h>
8633           #include <openssl/opensslv.h>
8634           #include <openssl/crypto.h>
8635
8636 int
8637 main ()
8638 {
8639
8640           printf("library: %lx header: %lx... ", (unsigned long) SSLeay(), (unsigned long) OPENSSL_VERSION_NUMBER);
8641           if (SSLeay() == OPENSSL_VERSION_NUMBER) {
8642             return 0;
8643           } else {
8644             return 1;
8645           }
8646
8647
8648   ;
8649   return 0;
8650 }
8651 _ACEOF
8652 if ac_fn_c_try_run "$LINENO"; then :
8653
8654         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8655 $as_echo "yes" >&6; }
8656
8657 else
8658
8659         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8660 $as_echo "no" >&6; }
8661         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8662 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8663 as_fn_error $? "OpenSSL library version does not match header version
8664 See \`config.log' for more details" "$LINENO" 5; }
8665
8666
8667 fi
8668 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8669   conftest.$ac_objext conftest.beam conftest.$ac_ext
8670 fi
8671
8672     CPPFLAGS="$old_CPPFLAGS"
8673   fi
8674
8675   LIBS="$OLD_LIBS"
8676
8677
8678
8679   export OPENSSL_LIBS OPENSSL_LDFLAGS OPENSSL_CPPFLAGS
8680 fi
8681
8682 if test "x$PCAP_LIBS" = x; then
8683   { $as_echo "$as_me:${as_lineno-$LINENO}: skipping test for pcap.h." >&5
8684 $as_echo "$as_me: skipping test for pcap.h." >&6;}
8685 else
8686         smart_try_dir="$pcap_include_dir"
8687
8688
8689 ac_safe=`echo "pcap.h" | sed 'y%./+-%__pm%'`
8690 old_CPPFLAGS="$CPPFLAGS"
8691 smart_include=
8692 smart_include_dir="/usr/local/include /opt/include"
8693
8694 _smart_try_dir=
8695 _smart_include_dir=
8696
8697 for _prefix in $smart_prefix ""; do
8698   for _dir in $smart_try_dir; do
8699     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
8700   done
8701
8702   for _dir in $smart_include_dir; do
8703     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
8704   done
8705 done
8706
8707 if test "x$_smart_try_dir" != "x"; then
8708   for try in $_smart_try_dir; do
8709     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap.h in $try" >&5
8710 $as_echo_n "checking for pcap.h in $try... " >&6; }
8711     CPPFLAGS="-isystem $try $old_CPPFLAGS"
8712     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8713 /* end confdefs.h.  */
8714
8715                     #include <pcap.h>
8716 int
8717 main ()
8718 {
8719 int a = 1;
8720   ;
8721   return 0;
8722 }
8723 _ACEOF
8724 if ac_fn_c_try_compile "$LINENO"; then :
8725
8726                      smart_include="-isystem $try"
8727                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8728 $as_echo "yes" >&6; }
8729                      break
8730
8731 else
8732
8733                      smart_include=
8734                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8735 $as_echo "no" >&6; }
8736
8737 fi
8738 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8739   done
8740   CPPFLAGS="$old_CPPFLAGS"
8741 fi
8742
8743 if test "x$smart_include" = "x"; then
8744   for _prefix in $smart_prefix; do
8745     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/pcap.h" >&5
8746 $as_echo_n "checking for ${_prefix}/pcap.h... " >&6; }
8747
8748     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8749 /* end confdefs.h.  */
8750
8751                     #include <pcap.h>
8752 int
8753 main ()
8754 {
8755 int a = 1;
8756   ;
8757   return 0;
8758 }
8759 _ACEOF
8760 if ac_fn_c_try_compile "$LINENO"; then :
8761
8762                      smart_include="-isystem ${_prefix}/"
8763                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8764 $as_echo "yes" >&6; }
8765                      break
8766
8767 else
8768
8769                      smart_include=
8770                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8771 $as_echo "no" >&6; }
8772
8773 fi
8774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8775   done
8776 fi
8777
8778 if test "x$smart_include" = "x"; then
8779     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap.h" >&5
8780 $as_echo_n "checking for pcap.h... " >&6; }
8781
8782     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8783 /* end confdefs.h.  */
8784
8785                     #include <pcap.h>
8786 int
8787 main ()
8788 {
8789 int a = 1;
8790   ;
8791   return 0;
8792 }
8793 _ACEOF
8794 if ac_fn_c_try_compile "$LINENO"; then :
8795
8796                      smart_include=" "
8797                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8798 $as_echo "yes" >&6; }
8799                      break
8800
8801 else
8802
8803                      smart_include=
8804                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8805 $as_echo "no" >&6; }
8806
8807 fi
8808 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8809 fi
8810
8811 if test "x$smart_include" = "x"; then
8812
8813   for prefix in $smart_prefix; do
8814
8815
8816 if test "x$LOCATE" != "x"; then
8817         DIRS=
8818   file="${_prefix}/${1}"
8819
8820   for x in `${LOCATE} $file 2>/dev/null`; do
8821                                         base=`echo $x | sed "s%/${file}%%"`
8822     if test "x$x" = "x$base"; then
8823       continue;
8824     fi
8825
8826     dir=`${DIRNAME} $x 2>/dev/null`
8827                 exclude=`echo ${dir} | ${GREP} /home`
8828     if test "x$exclude" != "x"; then
8829       continue
8830     fi
8831
8832                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
8833     if test "x$already" = "x"; then
8834       DIRS="$DIRS $dir"
8835     fi
8836   done
8837 fi
8838
8839 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
8840
8841   done
8842
8843
8844 if test "x$LOCATE" != "x"; then
8845         DIRS=
8846   file=pcap.h
8847
8848   for x in `${LOCATE} $file 2>/dev/null`; do
8849                                         base=`echo $x | sed "s%/${file}%%"`
8850     if test "x$x" = "x$base"; then
8851       continue;
8852     fi
8853
8854     dir=`${DIRNAME} $x 2>/dev/null`
8855                 exclude=`echo ${dir} | ${GREP} /home`
8856     if test "x$exclude" != "x"; then
8857       continue
8858     fi
8859
8860                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
8861     if test "x$already" = "x"; then
8862       DIRS="$DIRS $dir"
8863     fi
8864   done
8865 fi
8866
8867 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
8868
8869
8870   for try in $_smart_include_dir; do
8871     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcap.h in $try" >&5
8872 $as_echo_n "checking for pcap.h in $try... " >&6; }
8873     CPPFLAGS="-isystem $try $old_CPPFLAGS"
8874     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8875 /* end confdefs.h.  */
8876
8877                     #include <pcap.h>
8878 int
8879 main ()
8880 {
8881 int a = 1;
8882   ;
8883   return 0;
8884 }
8885 _ACEOF
8886 if ac_fn_c_try_compile "$LINENO"; then :
8887
8888                      smart_include="-isystem $try"
8889                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8890 $as_echo "yes" >&6; }
8891                      break
8892
8893 else
8894
8895                      smart_include=
8896                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8897 $as_echo "no" >&6; }
8898
8899 fi
8900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8901   done
8902   CPPFLAGS="$old_CPPFLAGS"
8903 fi
8904
8905 if test "x$smart_include" != "x"; then
8906   eval "ac_cv_header_$ac_safe=yes"
8907   CPPFLAGS="$smart_include $old_CPPFLAGS"
8908   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
8909 fi
8910
8911 smart_prefix=
8912
8913   if test "x$ac_cv_header_pcap_h" == "xyes"; then
8914
8915 $as_echo "#define HAVE_PCAP_H 1" >>confdefs.h
8916
8917
8918
8919   else
8920     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcap headers not found, silently disabling the RADIUS sniffer, and ARP listener. Use --with-pcap-include-dir=<path>." >&5
8921 $as_echo "$as_me: WARNING: pcap headers not found, silently disabling the RADIUS sniffer, and ARP listener. Use --with-pcap-include-dir=<path>." >&2;}
8922   fi
8923 fi
8924
8925 if test "x$COLLECTDC_LIBS" = x; then
8926   { $as_echo "$as_me:${as_lineno-$LINENO}: skipping test for collectd/client.h." >&5
8927 $as_echo "$as_me: skipping test for collectd/client.h." >&6;}
8928 else
8929         smart_try_dir="$collectdclient_include_dir"
8930
8931
8932 ac_safe=`echo "collectd/client.h" | sed 'y%./+-%__pm%'`
8933 old_CPPFLAGS="$CPPFLAGS"
8934 smart_include=
8935 smart_include_dir="/usr/local/include /opt/include"
8936
8937 _smart_try_dir=
8938 _smart_include_dir=
8939
8940 for _prefix in $smart_prefix ""; do
8941   for _dir in $smart_try_dir; do
8942     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
8943   done
8944
8945   for _dir in $smart_include_dir; do
8946     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
8947   done
8948 done
8949
8950 if test "x$_smart_try_dir" != "x"; then
8951   for try in $_smart_try_dir; do
8952     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for collectd/client.h in $try" >&5
8953 $as_echo_n "checking for collectd/client.h in $try... " >&6; }
8954     CPPFLAGS="-isystem $try $old_CPPFLAGS"
8955     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8956 /* end confdefs.h.  */
8957
8958                     #include <collectd/client.h>
8959 int
8960 main ()
8961 {
8962 int a = 1;
8963   ;
8964   return 0;
8965 }
8966 _ACEOF
8967 if ac_fn_c_try_compile "$LINENO"; then :
8968
8969                      smart_include="-isystem $try"
8970                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8971 $as_echo "yes" >&6; }
8972                      break
8973
8974 else
8975
8976                      smart_include=
8977                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8978 $as_echo "no" >&6; }
8979
8980 fi
8981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8982   done
8983   CPPFLAGS="$old_CPPFLAGS"
8984 fi
8985
8986 if test "x$smart_include" = "x"; then
8987   for _prefix in $smart_prefix; do
8988     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/collectd/client.h" >&5
8989 $as_echo_n "checking for ${_prefix}/collectd/client.h... " >&6; }
8990
8991     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8992 /* end confdefs.h.  */
8993
8994                     #include <collectd/client.h>
8995 int
8996 main ()
8997 {
8998 int a = 1;
8999   ;
9000   return 0;
9001 }
9002 _ACEOF
9003 if ac_fn_c_try_compile "$LINENO"; then :
9004
9005                      smart_include="-isystem ${_prefix}/"
9006                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9007 $as_echo "yes" >&6; }
9008                      break
9009
9010 else
9011
9012                      smart_include=
9013                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9014 $as_echo "no" >&6; }
9015
9016 fi
9017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9018   done
9019 fi
9020
9021 if test "x$smart_include" = "x"; then
9022     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for collectd/client.h" >&5
9023 $as_echo_n "checking for collectd/client.h... " >&6; }
9024
9025     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9026 /* end confdefs.h.  */
9027
9028                     #include <collectd/client.h>
9029 int
9030 main ()
9031 {
9032 int a = 1;
9033   ;
9034   return 0;
9035 }
9036 _ACEOF
9037 if ac_fn_c_try_compile "$LINENO"; then :
9038
9039                      smart_include=" "
9040                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9041 $as_echo "yes" >&6; }
9042                      break
9043
9044 else
9045
9046                      smart_include=
9047                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9048 $as_echo "no" >&6; }
9049
9050 fi
9051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9052 fi
9053
9054 if test "x$smart_include" = "x"; then
9055
9056   for prefix in $smart_prefix; do
9057
9058
9059 if test "x$LOCATE" != "x"; then
9060         DIRS=
9061   file="${_prefix}/${1}"
9062
9063   for x in `${LOCATE} $file 2>/dev/null`; do
9064                                         base=`echo $x | sed "s%/${file}%%"`
9065     if test "x$x" = "x$base"; then
9066       continue;
9067     fi
9068
9069     dir=`${DIRNAME} $x 2>/dev/null`
9070                 exclude=`echo ${dir} | ${GREP} /home`
9071     if test "x$exclude" != "x"; then
9072       continue
9073     fi
9074
9075                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
9076     if test "x$already" = "x"; then
9077       DIRS="$DIRS $dir"
9078     fi
9079   done
9080 fi
9081
9082 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
9083
9084   done
9085
9086
9087 if test "x$LOCATE" != "x"; then
9088         DIRS=
9089   file=collectd/client.h
9090
9091   for x in `${LOCATE} $file 2>/dev/null`; do
9092                                         base=`echo $x | sed "s%/${file}%%"`
9093     if test "x$x" = "x$base"; then
9094       continue;
9095     fi
9096
9097     dir=`${DIRNAME} $x 2>/dev/null`
9098                 exclude=`echo ${dir} | ${GREP} /home`
9099     if test "x$exclude" != "x"; then
9100       continue
9101     fi
9102
9103                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
9104     if test "x$already" = "x"; then
9105       DIRS="$DIRS $dir"
9106     fi
9107   done
9108 fi
9109
9110 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
9111
9112
9113   for try in $_smart_include_dir; do
9114     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for collectd/client.h in $try" >&5
9115 $as_echo_n "checking for collectd/client.h in $try... " >&6; }
9116     CPPFLAGS="-isystem $try $old_CPPFLAGS"
9117     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9118 /* end confdefs.h.  */
9119
9120                     #include <collectd/client.h>
9121 int
9122 main ()
9123 {
9124 int a = 1;
9125   ;
9126   return 0;
9127 }
9128 _ACEOF
9129 if ac_fn_c_try_compile "$LINENO"; then :
9130
9131                      smart_include="-isystem $try"
9132                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9133 $as_echo "yes" >&6; }
9134                      break
9135
9136 else
9137
9138                      smart_include=
9139                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9140 $as_echo "no" >&6; }
9141
9142 fi
9143 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9144   done
9145   CPPFLAGS="$old_CPPFLAGS"
9146 fi
9147
9148 if test "x$smart_include" != "x"; then
9149   eval "ac_cv_header_$ac_safe=yes"
9150   CPPFLAGS="$smart_include $old_CPPFLAGS"
9151   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
9152 fi
9153
9154 smart_prefix=
9155
9156   if test "x$ac_cv_header_collectd_client_h" == "xyes"; then
9157
9158 $as_echo "#define HAVE_COLLECTDC_H 1" >>confdefs.h
9159
9160
9161
9162   else
9163     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: collectdclient headers not found. Use --with-collectdclient-include-dir=<path>." >&5
9164 $as_echo "$as_me: WARNING: collectdclient headers not found. Use --with-collectdclient-include-dir=<path>." >&2;}
9165   fi
9166 fi
9167
9168 if test "x$HAVE_LIBCAP" = x; then
9169   { $as_echo "$as_me:${as_lineno-$LINENO}: skipping test for cap.h." >&5
9170 $as_echo "$as_me: skipping test for cap.h." >&6;}
9171 else
9172         smart_try_dir="$cap_include_dir"
9173
9174
9175 ac_safe=`echo "sys/capability.h" | sed 'y%./+-%__pm%'`
9176 old_CPPFLAGS="$CPPFLAGS"
9177 smart_include=
9178 smart_include_dir="/usr/local/include /opt/include"
9179
9180 _smart_try_dir=
9181 _smart_include_dir=
9182
9183 for _prefix in $smart_prefix ""; do
9184   for _dir in $smart_try_dir; do
9185     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
9186   done
9187
9188   for _dir in $smart_include_dir; do
9189     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
9190   done
9191 done
9192
9193 if test "x$_smart_try_dir" != "x"; then
9194   for try in $_smart_try_dir; do
9195     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/capability.h in $try" >&5
9196 $as_echo_n "checking for sys/capability.h in $try... " >&6; }
9197     CPPFLAGS="-isystem $try $old_CPPFLAGS"
9198     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9199 /* end confdefs.h.  */
9200
9201                     #include <sys/capability.h>
9202 int
9203 main ()
9204 {
9205 int a = 1;
9206   ;
9207   return 0;
9208 }
9209 _ACEOF
9210 if ac_fn_c_try_compile "$LINENO"; then :
9211
9212                      smart_include="-isystem $try"
9213                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9214 $as_echo "yes" >&6; }
9215                      break
9216
9217 else
9218
9219                      smart_include=
9220                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9221 $as_echo "no" >&6; }
9222
9223 fi
9224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9225   done
9226   CPPFLAGS="$old_CPPFLAGS"
9227 fi
9228
9229 if test "x$smart_include" = "x"; then
9230   for _prefix in $smart_prefix; do
9231     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/sys/capability.h" >&5
9232 $as_echo_n "checking for ${_prefix}/sys/capability.h... " >&6; }
9233
9234     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9235 /* end confdefs.h.  */
9236
9237                     #include <sys/capability.h>
9238 int
9239 main ()
9240 {
9241 int a = 1;
9242   ;
9243   return 0;
9244 }
9245 _ACEOF
9246 if ac_fn_c_try_compile "$LINENO"; then :
9247
9248                      smart_include="-isystem ${_prefix}/"
9249                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9250 $as_echo "yes" >&6; }
9251                      break
9252
9253 else
9254
9255                      smart_include=
9256                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9257 $as_echo "no" >&6; }
9258
9259 fi
9260 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9261   done
9262 fi
9263
9264 if test "x$smart_include" = "x"; then
9265     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/capability.h" >&5
9266 $as_echo_n "checking for sys/capability.h... " >&6; }
9267
9268     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9269 /* end confdefs.h.  */
9270
9271                     #include <sys/capability.h>
9272 int
9273 main ()
9274 {
9275 int a = 1;
9276   ;
9277   return 0;
9278 }
9279 _ACEOF
9280 if ac_fn_c_try_compile "$LINENO"; then :
9281
9282                      smart_include=" "
9283                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9284 $as_echo "yes" >&6; }
9285                      break
9286
9287 else
9288
9289                      smart_include=
9290                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9291 $as_echo "no" >&6; }
9292
9293 fi
9294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9295 fi
9296
9297 if test "x$smart_include" = "x"; then
9298
9299   for prefix in $smart_prefix; do
9300
9301
9302 if test "x$LOCATE" != "x"; then
9303         DIRS=
9304   file="${_prefix}/${1}"
9305
9306   for x in `${LOCATE} $file 2>/dev/null`; do
9307                                         base=`echo $x | sed "s%/${file}%%"`
9308     if test "x$x" = "x$base"; then
9309       continue;
9310     fi
9311
9312     dir=`${DIRNAME} $x 2>/dev/null`
9313                 exclude=`echo ${dir} | ${GREP} /home`
9314     if test "x$exclude" != "x"; then
9315       continue
9316     fi
9317
9318                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
9319     if test "x$already" = "x"; then
9320       DIRS="$DIRS $dir"
9321     fi
9322   done
9323 fi
9324
9325 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
9326
9327   done
9328
9329
9330 if test "x$LOCATE" != "x"; then
9331         DIRS=
9332   file=sys/capability.h
9333
9334   for x in `${LOCATE} $file 2>/dev/null`; do
9335                                         base=`echo $x | sed "s%/${file}%%"`
9336     if test "x$x" = "x$base"; then
9337       continue;
9338     fi
9339
9340     dir=`${DIRNAME} $x 2>/dev/null`
9341                 exclude=`echo ${dir} | ${GREP} /home`
9342     if test "x$exclude" != "x"; then
9343       continue
9344     fi
9345
9346                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
9347     if test "x$already" = "x"; then
9348       DIRS="$DIRS $dir"
9349     fi
9350   done
9351 fi
9352
9353 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
9354
9355
9356   for try in $_smart_include_dir; do
9357     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/capability.h in $try" >&5
9358 $as_echo_n "checking for sys/capability.h in $try... " >&6; }
9359     CPPFLAGS="-isystem $try $old_CPPFLAGS"
9360     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9361 /* end confdefs.h.  */
9362
9363                     #include <sys/capability.h>
9364 int
9365 main ()
9366 {
9367 int a = 1;
9368   ;
9369   return 0;
9370 }
9371 _ACEOF
9372 if ac_fn_c_try_compile "$LINENO"; then :
9373
9374                      smart_include="-isystem $try"
9375                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9376 $as_echo "yes" >&6; }
9377                      break
9378
9379 else
9380
9381                      smart_include=
9382                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9383 $as_echo "no" >&6; }
9384
9385 fi
9386 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9387   done
9388   CPPFLAGS="$old_CPPFLAGS"
9389 fi
9390
9391 if test "x$smart_include" != "x"; then
9392   eval "ac_cv_header_$ac_safe=yes"
9393   CPPFLAGS="$smart_include $old_CPPFLAGS"
9394   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
9395 fi
9396
9397 smart_prefix=
9398
9399   if test "x$ac_cv_header_sys_capability_h" == "xyes"; then
9400
9401 $as_echo "#define HAVE_CAPABILITY_H 1" >>confdefs.h
9402
9403   else
9404     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cap headers not found, will not perform debugger checks. Use --with-cap-include-dir=<path>." >&5
9405 $as_echo "$as_me: WARNING: cap headers not found, will not perform debugger checks. Use --with-cap-include-dir=<path>." >&2;}
9406   fi
9407 fi
9408
9409
9410 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
9411 if test "x$ac_cv_type_off_t" = xyes; then :
9412
9413 else
9414
9415 cat >>confdefs.h <<_ACEOF
9416 #define off_t long int
9417 _ACEOF
9418
9419 fi
9420
9421 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
9422 if test "x$ac_cv_type_pid_t" = xyes; then :
9423
9424 else
9425
9426 cat >>confdefs.h <<_ACEOF
9427 #define pid_t int
9428 _ACEOF
9429
9430 fi
9431
9432 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
9433 if test "x$ac_cv_type_size_t" = xyes; then :
9434
9435 else
9436
9437 cat >>confdefs.h <<_ACEOF
9438 #define size_t unsigned int
9439 _ACEOF
9440
9441 fi
9442
9443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
9444 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
9445 if ${ac_cv_type_uid_t+:} false; then :
9446   $as_echo_n "(cached) " >&6
9447 else
9448   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9449 /* end confdefs.h.  */
9450 #include <sys/types.h>
9451
9452 _ACEOF
9453 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9454   $EGREP "uid_t" >/dev/null 2>&1; then :
9455   ac_cv_type_uid_t=yes
9456 else
9457   ac_cv_type_uid_t=no
9458 fi
9459 rm -f conftest*
9460
9461 fi
9462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
9463 $as_echo "$ac_cv_type_uid_t" >&6; }
9464 if test $ac_cv_type_uid_t = no; then
9465
9466 $as_echo "#define uid_t int" >>confdefs.h
9467
9468
9469 $as_echo "#define gid_t int" >>confdefs.h
9470
9471 fi
9472
9473
9474
9475   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5
9476 $as_echo_n "checking for socklen_t... " >&6; }
9477 if ${ac_cv_type_socklen_t+:} false; then :
9478   $as_echo_n "(cached) " >&6
9479 else
9480    ac_cv_type_socklen_t=no
9481       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9482 /* end confdefs.h.  */
9483 #ifdef HAVE_SYS_TYPES_H
9484     #  include <sys/types.h>
9485     #endif
9486
9487     #ifdef HAVE_SYS_SOCKET_H
9488     #  include <sys/socket.h>
9489     #endif
9490
9491 int
9492 main ()
9493 {
9494 socklen_t foo
9495   ;
9496   return 0;
9497 }
9498 _ACEOF
9499 if ac_fn_c_try_compile "$LINENO"; then :
9500   ac_cv_type_socklen_t=yes
9501 fi
9502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9503
9504
9505 fi
9506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_socklen_t" >&5
9507 $as_echo "$ac_cv_type_socklen_t" >&6; }
9508
9509   if test "$ac_cv_type_socklen_t" != "yes"; then
9510
9511 $as_echo "#define socklen_t int" >>confdefs.h
9512
9513   fi
9514
9515
9516
9517   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint8_t" >&5
9518 $as_echo_n "checking for uint8_t... " >&6; }
9519 if ${ac_cv_type_uint8_t+:} false; then :
9520   $as_echo_n "(cached) " >&6
9521 else
9522    ac_cv_type_uint8_t=no
9523       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9524 /* end confdefs.h.  */
9525 #ifdef HAVE_INTTYPES_H
9526     #  include <inttypes.h>
9527     #endif
9528
9529     #ifdef HAVE_STDINT_H
9530     #  include <stdint.h>
9531     #endif
9532
9533 int
9534 main ()
9535 {
9536 uint8_t foo
9537   ;
9538   return 0;
9539 }
9540 _ACEOF
9541 if ac_fn_c_try_compile "$LINENO"; then :
9542   ac_cv_type_uint8_t=yes
9543 fi
9544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9545
9546
9547 fi
9548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uint8_t" >&5
9549 $as_echo "$ac_cv_type_uint8_t" >&6; }
9550
9551   if test "$ac_cv_type_uint8_t" != "yes"; then
9552
9553 $as_echo "#define uint8_t unsigned char" >>confdefs.h
9554
9555   fi
9556
9557
9558
9559   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint16_t" >&5
9560 $as_echo_n "checking for uint16_t... " >&6; }
9561 if ${ac_cv_type_uint16_t+:} false; then :
9562   $as_echo_n "(cached) " >&6
9563 else
9564    ac_cv_type_uint16_t=no
9565       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9566 /* end confdefs.h.  */
9567 #ifdef HAVE_INTTYPES_H
9568     #  include <inttypes.h>
9569     #endif
9570
9571     #ifdef HAVE_STDINT_H
9572     #  include <stdint.h>
9573     #endif
9574
9575 int
9576 main ()
9577 {
9578 uint16_t foo
9579   ;
9580   return 0;
9581 }
9582 _ACEOF
9583 if ac_fn_c_try_compile "$LINENO"; then :
9584   ac_cv_type_uint16_t=yes
9585 fi
9586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9587
9588
9589 fi
9590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uint16_t" >&5
9591 $as_echo "$ac_cv_type_uint16_t" >&6; }
9592
9593   if test "$ac_cv_type_uint16_t" != "yes"; then
9594
9595 $as_echo "#define uint16_t unsigned short" >>confdefs.h
9596
9597   fi
9598
9599
9600
9601   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint32_t" >&5
9602 $as_echo_n "checking for uint32_t... " >&6; }
9603 if ${ac_cv_type_uint32_t+:} false; then :
9604   $as_echo_n "(cached) " >&6
9605 else
9606    ac_cv_type_uint32_t=no
9607       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9608 /* end confdefs.h.  */
9609 #ifdef HAVE_INTTYPES_H
9610     #  include <inttypes.h>
9611     #endif
9612
9613     #ifdef HAVE_STDINT_H
9614     #  include <stdint.h>
9615     #endif
9616
9617 int
9618 main ()
9619 {
9620 uint32_t foo
9621   ;
9622   return 0;
9623 }
9624 _ACEOF
9625 if ac_fn_c_try_compile "$LINENO"; then :
9626   ac_cv_type_uint32_t=yes
9627 fi
9628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9629
9630
9631 fi
9632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uint32_t" >&5
9633 $as_echo "$ac_cv_type_uint32_t" >&6; }
9634
9635   if test "$ac_cv_type_uint32_t" != "yes"; then
9636
9637 $as_echo "#define uint32_t unsigned int" >>confdefs.h
9638
9639   fi
9640
9641
9642
9643   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint64_t" >&5
9644 $as_echo_n "checking for uint64_t... " >&6; }
9645 if ${ac_cv_type_uint64_t+:} false; then :
9646   $as_echo_n "(cached) " >&6
9647 else
9648    ac_cv_type_uint64_t=no
9649       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9650 /* end confdefs.h.  */
9651 #ifdef HAVE_INTTYPES_H
9652     #  include <inttypes.h>
9653     #endif
9654
9655     #ifdef HAVE_STDINT_H
9656     #  include <stdint.h>
9657     #endif
9658
9659 int
9660 main ()
9661 {
9662 uint64_t foo
9663   ;
9664   return 0;
9665 }
9666 _ACEOF
9667 if ac_fn_c_try_compile "$LINENO"; then :
9668   ac_cv_type_uint64_t=yes
9669 fi
9670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9671
9672
9673 fi
9674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uint64_t" >&5
9675 $as_echo "$ac_cv_type_uint64_t" >&6; }
9676
9677   if test "$ac_cv_type_uint64_t" != "yes"; then
9678
9679 $as_echo "#define uint64_t unsigned long long" >>confdefs.h
9680
9681   fi
9682
9683
9684 ac_fn_c_check_type "$LINENO" "__uint128_t" "ac_cv_type___uint128_t" "$ac_includes_default"
9685 if test "x$ac_cv_type___uint128_t" = xyes; then :
9686
9687 $as_echo "#define HAVE___UINT128_T 1" >>confdefs.h
9688
9689 fi
9690
9691
9692 ac_fn_c_check_type "$LINENO" "uint128_t" "ac_cv_type_uint128_t" "
9693     #ifdef HAVE_INTTYPES_H
9694     #  include <inttypes.h>
9695     #endif
9696
9697     #ifdef HAVE_STDINT_H
9698     #  include <stdint.h>
9699     #endif
9700
9701
9702 "
9703 if test "x$ac_cv_type_uint128_t" = xyes; then :
9704
9705 $as_echo "#define HAVE_UINT128_T 1" >>confdefs.h
9706
9707 fi
9708
9709
9710 ac_fn_c_check_type "$LINENO" "struct in6_addr" "ac_cv_type_struct_in6_addr" "
9711     #ifdef HAVE_NETINET_IN_H
9712     #  include <netinet/in.h>
9713     #endif
9714
9715
9716 "
9717 if test "x$ac_cv_type_struct_in6_addr" = xyes; then :
9718
9719 $as_echo "#define HAVE_STRUCT_IN6_ADDR 1" >>confdefs.h
9720
9721 fi
9722
9723
9724 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
9725     #ifdef HAVE_NETINET_IN_H
9726     #  include <netinet/in.h>
9727     #endif
9728
9729     #ifdef HAVE_SYS_SOCKET_H
9730     #  include <sys/socket.h>
9731     #endif
9732
9733 "
9734 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
9735
9736 $as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
9737
9738 fi
9739
9740
9741 ac_fn_c_check_type "$LINENO" "struct sockaddr_in6" "ac_cv_type_struct_sockaddr_in6" "
9742     #ifdef HAVE_NETINET_IN_H
9743     #  include <netinet/in.h>
9744     #endif
9745
9746 "
9747 if test "x$ac_cv_type_struct_sockaddr_in6" = xyes; then :
9748
9749 $as_echo "#define HAVE_STRUCT_SOCKADDR_IN6 1" >>confdefs.h
9750
9751 fi
9752
9753
9754 ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "
9755     #ifdef HAVE_SYS_TYPES_H
9756     #  include <sys/types.h>
9757     #endif
9758
9759     #ifdef HAVE_SYS_SOCKET_H
9760     #  include <sys/socket.h>
9761     #endif
9762
9763     #ifdef HAVE_NETDB_H
9764     #  include <netdb.h>
9765     #endif
9766
9767
9768 "
9769 if test "x$ac_cv_type_struct_addrinfo" = xyes; then :
9770
9771 $as_echo "#define HAVE_STRUCT_ADDRINFO 1" >>confdefs.h
9772
9773 fi
9774
9775
9776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sig_t is defined" >&5
9777 $as_echo_n "checking if sig_t is defined... " >&6; }
9778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9779 /* end confdefs.h.  */
9780
9781       #ifdef HAVE_SIGNAL_H
9782       #  include <signal.h>
9783       #endif
9784
9785 int
9786 main ()
9787 {
9788
9789       sig_t func;
9790       return 0;
9791
9792
9793   ;
9794   return 0;
9795 }
9796 _ACEOF
9797 if ac_fn_c_try_link "$LINENO"; then :
9798
9799       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9800 $as_echo "yes" >&6; }
9801
9802 $as_echo "#define HAVE_SIG_T 1" >>confdefs.h
9803
9804
9805 else
9806
9807       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9808 $as_echo "no" >&6; }
9809
9810
9811 fi
9812 rm -f core conftest.err conftest.$ac_objext \
9813     conftest$ac_exeext conftest.$ac_ext
9814
9815 for ac_func in \
9816   getopt_long \
9817   fcntl \
9818   strsignal \
9819   sigaction \
9820   sigprocmask \
9821   pthread_sigmask \
9822   snprintf \
9823   vsnprintf \
9824   setsid \
9825   strncasecmp \
9826   strcasecmp \
9827   localtime_r \
9828   ctime_r \
9829   gmtime_r \
9830   strsep \
9831   inet_aton \
9832   inet_pton \
9833   inet_ntop \
9834   mallopt \
9835   setlinebuf \
9836   setvbuf \
9837   getusershell \
9838   initgroups \
9839   getaddrinfo \
9840   getnameinfo \
9841   closefrom \
9842   gettimeofday \
9843   getpeereid \
9844   setuid \
9845   setresuid \
9846   getresuid \
9847   strlcat \
9848   strlcpy
9849
9850 do :
9851   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9852 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9853 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9854   cat >>confdefs.h <<_ACEOF
9855 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9856 _ACEOF
9857
9858 fi
9859 done
9860
9861
9862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
9863 $as_echo_n "checking return type of signal handlers... " >&6; }
9864 if ${ac_cv_type_signal+:} false; then :
9865   $as_echo_n "(cached) " >&6
9866 else
9867   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9868 /* end confdefs.h.  */
9869 #include <sys/types.h>
9870 #include <signal.h>
9871
9872 int
9873 main ()
9874 {
9875 return *(signal (0, 0)) (0) == 1;
9876   ;
9877   return 0;
9878 }
9879 _ACEOF
9880 if ac_fn_c_try_compile "$LINENO"; then :
9881   ac_cv_type_signal=int
9882 else
9883   ac_cv_type_signal=void
9884 fi
9885 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9886 fi
9887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
9888 $as_echo "$ac_cv_type_signal" >&6; }
9889
9890 cat >>confdefs.h <<_ACEOF
9891 #define RETSIGTYPE $ac_cv_type_signal
9892 _ACEOF
9893
9894
9895
9896 if test "x$ac_cv_header_utmpx_h" = "xyes"; then
9897
9898   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_xtime in struct utmpx" >&5
9899 $as_echo_n "checking for ut_xtime in struct utmpx... " >&6; }
9900
9901
9902   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9903 /* end confdefs.h.  */
9904
9905 #include <utmpx.h>
9906 #ifdef HAVE_STDDEF_H
9907 #include <stddef.h>
9908 #endif
9909 #ifndef offsetof
9910 #define offsetof(TYPE, MEMBER) ((int) &((TYPE *)0)->MEMBER)
9911 #endif
9912
9913 int
9914 main ()
9915 {
9916  int foo = offsetof(struct utmpx, ut_xtime)
9917   ;
9918   return 0;
9919 }
9920 _ACEOF
9921 if ac_fn_c_try_compile "$LINENO"; then :
9922   has_element=" "
9923 else
9924   has_element=
9925 fi
9926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9927
9928   ac_safe_type=`echo "struct utmpx" | sed 'y% %_%'`
9929   if test "x$has_element" != "x"; then
9930     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9931 $as_echo "yes" >&6; }
9932     eval "ac_cv_type_${ac_safe_type}_has_ut_xtime=yes"
9933   else
9934     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9935 $as_echo "no" >&6; }
9936     eval "ac_cv_type_${ac_safe_type}_has_ut_xtime="
9937  fi
9938
9939  if test "x$ac_cv_type_struct_utmpx_has_ut_xtime" = "x"; then
9940
9941 $as_echo "#define ut_xtime ut_tv.tv_sec" >>confdefs.h
9942
9943  fi
9944 fi
9945
9946
9947   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ipi_addr in struct in_pktinfo" >&5
9948 $as_echo_n "checking for ipi_addr in struct in_pktinfo... " >&6; }
9949
9950
9951   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9952 /* end confdefs.h.  */
9953
9954 #include <netinet/in.h>
9955 #ifdef HAVE_STDDEF_H
9956 #include <stddef.h>
9957 #endif
9958 #ifndef offsetof
9959 #define offsetof(TYPE, MEMBER) ((int) &((TYPE *)0)->MEMBER)
9960 #endif
9961
9962 int
9963 main ()
9964 {
9965  int foo = offsetof(struct in_pktinfo, ipi_addr)
9966   ;
9967   return 0;
9968 }
9969 _ACEOF
9970 if ac_fn_c_try_compile "$LINENO"; then :
9971   has_element=" "
9972 else
9973   has_element=
9974 fi
9975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9976
9977   ac_safe_type=`echo "struct in_pktinfo" | sed 'y% %_%'`
9978   if test "x$has_element" != "x"; then
9979     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9980 $as_echo "yes" >&6; }
9981     eval "ac_cv_type_${ac_safe_type}_has_ipi_addr=yes"
9982   else
9983     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9984 $as_echo "no" >&6; }
9985     eval "ac_cv_type_${ac_safe_type}_has_ipi_addr="
9986  fi
9987
9988 if test "x$ac_cv_type_struct_in_pktinfo_has_ipi_addr" = "xyes"; then
9989
9990 $as_echo "#define HAVE_IP_PKTINFO /**/" >>confdefs.h
9991
9992 fi
9993
9994
9995   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ipi6_addr in struct in6_pktinfo" >&5
9996 $as_echo_n "checking for ipi6_addr in struct in6_pktinfo... " >&6; }
9997
9998
9999   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10000 /* end confdefs.h.  */
10001
10002 #include <netinet/in.h>
10003 #ifdef HAVE_STDDEF_H
10004 #include <stddef.h>
10005 #endif
10006 #ifndef offsetof
10007 #define offsetof(TYPE, MEMBER) ((int) &((TYPE *)0)->MEMBER)
10008 #endif
10009
10010 int
10011 main ()
10012 {
10013  int foo = offsetof(struct in6_pktinfo, ipi6_addr)
10014   ;
10015   return 0;
10016 }
10017 _ACEOF
10018 if ac_fn_c_try_compile "$LINENO"; then :
10019   has_element=" "
10020 else
10021   has_element=
10022 fi
10023 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10024
10025   ac_safe_type=`echo "struct in6_pktinfo" | sed 'y% %_%'`
10026   if test "x$has_element" != "x"; then
10027     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10028 $as_echo "yes" >&6; }
10029     eval "ac_cv_type_${ac_safe_type}_has_ipi6_addr=yes"
10030   else
10031     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10032 $as_echo "no" >&6; }
10033     eval "ac_cv_type_${ac_safe_type}_has_ipi6_addr="
10034  fi
10035
10036 if test "x$ac_cv_type_struct_in6_pktinfo_has_ipi6_addr" = "xyes"; then
10037
10038 $as_echo "#define HAVE_IN6_PKTINFO /**/" >>confdefs.h
10039
10040 fi
10041
10042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if htonll is defined" >&5
10043 $as_echo_n "checking if htonll is defined... " >&6; }
10044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10045 /* end confdefs.h.  */
10046
10047       #include <sys/types.h>
10048       #include <netinet/in.h>
10049
10050 int
10051 main ()
10052 {
10053
10054       return htonll(0);
10055
10056
10057   ;
10058   return 0;
10059 }
10060 _ACEOF
10061 if ac_fn_c_try_link "$LINENO"; then :
10062
10063       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10064 $as_echo "yes" >&6; }
10065
10066 $as_echo "#define HAVE_HTONLL 1" >>confdefs.h
10067
10068
10069 else
10070
10071       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10072 $as_echo "no" >&6; }
10073
10074
10075 fi
10076 rm -f core conftest.err conftest.$ac_objext \
10077     conftest$ac_exeext conftest.$ac_ext
10078
10079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if htonlll is defined" >&5
10080 $as_echo_n "checking if htonlll is defined... " >&6; }
10081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10082 /* end confdefs.h.  */
10083
10084       #include <sys/types.h>
10085       #include <netinet/in.h>
10086
10087 int
10088 main ()
10089 {
10090
10091       return htonlll(0);
10092
10093
10094   ;
10095   return 0;
10096 }
10097 _ACEOF
10098 if ac_fn_c_try_link "$LINENO"; then :
10099
10100       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10101 $as_echo "yes" >&6; }
10102
10103 $as_echo "#define HAVE_HTONLLL 1" >>confdefs.h
10104
10105
10106 else
10107
10108       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10109 $as_echo "no" >&6; }
10110
10111
10112 fi
10113 rm -f core conftest.err conftest.$ac_objext \
10114     conftest$ac_exeext conftest.$ac_ext
10115
10116
10117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
10118 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
10119 if ${ac_cv_c_const+:} false; then :
10120   $as_echo_n "(cached) " >&6
10121 else
10122   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10123 /* end confdefs.h.  */
10124
10125 int
10126 main ()
10127 {
10128
10129 #ifndef __cplusplus
10130   /* Ultrix mips cc rejects this sort of thing.  */
10131   typedef int charset[2];
10132   const charset cs = { 0, 0 };
10133   /* SunOS 4.1.1 cc rejects this.  */
10134   char const *const *pcpcc;
10135   char **ppc;
10136   /* NEC SVR4.0.2 mips cc rejects this.  */
10137   struct point {int x, y;};
10138   static struct point const zero = {0,0};
10139   /* AIX XL C 1.02.0.0 rejects this.
10140      It does not let you subtract one const X* pointer from another in
10141      an arm of an if-expression whose if-part is not a constant
10142      expression */
10143   const char *g = "string";
10144   pcpcc = &g + (g ? g-g : 0);
10145   /* HPUX 7.0 cc rejects these. */
10146   ++pcpcc;
10147   ppc = (char**) pcpcc;
10148   pcpcc = (char const *const *) ppc;
10149   { /* SCO 3.2v4 cc rejects this sort of thing.  */
10150     char tx;
10151     char *t = &tx;
10152     char const *s = 0 ? (char *) 0 : (char const *) 0;
10153
10154     *t++ = 0;
10155     if (s) return 0;
10156   }
10157   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
10158     int x[] = {25, 17};
10159     const int *foo = &x[0];
10160     ++foo;
10161   }
10162   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10163     typedef const int *iptr;
10164     iptr p = 0;
10165     ++p;
10166   }
10167   { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
10168        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10169     struct s { int j; const int *ap[3]; } bx;
10170     struct s *b = &bx; b->j = 5;
10171   }
10172   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10173     const int foo = 10;
10174     if (!foo) return 0;
10175   }
10176   return !cs[0] && !zero.x;
10177 #endif
10178
10179   ;
10180   return 0;
10181 }
10182 _ACEOF
10183 if ac_fn_c_try_compile "$LINENO"; then :
10184   ac_cv_c_const=yes
10185 else
10186   ac_cv_c_const=no
10187 fi
10188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10189 fi
10190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
10191 $as_echo "$ac_cv_c_const" >&6; }
10192 if test $ac_cv_c_const = no; then
10193
10194 $as_echo "#define const /**/" >>confdefs.h
10195
10196 fi
10197
10198
10199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of OS" >&5
10200 $as_echo_n "checking type of OS... " >&6; }
10201 OS=`uname -s`
10202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OS" >&5
10203 $as_echo "$OS" >&6; }
10204 if test "$OS" = "OS/2"; then
10205   LIBPREFIX=
10206 else
10207   LIBPREFIX=lib
10208 fi
10209
10210
10211 if test "x$developer" = "xyes"; then
10212   { $as_echo "$as_me:${as_lineno-$LINENO}: Setting additional developer CFLAGS" >&5
10213 $as_echo "$as_me: Setting additional developer CFLAGS" >&6;}
10214
10215
10216   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the compiler flag \"-Wdocumentation\"" >&5
10217 $as_echo_n "checking for the compiler flag \"-Wdocumentation\"... " >&6; }
10218 if ${ax_cv_cc_wdocumentation_flag+:} false; then :
10219   $as_echo_n "(cached) " >&6
10220 else
10221
10222
10223     CFLAGS_SAVED=$CFLAGS
10224     CFLAGS="$CFLAGS -Werror -Wdocumentation"
10225
10226     ac_ext=c
10227 ac_cpp='$CPP $CPPFLAGS'
10228 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10229 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10230 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10231
10232     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10233 /* end confdefs.h.  */
10234
10235 int
10236 main ()
10237 {
10238 return 0;
10239   ;
10240   return 0;
10241 }
10242 _ACEOF
10243 if ac_fn_c_try_compile "$LINENO"; then :
10244   ax_cv_cc_wdocumentation_flag="yes"
10245 else
10246   ax_cv_cc_wdocumentation_flag="no"
10247 fi
10248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10249     ac_ext=c
10250 ac_cpp='$CPP $CPPFLAGS'
10251 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10252 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10253 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10254
10255
10256     CFLAGS="$CFLAGS_SAVED"
10257
10258 fi
10259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cc_wdocumentation_flag" >&5
10260 $as_echo "$ax_cv_cc_wdocumentation_flag" >&6; }
10261
10262   if test "x$ax_cv_cc_wdocumentation_flag" = "xyes"; then
10263     devflags="-Wdocumentation"
10264   fi
10265
10266   if test "x$GCC" = "xyes"; then
10267     devflags="$devflags -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -W -Wredundant-decls -Wundef -Wformat-y2k -Wno-format-extra-args -Wno-format-zero-length -Wno-cast-align -Wformat-nonliteral -Wformat-security -Wformat=2 -DWITH_VERIFY_PTR=1"
10268     INSTALLSTRIP=""
10269   fi
10270
10271   { $as_echo "$as_me:${as_lineno-$LINENO}: Developer CFLAGS are \"$devflags\"" >&5
10272 $as_echo "$as_me: Developer CFLAGS are \"$devflags\"" >&6;}
10273
10274   CFLAGS="$CFLAGS $devflags"
10275         if test "x$EXPERIMENTAL" != "xno"; then
10276     { $as_echo "$as_me:${as_lineno-$LINENO}: is developer build, enabling experimental modules implicitly, disable with --without-experimental-modules" >&5
10277 $as_echo "$as_me: is developer build, enabling experimental modules implicitly, disable with --without-experimental-modules" >&6;}
10278     EXPERIMENTAL=yes
10279   fi
10280 else
10281   devflags=""
10282   CFLAGS="$CFLAGS -DNDEBUG"
10283   INSTALLSTRIP=""
10284 fi
10285
10286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if building with -DNDEBUG" >&5
10287 $as_echo_n "checking if building with -DNDEBUG... " >&6; }
10288 if echo "$CFLAGS" | grep '\-DNDEBUG' > /dev/null; then
10289   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10290 $as_echo "yes" >&6; }
10291
10292 $as_echo "#define WITH_NDEBUG 1" >>confdefs.h
10293
10294 else
10295   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10296 $as_echo "no" >&6; }
10297 fi
10298
10299 export EXPERIMENTAL
10300
10301 if test -d $srcdir/.git -a "x$GIT" = "xyes"; then
10302   RADIUSD_VERSION_COMMIT=`git log --pretty=format:'%h' -n 1`
10303
10304 cat >>confdefs.h <<_ACEOF
10305 #define RADIUSD_VERSION_COMMIT ${RADIUSD_VERSION_COMMIT}
10306 _ACEOF
10307
10308 fi
10309
10310
10311   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread support in compiler" >&5
10312 $as_echo_n "checking for __thread support in compiler... " >&6; }
10313   if test "$cross_compiling" = yes; then :
10314   have_tls=no
10315 else
10316   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10317 /* end confdefs.h.  */
10318
10319         static __thread int val;
10320         int main(int argc, char **argv) {
10321           val = 0;
10322           return val;
10323         }
10324
10325
10326 _ACEOF
10327 if ac_fn_c_try_run "$LINENO"; then :
10328   have_tls=yes
10329 else
10330   have_tls=no
10331 fi
10332 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10333   conftest.$ac_objext conftest.beam conftest.$ac_ext
10334 fi
10335
10336   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_tls" >&5
10337 $as_echo "$have_tls" >&6; }
10338   if test "x$have_tls" = "xyes"; then
10339
10340 $as_echo "#define TLS_STORAGE_CLASS __thread" >>confdefs.h
10341
10342   fi
10343
10344   if test "x$have_tls" = "xno"; then
10345     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __declspec(thread) support in compiler" >&5
10346 $as_echo_n "checking for __declspec(thread) support in compiler... " >&6; }
10347     if test "$cross_compiling" = yes; then :
10348   have_tls=no
10349 else
10350   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10351 /* end confdefs.h.  */
10352
10353           static _Thread_local int val;
10354           int main(int argc, char **argv) {
10355             val = 0;
10356             return val;
10357           }
10358
10359
10360 _ACEOF
10361 if ac_fn_c_try_run "$LINENO"; then :
10362   have_tls=yes
10363 else
10364   have_tls=no
10365 fi
10366 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10367   conftest.$ac_objext conftest.beam conftest.$ac_ext
10368 fi
10369
10370     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_tls" >&5
10371 $as_echo "$have_tls" >&6; }
10372     if test "x$have_tls" = "xyes"; then
10373
10374 $as_echo "#define TLS_STORAGE_CLASS __declspec(thread)" >>confdefs.h
10375
10376     fi
10377   fi
10378   if test "x$have_tls" = "xno"; then
10379     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Thread_local support in compiler" >&5
10380 $as_echo_n "checking for _Thread_local support in compiler... " >&6; }
10381     if test "$cross_compiling" = yes; then :
10382   have_tls=no
10383 else
10384   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10385 /* end confdefs.h.  */
10386
10387           static _Thread_local int val;
10388           int main(int argc, char **argv) {
10389             val = 0;
10390             return val;
10391           }
10392
10393
10394 _ACEOF
10395 if ac_fn_c_try_run "$LINENO"; then :
10396   have_tls=yes
10397 else
10398   have_tls=no
10399 fi
10400 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10401   conftest.$ac_objext conftest.beam conftest.$ac_ext
10402 fi
10403
10404     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_tls" >&5
10405 $as_echo "$have_tls" >&6; }
10406     if test "x$have_tls" = "xyes"; then
10407
10408 $as_echo "#define TLS_STORAGE_CLASS _Thread_local" >>confdefs.h
10409
10410     fi
10411   fi
10412
10413
10414   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_choose_expr support in compiler" >&5
10415 $as_echo_n "checking for __builtin_choose_expr support in compiler... " >&6; }
10416   if test "$cross_compiling" = yes; then :
10417   have_builtin_choose_expr=no
10418 else
10419   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10420 /* end confdefs.h.  */
10421
10422         int main(int argc, char **argv) {
10423           return __builtin_choose_expr(0, 1, 0);
10424         }
10425
10426
10427 _ACEOF
10428 if ac_fn_c_try_run "$LINENO"; then :
10429   have_builtin_choose_expr=yes
10430 else
10431   have_builtin_choose_expr=no
10432 fi
10433 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10434   conftest.$ac_objext conftest.beam conftest.$ac_ext
10435 fi
10436
10437   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_builtin_choose_expr" >&5
10438 $as_echo "$have_builtin_choose_expr" >&6; }
10439   if test "x$have_builtin_choose_expr" = "xyes"; then
10440
10441 $as_echo "#define HAVE_BUILTIN_CHOOSE_EXPR 1" >>confdefs.h
10442
10443   fi
10444
10445
10446   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_types_compatible_p support in compiler" >&5
10447 $as_echo_n "checking for __builtin_types_compatible_p support in compiler... " >&6; }
10448   if test "$cross_compiling" = yes; then :
10449   have_builtin_types_compatible_p=no
10450 else
10451   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10452 /* end confdefs.h.  */
10453
10454         int main(int argc, char **argv) {
10455           return !(__builtin_types_compatible_p(char *, char *));
10456         }
10457
10458
10459 _ACEOF
10460 if ac_fn_c_try_run "$LINENO"; then :
10461   have_builtin_types_compatible_p=yes
10462 else
10463   have_builtin_types_compatible_p=no
10464 fi
10465 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10466   conftest.$ac_objext conftest.beam conftest.$ac_ext
10467 fi
10468
10469   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_builtin_types_compatible_p" >&5
10470 $as_echo "$have_builtin_types_compatible_p" >&6; }
10471   if test "x$have_builtin_types_compatible_p" = "xyes"; then
10472
10473 $as_echo "#define HAVE_BUILTIN_TYPES_COMPATIBLE_P 1" >>confdefs.h
10474
10475   fi
10476
10477
10478   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap64 support in compiler" >&5
10479 $as_echo_n "checking for __builtin_bswap64 support in compiler... " >&6; }
10480   if test "$cross_compiling" = yes; then :
10481   have_builtin_bswap64=no
10482 else
10483   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10484 /* end confdefs.h.  */
10485
10486         int main(int argc, char **argv) {
10487           return (__builtin_bswap64(0));
10488         }
10489
10490
10491 _ACEOF
10492 if ac_fn_c_try_run "$LINENO"; then :
10493   have_builtin_bswap64=yes
10494 else
10495   have_builtin_bswap64=no
10496 fi
10497 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10498   conftest.$ac_objext conftest.beam conftest.$ac_ext
10499 fi
10500
10501   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_builtin_bswap64" >&5
10502 $as_echo "$have_builtin_bswap64" >&6; }
10503   if test "x$have_builtin_bswap64" = "xyes"; then
10504
10505 $as_echo "#define HAVE_BUILTIN_BSWAP_64 1" >>confdefs.h
10506
10507   fi
10508
10509
10510
10511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for talloc_set_memlimit in -ltalloc" >&5
10512 $as_echo_n "checking for talloc_set_memlimit in -ltalloc... " >&6; }
10513 if ${ac_cv_lib_talloc_talloc_set_memlimit+:} false; then :
10514   $as_echo_n "(cached) " >&6
10515 else
10516   ac_check_lib_save_LIBS=$LIBS
10517 LIBS="-ltalloc  $LIBS"
10518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10519 /* end confdefs.h.  */
10520
10521 /* Override any GCC internal prototype to avoid an error.
10522    Use char because int might match the return type of a GCC
10523    builtin and then its argument prototype would still apply.  */
10524 #ifdef __cplusplus
10525 extern "C"
10526 #endif
10527 char talloc_set_memlimit ();
10528 int
10529 main ()
10530 {
10531 return talloc_set_memlimit ();
10532   ;
10533   return 0;
10534 }
10535 _ACEOF
10536 if ac_fn_c_try_link "$LINENO"; then :
10537   ac_cv_lib_talloc_talloc_set_memlimit=yes
10538 else
10539   ac_cv_lib_talloc_talloc_set_memlimit=no
10540 fi
10541 rm -f core conftest.err conftest.$ac_objext \
10542     conftest$ac_exeext conftest.$ac_ext
10543 LIBS=$ac_check_lib_save_LIBS
10544 fi
10545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_talloc_talloc_set_memlimit" >&5
10546 $as_echo "$ac_cv_lib_talloc_talloc_set_memlimit" >&6; }
10547 if test "x$ac_cv_lib_talloc_talloc_set_memlimit" = xyes; then :
10548
10549
10550 $as_echo "#define HAVE_TALLOC_SET_MEMLIMIT 1" >>confdefs.h
10551
10552
10553
10554 fi
10555
10556
10557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5
10558 $as_echo_n "checking for crypt in -lcrypt... " >&6; }
10559 if ${ac_cv_lib_crypt_crypt+:} false; then :
10560   $as_echo_n "(cached) " >&6
10561 else
10562   ac_check_lib_save_LIBS=$LIBS
10563 LIBS="-lcrypt  $LIBS"
10564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10565 /* end confdefs.h.  */
10566
10567 /* Override any GCC internal prototype to avoid an error.
10568    Use char because int might match the return type of a GCC
10569    builtin and then its argument prototype would still apply.  */
10570 #ifdef __cplusplus
10571 extern "C"
10572 #endif
10573 char crypt ();
10574 int
10575 main ()
10576 {
10577 return crypt ();
10578   ;
10579   return 0;
10580 }
10581 _ACEOF
10582 if ac_fn_c_try_link "$LINENO"; then :
10583   ac_cv_lib_crypt_crypt=yes
10584 else
10585   ac_cv_lib_crypt_crypt=no
10586 fi
10587 rm -f core conftest.err conftest.$ac_objext \
10588     conftest$ac_exeext conftest.$ac_ext
10589 LIBS=$ac_check_lib_save_LIBS
10590 fi
10591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
10592 $as_echo "$ac_cv_lib_crypt_crypt" >&6; }
10593 if test "x$ac_cv_lib_crypt_crypt" = xyes; then :
10594   CRYPTLIB="-lcrypt"
10595
10596 fi
10597
10598
10599 if test "$CRYPTLIB" != ""; then
10600
10601 $as_echo "#define HAVE_CRYPT /**/" >>confdefs.h
10602
10603 else
10604   ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
10605 if test "x$ac_cv_func_crypt" = xyes; then :
10606
10607 $as_echo "#define HAVE_CRYPT /**/" >>confdefs.h
10608
10609 fi
10610
10611 fi
10612
10613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setkey in -lcipher" >&5
10614 $as_echo_n "checking for setkey in -lcipher... " >&6; }
10615 if ${ac_cv_lib_cipher_setkey+:} false; then :
10616   $as_echo_n "(cached) " >&6
10617 else
10618   ac_check_lib_save_LIBS=$LIBS
10619 LIBS="-lcipher  $LIBS"
10620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10621 /* end confdefs.h.  */
10622
10623 /* Override any GCC internal prototype to avoid an error.
10624    Use char because int might match the return type of a GCC
10625    builtin and then its argument prototype would still apply.  */
10626 #ifdef __cplusplus
10627 extern "C"
10628 #endif
10629 char setkey ();
10630 int
10631 main ()
10632 {
10633 return setkey ();
10634   ;
10635   return 0;
10636 }
10637 _ACEOF
10638 if ac_fn_c_try_link "$LINENO"; then :
10639   ac_cv_lib_cipher_setkey=yes
10640 else
10641   ac_cv_lib_cipher_setkey=no
10642 fi
10643 rm -f core conftest.err conftest.$ac_objext \
10644     conftest$ac_exeext conftest.$ac_ext
10645 LIBS=$ac_check_lib_save_LIBS
10646 fi
10647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cipher_setkey" >&5
10648 $as_echo "$ac_cv_lib_cipher_setkey" >&6; }
10649 if test "x$ac_cv_lib_cipher_setkey" = xyes; then :
10650   CRYPTLIB="${CRYPTLIB} -lcipher"
10651
10652 fi
10653
10654
10655
10656 execinfo_lib_dir=
10657
10658 # Check whether --with-execinfo-lib-dir was given.
10659 if test "${with_execinfo_lib_dir+set}" = set; then :
10660   withval=$with_execinfo_lib_dir;  case "$withval" in
10661     no)
10662         as_fn_error $? "Need execinfo-lib-dir" "$LINENO" 5
10663         ;;
10664     yes)
10665         ;;
10666     *)
10667         execinfo_lib_dir="$withval"
10668         ;;
10669   esac
10670
10671 fi
10672
10673
10674 execinfo_include_dir=
10675
10676 # Check whether --with-execinfo-include-dir was given.
10677 if test "${with_execinfo_include_dir+set}" = set; then :
10678   withval=$with_execinfo_include_dir;  case "$withval" in
10679     no)
10680         as_fn_error $? "Need execinfo-include-dir" "$LINENO" 5
10681         ;;
10682     yes)
10683         ;;
10684     *)
10685         execinfo_include_dir="$withval"
10686         ;;
10687   esac
10688
10689 fi
10690
10691
10692 smart_try_dir=$execinfo_include_dir
10693
10694
10695 ac_safe=`echo "execinfo.h" | sed 'y%./+-%__pm%'`
10696 old_CPPFLAGS="$CPPFLAGS"
10697 smart_include=
10698 smart_include_dir="/usr/local/include /opt/include"
10699
10700 _smart_try_dir=
10701 _smart_include_dir=
10702
10703 for _prefix in $smart_prefix ""; do
10704   for _dir in $smart_try_dir; do
10705     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
10706   done
10707
10708   for _dir in $smart_include_dir; do
10709     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
10710   done
10711 done
10712
10713 if test "x$_smart_try_dir" != "x"; then
10714   for try in $_smart_try_dir; do
10715     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for execinfo.h in $try" >&5
10716 $as_echo_n "checking for execinfo.h in $try... " >&6; }
10717     CPPFLAGS="-isystem $try $old_CPPFLAGS"
10718     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10719 /* end confdefs.h.  */
10720
10721                     #include <execinfo.h>
10722 int
10723 main ()
10724 {
10725 int a = 1;
10726   ;
10727   return 0;
10728 }
10729 _ACEOF
10730 if ac_fn_c_try_compile "$LINENO"; then :
10731
10732                      smart_include="-isystem $try"
10733                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10734 $as_echo "yes" >&6; }
10735                      break
10736
10737 else
10738
10739                      smart_include=
10740                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10741 $as_echo "no" >&6; }
10742
10743 fi
10744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10745   done
10746   CPPFLAGS="$old_CPPFLAGS"
10747 fi
10748
10749 if test "x$smart_include" = "x"; then
10750   for _prefix in $smart_prefix; do
10751     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/execinfo.h" >&5
10752 $as_echo_n "checking for ${_prefix}/execinfo.h... " >&6; }
10753
10754     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10755 /* end confdefs.h.  */
10756
10757                     #include <execinfo.h>
10758 int
10759 main ()
10760 {
10761 int a = 1;
10762   ;
10763   return 0;
10764 }
10765 _ACEOF
10766 if ac_fn_c_try_compile "$LINENO"; then :
10767
10768                      smart_include="-isystem ${_prefix}/"
10769                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10770 $as_echo "yes" >&6; }
10771                      break
10772
10773 else
10774
10775                      smart_include=
10776                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10777 $as_echo "no" >&6; }
10778
10779 fi
10780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10781   done
10782 fi
10783
10784 if test "x$smart_include" = "x"; then
10785     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for execinfo.h" >&5
10786 $as_echo_n "checking for execinfo.h... " >&6; }
10787
10788     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10789 /* end confdefs.h.  */
10790
10791                     #include <execinfo.h>
10792 int
10793 main ()
10794 {
10795 int a = 1;
10796   ;
10797   return 0;
10798 }
10799 _ACEOF
10800 if ac_fn_c_try_compile "$LINENO"; then :
10801
10802                      smart_include=" "
10803                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10804 $as_echo "yes" >&6; }
10805                      break
10806
10807 else
10808
10809                      smart_include=
10810                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10811 $as_echo "no" >&6; }
10812
10813 fi
10814 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10815 fi
10816
10817 if test "x$smart_include" = "x"; then
10818
10819   for prefix in $smart_prefix; do
10820
10821
10822 if test "x$LOCATE" != "x"; then
10823         DIRS=
10824   file="${_prefix}/${1}"
10825
10826   for x in `${LOCATE} $file 2>/dev/null`; do
10827                                         base=`echo $x | sed "s%/${file}%%"`
10828     if test "x$x" = "x$base"; then
10829       continue;
10830     fi
10831
10832     dir=`${DIRNAME} $x 2>/dev/null`
10833                 exclude=`echo ${dir} | ${GREP} /home`
10834     if test "x$exclude" != "x"; then
10835       continue
10836     fi
10837
10838                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
10839     if test "x$already" = "x"; then
10840       DIRS="$DIRS $dir"
10841     fi
10842   done
10843 fi
10844
10845 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
10846
10847   done
10848
10849
10850 if test "x$LOCATE" != "x"; then
10851         DIRS=
10852   file=execinfo.h
10853
10854   for x in `${LOCATE} $file 2>/dev/null`; do
10855                                         base=`echo $x | sed "s%/${file}%%"`
10856     if test "x$x" = "x$base"; then
10857       continue;
10858     fi
10859
10860     dir=`${DIRNAME} $x 2>/dev/null`
10861                 exclude=`echo ${dir} | ${GREP} /home`
10862     if test "x$exclude" != "x"; then
10863       continue
10864     fi
10865
10866                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
10867     if test "x$already" = "x"; then
10868       DIRS="$DIRS $dir"
10869     fi
10870   done
10871 fi
10872
10873 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
10874
10875
10876   for try in $_smart_include_dir; do
10877     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for execinfo.h in $try" >&5
10878 $as_echo_n "checking for execinfo.h in $try... " >&6; }
10879     CPPFLAGS="-isystem $try $old_CPPFLAGS"
10880     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10881 /* end confdefs.h.  */
10882
10883                     #include <execinfo.h>
10884 int
10885 main ()
10886 {
10887 int a = 1;
10888   ;
10889   return 0;
10890 }
10891 _ACEOF
10892 if ac_fn_c_try_compile "$LINENO"; then :
10893
10894                      smart_include="-isystem $try"
10895                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10896 $as_echo "yes" >&6; }
10897                      break
10898
10899 else
10900
10901                      smart_include=
10902                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10903 $as_echo "no" >&6; }
10904
10905 fi
10906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10907   done
10908   CPPFLAGS="$old_CPPFLAGS"
10909 fi
10910
10911 if test "x$smart_include" != "x"; then
10912   eval "ac_cv_header_$ac_safe=yes"
10913   CPPFLAGS="$smart_include $old_CPPFLAGS"
10914   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
10915 fi
10916
10917 smart_prefix=
10918
10919 if test "x$ac_cv_header_execinfo_h" = "xyes"; then
10920   smart_try_dir=$execinfo_lib_dir
10921
10922
10923 sm_lib_safe=`echo "execinfo" | sed 'y%./+-%__p_%'`
10924 sm_func_safe=`echo "backtrace_symbols" | sed 'y%./+-%__p_%'`
10925
10926 old_LIBS="$LIBS"
10927 old_CPPFLAGS="$CPPFLAGS"
10928 smart_lib=
10929 smart_ldflags=
10930 smart_lib_dir=
10931
10932 if test "x$smart_try_dir" != "x"; then
10933   for try in $smart_try_dir; do
10934     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for backtrace_symbols in -lexecinfo in $try" >&5
10935 $as_echo_n "checking for backtrace_symbols in -lexecinfo in $try... " >&6; }
10936     LIBS="-lexecinfo $old_LIBS"
10937     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
10938     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10939 /* end confdefs.h.  */
10940 extern char backtrace_symbols();
10941 int
10942 main ()
10943 {
10944 backtrace_symbols()
10945   ;
10946   return 0;
10947 }
10948 _ACEOF
10949 if ac_fn_c_try_link "$LINENO"; then :
10950
10951                  smart_lib="-lexecinfo"
10952                  smart_ldflags="-L$try -Wl,-rpath,$try"
10953                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10954 $as_echo "yes" >&6; }
10955                  break
10956
10957 else
10958   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10959 $as_echo "no" >&6; }
10960 fi
10961 rm -f core conftest.err conftest.$ac_objext \
10962     conftest$ac_exeext conftest.$ac_ext
10963   done
10964   LIBS="$old_LIBS"
10965   CPPFLAGS="$old_CPPFLAGS"
10966 fi
10967
10968 if test "x$smart_lib" = "x"; then
10969   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for backtrace_symbols in -lexecinfo" >&5
10970 $as_echo_n "checking for backtrace_symbols in -lexecinfo... " >&6; }
10971   LIBS="-lexecinfo $old_LIBS"
10972   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10973 /* end confdefs.h.  */
10974 extern char backtrace_symbols();
10975 int
10976 main ()
10977 {
10978 backtrace_symbols()
10979   ;
10980   return 0;
10981 }
10982 _ACEOF
10983 if ac_fn_c_try_link "$LINENO"; then :
10984
10985                 smart_lib="-lexecinfo"
10986                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10987 $as_echo "yes" >&6; }
10988
10989 else
10990   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10991 $as_echo "no" >&6; }
10992 fi
10993 rm -f core conftest.err conftest.$ac_objext \
10994     conftest$ac_exeext conftest.$ac_ext
10995   LIBS="$old_LIBS"
10996 fi
10997
10998 if test "x$smart_lib" = "x"; then
10999
11000
11001 if test "x$LOCATE" != "x"; then
11002         DIRS=
11003   file=libexecinfo${libltdl_cv_shlibext}
11004
11005   for x in `${LOCATE} $file 2>/dev/null`; do
11006                                         base=`echo $x | sed "s%/${file}%%"`
11007     if test "x$x" = "x$base"; then
11008       continue;
11009     fi
11010
11011     dir=`${DIRNAME} $x 2>/dev/null`
11012                 exclude=`echo ${dir} | ${GREP} /home`
11013     if test "x$exclude" != "x"; then
11014       continue
11015     fi
11016
11017                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
11018     if test "x$already" = "x"; then
11019       DIRS="$DIRS $dir"
11020     fi
11021   done
11022 fi
11023
11024 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
11025
11026
11027
11028 if test "x$LOCATE" != "x"; then
11029         DIRS=
11030   file=libexecinfo.a
11031
11032   for x in `${LOCATE} $file 2>/dev/null`; do
11033                                         base=`echo $x | sed "s%/${file}%%"`
11034     if test "x$x" = "x$base"; then
11035       continue;
11036     fi
11037
11038     dir=`${DIRNAME} $x 2>/dev/null`
11039                 exclude=`echo ${dir} | ${GREP} /home`
11040     if test "x$exclude" != "x"; then
11041       continue
11042     fi
11043
11044                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
11045     if test "x$already" = "x"; then
11046       DIRS="$DIRS $dir"
11047     fi
11048   done
11049 fi
11050
11051 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
11052
11053
11054   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
11055     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for backtrace_symbols in -lexecinfo in $try" >&5
11056 $as_echo_n "checking for backtrace_symbols in -lexecinfo in $try... " >&6; }
11057     LIBS="-lexecinfo $old_LIBS"
11058     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
11059     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11060 /* end confdefs.h.  */
11061 extern char backtrace_symbols();
11062 int
11063 main ()
11064 {
11065 backtrace_symbols()
11066   ;
11067   return 0;
11068 }
11069 _ACEOF
11070 if ac_fn_c_try_link "$LINENO"; then :
11071
11072                   smart_lib="-lexecinfo"
11073                   smart_ldflags="-L$try -Wl,-rpath,$try"
11074                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11075 $as_echo "yes" >&6; }
11076                   break
11077
11078 else
11079   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11080 $as_echo "no" >&6; }
11081 fi
11082 rm -f core conftest.err conftest.$ac_objext \
11083     conftest$ac_exeext conftest.$ac_ext
11084   done
11085   LIBS="$old_LIBS"
11086   CPPFLAGS="$old_CPPFLAGS"
11087 fi
11088
11089 if test "x$smart_lib" != "x"; then
11090   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
11091   LIBS="$smart_ldflags $smart_lib $old_LIBS"
11092   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
11093 fi
11094
11095   if test "x$ac_cv_lib_execinfo_backtrace_symbols" != "xyes"; then
11096         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if execinfo provided as part of libc" >&5
11097 $as_echo_n "checking if execinfo provided as part of libc... " >&6; }
11098     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11099 /* end confdefs.h.  */
11100
11101         #include <execinfo.h>
11102
11103 int
11104 main ()
11105 {
11106
11107         void *sym[1];
11108         backtrace_symbols(&sym, sizeof(sym))
11109   ;
11110   return 0;
11111 }
11112 _ACEOF
11113 if ac_fn_c_try_link "$LINENO"; then :
11114
11115         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11116 $as_echo "yes" >&6; }
11117         ac_cv_lib_execinfo_backtrace_symbols="yes"
11118
11119 else
11120
11121         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11122 $as_echo "no" >&6; }
11123
11124
11125 fi
11126 rm -f core conftest.err conftest.$ac_objext \
11127     conftest$ac_exeext conftest.$ac_ext
11128   fi
11129
11130   if test "x$ac_cv_lib_execinfo_backtrace_symbols" = "xyes"; then
11131
11132 $as_echo "#define HAVE_EXECINFO 1" >>confdefs.h
11133
11134   fi
11135 fi
11136
11137 pcre_lib_dir=
11138
11139 # Check whether --with-pcre-lib-dir was given.
11140 if test "${with_pcre_lib_dir+set}" = set; then :
11141   withval=$with_pcre_lib_dir;  case "$withval" in
11142     no)
11143         as_fn_error $? "Need pcre-lib-dir" "$LINENO" 5
11144         ;;
11145     yes)
11146         ;;
11147     *)
11148         pcre_lib_dir="$withval"
11149         ;;
11150   esac
11151
11152 fi
11153
11154
11155 pcre_include_dir=
11156
11157 # Check whether --with-pcre-include-dir was given.
11158 if test "${with_pcre_include_dir+set}" = set; then :
11159   withval=$with_pcre_include_dir;  case "$withval" in
11160     no)
11161         as_fn_error $? "Need pcre-include-dir" "$LINENO" 5
11162         ;;
11163     yes)
11164         ;;
11165     *)
11166         pcre_include_dir="$withval"
11167         ;;
11168   esac
11169
11170 fi
11171
11172
11173 REGEX=
11174
11175 # Check whether --with-regex was given.
11176 if test "${with_regex+set}" = set; then :
11177   withval=$with_regex;  case "$withval" in
11178     no)
11179         REGEX=no
11180         ;;
11181     *)
11182         ;;
11183   esac
11184
11185 fi
11186
11187
11188 if test "x$REGEX" = "x"; then
11189   smart_try_dir=$pcre_include_dir
11190
11191
11192 ac_safe=`echo "pcreposix.h" | sed 'y%./+-%__pm%'`
11193 old_CPPFLAGS="$CPPFLAGS"
11194 smart_include=
11195 smart_include_dir="/usr/local/include /opt/include"
11196
11197 _smart_try_dir=
11198 _smart_include_dir=
11199
11200 for _prefix in $smart_prefix ""; do
11201   for _dir in $smart_try_dir; do
11202     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
11203   done
11204
11205   for _dir in $smart_include_dir; do
11206     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
11207   done
11208 done
11209
11210 if test "x$_smart_try_dir" != "x"; then
11211   for try in $_smart_try_dir; do
11212     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcreposix.h in $try" >&5
11213 $as_echo_n "checking for pcreposix.h in $try... " >&6; }
11214     CPPFLAGS="-isystem $try $old_CPPFLAGS"
11215     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11216 /* end confdefs.h.  */
11217
11218                     #include <pcreposix.h>
11219 int
11220 main ()
11221 {
11222 int a = 1;
11223   ;
11224   return 0;
11225 }
11226 _ACEOF
11227 if ac_fn_c_try_compile "$LINENO"; then :
11228
11229                      smart_include="-isystem $try"
11230                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11231 $as_echo "yes" >&6; }
11232                      break
11233
11234 else
11235
11236                      smart_include=
11237                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11238 $as_echo "no" >&6; }
11239
11240 fi
11241 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11242   done
11243   CPPFLAGS="$old_CPPFLAGS"
11244 fi
11245
11246 if test "x$smart_include" = "x"; then
11247   for _prefix in $smart_prefix; do
11248     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/pcreposix.h" >&5
11249 $as_echo_n "checking for ${_prefix}/pcreposix.h... " >&6; }
11250
11251     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11252 /* end confdefs.h.  */
11253
11254                     #include <pcreposix.h>
11255 int
11256 main ()
11257 {
11258 int a = 1;
11259   ;
11260   return 0;
11261 }
11262 _ACEOF
11263 if ac_fn_c_try_compile "$LINENO"; then :
11264
11265                      smart_include="-isystem ${_prefix}/"
11266                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11267 $as_echo "yes" >&6; }
11268                      break
11269
11270 else
11271
11272                      smart_include=
11273                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11274 $as_echo "no" >&6; }
11275
11276 fi
11277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11278   done
11279 fi
11280
11281 if test "x$smart_include" = "x"; then
11282     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcreposix.h" >&5
11283 $as_echo_n "checking for pcreposix.h... " >&6; }
11284
11285     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11286 /* end confdefs.h.  */
11287
11288                     #include <pcreposix.h>
11289 int
11290 main ()
11291 {
11292 int a = 1;
11293   ;
11294   return 0;
11295 }
11296 _ACEOF
11297 if ac_fn_c_try_compile "$LINENO"; then :
11298
11299                      smart_include=" "
11300                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11301 $as_echo "yes" >&6; }
11302                      break
11303
11304 else
11305
11306                      smart_include=
11307                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11308 $as_echo "no" >&6; }
11309
11310 fi
11311 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11312 fi
11313
11314 if test "x$smart_include" = "x"; then
11315
11316   for prefix in $smart_prefix; do
11317
11318
11319 if test "x$LOCATE" != "x"; then
11320         DIRS=
11321   file="${_prefix}/${1}"
11322
11323   for x in `${LOCATE} $file 2>/dev/null`; do
11324                                         base=`echo $x | sed "s%/${file}%%"`
11325     if test "x$x" = "x$base"; then
11326       continue;
11327     fi
11328
11329     dir=`${DIRNAME} $x 2>/dev/null`
11330                 exclude=`echo ${dir} | ${GREP} /home`
11331     if test "x$exclude" != "x"; then
11332       continue
11333     fi
11334
11335                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
11336     if test "x$already" = "x"; then
11337       DIRS="$DIRS $dir"
11338     fi
11339   done
11340 fi
11341
11342 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
11343
11344   done
11345
11346
11347 if test "x$LOCATE" != "x"; then
11348         DIRS=
11349   file=pcreposix.h
11350
11351   for x in `${LOCATE} $file 2>/dev/null`; do
11352                                         base=`echo $x | sed "s%/${file}%%"`
11353     if test "x$x" = "x$base"; then
11354       continue;
11355     fi
11356
11357     dir=`${DIRNAME} $x 2>/dev/null`
11358                 exclude=`echo ${dir} | ${GREP} /home`
11359     if test "x$exclude" != "x"; then
11360       continue
11361     fi
11362
11363                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
11364     if test "x$already" = "x"; then
11365       DIRS="$DIRS $dir"
11366     fi
11367   done
11368 fi
11369
11370 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
11371
11372
11373   for try in $_smart_include_dir; do
11374     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcreposix.h in $try" >&5
11375 $as_echo_n "checking for pcreposix.h in $try... " >&6; }
11376     CPPFLAGS="-isystem $try $old_CPPFLAGS"
11377     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11378 /* end confdefs.h.  */
11379
11380                     #include <pcreposix.h>
11381 int
11382 main ()
11383 {
11384 int a = 1;
11385   ;
11386   return 0;
11387 }
11388 _ACEOF
11389 if ac_fn_c_try_compile "$LINENO"; then :
11390
11391                      smart_include="-isystem $try"
11392                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11393 $as_echo "yes" >&6; }
11394                      break
11395
11396 else
11397
11398                      smart_include=
11399                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11400 $as_echo "no" >&6; }
11401
11402 fi
11403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11404   done
11405   CPPFLAGS="$old_CPPFLAGS"
11406 fi
11407
11408 if test "x$smart_include" != "x"; then
11409   eval "ac_cv_header_$ac_safe=yes"
11410   CPPFLAGS="$smart_include $old_CPPFLAGS"
11411   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
11412 fi
11413
11414 smart_prefix=
11415
11416   if test "x$ac_cv_header_pcreposix_h" = "xyes"; then
11417     smart_try_dir=$pcre_lib_dir
11418
11419
11420 sm_lib_safe=`echo "pcre" | sed 'y%./+-%__p_%'`
11421 sm_func_safe=`echo "pcre_compile" | sed 'y%./+-%__p_%'`
11422
11423 old_LIBS="$LIBS"
11424 old_CPPFLAGS="$CPPFLAGS"
11425 smart_lib=
11426 smart_ldflags=
11427 smart_lib_dir=
11428
11429 if test "x$smart_try_dir" != "x"; then
11430   for try in $smart_try_dir; do
11431     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre in $try" >&5
11432 $as_echo_n "checking for pcre_compile in -lpcre in $try... " >&6; }
11433     LIBS="-lpcre $old_LIBS"
11434     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
11435     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11436 /* end confdefs.h.  */
11437 extern char pcre_compile();
11438 int
11439 main ()
11440 {
11441 pcre_compile()
11442   ;
11443   return 0;
11444 }
11445 _ACEOF
11446 if ac_fn_c_try_link "$LINENO"; then :
11447
11448                  smart_lib="-lpcre"
11449                  smart_ldflags="-L$try -Wl,-rpath,$try"
11450                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11451 $as_echo "yes" >&6; }
11452                  break
11453
11454 else
11455   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11456 $as_echo "no" >&6; }
11457 fi
11458 rm -f core conftest.err conftest.$ac_objext \
11459     conftest$ac_exeext conftest.$ac_ext
11460   done
11461   LIBS="$old_LIBS"
11462   CPPFLAGS="$old_CPPFLAGS"
11463 fi
11464
11465 if test "x$smart_lib" = "x"; then
11466   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre" >&5
11467 $as_echo_n "checking for pcre_compile in -lpcre... " >&6; }
11468   LIBS="-lpcre $old_LIBS"
11469   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11470 /* end confdefs.h.  */
11471 extern char pcre_compile();
11472 int
11473 main ()
11474 {
11475 pcre_compile()
11476   ;
11477   return 0;
11478 }
11479 _ACEOF
11480 if ac_fn_c_try_link "$LINENO"; then :
11481
11482                 smart_lib="-lpcre"
11483                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11484 $as_echo "yes" >&6; }
11485
11486 else
11487   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11488 $as_echo "no" >&6; }
11489 fi
11490 rm -f core conftest.err conftest.$ac_objext \
11491     conftest$ac_exeext conftest.$ac_ext
11492   LIBS="$old_LIBS"
11493 fi
11494
11495 if test "x$smart_lib" = "x"; then
11496
11497
11498 if test "x$LOCATE" != "x"; then
11499         DIRS=
11500   file=libpcre${libltdl_cv_shlibext}
11501
11502   for x in `${LOCATE} $file 2>/dev/null`; do
11503                                         base=`echo $x | sed "s%/${file}%%"`
11504     if test "x$x" = "x$base"; then
11505       continue;
11506     fi
11507
11508     dir=`${DIRNAME} $x 2>/dev/null`
11509                 exclude=`echo ${dir} | ${GREP} /home`
11510     if test "x$exclude" != "x"; then
11511       continue
11512     fi
11513
11514                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
11515     if test "x$already" = "x"; then
11516       DIRS="$DIRS $dir"
11517     fi
11518   done
11519 fi
11520
11521 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
11522
11523
11524
11525 if test "x$LOCATE" != "x"; then
11526         DIRS=
11527   file=libpcre.a
11528
11529   for x in `${LOCATE} $file 2>/dev/null`; do
11530                                         base=`echo $x | sed "s%/${file}%%"`
11531     if test "x$x" = "x$base"; then
11532       continue;
11533     fi
11534
11535     dir=`${DIRNAME} $x 2>/dev/null`
11536                 exclude=`echo ${dir} | ${GREP} /home`
11537     if test "x$exclude" != "x"; then
11538       continue
11539     fi
11540
11541                     already=`echo \$smart_lib_dir ${DIRS} | ${GREP} ${dir}`
11542     if test "x$already" = "x"; then
11543       DIRS="$DIRS $dir"
11544     fi
11545   done
11546 fi
11547
11548 eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\""
11549
11550
11551   for try in $smart_lib_dir /usr/local/lib /opt/lib; do
11552     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre in $try" >&5
11553 $as_echo_n "checking for pcre_compile in -lpcre in $try... " >&6; }
11554     LIBS="-lpcre $old_LIBS"
11555     CPPFLAGS="-L$try -Wl,-rpath,$try $old_CPPFLAGS"
11556     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11557 /* end confdefs.h.  */
11558 extern char pcre_compile();
11559 int
11560 main ()
11561 {
11562 pcre_compile()
11563   ;
11564   return 0;
11565 }
11566 _ACEOF
11567 if ac_fn_c_try_link "$LINENO"; then :
11568
11569                   smart_lib="-lpcre"
11570                   smart_ldflags="-L$try -Wl,-rpath,$try"
11571                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11572 $as_echo "yes" >&6; }
11573                   break
11574
11575 else
11576   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11577 $as_echo "no" >&6; }
11578 fi
11579 rm -f core conftest.err conftest.$ac_objext \
11580     conftest$ac_exeext conftest.$ac_ext
11581   done
11582   LIBS="$old_LIBS"
11583   CPPFLAGS="$old_CPPFLAGS"
11584 fi
11585
11586 if test "x$smart_lib" != "x"; then
11587   eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes"
11588   LIBS="$smart_ldflags $smart_lib $old_LIBS"
11589   SMART_LIBS="$smart_ldflags $smart_lib $SMART_LIBS"
11590 fi
11591
11592     if test "x$ac_cv_lib_pcre_pcre_compile" = "xyes"; then
11593       REGEX=yes
11594
11595       smart_try_dir=$pcre_lib_dir
11596
11597 $as_echo "#define HAVE_PCRE 1" >>confdefs.h
11598
11599
11600                               LIBS=$(echo "$LIBS" | sed -e 's/-lpcre/-lpcre -lpcreposix/')
11601     fi
11602   fi
11603 fi
11604
11605 if test "x$REGEX" = "x"; then
11606   smart_try_dir=
11607
11608
11609 ac_safe=`echo "regex.h" | sed 'y%./+-%__pm%'`
11610 old_CPPFLAGS="$CPPFLAGS"
11611 smart_include=
11612 smart_include_dir="/usr/local/include /opt/include"
11613
11614 _smart_try_dir=
11615 _smart_include_dir=
11616
11617 for _prefix in $smart_prefix ""; do
11618   for _dir in $smart_try_dir; do
11619     _smart_try_dir="${_smart_try_dir} ${_dir}/${_prefix}"
11620   done
11621
11622   for _dir in $smart_include_dir; do
11623     _smart_include_dir="${_smart_include_dir} ${_dir}/${_prefix}"
11624   done
11625 done
11626
11627 if test "x$_smart_try_dir" != "x"; then
11628   for try in $_smart_try_dir; do
11629     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for regex.h in $try" >&5
11630 $as_echo_n "checking for regex.h in $try... " >&6; }
11631     CPPFLAGS="-isystem $try $old_CPPFLAGS"
11632     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11633 /* end confdefs.h.  */
11634
11635                     #include <regex.h>
11636 int
11637 main ()
11638 {
11639 int a = 1;
11640   ;
11641   return 0;
11642 }
11643 _ACEOF
11644 if ac_fn_c_try_compile "$LINENO"; then :
11645
11646                      smart_include="-isystem $try"
11647                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11648 $as_echo "yes" >&6; }
11649                      break
11650
11651 else
11652
11653                      smart_include=
11654                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11655 $as_echo "no" >&6; }
11656
11657 fi
11658 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11659   done
11660   CPPFLAGS="$old_CPPFLAGS"
11661 fi
11662
11663 if test "x$smart_include" = "x"; then
11664   for _prefix in $smart_prefix; do
11665     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${_prefix}/regex.h" >&5
11666 $as_echo_n "checking for ${_prefix}/regex.h... " >&6; }
11667
11668     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11669 /* end confdefs.h.  */
11670
11671                     #include <regex.h>
11672 int
11673 main ()
11674 {
11675 int a = 1;
11676   ;
11677   return 0;
11678 }
11679 _ACEOF
11680 if ac_fn_c_try_compile "$LINENO"; then :
11681
11682                      smart_include="-isystem ${_prefix}/"
11683                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11684 $as_echo "yes" >&6; }
11685                      break
11686
11687 else
11688
11689                      smart_include=
11690                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11691 $as_echo "no" >&6; }
11692
11693 fi
11694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11695   done
11696 fi
11697
11698 if test "x$smart_include" = "x"; then
11699     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for regex.h" >&5
11700 $as_echo_n "checking for regex.h... " >&6; }
11701
11702     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11703 /* end confdefs.h.  */
11704
11705                     #include <regex.h>
11706 int
11707 main ()
11708 {
11709 int a = 1;
11710   ;
11711   return 0;
11712 }
11713 _ACEOF
11714 if ac_fn_c_try_compile "$LINENO"; then :
11715
11716                      smart_include=" "
11717                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11718 $as_echo "yes" >&6; }
11719                      break
11720
11721 else
11722
11723                      smart_include=
11724                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11725 $as_echo "no" >&6; }
11726
11727 fi
11728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11729 fi
11730
11731 if test "x$smart_include" = "x"; then
11732
11733   for prefix in $smart_prefix; do
11734
11735
11736 if test "x$LOCATE" != "x"; then
11737         DIRS=
11738   file="${_prefix}/${1}"
11739
11740   for x in `${LOCATE} $file 2>/dev/null`; do
11741                                         base=`echo $x | sed "s%/${file}%%"`
11742     if test "x$x" = "x$base"; then
11743       continue;
11744     fi
11745
11746     dir=`${DIRNAME} $x 2>/dev/null`
11747                 exclude=`echo ${dir} | ${GREP} /home`
11748     if test "x$exclude" != "x"; then
11749       continue
11750     fi
11751
11752                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
11753     if test "x$already" = "x"; then
11754       DIRS="$DIRS $dir"
11755     fi
11756   done
11757 fi
11758
11759 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
11760
11761   done
11762
11763
11764 if test "x$LOCATE" != "x"; then
11765         DIRS=
11766   file=regex.h
11767
11768   for x in `${LOCATE} $file 2>/dev/null`; do
11769                                         base=`echo $x | sed "s%/${file}%%"`
11770     if test "x$x" = "x$base"; then
11771       continue;
11772     fi
11773
11774     dir=`${DIRNAME} $x 2>/dev/null`
11775                 exclude=`echo ${dir} | ${GREP} /home`
11776     if test "x$exclude" != "x"; then
11777       continue
11778     fi
11779
11780                     already=`echo \$_smart_include_dir ${DIRS} | ${GREP} ${dir}`
11781     if test "x$already" = "x"; then
11782       DIRS="$DIRS $dir"
11783     fi
11784   done
11785 fi
11786
11787 eval "_smart_include_dir=\"\$_smart_include_dir $DIRS\""
11788
11789
11790   for try in $_smart_include_dir; do
11791     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for regex.h in $try" >&5
11792 $as_echo_n "checking for regex.h in $try... " >&6; }
11793     CPPFLAGS="-isystem $try $old_CPPFLAGS"
11794     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11795 /* end confdefs.h.  */
11796
11797                     #include <regex.h>
11798 int
11799 main ()
11800 {
11801 int a = 1;
11802   ;
11803   return 0;
11804 }
11805 _ACEOF
11806 if ac_fn_c_try_compile "$LINENO"; then :
11807
11808                      smart_include="-isystem $try"
11809                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11810 $as_echo "yes" >&6; }
11811                      break
11812
11813 else
11814
11815                      smart_include=
11816                      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11817 $as_echo "no" >&6; }
11818
11819 fi
11820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11821   done
11822   CPPFLAGS="$old_CPPFLAGS"
11823 fi
11824
11825 if test "x$smart_include" != "x"; then
11826   eval "ac_cv_header_$ac_safe=yes"
11827   CPPFLAGS="$smart_include $old_CPPFLAGS"
11828   SMART_CPPFLAGS="$smart_include $SMART_CPPFLAGS"
11829 fi
11830
11831 smart_prefix=
11832
11833   if test "x$ac_cv_header_regex_h" = "xyes"; then
11834     REGEX=yes
11835     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extended regular expressions" >&5
11836 $as_echo_n "checking for extended regular expressions... " >&6; }
11837     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11838 /* end confdefs.h.  */
11839
11840         #include <regex.h>
11841         #ifdef REG_EXTENDED
11842         yes
11843         #endif
11844
11845 _ACEOF
11846 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11847   $EGREP "yes" >/dev/null 2>&1; then :
11848
11849         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11850 $as_echo "yes" >&6; }
11851
11852 $as_echo "#define HAVE_REG_EXTENDED 1" >>confdefs.h
11853
11854
11855 else
11856
11857         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11858 $as_echo "no" >&6; }
11859
11860
11861 fi
11862 rm -f conftest*
11863
11864
11865                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcomp in -lregex" >&5
11866 $as_echo_n "checking for regcomp in -lregex... " >&6; }
11867 if ${ac_cv_lib_regex_regcomp+:} false; then :
11868   $as_echo_n "(cached) " >&6
11869 else
11870   ac_check_lib_save_LIBS=$LIBS
11871 LIBS="-lregex  $LIBS"
11872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11873 /* end confdefs.h.  */
11874
11875 /* Override any GCC internal prototype to avoid an error.
11876    Use char because int might match the return type of a GCC
11877    builtin and then its argument prototype would still apply.  */
11878 #ifdef __cplusplus
11879 extern "C"
11880 #endif
11881 char regcomp ();
11882 int
11883 main ()
11884 {
11885 return regcomp ();
11886   ;
11887   return 0;
11888 }
11889 _ACEOF
11890 if ac_fn_c_try_link "$LINENO"; then :
11891   ac_cv_lib_regex_regcomp=yes
11892 else
11893   ac_cv_lib_regex_regcomp=no
11894 fi
11895 rm -f core conftest.err conftest.$ac_objext \
11896     conftest$ac_exeext conftest.$ac_ext
11897 LIBS=$ac_check_lib_save_LIBS
11898 fi
11899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_regex_regcomp" >&5
11900 $as_echo "$ac_cv_lib_regex_regcomp" >&6; }
11901 if test "x$ac_cv_lib_regex_regcomp" = xyes; then :
11902
11903         LIBS="-lregex $LIBS"
11904
11905
11906 fi
11907
11908   fi
11909 fi
11910
11911 if test "x$REGEX" = "xyes"; then
11912
11913 $as_echo "#define HAVE_REGEX 1" >>confdefs.h
11914
11915 fi
11916
11917
11918 $as_echo "#define GNUSTYLE 1" >>confdefs.h
11919
11920
11921
11922 $as_echo "#define SYSVSTYLE 2" >>confdefs.h
11923
11924
11925
11926 $as_echo "#define BSDSTYLE 3" >>confdefs.h
11927
11928
11929 gethostbyaddrrstyle=""
11930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyaddr_r() syntax" >&5
11931 $as_echo_n "checking gethostbyaddr_r() syntax... " >&6; }
11932 case "$host" in
11933   *-freebsd*)
11934                             ac_fn_c_check_decl "$LINENO" "gethostbyaddr_r" "ac_cv_have_decl_gethostbyaddr_r" "
11935         #ifdef HAVE_NETDB_H
11936         #include <netdb.h>
11937         #endif
11938
11939 "
11940 if test "x$ac_cv_have_decl_gethostbyaddr_r" = xyes; then :
11941   ac_have_decl=1
11942 else
11943   ac_have_decl=0
11944 fi
11945
11946 cat >>confdefs.h <<_ACEOF
11947 #define HAVE_DECL_GETHOSTBYADDR_R $ac_have_decl
11948 _ACEOF
11949 if test $ac_have_decl = 1; then :
11950
11951 else
11952
11953
11954 $as_echo "#define GETHOSTBYADDRRSTYLE BSDSTYLE" >>confdefs.h
11955
11956         gethostbyaddrrstyle=BSD
11957         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: FreeBSD overridden to BSD-style" >&5
11958 $as_echo "$as_me: WARNING: FreeBSD overridden to BSD-style" >&2;}
11959
11960 fi
11961
11962     ;;
11963 esac
11964
11965 if test "x$gethostbyaddrrstyle" = "x"; then
11966   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11967 /* end confdefs.h.  */
11968
11969       #include <stdio.h>
11970       #include <netdb.h>
11971
11972 int
11973 main ()
11974 {
11975  gethostbyaddr_r(NULL, 0, 0, NULL, NULL, 0, NULL, NULL)
11976   ;
11977   return 0;
11978 }
11979 _ACEOF
11980 if ac_fn_c_try_link "$LINENO"; then :
11981
11982
11983 $as_echo "#define GETHOSTBYADDRRSTYLE GNUSTYLE" >>confdefs.h
11984
11985       gethostbyaddrrstyle=GNU
11986
11987
11988 fi
11989 rm -f core conftest.err conftest.$ac_objext \
11990     conftest$ac_exeext conftest.$ac_ext
11991 fi
11992
11993 if test "x$gethostbyaddrrstyle" = "x"; then
11994   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11995 /* end confdefs.h.  */
11996
11997       #include <stdio.h>
11998       #include <netdb.h>
11999
12000 int
12001 main ()
12002 {
12003  gethostbyaddr_r(NULL, 0, 0, NULL, NULL, 0, NULL)
12004   ;
12005   return 0;
12006 }
12007 _ACEOF
12008 if ac_fn_c_try_link "$LINENO"; then :
12009
12010
12011 $as_echo "#define GETHOSTBYADDRRSTYLE SYSVSTYLE" >>confdefs.h
12012
12013       gethostbyaddrrstyle=SYSV
12014
12015
12016 fi
12017 rm -f core conftest.err conftest.$ac_objext \
12018     conftest$ac_exeext conftest.$ac_ext
12019 fi
12020
12021
12022 if test "x$gethostbyaddrrstyle" = "x"; then
12023   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12024 /* end confdefs.h.  */
12025
12026       #include <stdio.h>
12027       #include <netdb.h>
12028
12029 int
12030 main ()
12031 {
12032  gethostbyaddr(NULL, 0, 0)
12033   ;
12034   return 0;
12035 }
12036 _ACEOF
12037 if ac_fn_c_try_link "$LINENO"; then :
12038
12039
12040 $as_echo "#define GETHOSTBYADDRRSTYLE BSDSTYLE" >>confdefs.h
12041
12042       gethostbyaddrrstyle=BSD
12043
12044
12045 fi
12046 rm -f core conftest.err conftest.$ac_objext \
12047     conftest$ac_exeext conftest.$ac_ext
12048 fi
12049
12050 if test "x$gethostbyaddrrstyle" = "x"; then
12051   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none!  It must not exist, here." >&5
12052 $as_echo "none!  It must not exist, here." >&6; }
12053 else
12054   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${gethostbyaddrrstyle}-style" >&5
12055 $as_echo "${gethostbyaddrrstyle}-style" >&6; }
12056 fi
12057
12058 if test "x$gethostbyaddrrstyle" = "xBSD"; then
12059   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:  ****** BSD-style gethostbyaddr might NOT be thread-safe! ****** " >&5
12060 $as_echo "$as_me: WARNING:  ****** BSD-style gethostbyaddr might NOT be thread-safe! ****** " >&2;}
12061 fi
12062
12063 gethostbynamerstyle=""
12064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r() syntax" >&5
12065 $as_echo_n "checking gethostbyname_r() syntax... " >&6; }
12066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12067 /* end confdefs.h.  */
12068
12069     #include <stdio.h>
12070     #include <netdb.h>
12071
12072 int
12073 main ()
12074 {
12075  gethostbyname_r(NULL, NULL, NULL, 0, NULL, NULL)
12076   ;
12077   return 0;
12078 }
12079 _ACEOF
12080 if ac_fn_c_try_link "$LINENO"; then :
12081
12082
12083 $as_echo "#define GETHOSTBYNAMERSTYLE GNUSTYLE" >>confdefs.h
12084
12085     gethostbynamerstyle=GNU
12086
12087
12088 fi
12089 rm -f core conftest.err conftest.$ac_objext \
12090     conftest$ac_exeext conftest.$ac_ext
12091
12092 if test "x$gethostbynamerstyle" = "x"; then
12093   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12094 /* end confdefs.h.  */
12095
12096       #include <stdio.h>
12097       #include <netdb.h>
12098
12099 int
12100 main ()
12101 {
12102  gethostbyname_r(NULL, NULL, NULL, 0, NULL)
12103   ;
12104   return 0;
12105 }
12106 _ACEOF
12107 if ac_fn_c_try_link "$LINENO"; then :
12108
12109
12110 $as_echo "#define GETHOSTBYNAMERSTYLE SYSVSTYLE" >>confdefs.h
12111
12112       gethostbynamerstyle=SYSV
12113
12114
12115 fi
12116 rm -f core conftest.err conftest.$ac_objext \
12117     conftest$ac_exeext conftest.$ac_ext
12118 fi
12119
12120 if test "x$gethostbynamerstyle" = "x"; then
12121   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12122 /* end confdefs.h.  */
12123
12124       #include <stdio.h>
12125       #include <netdb.h>
12126
12127 int
12128 main ()
12129 {
12130  gethostbyname(NULL)
12131   ;
12132   return 0;
12133 }
12134 _ACEOF
12135 if ac_fn_c_try_link "$LINENO"; then :
12136
12137
12138 $as_echo "#define GETHOSTBYNAMERSTYLE BSDSTYLE" >>confdefs.h
12139
12140       gethostbynamerstyle=BSD
12141
12142
12143 fi
12144 rm -f core conftest.err conftest.$ac_objext \
12145     conftest$ac_exeext conftest.$ac_ext
12146 fi
12147
12148 if test "x$gethostbynamerstyle" = "x"; then
12149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none!  It must not exist, here." >&5
12150 $as_echo "none!  It must not exist, here." >&6; }
12151 else
12152   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${gethostbynamerstyle}-style" >&5
12153 $as_echo "${gethostbynamerstyle}-style" >&6; }
12154 fi
12155
12156 if test "x$gethostbynamerstyle" = "xBSD"; then
12157   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:  ****** BSD-style gethostbyname might NOT be thread-safe! ****** " >&5
12158 $as_echo "$as_me: WARNING:  ****** BSD-style gethostbyname might NOT be thread-safe! ****** " >&2;}
12159 fi
12160
12161 if test "x$ac_cv_header_pwd_h" = "xyes"; then
12162   { $as_echo "$as_me:${as_lineno-$LINENO}: checking getpwnam_r" >&5
12163 $as_echo_n "checking getpwnam_r... " >&6; }
12164   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12165 /* end confdefs.h.  */
12166
12167       #include <stdlib.h>
12168       #include <sys/types.h>
12169       #include <pwd.h>
12170
12171 int
12172 main ()
12173 {
12174  getpwnam_r(NULL, NULL, NULL, 0, NULL)
12175   ;
12176   return 0;
12177 }
12178 _ACEOF
12179 if ac_fn_c_try_link "$LINENO"; then :
12180
12181       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12182 $as_echo "yes" >&6; }
12183
12184 $as_echo "#define HAVE_GETPWNAM_R 1" >>confdefs.h
12185
12186
12187 else
12188
12189         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12190 $as_echo "no" >&6; }
12191
12192
12193 fi
12194 rm -f core conftest.err conftest.$ac_objext \
12195     conftest$ac_exeext conftest.$ac_ext
12196 fi
12197
12198 if test "x$ac_cv_header_grp_h" = "xyes"; then
12199   { $as_echo "$as_me:${as_lineno-$LINENO}: checking getgrnam_r" >&5
12200 $as_echo_n "checking getgrnam_r... " >&6; }
12201   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12202 /* end confdefs.h.  */
12203
12204       #include <stdlib.h>
12205       #include <sys/types.h>
12206       #include <grp.h>
12207
12208 int
12209 main ()
12210 {
12211  getgrnam_r(NULL, NULL, NULL, 0, NULL)
12212   ;
12213   return 0;
12214 }
12215 _ACEOF
12216 if ac_fn_c_try_link "$LINENO"; then :
12217
12218       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12219 $as_echo "yes" >&6; }
12220
12221 $as_echo "#define HAVE_GETGRNAM_R 1" >>confdefs.h
12222
12223
12224 else
12225
12226         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12227 $as_echo "no" >&6; }
12228
12229
12230 fi
12231 rm -f core conftest.err conftest.$ac_objext \
12232     conftest$ac_exeext conftest.$ac_ext
12233 fi
12234
12235
12236
12237 $as_echo "#define POSIXSTYLE 1" >>confdefs.h
12238
12239
12240 $as_echo "#define SOLARISSTYLE 2" >>confdefs.h
12241
12242 ctimerstyle=""
12243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ctime_r() syntax" >&5
12244 $as_echo_n "checking ctime_r() syntax... " >&6; }
12245 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12246 /* end confdefs.h.  */
12247
12248     #include <time.h>
12249
12250 int
12251 main ()
12252 {
12253  ctime_r(NULL, NULL, 0)
12254   ;
12255   return 0;
12256 }
12257 _ACEOF
12258 if ac_fn_c_try_link "$LINENO"; then :
12259
12260
12261 $as_echo "#define CTIMERSTYLE SOLARISSTYLE" >>confdefs.h
12262
12263     ctimerstyle="SOLARIS"
12264
12265
12266 fi
12267 rm -f core conftest.err conftest.$ac_objext \
12268     conftest$ac_exeext conftest.$ac_ext
12269
12270 if test "x$ctimerstyle" = "x"; then
12271   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12272 /* end confdefs.h.  */
12273
12274       #include <time.h>
12275
12276 int
12277 main ()
12278 {
12279  ctime_r(NULL, NULL)
12280   ;
12281   return 0;
12282 }
12283 _ACEOF
12284 if ac_fn_c_try_link "$LINENO"; then :
12285
12286
12287 $as_echo "#define CTIMERSTYLE POSIXSTYLE" >>confdefs.h
12288
12289       ctimerstyle="POSIX"
12290
12291
12292 fi
12293 rm -f core conftest.err conftest.$ac_objext \
12294     conftest$ac_exeext conftest.$ac_ext
12295 fi
12296
12297 if test "x$ctimerstyle" = "x"; then
12298     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none!  It must not exist, here." >&5
12299 $as_echo "none!  It must not exist, here." >&6; }
12300 else
12301     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ctimerstyle}-style" >&5
12302 $as_echo "${ctimerstyle}-style" >&6; }
12303 fi
12304
12305 HOSTINFO=$host
12306
12307
12308
12309 top_builddir=`pwd`
12310 export top_builddir
12311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: top_builddir=$top_builddir" >&5
12312 $as_echo "top_builddir=$top_builddir" >&6; }
12313
12314
12315
12316
12317 if test "x$EXPERIMENTAL" = "xyes"; then
12318   for foo in `ls -1 "${srcdir}"/src/modules | grep rlm_`; do
12319     MODULES="$MODULES $foo"
12320   done
12321 else
12322             for foo in `cat "${srcdir}"/src/modules/stable`; do
12323       MODULES="$MODULES $foo"
12324    done
12325 fi
12326
12327 mysubdirs=""
12328 for bar in $MODULES; do
12329   if test -f "${srcdir}"/src/modules/$bar/configure; then
12330     mysubdirs="$mysubdirs src/modules/$bar"
12331   fi
12332 done
12333
12334
12335
12336 subdirs="$subdirs $mysubdirs"
12337
12338
12339
12340 if test "x$werror" == "xyes"; then
12341   CFLAGS="-Werror $CFLAGS"
12342 fi
12343
12344 ac_config_commands="$ac_config_commands stamp-h"
12345
12346 ac_config_commands="$ac_config_commands build-radpaths-h"
12347
12348 ac_config_commands="$ac_config_commands main-chmod"
12349
12350 ac_config_commands="$ac_config_commands scripts-chmod"
12351
12352
12353
12354
12355
12356
12357 USE_STATIC_LIBS="yes"
12358
12359
12360
12361
12362   unset ac_cv_env_LIBS_set
12363   unset ac_cv_env_LIBS_value
12364
12365   ac_config_files="$ac_config_files ./Make.inc ./src/include/build-radpaths-h ./src/main/radsniff.mk ./src/main/checkrad ./src/main/radlast ./src/main/radtest ./scripts/rc.radiusd ./scripts/cron/radiusd.cron.daily ./scripts/cron/radiusd.cron.monthly ./scripts/cryptpasswd ./raddb/radrelay.conf ./raddb/radiusd.conf"
12366
12367 cat >confcache <<\_ACEOF
12368 # This file is a shell script that caches the results of configure
12369 # tests run on this system so they can be shared between configure
12370 # scripts and configure runs, see configure's option --config-cache.
12371 # It is not useful on other systems.  If it contains results you don't
12372 # want to keep, you may remove or edit it.
12373 #
12374 # config.status only pays attention to the cache file if you give it
12375 # the --recheck option to rerun configure.
12376 #
12377 # `ac_cv_env_foo' variables (set or unset) will be overridden when
12378 # loading this file, other *unset* `ac_cv_foo' will be assigned the
12379 # following values.
12380
12381 _ACEOF
12382
12383 # The following way of writing the cache mishandles newlines in values,
12384 # but we know of no workaround that is simple, portable, and efficient.
12385 # So, we kill variables containing newlines.
12386 # Ultrix sh set writes to stderr and can't be redirected directly,
12387 # and sets the high bit in the cache file unless we assign to the vars.
12388 (
12389   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
12390     eval ac_val=\$$ac_var
12391     case $ac_val in #(
12392     *${as_nl}*)
12393       case $ac_var in #(
12394       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
12395 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
12396       esac
12397       case $ac_var in #(
12398       _ | IFS | as_nl) ;; #(
12399       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
12400       *) { eval $ac_var=; unset $ac_var;} ;;
12401       esac ;;
12402     esac
12403   done
12404
12405   (set) 2>&1 |
12406     case $as_nl`(ac_space=' '; set) 2>&1` in #(
12407     *${as_nl}ac_space=\ *)
12408       # `set' does not quote correctly, so add quotes: double-quote
12409       # substitution turns \\\\ into \\, and sed turns \\ into \.
12410       sed -n \
12411         "s/'/'\\\\''/g;
12412           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
12413       ;; #(
12414     *)
12415       # `set' quotes correctly as required by POSIX, so do not add quotes.
12416       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
12417       ;;
12418     esac |
12419     sort
12420 ) |
12421   sed '
12422      /^ac_cv_env_/b end
12423      t clear
12424      :clear
12425      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
12426      t end
12427      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
12428      :end' >>confcache
12429 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
12430   if test -w "$cache_file"; then
12431     if test "x$cache_file" != "x/dev/null"; then
12432       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
12433 $as_echo "$as_me: updating cache $cache_file" >&6;}
12434       if test ! -f "$cache_file" || test -h "$cache_file"; then
12435         cat confcache >"$cache_file"
12436       else
12437         case $cache_file in #(
12438         */* | ?:*)
12439           mv -f confcache "$cache_file"$$ &&
12440           mv -f "$cache_file"$$ "$cache_file" ;; #(
12441         *)
12442           mv -f confcache "$cache_file" ;;
12443         esac
12444       fi
12445     fi
12446   else
12447     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
12448 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
12449   fi
12450 fi
12451 rm -f confcache
12452
12453 test "x$prefix" = xNONE && prefix=$ac_default_prefix
12454 # Let make expand exec_prefix.
12455 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12456
12457 DEFS=-DHAVE_CONFIG_H
12458
12459 ac_libobjs=
12460 ac_ltlibobjs=
12461 U=
12462 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
12463   # 1. Remove the extension, and $U if already installed.
12464   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
12465   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
12466   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
12467   #    will be set to the directory where LIBOBJS objects are built.
12468   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
12469   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
12470 done
12471 LIBOBJS=$ac_libobjs
12472
12473 LTLIBOBJS=$ac_ltlibobjs
12474
12475
12476
12477
12478 : "${CONFIG_STATUS=./config.status}"
12479 ac_write_fail=0
12480 ac_clean_files_save=$ac_clean_files
12481 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
12482 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
12483 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
12484 as_write_fail=0
12485 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
12486 #! $SHELL
12487 # Generated by $as_me.
12488 # Run this file to recreate the current configuration.
12489 # Compiler output produced by configure, useful for debugging
12490 # configure, is in config.log if it exists.
12491
12492 debug=false
12493 ac_cs_recheck=false
12494 ac_cs_silent=false
12495
12496 SHELL=\${CONFIG_SHELL-$SHELL}
12497 export SHELL
12498 _ASEOF
12499 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
12500 ## -------------------- ##
12501 ## M4sh Initialization. ##
12502 ## -------------------- ##
12503
12504 # Be more Bourne compatible
12505 DUALCASE=1; export DUALCASE # for MKS sh
12506 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
12507   emulate sh
12508   NULLCMD=:
12509   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
12510   # is contrary to our usage.  Disable this feature.
12511   alias -g '${1+"$@"}'='"$@"'
12512   setopt NO_GLOB_SUBST
12513 else
12514   case `(set -o) 2>/dev/null` in #(
12515   *posix*) :
12516     set -o posix ;; #(
12517   *) :
12518      ;;
12519 esac
12520 fi
12521
12522
12523 as_nl='
12524 '
12525 export as_nl
12526 # Printing a long string crashes Solaris 7 /usr/bin/printf.
12527 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
12528 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
12529 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
12530 # Prefer a ksh shell builtin over an external printf program on Solaris,
12531 # but without wasting forks for bash or zsh.
12532 if test -z "$BASH_VERSION$ZSH_VERSION" \
12533     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
12534   as_echo='print -r --'
12535   as_echo_n='print -rn --'
12536 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
12537   as_echo='printf %s\n'
12538   as_echo_n='printf %s'
12539 else
12540   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
12541     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
12542     as_echo_n='/usr/ucb/echo -n'
12543   else
12544     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
12545     as_echo_n_body='eval
12546       arg=$1;
12547       case $arg in #(
12548       *"$as_nl"*)
12549         expr "X$arg" : "X\\(.*\\)$as_nl";
12550         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
12551       esac;
12552       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
12553     '
12554     export as_echo_n_body
12555     as_echo_n='sh -c $as_echo_n_body as_echo'
12556   fi
12557   export as_echo_body
12558   as_echo='sh -c $as_echo_body as_echo'
12559 fi
12560
12561 # The user is always right.
12562 if test "${PATH_SEPARATOR+set}" != set; then
12563   PATH_SEPARATOR=:
12564   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
12565     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
12566       PATH_SEPARATOR=';'
12567   }
12568 fi
12569
12570
12571 # IFS
12572 # We need space, tab and new line, in precisely that order.  Quoting is
12573 # there to prevent editors from complaining about space-tab.
12574 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
12575 # splitting by setting IFS to empty value.)
12576 IFS=" ""        $as_nl"
12577
12578 # Find who we are.  Look in the path if we contain no directory separator.
12579 as_myself=
12580 case $0 in #((
12581   *[\\/]* ) as_myself=$0 ;;
12582   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12583 for as_dir in $PATH
12584 do
12585   IFS=$as_save_IFS
12586   test -z "$as_dir" && as_dir=.
12587     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
12588   done
12589 IFS=$as_save_IFS
12590
12591      ;;
12592 esac
12593 # We did not find ourselves, most probably we were run as `sh COMMAND'
12594 # in which case we are not to be found in the path.
12595 if test "x$as_myself" = x; then
12596   as_myself=$0
12597 fi
12598 if test ! -f "$as_myself"; then
12599   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
12600   exit 1
12601 fi
12602
12603 # Unset variables that we do not need and which cause bugs (e.g. in
12604 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
12605 # suppresses any "Segmentation fault" message there.  '((' could
12606 # trigger a bug in pdksh 5.2.14.
12607 for as_var in BASH_ENV ENV MAIL MAILPATH
12608 do eval test x\${$as_var+set} = xset \
12609   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
12610 done
12611 PS1='$ '
12612 PS2='> '
12613 PS4='+ '
12614
12615 # NLS nuisances.
12616 LC_ALL=C
12617 export LC_ALL
12618 LANGUAGE=C
12619 export LANGUAGE
12620
12621 # CDPATH.
12622 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
12623
12624
12625 # as_fn_error STATUS ERROR [LINENO LOG_FD]
12626 # ----------------------------------------
12627 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
12628 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
12629 # script with STATUS, using 1 if that was 0.
12630 as_fn_error ()
12631 {
12632   as_status=$1; test $as_status -eq 0 && as_status=1
12633   if test "$4"; then
12634     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
12635     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
12636   fi
12637   $as_echo "$as_me: error: $2" >&2
12638   as_fn_exit $as_status
12639 } # as_fn_error
12640
12641
12642 # as_fn_set_status STATUS
12643 # -----------------------
12644 # Set $? to STATUS, without forking.
12645 as_fn_set_status ()
12646 {
12647   return $1
12648 } # as_fn_set_status
12649
12650 # as_fn_exit STATUS
12651 # -----------------
12652 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
12653 as_fn_exit ()
12654 {
12655   set +e
12656   as_fn_set_status $1
12657   exit $1
12658 } # as_fn_exit
12659
12660 # as_fn_unset VAR
12661 # ---------------
12662 # Portably unset VAR.
12663 as_fn_unset ()
12664 {
12665   { eval $1=; unset $1;}
12666 }
12667 as_unset=as_fn_unset
12668 # as_fn_append VAR VALUE
12669 # ----------------------
12670 # Append the text in VALUE to the end of the definition contained in VAR. Take
12671 # advantage of any shell optimizations that allow amortized linear growth over
12672 # repeated appends, instead of the typical quadratic growth present in naive
12673 # implementations.
12674 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
12675   eval 'as_fn_append ()
12676   {
12677     eval $1+=\$2
12678   }'
12679 else
12680   as_fn_append ()
12681   {
12682     eval $1=\$$1\$2
12683   }
12684 fi # as_fn_append
12685
12686 # as_fn_arith ARG...
12687 # ------------------
12688 # Perform arithmetic evaluation on the ARGs, and store the result in the
12689 # global $as_val. Take advantage of shells that can avoid forks. The arguments
12690 # must be portable across $(()) and expr.
12691 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
12692   eval 'as_fn_arith ()
12693   {
12694     as_val=$(( $* ))
12695   }'
12696 else
12697   as_fn_arith ()
12698   {
12699     as_val=`expr "$@" || test $? -eq 1`
12700   }
12701 fi # as_fn_arith
12702
12703
12704 if expr a : '\(a\)' >/dev/null 2>&1 &&
12705    test "X`expr 00001 : '.*\(...\)'`" = X001; then
12706   as_expr=expr
12707 else
12708   as_expr=false
12709 fi
12710
12711 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
12712   as_basename=basename
12713 else
12714   as_basename=false
12715 fi
12716
12717 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
12718   as_dirname=dirname
12719 else
12720   as_dirname=false
12721 fi
12722
12723 as_me=`$as_basename -- "$0" ||
12724 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
12725          X"$0" : 'X\(//\)$' \| \
12726          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
12727 $as_echo X/"$0" |
12728     sed '/^.*\/\([^/][^/]*\)\/*$/{
12729             s//\1/
12730             q
12731           }
12732           /^X\/\(\/\/\)$/{
12733             s//\1/
12734             q
12735           }
12736           /^X\/\(\/\).*/{
12737             s//\1/
12738             q
12739           }
12740           s/.*/./; q'`
12741
12742 # Avoid depending upon Character Ranges.
12743 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12744 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
12745 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
12746 as_cr_digits='0123456789'
12747 as_cr_alnum=$as_cr_Letters$as_cr_digits
12748
12749 ECHO_C= ECHO_N= ECHO_T=
12750 case `echo -n x` in #(((((
12751 -n*)
12752   case `echo 'xy\c'` in
12753   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
12754   xy)  ECHO_C='\c';;
12755   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
12756        ECHO_T=' ';;
12757   esac;;
12758 *)
12759   ECHO_N='-n';;
12760 esac
12761
12762 rm -f conf$$ conf$$.exe conf$$.file
12763 if test -d conf$$.dir; then
12764   rm -f conf$$.dir/conf$$.file
12765 else
12766   rm -f conf$$.dir
12767   mkdir conf$$.dir 2>/dev/null
12768 fi
12769 if (echo >conf$$.file) 2>/dev/null; then
12770   if ln -s conf$$.file conf$$ 2>/dev/null; then
12771     as_ln_s='ln -s'
12772     # ... but there are two gotchas:
12773     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
12774     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
12775     # In both cases, we have to default to `cp -pR'.
12776     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
12777       as_ln_s='cp -pR'
12778   elif ln conf$$.file conf$$ 2>/dev/null; then
12779     as_ln_s=ln
12780   else
12781     as_ln_s='cp -pR'
12782   fi
12783 else
12784   as_ln_s='cp -pR'
12785 fi
12786 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
12787 rmdir conf$$.dir 2>/dev/null
12788
12789
12790 # as_fn_mkdir_p
12791 # -------------
12792 # Create "$as_dir" as a directory, including parents if necessary.
12793 as_fn_mkdir_p ()
12794 {
12795
12796   case $as_dir in #(
12797   -*) as_dir=./$as_dir;;
12798   esac
12799   test -d "$as_dir" || eval $as_mkdir_p || {
12800     as_dirs=
12801     while :; do
12802       case $as_dir in #(
12803       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
12804       *) as_qdir=$as_dir;;
12805       esac
12806       as_dirs="'$as_qdir' $as_dirs"
12807       as_dir=`$as_dirname -- "$as_dir" ||
12808 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
12809          X"$as_dir" : 'X\(//\)[^/]' \| \
12810          X"$as_dir" : 'X\(//\)$' \| \
12811          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
12812 $as_echo X"$as_dir" |
12813     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
12814             s//\1/
12815             q
12816           }
12817           /^X\(\/\/\)[^/].*/{
12818             s//\1/
12819             q
12820           }
12821           /^X\(\/\/\)$/{
12822             s//\1/
12823             q
12824           }
12825           /^X\(\/\).*/{
12826             s//\1/
12827             q
12828           }
12829           s/.*/./; q'`
12830       test -d "$as_dir" && break
12831     done
12832     test -z "$as_dirs" || eval "mkdir $as_dirs"
12833   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
12834
12835
12836 } # as_fn_mkdir_p
12837 if mkdir -p . 2>/dev/null; then
12838   as_mkdir_p='mkdir -p "$as_dir"'
12839 else
12840   test -d ./-p && rmdir ./-p
12841   as_mkdir_p=false
12842 fi
12843
12844
12845 # as_fn_executable_p FILE
12846 # -----------------------
12847 # Test if FILE is an executable regular file.
12848 as_fn_executable_p ()
12849 {
12850   test -f "$1" && test -x "$1"
12851 } # as_fn_executable_p
12852 as_test_x='test -x'
12853 as_executable_p=as_fn_executable_p
12854
12855 # Sed expression to map a string onto a valid CPP name.
12856 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
12857
12858 # Sed expression to map a string onto a valid variable name.
12859 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
12860
12861
12862 exec 6>&1
12863 ## ----------------------------------- ##
12864 ## Main body of $CONFIG_STATUS script. ##
12865 ## ----------------------------------- ##
12866 _ASEOF
12867 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
12868
12869 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
12870 # Save the log message, to keep $0 and so on meaningful, and to
12871 # report actual input values of CONFIG_FILES etc. instead of their
12872 # values after options handling.
12873 ac_log="
12874 This file was extended by freeradius $as_me $Id$, which was
12875 generated by GNU Autoconf 2.69.  Invocation command line was
12876
12877   CONFIG_FILES    = $CONFIG_FILES
12878   CONFIG_HEADERS  = $CONFIG_HEADERS
12879   CONFIG_LINKS    = $CONFIG_LINKS
12880   CONFIG_COMMANDS = $CONFIG_COMMANDS
12881   $ $0 $@
12882
12883 on `(hostname || uname -n) 2>/dev/null | sed 1q`
12884 "
12885
12886 _ACEOF
12887
12888 case $ac_config_files in *"
12889 "*) set x $ac_config_files; shift; ac_config_files=$*;;
12890 esac
12891
12892 case $ac_config_headers in *"
12893 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
12894 esac
12895
12896
12897 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
12898 # Files that config.status was made for.
12899 config_files="$ac_config_files"
12900 config_headers="$ac_config_headers"
12901 config_commands="$ac_config_commands"
12902
12903 _ACEOF
12904
12905 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
12906 ac_cs_usage="\
12907 \`$as_me' instantiates files and other configuration actions
12908 from templates according to the current configuration.  Unless the files
12909 and actions are specified as TAGs, all are instantiated by default.
12910
12911 Usage: $0 [OPTION]... [TAG]...
12912
12913   -h, --help       print this help, then exit
12914   -V, --version    print version number and configuration settings, then exit
12915       --config     print configuration, then exit
12916   -q, --quiet, --silent
12917                    do not print progress messages
12918   -d, --debug      don't remove temporary files
12919       --recheck    update $as_me by reconfiguring in the same conditions
12920       --file=FILE[:TEMPLATE]
12921                    instantiate the configuration file FILE
12922       --header=FILE[:TEMPLATE]
12923                    instantiate the configuration header FILE
12924
12925 Configuration files:
12926 $config_files
12927
12928 Configuration headers:
12929 $config_headers
12930
12931 Configuration commands:
12932 $config_commands
12933
12934 Report bugs to <http://bugs.freeradius.org>.
12935 freeradius home page: <http://www.freeradius.org>."
12936
12937 _ACEOF
12938 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
12939 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
12940 ac_cs_version="\\
12941 freeradius config.status $Id$
12942 configured by $0, generated by GNU Autoconf 2.69,
12943   with options \\"\$ac_cs_config\\"
12944
12945 Copyright (C) 2012 Free Software Foundation, Inc.
12946 This config.status script is free software; the Free Software Foundation
12947 gives unlimited permission to copy, distribute and modify it."
12948
12949 ac_pwd='$ac_pwd'
12950 srcdir='$srcdir'
12951 test -n "\$AWK" || AWK=awk
12952 _ACEOF
12953
12954 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
12955 # The default lists apply if the user does not specify any file.
12956 ac_need_defaults=:
12957 while test $# != 0
12958 do
12959   case $1 in
12960   --*=?*)
12961     ac_option=`expr "X$1" : 'X\([^=]*\)='`
12962     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
12963     ac_shift=:
12964     ;;
12965   --*=)
12966     ac_option=`expr "X$1" : 'X\([^=]*\)='`
12967     ac_optarg=
12968     ac_shift=:
12969     ;;
12970   *)
12971     ac_option=$1
12972     ac_optarg=$2
12973     ac_shift=shift
12974     ;;
12975   esac
12976
12977   case $ac_option in
12978   # Handling of the options.
12979   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
12980     ac_cs_recheck=: ;;
12981   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
12982     $as_echo "$ac_cs_version"; exit ;;
12983   --config | --confi | --conf | --con | --co | --c )
12984     $as_echo "$ac_cs_config"; exit ;;
12985   --debug | --debu | --deb | --de | --d | -d )
12986     debug=: ;;
12987   --file | --fil | --fi | --f )
12988     $ac_shift
12989     case $ac_optarg in
12990     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
12991     '') as_fn_error $? "missing file argument" ;;
12992     esac
12993     as_fn_append CONFIG_FILES " '$ac_optarg'"
12994     ac_need_defaults=false;;
12995   --header | --heade | --head | --hea )
12996     $ac_shift
12997     case $ac_optarg in
12998     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
12999     esac
13000     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
13001     ac_need_defaults=false;;
13002   --he | --h)
13003     # Conflict between --help and --header
13004     as_fn_error $? "ambiguous option: \`$1'
13005 Try \`$0 --help' for more information.";;
13006   --help | --hel | -h )
13007     $as_echo "$ac_cs_usage"; exit ;;
13008   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
13009   | -silent | --silent | --silen | --sile | --sil | --si | --s)
13010     ac_cs_silent=: ;;
13011
13012   # This is an error.
13013   -*) as_fn_error $? "unrecognized option: \`$1'
13014 Try \`$0 --help' for more information." ;;
13015
13016   *) as_fn_append ac_config_targets " $1"
13017      ac_need_defaults=false ;;
13018
13019   esac
13020   shift
13021 done
13022
13023 ac_configure_extra_args=
13024
13025 if $ac_cs_silent; then
13026   exec 6>/dev/null
13027   ac_configure_extra_args="$ac_configure_extra_args --silent"
13028 fi
13029
13030 _ACEOF
13031 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13032 if \$ac_cs_recheck; then
13033   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
13034   shift
13035   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
13036   CONFIG_SHELL='$SHELL'
13037   export CONFIG_SHELL
13038   exec "\$@"
13039 fi
13040
13041 _ACEOF
13042 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13043 exec 5>>config.log
13044 {
13045   echo
13046   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
13047 ## Running $as_me. ##
13048 _ASBOX
13049   $as_echo "$ac_log"
13050 } >&5
13051
13052 _ACEOF
13053 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13054 _ACEOF
13055
13056 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13057
13058 # Handling of arguments.
13059 for ac_config_target in $ac_config_targets
13060 do
13061   case $ac_config_target in
13062     "src/include/autoconf.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/autoconf.h" ;;
13063     "stamp-h") CONFIG_COMMANDS="$CONFIG_COMMANDS stamp-h" ;;
13064     "build-radpaths-h") CONFIG_COMMANDS="$CONFIG_COMMANDS build-radpaths-h" ;;
13065     "main-chmod") CONFIG_COMMANDS="$CONFIG_COMMANDS main-chmod" ;;
13066     "scripts-chmod") CONFIG_COMMANDS="$CONFIG_COMMANDS scripts-chmod" ;;
13067     "./Make.inc") CONFIG_FILES="$CONFIG_FILES ./Make.inc" ;;
13068     "./src/include/build-radpaths-h") CONFIG_FILES="$CONFIG_FILES ./src/include/build-radpaths-h" ;;
13069     "./src/main/radsniff.mk") CONFIG_FILES="$CONFIG_FILES ./src/main/radsniff.mk" ;;
13070     "./src/main/checkrad") CONFIG_FILES="$CONFIG_FILES ./src/main/checkrad" ;;
13071     "./src/main/radlast") CONFIG_FILES="$CONFIG_FILES ./src/main/radlast" ;;
13072     "./src/main/radtest") CONFIG_FILES="$CONFIG_FILES ./src/main/radtest" ;;
13073     "./scripts/rc.radiusd") CONFIG_FILES="$CONFIG_FILES ./scripts/rc.radiusd" ;;
13074     "./scripts/cron/radiusd.cron.daily") CONFIG_FILES="$CONFIG_FILES ./scripts/cron/radiusd.cron.daily" ;;
13075     "./scripts/cron/radiusd.cron.monthly") CONFIG_FILES="$CONFIG_FILES ./scripts/cron/radiusd.cron.monthly" ;;
13076     "./scripts/cryptpasswd") CONFIG_FILES="$CONFIG_FILES ./scripts/cryptpasswd" ;;
13077     "./raddb/radrelay.conf") CONFIG_FILES="$CONFIG_FILES ./raddb/radrelay.conf" ;;
13078     "./raddb/radiusd.conf") CONFIG_FILES="$CONFIG_FILES ./raddb/radiusd.conf" ;;
13079
13080   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
13081   esac
13082 done
13083
13084
13085 # If the user did not use the arguments to specify the items to instantiate,
13086 # then the envvar interface is used.  Set only those that are not.
13087 # We use the long form for the default assignment because of an extremely
13088 # bizarre bug on SunOS 4.1.3.
13089 if $ac_need_defaults; then
13090   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
13091   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
13092   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
13093 fi
13094
13095 # Have a temporary directory for convenience.  Make it in the build tree
13096 # simply because there is no reason against having it here, and in addition,
13097 # creating and moving files from /tmp can sometimes cause problems.
13098 # Hook for its removal unless debugging.
13099 # Note that there is a small window in which the directory will not be cleaned:
13100 # after its creation but before its name has been assigned to `$tmp'.
13101 $debug ||
13102 {
13103   tmp= ac_tmp=
13104   trap 'exit_status=$?
13105   : "${ac_tmp:=$tmp}"
13106   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
13107 ' 0
13108   trap 'as_fn_exit 1' 1 2 13 15
13109 }
13110 # Create a (secure) tmp directory for tmp files.
13111
13112 {
13113   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
13114   test -d "$tmp"
13115 }  ||
13116 {
13117   tmp=./conf$$-$RANDOM
13118   (umask 077 && mkdir "$tmp")
13119 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
13120 ac_tmp=$tmp
13121
13122 # Set up the scripts for CONFIG_FILES section.
13123 # No need to generate them if there are no CONFIG_FILES.
13124 # This happens for instance with `./config.status config.h'.
13125 if test -n "$CONFIG_FILES"; then
13126
13127
13128 ac_cr=`echo X | tr X '\015'`
13129 # On cygwin, bash can eat \r inside `` if the user requested igncr.
13130 # But we know of no other shell where ac_cr would be empty at this
13131 # point, so we can use a bashism as a fallback.
13132 if test "x$ac_cr" = x; then
13133   eval ac_cr=\$\'\\r\'
13134 fi
13135 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
13136 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
13137   ac_cs_awk_cr='\\r'
13138 else
13139   ac_cs_awk_cr=$ac_cr
13140 fi
13141
13142 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
13143 _ACEOF
13144
13145
13146 {
13147   echo "cat >conf$$subs.awk <<_ACEOF" &&
13148   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
13149   echo "_ACEOF"
13150 } >conf$$subs.sh ||
13151   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
13152 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
13153 ac_delim='%!_!# '
13154 for ac_last_try in false false false false false :; do
13155   . ./conf$$subs.sh ||
13156     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
13157
13158   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
13159   if test $ac_delim_n = $ac_delim_num; then
13160     break
13161   elif $ac_last_try; then
13162     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
13163   else
13164     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
13165   fi
13166 done
13167 rm -f conf$$subs.sh
13168
13169 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13170 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
13171 _ACEOF
13172 sed -n '
13173 h
13174 s/^/S["/; s/!.*/"]=/
13175 p
13176 g
13177 s/^[^!]*!//
13178 :repl
13179 t repl
13180 s/'"$ac_delim"'$//
13181 t delim
13182 :nl
13183 h
13184 s/\(.\{148\}\)..*/\1/
13185 t more1
13186 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
13187 p
13188 n
13189 b repl
13190 :more1
13191 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
13192 p
13193 g
13194 s/.\{148\}//
13195 t nl
13196 :delim
13197 h
13198 s/\(.\{148\}\)..*/\1/
13199 t more2
13200 s/["\\]/\\&/g; s/^/"/; s/$/"/
13201 p
13202 b
13203 :more2
13204 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
13205 p
13206 g
13207 s/.\{148\}//
13208 t delim
13209 ' <conf$$subs.awk | sed '
13210 /^[^""]/{
13211   N
13212   s/\n//
13213 }
13214 ' >>$CONFIG_STATUS || ac_write_fail=1
13215 rm -f conf$$subs.awk
13216 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13217 _ACAWK
13218 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
13219   for (key in S) S_is_set[key] = 1
13220   FS = "\a"
13221
13222 }
13223 {
13224   line = $ 0
13225   nfields = split(line, field, "@")
13226   substed = 0
13227   len = length(field[1])
13228   for (i = 2; i < nfields; i++) {
13229     key = field[i]
13230     keylen = length(key)
13231     if (S_is_set[key]) {
13232       value = S[key]
13233       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
13234       len += length(value) + length(field[++i])
13235       substed = 1
13236     } else
13237       len += 1 + keylen
13238   }
13239
13240   print line
13241 }
13242
13243 _ACAWK
13244 _ACEOF
13245 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13246 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
13247   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
13248 else
13249   cat
13250 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
13251   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
13252 _ACEOF
13253
13254 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
13255 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
13256 # trailing colons and then remove the whole line if VPATH becomes empty
13257 # (actually we leave an empty line to preserve line numbers).
13258 if test "x$srcdir" = x.; then
13259   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
13260 h
13261 s///
13262 s/^/:/
13263 s/[      ]*$/:/
13264 s/:\$(srcdir):/:/g
13265 s/:\${srcdir}:/:/g
13266 s/:@srcdir@:/:/g
13267 s/^:*//
13268 s/:*$//
13269 x
13270 s/\(=[   ]*\).*/\1/
13271 G
13272 s/\n//
13273 s/^[^=]*=[       ]*$//
13274 }'
13275 fi
13276
13277 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13278 fi # test -n "$CONFIG_FILES"
13279
13280 # Set up the scripts for CONFIG_HEADERS section.
13281 # No need to generate them if there are no CONFIG_HEADERS.
13282 # This happens for instance with `./config.status Makefile'.
13283 if test -n "$CONFIG_HEADERS"; then
13284 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
13285 BEGIN {
13286 _ACEOF
13287
13288 # Transform confdefs.h into an awk script `defines.awk', embedded as
13289 # here-document in config.status, that substitutes the proper values into
13290 # config.h.in to produce config.h.
13291
13292 # Create a delimiter string that does not exist in confdefs.h, to ease
13293 # handling of long lines.
13294 ac_delim='%!_!# '
13295 for ac_last_try in false false :; do
13296   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
13297   if test -z "$ac_tt"; then
13298     break
13299   elif $ac_last_try; then
13300     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
13301   else
13302     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
13303   fi
13304 done
13305
13306 # For the awk script, D is an array of macro values keyed by name,
13307 # likewise P contains macro parameters if any.  Preserve backslash
13308 # newline sequences.
13309
13310 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
13311 sed -n '
13312 s/.\{148\}/&'"$ac_delim"'/g
13313 t rset
13314 :rset
13315 s/^[     ]*#[    ]*define[       ][      ]*/ /
13316 t def
13317 d
13318 :def
13319 s/\\$//
13320 t bsnl
13321 s/["\\]/\\&/g
13322 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
13323 D["\1"]=" \3"/p
13324 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
13325 d
13326 :bsnl
13327 s/["\\]/\\&/g
13328 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
13329 D["\1"]=" \3\\\\\\n"\\/p
13330 t cont
13331 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
13332 t cont
13333 d
13334 :cont
13335 n
13336 s/.\{148\}/&'"$ac_delim"'/g
13337 t clear
13338 :clear
13339 s/\\$//
13340 t bsnlc
13341 s/["\\]/\\&/g; s/^/"/; s/$/"/p
13342 d
13343 :bsnlc
13344 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
13345 b cont
13346 ' <confdefs.h | sed '
13347 s/'"$ac_delim"'/"\\\
13348 "/g' >>$CONFIG_STATUS || ac_write_fail=1
13349
13350 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13351   for (key in D) D_is_set[key] = 1
13352   FS = "\a"
13353 }
13354 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
13355   line = \$ 0
13356   split(line, arg, " ")
13357   if (arg[1] == "#") {
13358     defundef = arg[2]
13359     mac1 = arg[3]
13360   } else {
13361     defundef = substr(arg[1], 2)
13362     mac1 = arg[2]
13363   }
13364   split(mac1, mac2, "(") #)
13365   macro = mac2[1]
13366   prefix = substr(line, 1, index(line, defundef) - 1)
13367   if (D_is_set[macro]) {
13368     # Preserve the white space surrounding the "#".
13369     print prefix "define", macro P[macro] D[macro]
13370     next
13371   } else {
13372     # Replace #undef with comments.  This is necessary, for example,
13373     # in the case of _POSIX_SOURCE, which is predefined and required
13374     # on some systems where configure will not decide to define it.
13375     if (defundef == "undef") {
13376       print "/*", prefix defundef, macro, "*/"
13377       next
13378     }
13379   }
13380 }
13381 { print }
13382 _ACAWK
13383 _ACEOF
13384 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13385   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
13386 fi # test -n "$CONFIG_HEADERS"
13387
13388
13389 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
13390 shift
13391 for ac_tag
13392 do
13393   case $ac_tag in
13394   :[FHLC]) ac_mode=$ac_tag; continue;;
13395   esac
13396   case $ac_mode$ac_tag in
13397   :[FHL]*:*);;
13398   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
13399   :[FH]-) ac_tag=-:-;;
13400   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
13401   esac
13402   ac_save_IFS=$IFS
13403   IFS=:
13404   set x $ac_tag
13405   IFS=$ac_save_IFS
13406   shift
13407   ac_file=$1
13408   shift
13409
13410   case $ac_mode in
13411   :L) ac_source=$1;;
13412   :[FH])
13413     ac_file_inputs=
13414     for ac_f
13415     do
13416       case $ac_f in
13417       -) ac_f="$ac_tmp/stdin";;
13418       *) # Look for the file first in the build tree, then in the source tree
13419          # (if the path is not absolute).  The absolute path cannot be DOS-style,
13420          # because $ac_f cannot contain `:'.
13421          test -f "$ac_f" ||
13422            case $ac_f in
13423            [\\/$]*) false;;
13424            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
13425            esac ||
13426            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
13427       esac
13428       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
13429       as_fn_append ac_file_inputs " '$ac_f'"
13430     done
13431
13432     # Let's still pretend it is `configure' which instantiates (i.e., don't
13433     # use $as_me), people would be surprised to read:
13434     #    /* config.h.  Generated by config.status.  */
13435     configure_input='Generated from '`
13436           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
13437         `' by configure.'
13438     if test x"$ac_file" != x-; then
13439       configure_input="$ac_file.  $configure_input"
13440       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
13441 $as_echo "$as_me: creating $ac_file" >&6;}
13442     fi
13443     # Neutralize special characters interpreted by sed in replacement strings.
13444     case $configure_input in #(
13445     *\&* | *\|* | *\\* )
13446        ac_sed_conf_input=`$as_echo "$configure_input" |
13447        sed 's/[\\\\&|]/\\\\&/g'`;; #(
13448     *) ac_sed_conf_input=$configure_input;;
13449     esac
13450
13451     case $ac_tag in
13452     *:-:* | *:-) cat >"$ac_tmp/stdin" \
13453       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
13454     esac
13455     ;;
13456   esac
13457
13458   ac_dir=`$as_dirname -- "$ac_file" ||
13459 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13460          X"$ac_file" : 'X\(//\)[^/]' \| \
13461          X"$ac_file" : 'X\(//\)$' \| \
13462          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
13463 $as_echo X"$ac_file" |
13464     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
13465             s//\1/
13466             q
13467           }
13468           /^X\(\/\/\)[^/].*/{
13469             s//\1/
13470             q
13471           }
13472           /^X\(\/\/\)$/{
13473             s//\1/
13474             q
13475           }
13476           /^X\(\/\).*/{
13477             s//\1/
13478             q
13479           }
13480           s/.*/./; q'`
13481   as_dir="$ac_dir"; as_fn_mkdir_p
13482   ac_builddir=.
13483
13484 case "$ac_dir" in
13485 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
13486 *)
13487   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
13488   # A ".." for each directory in $ac_dir_suffix.
13489   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
13490   case $ac_top_builddir_sub in
13491   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
13492   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
13493   esac ;;
13494 esac
13495 ac_abs_top_builddir=$ac_pwd
13496 ac_abs_builddir=$ac_pwd$ac_dir_suffix
13497 # for backward compatibility:
13498 ac_top_builddir=$ac_top_build_prefix
13499
13500 case $srcdir in
13501   .)  # We are building in place.
13502     ac_srcdir=.
13503     ac_top_srcdir=$ac_top_builddir_sub
13504     ac_abs_top_srcdir=$ac_pwd ;;
13505   [\\/]* | ?:[\\/]* )  # Absolute name.
13506     ac_srcdir=$srcdir$ac_dir_suffix;
13507     ac_top_srcdir=$srcdir
13508     ac_abs_top_srcdir=$srcdir ;;
13509   *) # Relative name.
13510     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
13511     ac_top_srcdir=$ac_top_build_prefix$srcdir
13512     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
13513 esac
13514 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
13515
13516
13517   case $ac_mode in
13518   :F)
13519   #
13520   # CONFIG_FILE
13521   #
13522
13523 _ACEOF
13524
13525 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13526 # If the template does not know about datarootdir, expand it.
13527 # FIXME: This hack should be removed a few years after 2.60.
13528 ac_datarootdir_hack=; ac_datarootdir_seen=
13529 ac_sed_dataroot='
13530 /datarootdir/ {
13531   p
13532   q
13533 }
13534 /@datadir@/p
13535 /@docdir@/p
13536 /@infodir@/p
13537 /@localedir@/p
13538 /@mandir@/p'
13539 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
13540 *datarootdir*) ac_datarootdir_seen=yes;;
13541 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
13542   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
13543 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
13544 _ACEOF
13545 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13546   ac_datarootdir_hack='
13547   s&@datadir@&$datadir&g
13548   s&@docdir@&$docdir&g
13549   s&@infodir@&$infodir&g
13550   s&@localedir@&$localedir&g
13551   s&@mandir@&$mandir&g
13552   s&\\\${datarootdir}&$datarootdir&g' ;;
13553 esac
13554 _ACEOF
13555
13556 # Neutralize VPATH when `$srcdir' = `.'.
13557 # Shell code in configure.ac might set extrasub.
13558 # FIXME: do we really want to maintain this feature?
13559 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13560 ac_sed_extra="$ac_vpsub
13561 $extrasub
13562 _ACEOF
13563 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13564 :t
13565 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
13566 s|@configure_input@|$ac_sed_conf_input|;t t
13567 s&@top_builddir@&$ac_top_builddir_sub&;t t
13568 s&@top_build_prefix@&$ac_top_build_prefix&;t t
13569 s&@srcdir@&$ac_srcdir&;t t
13570 s&@abs_srcdir@&$ac_abs_srcdir&;t t
13571 s&@top_srcdir@&$ac_top_srcdir&;t t
13572 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
13573 s&@builddir@&$ac_builddir&;t t
13574 s&@abs_builddir@&$ac_abs_builddir&;t t
13575 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
13576 $ac_datarootdir_hack
13577 "
13578 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
13579   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
13580
13581 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
13582   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
13583   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
13584       "$ac_tmp/out"`; test -z "$ac_out"; } &&
13585   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
13586 which seems to be undefined.  Please make sure it is defined" >&5
13587 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
13588 which seems to be undefined.  Please make sure it is defined" >&2;}
13589
13590   rm -f "$ac_tmp/stdin"
13591   case $ac_file in
13592   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
13593   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
13594   esac \
13595   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
13596  ;;
13597   :H)
13598   #
13599   # CONFIG_HEADER
13600   #
13601   if test x"$ac_file" != x-; then
13602     {
13603       $as_echo "/* $configure_input  */" \
13604       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
13605     } >"$ac_tmp/config.h" \
13606       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
13607     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
13608       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
13609 $as_echo "$as_me: $ac_file is unchanged" >&6;}
13610     else
13611       rm -f "$ac_file"
13612       mv "$ac_tmp/config.h" "$ac_file" \
13613         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
13614     fi
13615   else
13616     $as_echo "/* $configure_input  */" \
13617       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
13618       || as_fn_error $? "could not create -" "$LINENO" 5
13619   fi
13620  ;;
13621
13622   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
13623 $as_echo "$as_me: executing $ac_file commands" >&6;}
13624  ;;
13625   esac
13626
13627
13628   case $ac_file$ac_mode in
13629     "stamp-h":C) echo timestamp > src/include/stamp-h ;;
13630     "build-radpaths-h":C) (cd ./src/include && /bin/sh ./build-radpaths-h) ;;
13631     "main-chmod":C) (cd ./src/main && chmod +x checkrad radlast radtest) ;;
13632     "scripts-chmod":C) (cd ./scripts && chmod +x rc.radiusd cron/radiusd.cron.daily cron/radiusd.cron.monthly cryptpasswd) ;;
13633
13634   esac
13635 done # for ac_tag
13636
13637
13638 as_fn_exit 0
13639 _ACEOF
13640 ac_clean_files=$ac_clean_files_save
13641
13642 test $ac_write_fail = 0 ||
13643   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
13644
13645
13646 # configure is writing to config.log, and then calls config.status.
13647 # config.status does its own redirection, appending to config.log.
13648 # Unfortunately, on DOS this fails, as config.log is still kept open
13649 # by configure, so config.status won't be able to write to it; its
13650 # output is simply discarded.  So we exec the FD to /dev/null,
13651 # effectively closing config.log, so it can be properly (re)opened and
13652 # appended to by config.status.  When coming back to configure, we
13653 # need to make the FD available again.
13654 if test "$no_create" != yes; then
13655   ac_cs_success=:
13656   ac_config_status_args=
13657   test "$silent" = yes &&
13658     ac_config_status_args="$ac_config_status_args --quiet"
13659   exec 5>/dev/null
13660   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
13661   exec 5>>config.log
13662   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
13663   # would make configure fail if this is the last instruction.
13664   $ac_cs_success || as_fn_exit 1
13665 fi
13666
13667 #
13668 # CONFIG_SUBDIRS section.
13669 #
13670 if test "$no_recursion" != yes; then
13671
13672   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
13673   # so they do not pile up.
13674   ac_sub_configure_args=
13675   ac_prev=
13676   eval "set x $ac_configure_args"
13677   shift
13678   for ac_arg
13679   do
13680     if test -n "$ac_prev"; then
13681       ac_prev=
13682       continue
13683     fi
13684     case $ac_arg in
13685     -cache-file | --cache-file | --cache-fil | --cache-fi \
13686     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
13687       ac_prev=cache_file ;;
13688     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
13689     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
13690     | --c=*)
13691       ;;
13692     --config-cache | -C)
13693       ;;
13694     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
13695       ac_prev=srcdir ;;
13696     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
13697       ;;
13698     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
13699       ac_prev=prefix ;;
13700     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
13701       ;;
13702     --disable-option-checking)
13703       ;;
13704     *)
13705       case $ac_arg in
13706       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
13707       esac
13708       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
13709     esac
13710   done
13711
13712   # Always prepend --prefix to ensure using the same prefix
13713   # in subdir configurations.
13714   ac_arg="--prefix=$prefix"
13715   case $ac_arg in
13716   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
13717   esac
13718   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
13719
13720   # Pass --silent
13721   if test "$silent" = yes; then
13722     ac_sub_configure_args="--silent $ac_sub_configure_args"
13723   fi
13724
13725   # Always prepend --disable-option-checking to silence warnings, since
13726   # different subdirs can have different --enable and --with options.
13727   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
13728
13729   ac_popdir=`pwd`
13730   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
13731
13732     # Do not complain, so a configure script can configure whichever
13733     # parts of a large source tree are present.
13734     test -d "$srcdir/$ac_dir" || continue
13735
13736     ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
13737     $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
13738     $as_echo "$ac_msg" >&6
13739     as_dir="$ac_dir"; as_fn_mkdir_p
13740     ac_builddir=.
13741
13742 case "$ac_dir" in
13743 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
13744 *)
13745   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
13746   # A ".." for each directory in $ac_dir_suffix.
13747   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
13748   case $ac_top_builddir_sub in
13749   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
13750   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
13751   esac ;;
13752 esac
13753 ac_abs_top_builddir=$ac_pwd
13754 ac_abs_builddir=$ac_pwd$ac_dir_suffix
13755 # for backward compatibility:
13756 ac_top_builddir=$ac_top_build_prefix
13757
13758 case $srcdir in
13759   .)  # We are building in place.
13760     ac_srcdir=.
13761     ac_top_srcdir=$ac_top_builddir_sub
13762     ac_abs_top_srcdir=$ac_pwd ;;
13763   [\\/]* | ?:[\\/]* )  # Absolute name.
13764     ac_srcdir=$srcdir$ac_dir_suffix;
13765     ac_top_srcdir=$srcdir
13766     ac_abs_top_srcdir=$srcdir ;;
13767   *) # Relative name.
13768     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
13769     ac_top_srcdir=$ac_top_build_prefix$srcdir
13770     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
13771 esac
13772 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
13773
13774
13775     cd "$ac_dir"
13776
13777     # Check for guested configure; otherwise get Cygnus style configure.
13778     if test -f "$ac_srcdir/configure.gnu"; then
13779       ac_sub_configure=$ac_srcdir/configure.gnu
13780     elif test -f "$ac_srcdir/configure"; then
13781       ac_sub_configure=$ac_srcdir/configure
13782     elif test -f "$ac_srcdir/configure.in"; then
13783       # This should be Cygnus configure.
13784       ac_sub_configure=$ac_aux_dir/configure
13785     else
13786       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
13787 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
13788       ac_sub_configure=
13789     fi
13790
13791     # The recursion is here.
13792     if test -n "$ac_sub_configure"; then
13793       # Make the cache file name correct relative to the subdirectory.
13794       case $cache_file in
13795       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
13796       *) # Relative name.
13797         ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
13798       esac
13799
13800       { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
13801 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
13802       # The eval makes quoting arguments work.
13803       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
13804            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
13805         as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
13806     fi
13807
13808     cd "$ac_popdir"
13809   done
13810 fi
13811 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
13812   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
13813 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
13814 fi
13815
13816