]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/unbound/configure
zfs: merge openzfs/zfs@9198de8f1
[FreeBSD/FreeBSD.git] / contrib / unbound / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for unbound 1.18.0.
4 #
5 # Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>.
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
203   test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
204     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
205     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
206     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
207     PATH=/empty FPATH=/empty; export PATH FPATH
208     test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
209       || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
210   if (eval "$as_required") 2>/dev/null; then :
211   as_have_required=yes
212 else
213   as_have_required=no
214 fi
215   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
216
217 else
218   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
219 as_found=false
220 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
221 do
222   IFS=$as_save_IFS
223   test -z "$as_dir" && as_dir=.
224   as_found=:
225   case $as_dir in #(
226          /*)
227            for as_base in sh bash ksh sh5; do
228              # Try only shells that exist, to save several forks.
229              as_shell=$as_dir/$as_base
230              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
231                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
232   CONFIG_SHELL=$as_shell as_have_required=yes
233                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
234   break 2
235 fi
236 fi
237            done;;
238        esac
239   as_found=false
240 done
241 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
242               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
243   CONFIG_SHELL=$SHELL as_have_required=yes
244 fi; }
245 IFS=$as_save_IFS
246
247
248       if test "x$CONFIG_SHELL" != x; then :
249   export CONFIG_SHELL
250              # We cannot yet assume a decent shell, so we have to provide a
251 # neutralization value for shells without unset; and this also
252 # works around shells that cannot unset nonexistent variables.
253 # Preserve -v and -x to the replacement shell.
254 BASH_ENV=/dev/null
255 ENV=/dev/null
256 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
257 case $- in # ((((
258   *v*x* | *x*v* ) as_opts=-vx ;;
259   *v* ) as_opts=-v ;;
260   *x* ) as_opts=-x ;;
261   * ) as_opts= ;;
262 esac
263 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
264 # Admittedly, this is quite paranoid, since all the known shells bail
265 # out after a failed `exec'.
266 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
267 exit 255
268 fi
269
270     if test x$as_have_required = xno; then :
271   $as_echo "$0: This script requires a shell more modern than all"
272   $as_echo "$0: the shells that I found on your system."
273   if test x${ZSH_VERSION+set} = xset ; then
274     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
275     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
276   else
277     $as_echo "$0: Please tell bug-autoconf@gnu.org and
278 $0: unbound-bugs@nlnetlabs.nl or
279 $0: https://github.com/NLnetLabs/unbound/issues about your
280 $0: system, including any error possibly output before this
281 $0: message. Then install a modern shell, or manually run
282 $0: the script under such a shell if you do have one."
283   fi
284   exit 1
285 fi
286 fi
287 fi
288 SHELL=${CONFIG_SHELL-/bin/sh}
289 export SHELL
290 # Unset more variables known to interfere with behavior of common tools.
291 CLICOLOR_FORCE= GREP_OPTIONS=
292 unset CLICOLOR_FORCE GREP_OPTIONS
293
294 ## --------------------- ##
295 ## M4sh Shell Functions. ##
296 ## --------------------- ##
297 # as_fn_unset VAR
298 # ---------------
299 # Portably unset VAR.
300 as_fn_unset ()
301 {
302   { eval $1=; unset $1;}
303 }
304 as_unset=as_fn_unset
305
306 # as_fn_set_status STATUS
307 # -----------------------
308 # Set $? to STATUS, without forking.
309 as_fn_set_status ()
310 {
311   return $1
312 } # as_fn_set_status
313
314 # as_fn_exit STATUS
315 # -----------------
316 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
317 as_fn_exit ()
318 {
319   set +e
320   as_fn_set_status $1
321   exit $1
322 } # as_fn_exit
323
324 # as_fn_mkdir_p
325 # -------------
326 # Create "$as_dir" as a directory, including parents if necessary.
327 as_fn_mkdir_p ()
328 {
329
330   case $as_dir in #(
331   -*) as_dir=./$as_dir;;
332   esac
333   test -d "$as_dir" || eval $as_mkdir_p || {
334     as_dirs=
335     while :; do
336       case $as_dir in #(
337       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
338       *) as_qdir=$as_dir;;
339       esac
340       as_dirs="'$as_qdir' $as_dirs"
341       as_dir=`$as_dirname -- "$as_dir" ||
342 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
343          X"$as_dir" : 'X\(//\)[^/]' \| \
344          X"$as_dir" : 'X\(//\)$' \| \
345          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
346 $as_echo X"$as_dir" |
347     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
348             s//\1/
349             q
350           }
351           /^X\(\/\/\)[^/].*/{
352             s//\1/
353             q
354           }
355           /^X\(\/\/\)$/{
356             s//\1/
357             q
358           }
359           /^X\(\/\).*/{
360             s//\1/
361             q
362           }
363           s/.*/./; q'`
364       test -d "$as_dir" && break
365     done
366     test -z "$as_dirs" || eval "mkdir $as_dirs"
367   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
368
369
370 } # as_fn_mkdir_p
371
372 # as_fn_executable_p FILE
373 # -----------------------
374 # Test if FILE is an executable regular file.
375 as_fn_executable_p ()
376 {
377   test -f "$1" && test -x "$1"
378 } # as_fn_executable_p
379 # as_fn_append VAR VALUE
380 # ----------------------
381 # Append the text in VALUE to the end of the definition contained in VAR. Take
382 # advantage of any shell optimizations that allow amortized linear growth over
383 # repeated appends, instead of the typical quadratic growth present in naive
384 # implementations.
385 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
386   eval 'as_fn_append ()
387   {
388     eval $1+=\$2
389   }'
390 else
391   as_fn_append ()
392   {
393     eval $1=\$$1\$2
394   }
395 fi # as_fn_append
396
397 # as_fn_arith ARG...
398 # ------------------
399 # Perform arithmetic evaluation on the ARGs, and store the result in the
400 # global $as_val. Take advantage of shells that can avoid forks. The arguments
401 # must be portable across $(()) and expr.
402 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
403   eval 'as_fn_arith ()
404   {
405     as_val=$(( $* ))
406   }'
407 else
408   as_fn_arith ()
409   {
410     as_val=`expr "$@" || test $? -eq 1`
411   }
412 fi # as_fn_arith
413
414
415 # as_fn_error STATUS ERROR [LINENO LOG_FD]
416 # ----------------------------------------
417 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
418 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
419 # script with STATUS, using 1 if that was 0.
420 as_fn_error ()
421 {
422   as_status=$1; test $as_status -eq 0 && as_status=1
423   if test "$4"; then
424     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
425     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
426   fi
427   $as_echo "$as_me: error: $2" >&2
428   as_fn_exit $as_status
429 } # as_fn_error
430
431 if expr a : '\(a\)' >/dev/null 2>&1 &&
432    test "X`expr 00001 : '.*\(...\)'`" = X001; then
433   as_expr=expr
434 else
435   as_expr=false
436 fi
437
438 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
439   as_basename=basename
440 else
441   as_basename=false
442 fi
443
444 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
445   as_dirname=dirname
446 else
447   as_dirname=false
448 fi
449
450 as_me=`$as_basename -- "$0" ||
451 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
452          X"$0" : 'X\(//\)$' \| \
453          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
454 $as_echo X/"$0" |
455     sed '/^.*\/\([^/][^/]*\)\/*$/{
456             s//\1/
457             q
458           }
459           /^X\/\(\/\/\)$/{
460             s//\1/
461             q
462           }
463           /^X\/\(\/\).*/{
464             s//\1/
465             q
466           }
467           s/.*/./; q'`
468
469 # Avoid depending upon Character Ranges.
470 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
471 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
472 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
473 as_cr_digits='0123456789'
474 as_cr_alnum=$as_cr_Letters$as_cr_digits
475
476
477   as_lineno_1=$LINENO as_lineno_1a=$LINENO
478   as_lineno_2=$LINENO as_lineno_2a=$LINENO
479   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
480   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
481   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
482   sed -n '
483     p
484     /[$]LINENO/=
485   ' <$as_myself |
486     sed '
487       s/[$]LINENO.*/&-/
488       t lineno
489       b
490       :lineno
491       N
492       :loop
493       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
494       t loop
495       s/-\n.*//
496     ' >$as_me.lineno &&
497   chmod +x "$as_me.lineno" ||
498     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
499
500   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
501   # already done that, so ensure we don't try to do so again and fall
502   # in an infinite loop.  This has already happened in practice.
503   _as_can_reexec=no; export _as_can_reexec
504   # Don't try to exec as it changes $[0], causing all sort of problems
505   # (the dirname of $[0] is not the place where we might find the
506   # original and so on.  Autoconf is especially sensitive to this).
507   . "./$as_me.lineno"
508   # Exit status is that of the last command.
509   exit
510 }
511
512 ECHO_C= ECHO_N= ECHO_T=
513 case `echo -n x` in #(((((
514 -n*)
515   case `echo 'xy\c'` in
516   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
517   xy)  ECHO_C='\c';;
518   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
519        ECHO_T=' ';;
520   esac;;
521 *)
522   ECHO_N='-n';;
523 esac
524
525 rm -f conf$$ conf$$.exe conf$$.file
526 if test -d conf$$.dir; then
527   rm -f conf$$.dir/conf$$.file
528 else
529   rm -f conf$$.dir
530   mkdir conf$$.dir 2>/dev/null
531 fi
532 if (echo >conf$$.file) 2>/dev/null; then
533   if ln -s conf$$.file conf$$ 2>/dev/null; then
534     as_ln_s='ln -s'
535     # ... but there are two gotchas:
536     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
537     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
538     # In both cases, we have to default to `cp -pR'.
539     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
540       as_ln_s='cp -pR'
541   elif ln conf$$.file conf$$ 2>/dev/null; then
542     as_ln_s=ln
543   else
544     as_ln_s='cp -pR'
545   fi
546 else
547   as_ln_s='cp -pR'
548 fi
549 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
550 rmdir conf$$.dir 2>/dev/null
551
552 if mkdir -p . 2>/dev/null; then
553   as_mkdir_p='mkdir -p "$as_dir"'
554 else
555   test -d ./-p && rmdir ./-p
556   as_mkdir_p=false
557 fi
558
559 as_test_x='test -x'
560 as_executable_p=as_fn_executable_p
561
562 # Sed expression to map a string onto a valid CPP name.
563 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
564
565 # Sed expression to map a string onto a valid variable name.
566 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
567
568 SHELL=${CONFIG_SHELL-/bin/sh}
569
570
571 test -n "$DJDIR" || exec 7<&0 </dev/null
572 exec 6>&1
573
574 # Name of the host.
575 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
576 # so uname gets run too.
577 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
578
579 #
580 # Initializations.
581 #
582 ac_default_prefix=/usr/local
583 ac_clean_files=
584 ac_config_libobj_dir=.
585 LIBOBJS=
586 cross_compiling=no
587 subdirs=
588 MFLAGS=
589 MAKEFLAGS=
590
591 # Identity of this package.
592 PACKAGE_NAME='unbound'
593 PACKAGE_TARNAME='unbound'
594 PACKAGE_VERSION='1.18.0'
595 PACKAGE_STRING='unbound 1.18.0'
596 PACKAGE_BUGREPORT='unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues'
597 PACKAGE_URL=''
598
599 # Factoring default headers for most tests.
600 ac_includes_default="\
601 #include <stdio.h>
602 #ifdef HAVE_SYS_TYPES_H
603 # include <sys/types.h>
604 #endif
605 #ifdef HAVE_SYS_STAT_H
606 # include <sys/stat.h>
607 #endif
608 #ifdef STDC_HEADERS
609 # include <stdlib.h>
610 # include <stddef.h>
611 #else
612 # ifdef HAVE_STDLIB_H
613 #  include <stdlib.h>
614 # endif
615 #endif
616 #ifdef HAVE_STRING_H
617 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
618 #  include <memory.h>
619 # endif
620 # include <string.h>
621 #endif
622 #ifdef HAVE_STRINGS_H
623 # include <strings.h>
624 #endif
625 #ifdef HAVE_INTTYPES_H
626 # include <inttypes.h>
627 #endif
628 #ifdef HAVE_STDINT_H
629 # include <stdint.h>
630 #endif
631 #ifdef HAVE_UNISTD_H
632 # include <unistd.h>
633 #endif"
634
635 ac_subst_vars='LTLIBOBJS
636 date
637 version
638 INSTALLTARGET
639 ALLTARGET
640 SOURCEFILE
641 SOURCEDETERMINE
642 IPSET_OBJ
643 IPSET_SRC
644 IPSECMOD_HEADER
645 IPSECMOD_OBJ
646 CACHEDB_OBJ
647 CACHEDB_SRC
648 DNSCRYPT_OBJ
649 DNSCRYPT_SRC
650 ENABLE_DNSCRYPT
651 ENABLE_DNSCRYPT_XCHACHA20
652 DNSTAP_OBJ
653 DNSTAP_SRC
654 DNSTAP_SOCKET_TESTBIN
655 DNSTAP_SOCKET_PATH
656 opt_dnstap_socket_path
657 ENABLE_DNSTAP
658 PROTOC_C
659 UBSYMS
660 EXTRALINK
661 COMMON_OBJ_ALL_SYMBOLS
662 LIBOBJ_WITHOUT_CTIME
663 LIBOBJ_WITHOUT_CTIMEARC4
664 WIN_CHECKCONF_OBJ_LINK
665 WIN_CONTROL_OBJ_LINK
666 WIN_UBANCHOR_OBJ_LINK
667 WIN_HOST_OBJ_LINK
668 WIN_DAEMON_OBJ_LINK
669 WIN_DAEMON_OBJ
670 WIN_DAEMON_SRC
671 WINAPPS
672 WINDRES
673 CHECKLOCK_OBJ
674 staticexe
675 PC_LIBEVENT_DEPENDENCY
676 UNBOUND_EVENT_UNINSTALL
677 UNBOUND_EVENT_INSTALL
678 SUBNET_HEADER
679 SUBNET_OBJ
680 PC_LIBBSD_DEPENDENCY
681 SSLLIB
682 HAVE_SSL
683 PC_CRYPTO_DEPENDENCY
684 CONFIG_DATE
685 GCC_DOCKER_LINTFLAGS
686 NETBSD_LINTFLAGS
687 PYUNBOUND_UNINSTALL
688 PYUNBOUND_INSTALL
689 PYUNBOUND_TARGET
690 PYUNBOUND_OBJ
691 WITH_PYUNBOUND
692 PYTHONMOD_UNINSTALL
693 PYTHONMOD_INSTALL
694 PYTHONMOD_HEADER
695 PYTHONMOD_OBJ
696 WITH_PYTHONMODULE
697 swig
698 SWIG_LIB
699 SWIG
700 PC_PY_DEPENDENCY
701 PYTHON_LIBS
702 PY_MAJOR_VERSION
703 PYTHON_SITE_PKG
704 PYTHON_LDFLAGS
705 PYTHON_CPPFLAGS
706 PYTHON
707 PYTHON_VERSION
708 DYNLIBMOD_EXTRALIBS
709 DYNLIBMOD_HEADER
710 DYNLIBMOD_OBJ
711 WITH_DYNLIBMODULE
712 PTHREAD_CFLAGS_ONLY
713 PTHREAD_CFLAGS
714 PTHREAD_LIBS
715 PTHREAD_CC
716 ax_pthread_config
717 ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ
718 SLDNS_ALLOCCHECK_EXTRA_OBJ
719 USE_SYSTEMD_FALSE
720 USE_SYSTEMD_TRUE
721 SYSTEMD_DAEMON_LIBS
722 SYSTEMD_DAEMON_CFLAGS
723 SYSTEMD_LIBS
724 SYSTEMD_CFLAGS
725 RUNTIME_PATH
726 LIBOBJS
727 PKG_CONFIG_LIBDIR
728 PKG_CONFIG_PATH
729 PKG_CONFIG
730 LT_SYS_LIBRARY_PATH
731 OTOOL64
732 OTOOL
733 LIPO
734 NMEDIT
735 DSYMUTIL
736 MANIFEST_TOOL
737 AWK
738 RANLIB
739 ac_ct_AR
740 DLLTOOL
741 OBJDUMP
742 LN_S
743 NM
744 ac_ct_DUMPBIN
745 DUMPBIN
746 LD
747 FGREP
748 SED
749 LIBTOOL
750 AR
751 host_os
752 host_vendor
753 host_cpu
754 host
755 build_os
756 build_vendor
757 build_cpu
758 build
759 libtool
760 STRIP
761 doxygen
762 YFLAGS
763 YACC
764 LEXLIB
765 LEX_OUTPUT_ROOT
766 LEX
767 debug_enabled
768 DEPFLAG
769 UNBOUND_USERNAME
770 UNBOUND_ROOTCERT_FILE
771 UNBOUND_ROOTKEY_FILE
772 UNBOUND_PIDFILE
773 UNBOUND_SHARE_DIR
774 UNBOUND_CHROOT_DIR
775 UNBOUND_RUN_DIR
776 ub_conf_dir
777 ub_conf_file
778 UNBOUND_LOCALSTATE_DIR
779 UNBOUND_SYSCONF_DIR
780 UNBOUND_SBIN_DIR
781 EGREP
782 GREP
783 CPP
784 OBJEXT
785 EXEEXT
786 ac_ct_CC
787 CPPFLAGS
788 LDFLAGS
789 CFLAGS
790 CC
791 LIBUNBOUND_AGE
792 LIBUNBOUND_REVISION
793 LIBUNBOUND_CURRENT
794 UNBOUND_VERSION_MICRO
795 UNBOUND_VERSION_MINOR
796 UNBOUND_VERSION_MAJOR
797 target_alias
798 host_alias
799 build_alias
800 LIBS
801 ECHO_T
802 ECHO_N
803 ECHO_C
804 DEFS
805 mandir
806 localedir
807 libdir
808 psdir
809 pdfdir
810 dvidir
811 htmldir
812 infodir
813 docdir
814 oldincludedir
815 includedir
816 runstatedir
817 localstatedir
818 sharedstatedir
819 sysconfdir
820 datadir
821 datarootdir
822 libexecdir
823 sbindir
824 bindir
825 program_transform_name
826 prefix
827 exec_prefix
828 PACKAGE_URL
829 PACKAGE_BUGREPORT
830 PACKAGE_STRING
831 PACKAGE_VERSION
832 PACKAGE_TARNAME
833 PACKAGE_NAME
834 PATH_SEPARATOR
835 SHELL'
836 ac_subst_files=''
837 ac_user_opts='
838 enable_option_checking
839 with_conf_file
840 with_run_dir
841 with_chroot_dir
842 with_share_dir
843 with_pidfile
844 with_rootkey_file
845 with_rootcert_file
846 with_username
847 enable_checking
848 enable_debug
849 enable_flto
850 enable_pie
851 enable_relro_now
852 enable_shared
853 enable_static
854 with_pic
855 enable_fast_install
856 with_aix_soname
857 with_gnu_ld
858 with_sysroot
859 enable_libtool_lock
860 enable_rpath
861 enable_largefile
862 enable_systemd
863 enable_alloc_checks
864 enable_alloc_lite
865 enable_alloc_nonregional
866 with_pthreads
867 with_solaris_threads
868 with_syslog_facility
869 with_dynlibmodule
870 with_pyunbound
871 with_pythonmodule
872 enable_swig_version_check
873 with_nss
874 with_nettle
875 with_ssl
876 with_libbsd
877 enable_sha1
878 enable_sha2
879 enable_subnet
880 enable_gost
881 enable_ecdsa
882 enable_dsa
883 with_deprecate_rsa_1024
884 enable_ed25519
885 enable_ed448
886 enable_event_api
887 enable_tfo_client
888 enable_tfo_server
889 with_libevent
890 with_libexpat
891 with_libhiredis
892 with_libnghttp2
893 enable_static_exe
894 enable_fully_static
895 enable_lock_checks
896 enable_allsymbols
897 enable_dnstap
898 with_dnstap_socket_path
899 with_protobuf_c
900 enable_dnscrypt
901 with_libsodium
902 enable_cachedb
903 enable_ipsecmod
904 enable_ipset
905 with_libmnl
906 enable_explicit_port_randomisation
907 enable_linux_ip_local_port_range
908 with_libunbound_only
909 '
910       ac_precious_vars='build_alias
911 host_alias
912 target_alias
913 CC
914 CFLAGS
915 LDFLAGS
916 LIBS
917 CPPFLAGS
918 CPP
919 YACC
920 YFLAGS
921 LT_SYS_LIBRARY_PATH
922 PKG_CONFIG
923 PKG_CONFIG_PATH
924 PKG_CONFIG_LIBDIR
925 SYSTEMD_CFLAGS
926 SYSTEMD_LIBS
927 SYSTEMD_DAEMON_CFLAGS
928 SYSTEMD_DAEMON_LIBS
929 PYTHON_VERSION'
930
931
932 # Initialize some variables set by options.
933 ac_init_help=
934 ac_init_version=false
935 ac_unrecognized_opts=
936 ac_unrecognized_sep=
937 # The variables have the same names as the options, with
938 # dashes changed to underlines.
939 cache_file=/dev/null
940 exec_prefix=NONE
941 no_create=
942 no_recursion=
943 prefix=NONE
944 program_prefix=NONE
945 program_suffix=NONE
946 program_transform_name=s,x,x,
947 silent=
948 site=
949 srcdir=
950 verbose=
951 x_includes=NONE
952 x_libraries=NONE
953
954 # Installation directory options.
955 # These are left unexpanded so users can "make install exec_prefix=/foo"
956 # and all the variables that are supposed to be based on exec_prefix
957 # by default will actually change.
958 # Use braces instead of parens because sh, perl, etc. also accept them.
959 # (The list follows the same order as the GNU Coding Standards.)
960 bindir='${exec_prefix}/bin'
961 sbindir='${exec_prefix}/sbin'
962 libexecdir='${exec_prefix}/libexec'
963 datarootdir='${prefix}/share'
964 datadir='${datarootdir}'
965 sysconfdir='${prefix}/etc'
966 sharedstatedir='${prefix}/com'
967 localstatedir='${prefix}/var'
968 runstatedir='${localstatedir}/run'
969 includedir='${prefix}/include'
970 oldincludedir='/usr/include'
971 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
972 infodir='${datarootdir}/info'
973 htmldir='${docdir}'
974 dvidir='${docdir}'
975 pdfdir='${docdir}'
976 psdir='${docdir}'
977 libdir='${exec_prefix}/lib'
978 localedir='${datarootdir}/locale'
979 mandir='${datarootdir}/man'
980
981 ac_prev=
982 ac_dashdash=
983 for ac_option
984 do
985   # If the previous option needs an argument, assign it.
986   if test -n "$ac_prev"; then
987     eval $ac_prev=\$ac_option
988     ac_prev=
989     continue
990   fi
991
992   case $ac_option in
993   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
994   *=)   ac_optarg= ;;
995   *)    ac_optarg=yes ;;
996   esac
997
998   # Accept the important Cygnus configure options, so we can diagnose typos.
999
1000   case $ac_dashdash$ac_option in
1001   --)
1002     ac_dashdash=yes ;;
1003
1004   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1005     ac_prev=bindir ;;
1006   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1007     bindir=$ac_optarg ;;
1008
1009   -build | --build | --buil | --bui | --bu)
1010     ac_prev=build_alias ;;
1011   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1012     build_alias=$ac_optarg ;;
1013
1014   -cache-file | --cache-file | --cache-fil | --cache-fi \
1015   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1016     ac_prev=cache_file ;;
1017   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1018   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1019     cache_file=$ac_optarg ;;
1020
1021   --config-cache | -C)
1022     cache_file=config.cache ;;
1023
1024   -datadir | --datadir | --datadi | --datad)
1025     ac_prev=datadir ;;
1026   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1027     datadir=$ac_optarg ;;
1028
1029   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1030   | --dataroo | --dataro | --datar)
1031     ac_prev=datarootdir ;;
1032   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1033   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1034     datarootdir=$ac_optarg ;;
1035
1036   -disable-* | --disable-*)
1037     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1038     # Reject names that are not valid shell variable names.
1039     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1040       as_fn_error $? "invalid feature name: $ac_useropt"
1041     ac_useropt_orig=$ac_useropt
1042     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1043     case $ac_user_opts in
1044       *"
1045 "enable_$ac_useropt"
1046 "*) ;;
1047       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1048          ac_unrecognized_sep=', ';;
1049     esac
1050     eval enable_$ac_useropt=no ;;
1051
1052   -docdir | --docdir | --docdi | --doc | --do)
1053     ac_prev=docdir ;;
1054   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1055     docdir=$ac_optarg ;;
1056
1057   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1058     ac_prev=dvidir ;;
1059   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1060     dvidir=$ac_optarg ;;
1061
1062   -enable-* | --enable-*)
1063     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1064     # Reject names that are not valid shell variable names.
1065     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1066       as_fn_error $? "invalid feature name: $ac_useropt"
1067     ac_useropt_orig=$ac_useropt
1068     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1069     case $ac_user_opts in
1070       *"
1071 "enable_$ac_useropt"
1072 "*) ;;
1073       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1074          ac_unrecognized_sep=', ';;
1075     esac
1076     eval enable_$ac_useropt=\$ac_optarg ;;
1077
1078   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1079   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1080   | --exec | --exe | --ex)
1081     ac_prev=exec_prefix ;;
1082   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1083   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1084   | --exec=* | --exe=* | --ex=*)
1085     exec_prefix=$ac_optarg ;;
1086
1087   -gas | --gas | --ga | --g)
1088     # Obsolete; use --with-gas.
1089     with_gas=yes ;;
1090
1091   -help | --help | --hel | --he | -h)
1092     ac_init_help=long ;;
1093   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1094     ac_init_help=recursive ;;
1095   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1096     ac_init_help=short ;;
1097
1098   -host | --host | --hos | --ho)
1099     ac_prev=host_alias ;;
1100   -host=* | --host=* | --hos=* | --ho=*)
1101     host_alias=$ac_optarg ;;
1102
1103   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1104     ac_prev=htmldir ;;
1105   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1106   | --ht=*)
1107     htmldir=$ac_optarg ;;
1108
1109   -includedir | --includedir | --includedi | --included | --include \
1110   | --includ | --inclu | --incl | --inc)
1111     ac_prev=includedir ;;
1112   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1113   | --includ=* | --inclu=* | --incl=* | --inc=*)
1114     includedir=$ac_optarg ;;
1115
1116   -infodir | --infodir | --infodi | --infod | --info | --inf)
1117     ac_prev=infodir ;;
1118   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1119     infodir=$ac_optarg ;;
1120
1121   -libdir | --libdir | --libdi | --libd)
1122     ac_prev=libdir ;;
1123   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1124     libdir=$ac_optarg ;;
1125
1126   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1127   | --libexe | --libex | --libe)
1128     ac_prev=libexecdir ;;
1129   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1130   | --libexe=* | --libex=* | --libe=*)
1131     libexecdir=$ac_optarg ;;
1132
1133   -localedir | --localedir | --localedi | --localed | --locale)
1134     ac_prev=localedir ;;
1135   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1136     localedir=$ac_optarg ;;
1137
1138   -localstatedir | --localstatedir | --localstatedi | --localstated \
1139   | --localstate | --localstat | --localsta | --localst | --locals)
1140     ac_prev=localstatedir ;;
1141   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1142   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1143     localstatedir=$ac_optarg ;;
1144
1145   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1146     ac_prev=mandir ;;
1147   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1148     mandir=$ac_optarg ;;
1149
1150   -nfp | --nfp | --nf)
1151     # Obsolete; use --without-fp.
1152     with_fp=no ;;
1153
1154   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1155   | --no-cr | --no-c | -n)
1156     no_create=yes ;;
1157
1158   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1159   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1160     no_recursion=yes ;;
1161
1162   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1163   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1164   | --oldin | --oldi | --old | --ol | --o)
1165     ac_prev=oldincludedir ;;
1166   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1167   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1168   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1169     oldincludedir=$ac_optarg ;;
1170
1171   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1172     ac_prev=prefix ;;
1173   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1174     prefix=$ac_optarg ;;
1175
1176   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1177   | --program-pre | --program-pr | --program-p)
1178     ac_prev=program_prefix ;;
1179   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1180   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1181     program_prefix=$ac_optarg ;;
1182
1183   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1184   | --program-suf | --program-su | --program-s)
1185     ac_prev=program_suffix ;;
1186   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1187   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1188     program_suffix=$ac_optarg ;;
1189
1190   -program-transform-name | --program-transform-name \
1191   | --program-transform-nam | --program-transform-na \
1192   | --program-transform-n | --program-transform- \
1193   | --program-transform | --program-transfor \
1194   | --program-transfo | --program-transf \
1195   | --program-trans | --program-tran \
1196   | --progr-tra | --program-tr | --program-t)
1197     ac_prev=program_transform_name ;;
1198   -program-transform-name=* | --program-transform-name=* \
1199   | --program-transform-nam=* | --program-transform-na=* \
1200   | --program-transform-n=* | --program-transform-=* \
1201   | --program-transform=* | --program-transfor=* \
1202   | --program-transfo=* | --program-transf=* \
1203   | --program-trans=* | --program-tran=* \
1204   | --progr-tra=* | --program-tr=* | --program-t=*)
1205     program_transform_name=$ac_optarg ;;
1206
1207   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1208     ac_prev=pdfdir ;;
1209   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1210     pdfdir=$ac_optarg ;;
1211
1212   -psdir | --psdir | --psdi | --psd | --ps)
1213     ac_prev=psdir ;;
1214   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1215     psdir=$ac_optarg ;;
1216
1217   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1218   | -silent | --silent | --silen | --sile | --sil)
1219     silent=yes ;;
1220
1221   -runstatedir | --runstatedir | --runstatedi | --runstated \
1222   | --runstate | --runstat | --runsta | --runst | --runs \
1223   | --run | --ru | --r)
1224     ac_prev=runstatedir ;;
1225   -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1226   | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1227   | --run=* | --ru=* | --r=*)
1228     runstatedir=$ac_optarg ;;
1229
1230   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1231     ac_prev=sbindir ;;
1232   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1233   | --sbi=* | --sb=*)
1234     sbindir=$ac_optarg ;;
1235
1236   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1237   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1238   | --sharedst | --shareds | --shared | --share | --shar \
1239   | --sha | --sh)
1240     ac_prev=sharedstatedir ;;
1241   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1242   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1243   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1244   | --sha=* | --sh=*)
1245     sharedstatedir=$ac_optarg ;;
1246
1247   -site | --site | --sit)
1248     ac_prev=site ;;
1249   -site=* | --site=* | --sit=*)
1250     site=$ac_optarg ;;
1251
1252   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1253     ac_prev=srcdir ;;
1254   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1255     srcdir=$ac_optarg ;;
1256
1257   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1258   | --syscon | --sysco | --sysc | --sys | --sy)
1259     ac_prev=sysconfdir ;;
1260   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1261   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1262     sysconfdir=$ac_optarg ;;
1263
1264   -target | --target | --targe | --targ | --tar | --ta | --t)
1265     ac_prev=target_alias ;;
1266   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1267     target_alias=$ac_optarg ;;
1268
1269   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1270     verbose=yes ;;
1271
1272   -version | --version | --versio | --versi | --vers | -V)
1273     ac_init_version=: ;;
1274
1275   -with-* | --with-*)
1276     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1277     # Reject names that are not valid shell variable names.
1278     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1279       as_fn_error $? "invalid package name: $ac_useropt"
1280     ac_useropt_orig=$ac_useropt
1281     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1282     case $ac_user_opts in
1283       *"
1284 "with_$ac_useropt"
1285 "*) ;;
1286       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1287          ac_unrecognized_sep=', ';;
1288     esac
1289     eval with_$ac_useropt=\$ac_optarg ;;
1290
1291   -without-* | --without-*)
1292     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1293     # Reject names that are not valid shell variable names.
1294     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1295       as_fn_error $? "invalid package name: $ac_useropt"
1296     ac_useropt_orig=$ac_useropt
1297     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1298     case $ac_user_opts in
1299       *"
1300 "with_$ac_useropt"
1301 "*) ;;
1302       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1303          ac_unrecognized_sep=', ';;
1304     esac
1305     eval with_$ac_useropt=no ;;
1306
1307   --x)
1308     # Obsolete; use --with-x.
1309     with_x=yes ;;
1310
1311   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1312   | --x-incl | --x-inc | --x-in | --x-i)
1313     ac_prev=x_includes ;;
1314   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1315   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1316     x_includes=$ac_optarg ;;
1317
1318   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1319   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1320     ac_prev=x_libraries ;;
1321   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1322   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1323     x_libraries=$ac_optarg ;;
1324
1325   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1326 Try \`$0 --help' for more information"
1327     ;;
1328
1329   *=*)
1330     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1331     # Reject names that are not valid shell variable names.
1332     case $ac_envvar in #(
1333       '' | [0-9]* | *[!_$as_cr_alnum]* )
1334       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1335     esac
1336     eval $ac_envvar=\$ac_optarg
1337     export $ac_envvar ;;
1338
1339   *)
1340     # FIXME: should be removed in autoconf 3.0.
1341     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1342     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1343       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1344     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1345     ;;
1346
1347   esac
1348 done
1349
1350 if test -n "$ac_prev"; then
1351   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1352   as_fn_error $? "missing argument to $ac_option"
1353 fi
1354
1355 if test -n "$ac_unrecognized_opts"; then
1356   case $enable_option_checking in
1357     no) ;;
1358     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1359     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1360   esac
1361 fi
1362
1363 # Check all directory arguments for consistency.
1364 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1365                 datadir sysconfdir sharedstatedir localstatedir includedir \
1366                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1367                 libdir localedir mandir runstatedir
1368 do
1369   eval ac_val=\$$ac_var
1370   # Remove trailing slashes.
1371   case $ac_val in
1372     */ )
1373       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1374       eval $ac_var=\$ac_val;;
1375   esac
1376   # Be sure to have absolute directory names.
1377   case $ac_val in
1378     [\\/$]* | ?:[\\/]* )  continue;;
1379     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1380   esac
1381   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1382 done
1383
1384 # There might be people who depend on the old broken behavior: `$host'
1385 # used to hold the argument of --host etc.
1386 # FIXME: To remove some day.
1387 build=$build_alias
1388 host=$host_alias
1389 target=$target_alias
1390
1391 # FIXME: To remove some day.
1392 if test "x$host_alias" != x; then
1393   if test "x$build_alias" = x; then
1394     cross_compiling=maybe
1395   elif test "x$build_alias" != "x$host_alias"; then
1396     cross_compiling=yes
1397   fi
1398 fi
1399
1400 ac_tool_prefix=
1401 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1402
1403 test "$silent" = yes && exec 6>/dev/null
1404
1405
1406 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1407 ac_ls_di=`ls -di .` &&
1408 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1409   as_fn_error $? "working directory cannot be determined"
1410 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1411   as_fn_error $? "pwd does not report name of working directory"
1412
1413
1414 # Find the source files, if location was not specified.
1415 if test -z "$srcdir"; then
1416   ac_srcdir_defaulted=yes
1417   # Try the directory containing this script, then the parent directory.
1418   ac_confdir=`$as_dirname -- "$as_myself" ||
1419 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1420          X"$as_myself" : 'X\(//\)[^/]' \| \
1421          X"$as_myself" : 'X\(//\)$' \| \
1422          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1423 $as_echo X"$as_myself" |
1424     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1425             s//\1/
1426             q
1427           }
1428           /^X\(\/\/\)[^/].*/{
1429             s//\1/
1430             q
1431           }
1432           /^X\(\/\/\)$/{
1433             s//\1/
1434             q
1435           }
1436           /^X\(\/\).*/{
1437             s//\1/
1438             q
1439           }
1440           s/.*/./; q'`
1441   srcdir=$ac_confdir
1442   if test ! -r "$srcdir/$ac_unique_file"; then
1443     srcdir=..
1444   fi
1445 else
1446   ac_srcdir_defaulted=no
1447 fi
1448 if test ! -r "$srcdir/$ac_unique_file"; then
1449   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1450   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1451 fi
1452 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1453 ac_abs_confdir=`(
1454         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1455         pwd)`
1456 # When building in place, set srcdir=.
1457 if test "$ac_abs_confdir" = "$ac_pwd"; then
1458   srcdir=.
1459 fi
1460 # Remove unnecessary trailing slashes from srcdir.
1461 # Double slashes in file names in object file debugging info
1462 # mess up M-x gdb in Emacs.
1463 case $srcdir in
1464 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1465 esac
1466 for ac_var in $ac_precious_vars; do
1467   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1468   eval ac_env_${ac_var}_value=\$${ac_var}
1469   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1470   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1471 done
1472
1473 #
1474 # Report the --help message.
1475 #
1476 if test "$ac_init_help" = "long"; then
1477   # Omit some internal or obsolete options to make the list less imposing.
1478   # This message is too long to be a string in the A/UX 3.1 sh.
1479   cat <<_ACEOF
1480 \`configure' configures unbound 1.18.0 to adapt to many kinds of systems.
1481
1482 Usage: $0 [OPTION]... [VAR=VALUE]...
1483
1484 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1485 VAR=VALUE.  See below for descriptions of some of the useful variables.
1486
1487 Defaults for the options are specified in brackets.
1488
1489 Configuration:
1490   -h, --help              display this help and exit
1491       --help=short        display options specific to this package
1492       --help=recursive    display the short help of all the included packages
1493   -V, --version           display version information and exit
1494   -q, --quiet, --silent   do not print \`checking ...' messages
1495       --cache-file=FILE   cache test results in FILE [disabled]
1496   -C, --config-cache      alias for \`--cache-file=config.cache'
1497   -n, --no-create         do not create output files
1498       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1499
1500 Installation directories:
1501   --prefix=PREFIX         install architecture-independent files in PREFIX
1502                           [$ac_default_prefix]
1503   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1504                           [PREFIX]
1505
1506 By default, \`make install' will install all the files in
1507 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1508 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1509 for instance \`--prefix=\$HOME'.
1510
1511 For better control, use the options below.
1512
1513 Fine tuning of the installation directories:
1514   --bindir=DIR            user executables [EPREFIX/bin]
1515   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1516   --libexecdir=DIR        program executables [EPREFIX/libexec]
1517   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1518   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1519   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1520   --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
1521   --libdir=DIR            object code libraries [EPREFIX/lib]
1522   --includedir=DIR        C header files [PREFIX/include]
1523   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1524   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1525   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1526   --infodir=DIR           info documentation [DATAROOTDIR/info]
1527   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1528   --mandir=DIR            man documentation [DATAROOTDIR/man]
1529   --docdir=DIR            documentation root [DATAROOTDIR/doc/unbound]
1530   --htmldir=DIR           html documentation [DOCDIR]
1531   --dvidir=DIR            dvi documentation [DOCDIR]
1532   --pdfdir=DIR            pdf documentation [DOCDIR]
1533   --psdir=DIR             ps documentation [DOCDIR]
1534 _ACEOF
1535
1536   cat <<\_ACEOF
1537
1538 System types:
1539   --build=BUILD     configure for building on BUILD [guessed]
1540   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1541 _ACEOF
1542 fi
1543
1544 if test -n "$ac_init_help"; then
1545   case $ac_init_help in
1546      short | recursive ) echo "Configuration of unbound 1.18.0:";;
1547    esac
1548   cat <<\_ACEOF
1549
1550 Optional Features:
1551   --disable-option-checking  ignore unrecognized --enable/--with options
1552   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1553   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1554   --enable-checking       Enable warnings, asserts, makefile-dependencies
1555   --enable-debug          same as enable-checking
1556   --disable-flto          Disable link-time optimization (gcc specific option)
1557   --enable-pie            Enable Position-Independent Executable (eg. to fully
1558                           benefit from ASLR, small performance penalty)
1559   --enable-relro-now      Enable full relocation binding at load-time (RELRO
1560                           NOW, to protect GOT and .dtor areas)
1561   --enable-shared[=PKGS]  build shared libraries [default=yes]
1562   --enable-static[=PKGS]  build static libraries [default=yes]
1563   --enable-fast-install[=PKGS]
1564                           optimize for fast installation [default=yes]
1565   --disable-libtool-lock  avoid locking (might break parallel builds)
1566   --disable-rpath         disable hardcoded rpath (default=enabled)
1567   --disable-largefile     omit support for large files
1568   --enable-systemd        compile with systemd support
1569   --enable-alloc-checks   enable to memory allocation statistics, for debug
1570                           purposes
1571   --enable-alloc-lite     enable for lightweight alloc assertions, for debug
1572                           purposes
1573   --enable-alloc-nonregional
1574                           enable nonregional allocs, slow but exposes regional
1575                           allocations to other memory purifiers, for debug
1576                           purposes
1577   --disable-swig-version-check
1578                           Disable swig version check to build python modules
1579                           with older swig even though that is unreliable
1580   --disable-sha1          Disable SHA1 RRSIG support, does not disable nsec3
1581                           support
1582   --disable-sha2          Disable SHA256 and SHA512 RRSIG support
1583   --enable-subnet         Enable client subnet
1584   --disable-gost          Disable GOST support
1585   --disable-ecdsa         Disable ECDSA support
1586   --disable-dsa           Disable DSA support
1587   --disable-ed25519       Disable ED25519 support
1588   --disable-ed448         Disable ED448 support
1589   --enable-event-api      Enable (experimental) pluggable event base
1590                           libunbound API installed to unbound-event.h
1591   --enable-tfo-client     Enable TCP Fast Open for client mode
1592   --enable-tfo-server     Enable TCP Fast Open for server mode
1593   --enable-static-exe     enable to compile executables statically against
1594                           (event) uninstalled libs, for debug purposes
1595   --enable-fully-static   enable to compile fully static
1596   --enable-lock-checks    enable to check lock and unlock calls, for debug
1597                           purposes
1598   --enable-allsymbols     export all symbols from libunbound and link binaries
1599                           to it, smaller install size but libunbound export
1600                           table is polluted by internal symbols
1601   --enable-dnstap         Enable dnstap support (requires protobuf-c)
1602   --enable-dnscrypt       Enable dnscrypt support (requires libsodium)
1603   --enable-cachedb        enable cachedb module that can use external cache
1604                           storage
1605   --enable-ipsecmod       Enable ipsecmod module that facilitates
1606                           opportunistic IPsec
1607   --enable-ipset          enable ipset module
1608   --disable-explicit-port-randomisation
1609                           disable explicit source port randomisation and rely
1610                           on the kernel to provide random source ports
1611   --enable-linux-ip-local-port-range
1612                           Define this to enable use of
1613                           /proc/sys/net/ipv4/ip_local_port_range as a default
1614                           outgoing port range. This is only for the libunbound
1615                           on Linux and does not affect unbound resolving
1616                           daemon itself. This may severely limit the number of
1617                           available outgoing ports and thus decrease
1618                           randomness. Define this only when the target system
1619                           restricts (e.g. some of SELinux enabled
1620                           distributions) the use of non-ephemeral ports.
1621
1622 Optional Packages:
1623   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1624   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1625   --with-conf-file=path   Pathname to the Unbound configuration file
1626   --with-run-dir=path     set default directory to chdir to (by default dir
1627                           part of cfg file)
1628   --with-chroot-dir=path  set default directory to chroot to (by default same
1629                           as run-dir)
1630   --with-share-dir=path   set default directory with shared data (by default
1631                           same as share/unbound)
1632   --with-pidfile=filename set default pathname to unbound pidfile (default
1633                           run-dir/unbound.pid)
1634   --with-rootkey-file=filename
1635                           set default pathname to root key file (default
1636                           run-dir/root.key). This file is read and written.
1637   --with-rootcert-file=filename
1638                           set default pathname to root update certificate file
1639                           (default run-dir/icannbundle.pem). This file need
1640                           not exist if you are content with the builtin.
1641   --with-username=user    set default user that unbound changes to (default
1642                           user is unbound)
1643   --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
1644                           both]
1645   --with-aix-soname=aix|svr4|both
1646                           shared library versioning (aka "SONAME") variant to
1647                           provide on AIX, [default=aix].
1648   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1649   --with-sysroot[=DIR]    Search for dependent libraries within DIR (or the
1650                           compiler's sysroot if not specified).
1651   --with-pthreads         use pthreads library, or --without-pthreads to
1652                           disable threading support.
1653   --with-solaris-threads  use solaris native thread library.
1654   --with-syslog-facility=LOCAL0 - LOCAL7
1655                           set SYSLOG_FACILITY, default DAEMON
1656   --with-dynlibmodule     build dynamic library module, or
1657                           --without-dynlibmodule to disable it. (default=no)
1658   --with-pyunbound        build PyUnbound, or --without-pyunbound to skip it.
1659                           (default=no)
1660   --with-pythonmodule     build Python module, or --without-pythonmodule to
1661                           disable script engine. (default=no)
1662   --with-nss=path         use libnss instead of openssl, installed at path.
1663   --with-nettle=path      use libnettle as crypto library, installed at path.
1664   --with-ssl=pathname     enable SSL (will check /usr/local/ssl /usr/lib/ssl
1665                           /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw
1666                           /usr or specify like /usr/include/openssl11)
1667   --with-libbsd           Use portable libbsd functions
1668   --with-deprecate-rsa-1024
1669                           Deprecate RSA 1024 bit length, makes that an
1670                           unsupported key, for use when OpenSSL FIPS refuses
1671                           1024 bit verification
1672   --with-libevent=pathname
1673                           use libevent (will check /usr/local /opt/local
1674                           /usr/lib /usr/pkg /usr/sfw /usr or you can specify
1675                           an explicit path). Slower, but allows use of large
1676                           outgoing port ranges.
1677   --with-libexpat=path    specify explicit path for libexpat.
1678   --with-libhiredis=path  specify explicit path for libhiredis.
1679   --with-libnghttp2=path  specify explicit path for libnghttp2.
1680   --with-dnstap-socket-path=pathname
1681                           set default dnstap socket path
1682   --with-protobuf-c=path  Path where protobuf-c is installed, for dnstap
1683   --with-libsodium=path   Path where libsodium is installed, for dnscrypt
1684   --with-libmnl=path      specify explicit path for libmnl.
1685   --with-libunbound-only  do not build daemon and tool programs
1686
1687 Some influential environment variables:
1688   CC          C compiler command
1689   CFLAGS      C compiler flags
1690   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1691               nonstandard directory <lib dir>
1692   LIBS        libraries to pass to the linker, e.g. -l<library>
1693   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1694               you have headers in a nonstandard directory <include dir>
1695   CPP         C preprocessor
1696   YACC        The `Yet Another Compiler Compiler' implementation to use.
1697               Defaults to the first program found out of: `bison -y', `byacc',
1698               `yacc'.
1699   YFLAGS      The list of arguments that will be passed by default to $YACC.
1700               This script will default YFLAGS to the empty string to avoid a
1701               default value of `-d' given by some make applications.
1702   LT_SYS_LIBRARY_PATH
1703               User-defined run-time library search path.
1704   PKG_CONFIG  path to pkg-config utility
1705   PKG_CONFIG_PATH
1706               directories to add to pkg-config's search path
1707   PKG_CONFIG_LIBDIR
1708               path overriding pkg-config's built-in search path
1709   SYSTEMD_CFLAGS
1710               C compiler flags for SYSTEMD, overriding pkg-config
1711   SYSTEMD_LIBS
1712               linker flags for SYSTEMD, overriding pkg-config
1713   SYSTEMD_DAEMON_CFLAGS
1714               C compiler flags for SYSTEMD_DAEMON, overriding pkg-config
1715   SYSTEMD_DAEMON_LIBS
1716               linker flags for SYSTEMD_DAEMON, overriding pkg-config
1717   PYTHON_VERSION
1718               The installed Python version to use, for example '2.3'. This
1719               string will be appended to the Python interpreter canonical
1720               name.
1721
1722 Use these variables to override the choices made by `configure' or to help
1723 it to find libraries and programs with nonstandard names/locations.
1724
1725 Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>.
1726 _ACEOF
1727 ac_status=$?
1728 fi
1729
1730 if test "$ac_init_help" = "recursive"; then
1731   # If there are subdirs, report their specific --help.
1732   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1733     test -d "$ac_dir" ||
1734       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1735       continue
1736     ac_builddir=.
1737
1738 case "$ac_dir" in
1739 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1740 *)
1741   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1742   # A ".." for each directory in $ac_dir_suffix.
1743   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1744   case $ac_top_builddir_sub in
1745   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1746   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1747   esac ;;
1748 esac
1749 ac_abs_top_builddir=$ac_pwd
1750 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1751 # for backward compatibility:
1752 ac_top_builddir=$ac_top_build_prefix
1753
1754 case $srcdir in
1755   .)  # We are building in place.
1756     ac_srcdir=.
1757     ac_top_srcdir=$ac_top_builddir_sub
1758     ac_abs_top_srcdir=$ac_pwd ;;
1759   [\\/]* | ?:[\\/]* )  # Absolute name.
1760     ac_srcdir=$srcdir$ac_dir_suffix;
1761     ac_top_srcdir=$srcdir
1762     ac_abs_top_srcdir=$srcdir ;;
1763   *) # Relative name.
1764     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1765     ac_top_srcdir=$ac_top_build_prefix$srcdir
1766     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1767 esac
1768 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1769
1770     cd "$ac_dir" || { ac_status=$?; continue; }
1771     # Check for guested configure.
1772     if test -f "$ac_srcdir/configure.gnu"; then
1773       echo &&
1774       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1775     elif test -f "$ac_srcdir/configure"; then
1776       echo &&
1777       $SHELL "$ac_srcdir/configure" --help=recursive
1778     else
1779       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1780     fi || ac_status=$?
1781     cd "$ac_pwd" || { ac_status=$?; break; }
1782   done
1783 fi
1784
1785 test -n "$ac_init_help" && exit $ac_status
1786 if $ac_init_version; then
1787   cat <<\_ACEOF
1788 unbound configure 1.18.0
1789 generated by GNU Autoconf 2.69
1790
1791 Copyright (C) 2012 Free Software Foundation, Inc.
1792 This configure script is free software; the Free Software Foundation
1793 gives unlimited permission to copy, distribute and modify it.
1794 _ACEOF
1795   exit
1796 fi
1797
1798 ## ------------------------ ##
1799 ## Autoconf initialization. ##
1800 ## ------------------------ ##
1801
1802 # ac_fn_c_try_compile LINENO
1803 # --------------------------
1804 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1805 ac_fn_c_try_compile ()
1806 {
1807   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1808   rm -f conftest.$ac_objext
1809   if { { ac_try="$ac_compile"
1810 case "(($ac_try" in
1811   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1812   *) ac_try_echo=$ac_try;;
1813 esac
1814 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1815 $as_echo "$ac_try_echo"; } >&5
1816   (eval "$ac_compile") 2>conftest.err
1817   ac_status=$?
1818   if test -s conftest.err; then
1819     grep -v '^ *+' conftest.err >conftest.er1
1820     cat conftest.er1 >&5
1821     mv -f conftest.er1 conftest.err
1822   fi
1823   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1824   test $ac_status = 0; } && {
1825          test -z "$ac_c_werror_flag" ||
1826          test ! -s conftest.err
1827        } && test -s conftest.$ac_objext; then :
1828   ac_retval=0
1829 else
1830   $as_echo "$as_me: failed program was:" >&5
1831 sed 's/^/| /' conftest.$ac_ext >&5
1832
1833         ac_retval=1
1834 fi
1835   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1836   as_fn_set_status $ac_retval
1837
1838 } # ac_fn_c_try_compile
1839
1840 # ac_fn_c_try_cpp LINENO
1841 # ----------------------
1842 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1843 ac_fn_c_try_cpp ()
1844 {
1845   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1846   if { { ac_try="$ac_cpp conftest.$ac_ext"
1847 case "(($ac_try" in
1848   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1849   *) ac_try_echo=$ac_try;;
1850 esac
1851 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1852 $as_echo "$ac_try_echo"; } >&5
1853   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1854   ac_status=$?
1855   if test -s conftest.err; then
1856     grep -v '^ *+' conftest.err >conftest.er1
1857     cat conftest.er1 >&5
1858     mv -f conftest.er1 conftest.err
1859   fi
1860   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1861   test $ac_status = 0; } > conftest.i && {
1862          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1863          test ! -s conftest.err
1864        }; then :
1865   ac_retval=0
1866 else
1867   $as_echo "$as_me: failed program was:" >&5
1868 sed 's/^/| /' conftest.$ac_ext >&5
1869
1870     ac_retval=1
1871 fi
1872   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1873   as_fn_set_status $ac_retval
1874
1875 } # ac_fn_c_try_cpp
1876
1877 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1878 # -------------------------------------------------------
1879 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1880 # the include files in INCLUDES and setting the cache variable VAR
1881 # accordingly.
1882 ac_fn_c_check_header_mongrel ()
1883 {
1884   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1885   if eval \${$3+:} false; then :
1886   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1887 $as_echo_n "checking for $2... " >&6; }
1888 if eval \${$3+:} false; then :
1889   $as_echo_n "(cached) " >&6
1890 fi
1891 eval ac_res=\$$3
1892                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1893 $as_echo "$ac_res" >&6; }
1894 else
1895   # Is the header compilable?
1896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1897 $as_echo_n "checking $2 usability... " >&6; }
1898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1899 /* end confdefs.h.  */
1900 $4
1901 #include <$2>
1902 _ACEOF
1903 if ac_fn_c_try_compile "$LINENO"; then :
1904   ac_header_compiler=yes
1905 else
1906   ac_header_compiler=no
1907 fi
1908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1910 $as_echo "$ac_header_compiler" >&6; }
1911
1912 # Is the header present?
1913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1914 $as_echo_n "checking $2 presence... " >&6; }
1915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1916 /* end confdefs.h.  */
1917 #include <$2>
1918 _ACEOF
1919 if ac_fn_c_try_cpp "$LINENO"; then :
1920   ac_header_preproc=yes
1921 else
1922   ac_header_preproc=no
1923 fi
1924 rm -f conftest.err conftest.i conftest.$ac_ext
1925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1926 $as_echo "$ac_header_preproc" >&6; }
1927
1928 # So?  What about this header?
1929 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1930   yes:no: )
1931     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1932 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1933     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1934 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1935     ;;
1936   no:yes:* )
1937     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1938 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1939     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1940 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1941     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1942 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1943     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1944 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1945     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1946 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1947 ( $as_echo "## --------------------------------------------------------------------------------------- ##
1948 ## Report this to unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues ##
1949 ## --------------------------------------------------------------------------------------- ##"
1950      ) | sed "s/^/$as_me: WARNING:     /" >&2
1951     ;;
1952 esac
1953   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1954 $as_echo_n "checking for $2... " >&6; }
1955 if eval \${$3+:} false; then :
1956   $as_echo_n "(cached) " >&6
1957 else
1958   eval "$3=\$ac_header_compiler"
1959 fi
1960 eval ac_res=\$$3
1961                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1962 $as_echo "$ac_res" >&6; }
1963 fi
1964   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1965
1966 } # ac_fn_c_check_header_mongrel
1967
1968 # ac_fn_c_try_run LINENO
1969 # ----------------------
1970 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1971 # that executables *can* be run.
1972 ac_fn_c_try_run ()
1973 {
1974   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1975   if { { ac_try="$ac_link"
1976 case "(($ac_try" in
1977   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1978   *) ac_try_echo=$ac_try;;
1979 esac
1980 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1981 $as_echo "$ac_try_echo"; } >&5
1982   (eval "$ac_link") 2>&5
1983   ac_status=$?
1984   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1985   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1986   { { case "(($ac_try" in
1987   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1988   *) ac_try_echo=$ac_try;;
1989 esac
1990 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1991 $as_echo "$ac_try_echo"; } >&5
1992   (eval "$ac_try") 2>&5
1993   ac_status=$?
1994   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1995   test $ac_status = 0; }; }; then :
1996   ac_retval=0
1997 else
1998   $as_echo "$as_me: program exited with status $ac_status" >&5
1999        $as_echo "$as_me: failed program was:" >&5
2000 sed 's/^/| /' conftest.$ac_ext >&5
2001
2002        ac_retval=$ac_status
2003 fi
2004   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2005   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2006   as_fn_set_status $ac_retval
2007
2008 } # ac_fn_c_try_run
2009
2010 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2011 # -------------------------------------------------------
2012 # Tests whether HEADER exists and can be compiled using the include files in
2013 # INCLUDES, setting the cache variable VAR accordingly.
2014 ac_fn_c_check_header_compile ()
2015 {
2016   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2017   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2018 $as_echo_n "checking for $2... " >&6; }
2019 if eval \${$3+:} false; then :
2020   $as_echo_n "(cached) " >&6
2021 else
2022   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2023 /* end confdefs.h.  */
2024 $4
2025 #include <$2>
2026 _ACEOF
2027 if ac_fn_c_try_compile "$LINENO"; then :
2028   eval "$3=yes"
2029 else
2030   eval "$3=no"
2031 fi
2032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2033 fi
2034 eval ac_res=\$$3
2035                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2036 $as_echo "$ac_res" >&6; }
2037   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2038
2039 } # ac_fn_c_check_header_compile
2040
2041 # ac_fn_c_try_link LINENO
2042 # -----------------------
2043 # Try to link conftest.$ac_ext, and return whether this succeeded.
2044 ac_fn_c_try_link ()
2045 {
2046   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2047   rm -f conftest.$ac_objext conftest$ac_exeext
2048   if { { ac_try="$ac_link"
2049 case "(($ac_try" in
2050   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2051   *) ac_try_echo=$ac_try;;
2052 esac
2053 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2054 $as_echo "$ac_try_echo"; } >&5
2055   (eval "$ac_link") 2>conftest.err
2056   ac_status=$?
2057   if test -s conftest.err; then
2058     grep -v '^ *+' conftest.err >conftest.er1
2059     cat conftest.er1 >&5
2060     mv -f conftest.er1 conftest.err
2061   fi
2062   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2063   test $ac_status = 0; } && {
2064          test -z "$ac_c_werror_flag" ||
2065          test ! -s conftest.err
2066        } && test -s conftest$ac_exeext && {
2067          test "$cross_compiling" = yes ||
2068          test -x conftest$ac_exeext
2069        }; then :
2070   ac_retval=0
2071 else
2072   $as_echo "$as_me: failed program was:" >&5
2073 sed 's/^/| /' conftest.$ac_ext >&5
2074
2075         ac_retval=1
2076 fi
2077   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2078   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2079   # interfere with the next link command; also delete a directory that is
2080   # left behind by Apple's compiler.  We do this before executing the actions.
2081   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2082   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2083   as_fn_set_status $ac_retval
2084
2085 } # ac_fn_c_try_link
2086
2087 # ac_fn_c_check_func LINENO FUNC VAR
2088 # ----------------------------------
2089 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2090 ac_fn_c_check_func ()
2091 {
2092   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2093   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2094 $as_echo_n "checking for $2... " >&6; }
2095 if eval \${$3+:} false; then :
2096   $as_echo_n "(cached) " >&6
2097 else
2098   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2099 /* end confdefs.h.  */
2100 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2101    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2102 #define $2 innocuous_$2
2103
2104 /* System header to define __stub macros and hopefully few prototypes,
2105     which can conflict with char $2 (); below.
2106     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2107     <limits.h> exists even on freestanding compilers.  */
2108
2109 #ifdef __STDC__
2110 # include <limits.h>
2111 #else
2112 # include <assert.h>
2113 #endif
2114
2115 #undef $2
2116
2117 /* Override any GCC internal prototype to avoid an error.
2118    Use char because int might match the return type of a GCC
2119    builtin and then its argument prototype would still apply.  */
2120 #ifdef __cplusplus
2121 extern "C"
2122 #endif
2123 char $2 ();
2124 /* The GNU C library defines this for functions which it implements
2125     to always fail with ENOSYS.  Some functions are actually named
2126     something starting with __ and the normal name is an alias.  */
2127 #if defined __stub_$2 || defined __stub___$2
2128 choke me
2129 #endif
2130
2131 int
2132 main ()
2133 {
2134 return $2 ();
2135   ;
2136   return 0;
2137 }
2138 _ACEOF
2139 if ac_fn_c_try_link "$LINENO"; then :
2140   eval "$3=yes"
2141 else
2142   eval "$3=no"
2143 fi
2144 rm -f core conftest.err conftest.$ac_objext \
2145     conftest$ac_exeext conftest.$ac_ext
2146 fi
2147 eval ac_res=\$$3
2148                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2149 $as_echo "$ac_res" >&6; }
2150   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2151
2152 } # ac_fn_c_check_func
2153
2154 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2155 # -------------------------------------------
2156 # Tests whether TYPE exists after having included INCLUDES, setting cache
2157 # variable VAR accordingly.
2158 ac_fn_c_check_type ()
2159 {
2160   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2161   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2162 $as_echo_n "checking for $2... " >&6; }
2163 if eval \${$3+:} false; then :
2164   $as_echo_n "(cached) " >&6
2165 else
2166   eval "$3=no"
2167   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2168 /* end confdefs.h.  */
2169 $4
2170 int
2171 main ()
2172 {
2173 if (sizeof ($2))
2174          return 0;
2175   ;
2176   return 0;
2177 }
2178 _ACEOF
2179 if ac_fn_c_try_compile "$LINENO"; then :
2180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2181 /* end confdefs.h.  */
2182 $4
2183 int
2184 main ()
2185 {
2186 if (sizeof (($2)))
2187             return 0;
2188   ;
2189   return 0;
2190 }
2191 _ACEOF
2192 if ac_fn_c_try_compile "$LINENO"; then :
2193
2194 else
2195   eval "$3=yes"
2196 fi
2197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2198 fi
2199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2200 fi
2201 eval ac_res=\$$3
2202                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2203 $as_echo "$ac_res" >&6; }
2204   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2205
2206 } # ac_fn_c_check_type
2207
2208 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2209 # --------------------------------------------
2210 # Tries to find the compile-time value of EXPR in a program that includes
2211 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2212 # computed
2213 ac_fn_c_compute_int ()
2214 {
2215   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2216   if test "$cross_compiling" = yes; then
2217     # Depending upon the size, compute the lo and hi bounds.
2218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2219 /* end confdefs.h.  */
2220 $4
2221 int
2222 main ()
2223 {
2224 static int test_array [1 - 2 * !(($2) >= 0)];
2225 test_array [0] = 0;
2226 return test_array [0];
2227
2228   ;
2229   return 0;
2230 }
2231 _ACEOF
2232 if ac_fn_c_try_compile "$LINENO"; then :
2233   ac_lo=0 ac_mid=0
2234   while :; do
2235     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2236 /* end confdefs.h.  */
2237 $4
2238 int
2239 main ()
2240 {
2241 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2242 test_array [0] = 0;
2243 return test_array [0];
2244
2245   ;
2246   return 0;
2247 }
2248 _ACEOF
2249 if ac_fn_c_try_compile "$LINENO"; then :
2250   ac_hi=$ac_mid; break
2251 else
2252   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2253                         if test $ac_lo -le $ac_mid; then
2254                           ac_lo= ac_hi=
2255                           break
2256                         fi
2257                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2258 fi
2259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2260   done
2261 else
2262   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2263 /* end confdefs.h.  */
2264 $4
2265 int
2266 main ()
2267 {
2268 static int test_array [1 - 2 * !(($2) < 0)];
2269 test_array [0] = 0;
2270 return test_array [0];
2271
2272   ;
2273   return 0;
2274 }
2275 _ACEOF
2276 if ac_fn_c_try_compile "$LINENO"; then :
2277   ac_hi=-1 ac_mid=-1
2278   while :; do
2279     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2280 /* end confdefs.h.  */
2281 $4
2282 int
2283 main ()
2284 {
2285 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2286 test_array [0] = 0;
2287 return test_array [0];
2288
2289   ;
2290   return 0;
2291 }
2292 _ACEOF
2293 if ac_fn_c_try_compile "$LINENO"; then :
2294   ac_lo=$ac_mid; break
2295 else
2296   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2297                         if test $ac_mid -le $ac_hi; then
2298                           ac_lo= ac_hi=
2299                           break
2300                         fi
2301                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2302 fi
2303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2304   done
2305 else
2306   ac_lo= ac_hi=
2307 fi
2308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2309 fi
2310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2311 # Binary search between lo and hi bounds.
2312 while test "x$ac_lo" != "x$ac_hi"; do
2313   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2314   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2315 /* end confdefs.h.  */
2316 $4
2317 int
2318 main ()
2319 {
2320 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2321 test_array [0] = 0;
2322 return test_array [0];
2323
2324   ;
2325   return 0;
2326 }
2327 _ACEOF
2328 if ac_fn_c_try_compile "$LINENO"; then :
2329   ac_hi=$ac_mid
2330 else
2331   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2332 fi
2333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2334 done
2335 case $ac_lo in #((
2336 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2337 '') ac_retval=1 ;;
2338 esac
2339   else
2340     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2341 /* end confdefs.h.  */
2342 $4
2343 static long int longval () { return $2; }
2344 static unsigned long int ulongval () { return $2; }
2345 #include <stdio.h>
2346 #include <stdlib.h>
2347 int
2348 main ()
2349 {
2350
2351   FILE *f = fopen ("conftest.val", "w");
2352   if (! f)
2353     return 1;
2354   if (($2) < 0)
2355     {
2356       long int i = longval ();
2357       if (i != ($2))
2358         return 1;
2359       fprintf (f, "%ld", i);
2360     }
2361   else
2362     {
2363       unsigned long int i = ulongval ();
2364       if (i != ($2))
2365         return 1;
2366       fprintf (f, "%lu", i);
2367     }
2368   /* Do not output a trailing newline, as this causes \r\n confusion
2369      on some platforms.  */
2370   return ferror (f) || fclose (f) != 0;
2371
2372   ;
2373   return 0;
2374 }
2375 _ACEOF
2376 if ac_fn_c_try_run "$LINENO"; then :
2377   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2378 else
2379   ac_retval=1
2380 fi
2381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2382   conftest.$ac_objext conftest.beam conftest.$ac_ext
2383 rm -f conftest.val
2384
2385   fi
2386   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2387   as_fn_set_status $ac_retval
2388
2389 } # ac_fn_c_compute_int
2390
2391 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2392 # ---------------------------------------------
2393 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2394 # accordingly.
2395 ac_fn_c_check_decl ()
2396 {
2397   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2398   as_decl_name=`echo $2|sed 's/ *(.*//'`
2399   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2400   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2401 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2402 if eval \${$3+:} false; then :
2403   $as_echo_n "(cached) " >&6
2404 else
2405   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2406 /* end confdefs.h.  */
2407 $4
2408 int
2409 main ()
2410 {
2411 #ifndef $as_decl_name
2412 #ifdef __cplusplus
2413   (void) $as_decl_use;
2414 #else
2415   (void) $as_decl_name;
2416 #endif
2417 #endif
2418
2419   ;
2420   return 0;
2421 }
2422 _ACEOF
2423 if ac_fn_c_try_compile "$LINENO"; then :
2424   eval "$3=yes"
2425 else
2426   eval "$3=no"
2427 fi
2428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2429 fi
2430 eval ac_res=\$$3
2431                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2432 $as_echo "$ac_res" >&6; }
2433   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2434
2435 } # ac_fn_c_check_decl
2436
2437 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2438 # ----------------------------------------------------
2439 # Tries to find if the field MEMBER exists in type AGGR, after including
2440 # INCLUDES, setting cache variable VAR accordingly.
2441 ac_fn_c_check_member ()
2442 {
2443   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2444   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2445 $as_echo_n "checking for $2.$3... " >&6; }
2446 if eval \${$4+:} false; then :
2447   $as_echo_n "(cached) " >&6
2448 else
2449   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2450 /* end confdefs.h.  */
2451 $5
2452 int
2453 main ()
2454 {
2455 static $2 ac_aggr;
2456 if (ac_aggr.$3)
2457 return 0;
2458   ;
2459   return 0;
2460 }
2461 _ACEOF
2462 if ac_fn_c_try_compile "$LINENO"; then :
2463   eval "$4=yes"
2464 else
2465   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2466 /* end confdefs.h.  */
2467 $5
2468 int
2469 main ()
2470 {
2471 static $2 ac_aggr;
2472 if (sizeof ac_aggr.$3)
2473 return 0;
2474   ;
2475   return 0;
2476 }
2477 _ACEOF
2478 if ac_fn_c_try_compile "$LINENO"; then :
2479   eval "$4=yes"
2480 else
2481   eval "$4=no"
2482 fi
2483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2484 fi
2485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2486 fi
2487 eval ac_res=\$$4
2488                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2489 $as_echo "$ac_res" >&6; }
2490   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2491
2492 } # ac_fn_c_check_member
2493 cat >config.log <<_ACEOF
2494 This file contains any messages produced by compilers while
2495 running configure, to aid debugging if configure makes a mistake.
2496
2497 It was created by unbound $as_me 1.18.0, which was
2498 generated by GNU Autoconf 2.69.  Invocation command line was
2499
2500   $ $0 $@
2501
2502 _ACEOF
2503 exec 5>>config.log
2504 {
2505 cat <<_ASUNAME
2506 ## --------- ##
2507 ## Platform. ##
2508 ## --------- ##
2509
2510 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2511 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2512 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2513 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2514 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2515
2516 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2517 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2518
2519 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2520 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2521 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2522 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2523 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2524 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2525 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2526
2527 _ASUNAME
2528
2529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2530 for as_dir in $PATH
2531 do
2532   IFS=$as_save_IFS
2533   test -z "$as_dir" && as_dir=.
2534     $as_echo "PATH: $as_dir"
2535   done
2536 IFS=$as_save_IFS
2537
2538 } >&5
2539
2540 cat >&5 <<_ACEOF
2541
2542
2543 ## ----------- ##
2544 ## Core tests. ##
2545 ## ----------- ##
2546
2547 _ACEOF
2548
2549
2550 # Keep a trace of the command line.
2551 # Strip out --no-create and --no-recursion so they do not pile up.
2552 # Strip out --silent because we don't want to record it for future runs.
2553 # Also quote any args containing shell meta-characters.
2554 # Make two passes to allow for proper duplicate-argument suppression.
2555 ac_configure_args=
2556 ac_configure_args0=
2557 ac_configure_args1=
2558 ac_must_keep_next=false
2559 for ac_pass in 1 2
2560 do
2561   for ac_arg
2562   do
2563     case $ac_arg in
2564     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2565     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2566     | -silent | --silent | --silen | --sile | --sil)
2567       continue ;;
2568     *\'*)
2569       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2570     esac
2571     case $ac_pass in
2572     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2573     2)
2574       as_fn_append ac_configure_args1 " '$ac_arg'"
2575       if test $ac_must_keep_next = true; then
2576         ac_must_keep_next=false # Got value, back to normal.
2577       else
2578         case $ac_arg in
2579           *=* | --config-cache | -C | -disable-* | --disable-* \
2580           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2581           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2582           | -with-* | --with-* | -without-* | --without-* | --x)
2583             case "$ac_configure_args0 " in
2584               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2585             esac
2586             ;;
2587           -* ) ac_must_keep_next=true ;;
2588         esac
2589       fi
2590       as_fn_append ac_configure_args " '$ac_arg'"
2591       ;;
2592     esac
2593   done
2594 done
2595 { ac_configure_args0=; unset ac_configure_args0;}
2596 { ac_configure_args1=; unset ac_configure_args1;}
2597
2598 # When interrupted or exit'd, cleanup temporary files, and complete
2599 # config.log.  We remove comments because anyway the quotes in there
2600 # would cause problems or look ugly.
2601 # WARNING: Use '\'' to represent an apostrophe within the trap.
2602 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2603 trap 'exit_status=$?
2604   # Save into config.log some information that might help in debugging.
2605   {
2606     echo
2607
2608     $as_echo "## ---------------- ##
2609 ## Cache variables. ##
2610 ## ---------------- ##"
2611     echo
2612     # The following way of writing the cache mishandles newlines in values,
2613 (
2614   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2615     eval ac_val=\$$ac_var
2616     case $ac_val in #(
2617     *${as_nl}*)
2618       case $ac_var in #(
2619       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2620 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2621       esac
2622       case $ac_var in #(
2623       _ | IFS | as_nl) ;; #(
2624       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2625       *) { eval $ac_var=; unset $ac_var;} ;;
2626       esac ;;
2627     esac
2628   done
2629   (set) 2>&1 |
2630     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2631     *${as_nl}ac_space=\ *)
2632       sed -n \
2633         "s/'\''/'\''\\\\'\'''\''/g;
2634           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2635       ;; #(
2636     *)
2637       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2638       ;;
2639     esac |
2640     sort
2641 )
2642     echo
2643
2644     $as_echo "## ----------------- ##
2645 ## Output variables. ##
2646 ## ----------------- ##"
2647     echo
2648     for ac_var in $ac_subst_vars
2649     do
2650       eval ac_val=\$$ac_var
2651       case $ac_val in
2652       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2653       esac
2654       $as_echo "$ac_var='\''$ac_val'\''"
2655     done | sort
2656     echo
2657
2658     if test -n "$ac_subst_files"; then
2659       $as_echo "## ------------------- ##
2660 ## File substitutions. ##
2661 ## ------------------- ##"
2662       echo
2663       for ac_var in $ac_subst_files
2664       do
2665         eval ac_val=\$$ac_var
2666         case $ac_val in
2667         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2668         esac
2669         $as_echo "$ac_var='\''$ac_val'\''"
2670       done | sort
2671       echo
2672     fi
2673
2674     if test -s confdefs.h; then
2675       $as_echo "## ----------- ##
2676 ## confdefs.h. ##
2677 ## ----------- ##"
2678       echo
2679       cat confdefs.h
2680       echo
2681     fi
2682     test "$ac_signal" != 0 &&
2683       $as_echo "$as_me: caught signal $ac_signal"
2684     $as_echo "$as_me: exit $exit_status"
2685   } >&5
2686   rm -f core *.core core.conftest.* &&
2687     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2688     exit $exit_status
2689 ' 0
2690 for ac_signal in 1 2 13 15; do
2691   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2692 done
2693 ac_signal=0
2694
2695 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2696 rm -f -r conftest* confdefs.h
2697
2698 $as_echo "/* confdefs.h */" > confdefs.h
2699
2700 # Predefined preprocessor variables.
2701
2702 cat >>confdefs.h <<_ACEOF
2703 #define PACKAGE_NAME "$PACKAGE_NAME"
2704 _ACEOF
2705
2706 cat >>confdefs.h <<_ACEOF
2707 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2708 _ACEOF
2709
2710 cat >>confdefs.h <<_ACEOF
2711 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2712 _ACEOF
2713
2714 cat >>confdefs.h <<_ACEOF
2715 #define PACKAGE_STRING "$PACKAGE_STRING"
2716 _ACEOF
2717
2718 cat >>confdefs.h <<_ACEOF
2719 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2720 _ACEOF
2721
2722 cat >>confdefs.h <<_ACEOF
2723 #define PACKAGE_URL "$PACKAGE_URL"
2724 _ACEOF
2725
2726
2727 # Let the site file select an alternate cache file if it wants to.
2728 # Prefer an explicitly selected file to automatically selected ones.
2729 ac_site_file1=NONE
2730 ac_site_file2=NONE
2731 if test -n "$CONFIG_SITE"; then
2732   # We do not want a PATH search for config.site.
2733   case $CONFIG_SITE in #((
2734     -*)  ac_site_file1=./$CONFIG_SITE;;
2735     */*) ac_site_file1=$CONFIG_SITE;;
2736     *)   ac_site_file1=./$CONFIG_SITE;;
2737   esac
2738 elif test "x$prefix" != xNONE; then
2739   ac_site_file1=$prefix/share/config.site
2740   ac_site_file2=$prefix/etc/config.site
2741 else
2742   ac_site_file1=$ac_default_prefix/share/config.site
2743   ac_site_file2=$ac_default_prefix/etc/config.site
2744 fi
2745 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2746 do
2747   test "x$ac_site_file" = xNONE && continue
2748   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2749     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2750 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2751     sed 's/^/| /' "$ac_site_file" >&5
2752     . "$ac_site_file" \
2753       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2754 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2755 as_fn_error $? "failed to load site script $ac_site_file
2756 See \`config.log' for more details" "$LINENO" 5; }
2757   fi
2758 done
2759
2760 if test -r "$cache_file"; then
2761   # Some versions of bash will fail to source /dev/null (special files
2762   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2763   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2764     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2765 $as_echo "$as_me: loading cache $cache_file" >&6;}
2766     case $cache_file in
2767       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2768       *)                      . "./$cache_file";;
2769     esac
2770   fi
2771 else
2772   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2773 $as_echo "$as_me: creating cache $cache_file" >&6;}
2774   >$cache_file
2775 fi
2776
2777 # Check that the precious variables saved in the cache have kept the same
2778 # value.
2779 ac_cache_corrupted=false
2780 for ac_var in $ac_precious_vars; do
2781   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2782   eval ac_new_set=\$ac_env_${ac_var}_set
2783   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2784   eval ac_new_val=\$ac_env_${ac_var}_value
2785   case $ac_old_set,$ac_new_set in
2786     set,)
2787       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2788 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2789       ac_cache_corrupted=: ;;
2790     ,set)
2791       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2792 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2793       ac_cache_corrupted=: ;;
2794     ,);;
2795     *)
2796       if test "x$ac_old_val" != "x$ac_new_val"; then
2797         # differences in whitespace do not lead to failure.
2798         ac_old_val_w=`echo x $ac_old_val`
2799         ac_new_val_w=`echo x $ac_new_val`
2800         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2801           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2802 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2803           ac_cache_corrupted=:
2804         else
2805           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2806 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2807           eval $ac_var=\$ac_old_val
2808         fi
2809         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2810 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2811         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2812 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2813       fi;;
2814   esac
2815   # Pass precious variables to config.status.
2816   if test "$ac_new_set" = set; then
2817     case $ac_new_val in
2818     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2819     *) ac_arg=$ac_var=$ac_new_val ;;
2820     esac
2821     case " $ac_configure_args " in
2822       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2823       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2824     esac
2825   fi
2826 done
2827 if $ac_cache_corrupted; then
2828   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2829 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2830   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2831 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2832   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2833 fi
2834 ## -------------------- ##
2835 ## Main body of script. ##
2836 ## -------------------- ##
2837
2838 ac_ext=c
2839 ac_cpp='$CPP $CPPFLAGS'
2840 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2841 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2842 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2843
2844
2845 UNBOUND_VERSION_MAJOR=1
2846
2847 UNBOUND_VERSION_MINOR=18
2848
2849 UNBOUND_VERSION_MICRO=0
2850
2851
2852 LIBUNBOUND_CURRENT=9
2853 LIBUNBOUND_REVISION=22
2854 LIBUNBOUND_AGE=1
2855 # 1.0.0 had 0:12:0
2856 # 1.0.1 had 0:13:0
2857 # 1.0.2 had 0:14:0
2858 # 1.1.0 had 0:15:0
2859 # 1.1.1 had 0:16:0
2860 # 1.2.0 had 0:17:0
2861 # 1.2.1 had 0:18:0
2862 # 1.3.0 had 1:0:0   # ub_cancel and -export-symbols.
2863 # 1.3.1 had 1:1:0
2864 # 1.3.2 had 1:2:0
2865 # 1.3.3 had 1:3:0
2866 # 1.3.4 had 1:4:0
2867 # 1.4.0-snapshots had 1:5:0
2868 # 1.4.0 had 1:5:0 (not 2:0:0)   # ub_result.why_bogus
2869 # 1.4.1 had 2:1:0
2870 # 1.4.2 had 2:2:0
2871 # 1.4.3 had 2:3:0
2872 # 1.4.4 had 2:4:0
2873 # 1.4.5 had 2:5:0
2874 # 1.4.6 had 2:6:0
2875 # 1.4.7 had 2:7:0
2876 # 1.4.8 had 2:8:0
2877 # 1.4.9 had 2:9:0
2878 # 1.4.10 had 2:10:0
2879 # 1.4.11 had 2:11:0
2880 # 1.4.12 had 2:12:0
2881 # 1.4.13 had 2:13:0
2882 # and 1.4.13p1 and 1.4.13.p2
2883 # 1.4.14 had 2:14:0
2884 # 1.4.15 had 3:0:1 # adds ub_version()
2885 # 1.4.16 had 3:1:1
2886 # 1.4.17 had 3:2:1
2887 # 1.4.18 had 3:3:1
2888 # 1.4.19 had 3:4:1
2889 # 1.4.20 had 4:0:2 # adds libunbound.ttl # but shipped 3:5:1
2890 # 1.4.21 had 4:1:2
2891 # 1.4.22 had 4:1:2
2892 # 1.5.0 had 5:3:3 # adds ub_ctx_add_ta_autr
2893 # 1.5.1 had 5:3:3
2894 # 1.5.2 had 5:5:3
2895 # 1.5.3 had 5:6:3
2896 # 1.5.4 had 5:7:3
2897 # 1.5.5 had 5:8:3
2898 # 1.5.6 had 5:9:3
2899 # 1.5.7 had 5:10:3
2900 # 1.5.8 had 6:0:4 # adds ub_ctx_set_stub
2901 # 1.5.9 had 6:1:4
2902 # 1.5.10 had 6:2:4
2903 # 1.6.0 had 6:3:4
2904 # 1.6.1 had 7:0:5 # ub_callback_t typedef renamed to ub_callback_type
2905 # 1.6.2 had 7:1:5
2906 # 1.6.3 had 7:2:5
2907 # 1.6.4 had 7:3:5
2908 # 1.6.5 had 7:4:5
2909 # 1.6.6 had 7:5:5
2910 # 1.6.7 had 7:6:5
2911 # 1.6.8 had 7:7:5
2912 # 1.7.0 had 7:8:5
2913 # 1.7.1 had 7:9:5
2914 # 1.7.2 had 7:10:5
2915 # 1.7.3 had 7:11:5
2916 # 1.8.0 had 8:0:0 # changes the event callback function signature
2917 # 1.8.1 had 8:1:0
2918 # 1.8.2 had 8:2:0
2919 # 1.8.3 had 8:3:0
2920 # 1.9.0 had 9:0:1 # add ub_ctx_set_tls
2921 # 1.9.1 had 9:1:1
2922 # 1.9.2 had 9:2:1
2923 # 1.9.3 had 9:3:1
2924 # 1.9.4 had 9:4:1
2925 # 1.9.5 had 9:5:1
2926 # 1.9.6 had 9:6:1
2927 # 1.10.0 had 9:7:1
2928 # 1.10.1 had 9:8:1
2929 # 1.11.0 had 9:9:1
2930 # 1.12.0 had 9:10:1
2931 # 1.13.0 had 9:11:1
2932 # 1.13.1 had 9:12:1
2933 # 1.13.2 had 9:13:1
2934 # 1.14.0 had 9:14:1
2935 # 1.15.0 had 9:15:1
2936 # 1.16.0 had 9:16:1
2937 # 1.16.1 had 9:17:1
2938 # 1.16.2 had 9:18:1
2939 # 1.16.3 had 9:19:1
2940 # 1.17.0 had 9:20:1
2941 # 1.17.1 had 9:21:1
2942 # 1.18.0 had 9:22:1
2943
2944 #   Current  -- the number of the binary API that we're implementing
2945 #   Revision -- which iteration of the implementation of the binary
2946 #               API are we supplying?
2947 #   Age      -- How many previous binary API versions do we also
2948 #               support?
2949 #
2950 # If we release a new version that does not change the binary API,
2951 # increment Revision.
2952 #
2953 # If we release a new version that changes the binary API, but does
2954 # not break programs compiled against the old binary API, increment
2955 # Current and Age.  Set Revision to 0, since this is the first
2956 # implementation of the new API.
2957 #
2958 # Otherwise, we're changing the binary API and breaking backward
2959 # compatibility with old binaries.  Increment Current.  Set Age to 0,
2960 # since we're backward compatible with no previous APIs.  Set Revision
2961 # to 0 too.
2962
2963
2964
2965
2966
2967 cmdln="`echo $@ | sed -e 's/\\\\/\\\\\\\\/g' | sed -e 's/"/\\\\"/'g`"
2968
2969 cat >>confdefs.h <<_ACEOF
2970 #define CONFCMDLINE "$cmdln"
2971 _ACEOF
2972
2973
2974 CFLAGS="$CFLAGS"
2975 ac_ext=c
2976 ac_cpp='$CPP $CPPFLAGS'
2977 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2978 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2979 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2980 if test -n "$ac_tool_prefix"; then
2981   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2982 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2984 $as_echo_n "checking for $ac_word... " >&6; }
2985 if ${ac_cv_prog_CC+:} false; then :
2986   $as_echo_n "(cached) " >&6
2987 else
2988   if test -n "$CC"; then
2989   ac_cv_prog_CC="$CC" # Let the user override the test.
2990 else
2991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2992 for as_dir in $PATH
2993 do
2994   IFS=$as_save_IFS
2995   test -z "$as_dir" && as_dir=.
2996     for ac_exec_ext in '' $ac_executable_extensions; do
2997   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2998     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2999     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3000     break 2
3001   fi
3002 done
3003   done
3004 IFS=$as_save_IFS
3005
3006 fi
3007 fi
3008 CC=$ac_cv_prog_CC
3009 if test -n "$CC"; then
3010   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3011 $as_echo "$CC" >&6; }
3012 else
3013   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3014 $as_echo "no" >&6; }
3015 fi
3016
3017
3018 fi
3019 if test -z "$ac_cv_prog_CC"; then
3020   ac_ct_CC=$CC
3021   # Extract the first word of "gcc", so it can be a program name with args.
3022 set dummy gcc; ac_word=$2
3023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3024 $as_echo_n "checking for $ac_word... " >&6; }
3025 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3026   $as_echo_n "(cached) " >&6
3027 else
3028   if test -n "$ac_ct_CC"; then
3029   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3030 else
3031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3032 for as_dir in $PATH
3033 do
3034   IFS=$as_save_IFS
3035   test -z "$as_dir" && as_dir=.
3036     for ac_exec_ext in '' $ac_executable_extensions; do
3037   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3038     ac_cv_prog_ac_ct_CC="gcc"
3039     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3040     break 2
3041   fi
3042 done
3043   done
3044 IFS=$as_save_IFS
3045
3046 fi
3047 fi
3048 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3049 if test -n "$ac_ct_CC"; then
3050   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3051 $as_echo "$ac_ct_CC" >&6; }
3052 else
3053   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3054 $as_echo "no" >&6; }
3055 fi
3056
3057   if test "x$ac_ct_CC" = x; then
3058     CC=""
3059   else
3060     case $cross_compiling:$ac_tool_warned in
3061 yes:)
3062 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3063 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3064 ac_tool_warned=yes ;;
3065 esac
3066     CC=$ac_ct_CC
3067   fi
3068 else
3069   CC="$ac_cv_prog_CC"
3070 fi
3071
3072 if test -z "$CC"; then
3073           if test -n "$ac_tool_prefix"; then
3074     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3075 set dummy ${ac_tool_prefix}cc; ac_word=$2
3076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3077 $as_echo_n "checking for $ac_word... " >&6; }
3078 if ${ac_cv_prog_CC+:} false; then :
3079   $as_echo_n "(cached) " >&6
3080 else
3081   if test -n "$CC"; then
3082   ac_cv_prog_CC="$CC" # Let the user override the test.
3083 else
3084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3085 for as_dir in $PATH
3086 do
3087   IFS=$as_save_IFS
3088   test -z "$as_dir" && as_dir=.
3089     for ac_exec_ext in '' $ac_executable_extensions; do
3090   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3091     ac_cv_prog_CC="${ac_tool_prefix}cc"
3092     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3093     break 2
3094   fi
3095 done
3096   done
3097 IFS=$as_save_IFS
3098
3099 fi
3100 fi
3101 CC=$ac_cv_prog_CC
3102 if test -n "$CC"; then
3103   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3104 $as_echo "$CC" >&6; }
3105 else
3106   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3107 $as_echo "no" >&6; }
3108 fi
3109
3110
3111   fi
3112 fi
3113 if test -z "$CC"; then
3114   # Extract the first word of "cc", so it can be a program name with args.
3115 set dummy cc; ac_word=$2
3116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3117 $as_echo_n "checking for $ac_word... " >&6; }
3118 if ${ac_cv_prog_CC+:} false; then :
3119   $as_echo_n "(cached) " >&6
3120 else
3121   if test -n "$CC"; then
3122   ac_cv_prog_CC="$CC" # Let the user override the test.
3123 else
3124   ac_prog_rejected=no
3125 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3126 for as_dir in $PATH
3127 do
3128   IFS=$as_save_IFS
3129   test -z "$as_dir" && as_dir=.
3130     for ac_exec_ext in '' $ac_executable_extensions; do
3131   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3132     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3133        ac_prog_rejected=yes
3134        continue
3135      fi
3136     ac_cv_prog_CC="cc"
3137     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3138     break 2
3139   fi
3140 done
3141   done
3142 IFS=$as_save_IFS
3143
3144 if test $ac_prog_rejected = yes; then
3145   # We found a bogon in the path, so make sure we never use it.
3146   set dummy $ac_cv_prog_CC
3147   shift
3148   if test $# != 0; then
3149     # We chose a different compiler from the bogus one.
3150     # However, it has the same basename, so the bogon will be chosen
3151     # first if we set CC to just the basename; use the full file name.
3152     shift
3153     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3154   fi
3155 fi
3156 fi
3157 fi
3158 CC=$ac_cv_prog_CC
3159 if test -n "$CC"; then
3160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3161 $as_echo "$CC" >&6; }
3162 else
3163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3164 $as_echo "no" >&6; }
3165 fi
3166
3167
3168 fi
3169 if test -z "$CC"; then
3170   if test -n "$ac_tool_prefix"; then
3171   for ac_prog in cl.exe
3172   do
3173     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3174 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3176 $as_echo_n "checking for $ac_word... " >&6; }
3177 if ${ac_cv_prog_CC+:} false; then :
3178   $as_echo_n "(cached) " >&6
3179 else
3180   if test -n "$CC"; then
3181   ac_cv_prog_CC="$CC" # Let the user override the test.
3182 else
3183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3184 for as_dir in $PATH
3185 do
3186   IFS=$as_save_IFS
3187   test -z "$as_dir" && as_dir=.
3188     for ac_exec_ext in '' $ac_executable_extensions; do
3189   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3190     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3191     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3192     break 2
3193   fi
3194 done
3195   done
3196 IFS=$as_save_IFS
3197
3198 fi
3199 fi
3200 CC=$ac_cv_prog_CC
3201 if test -n "$CC"; then
3202   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3203 $as_echo "$CC" >&6; }
3204 else
3205   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3206 $as_echo "no" >&6; }
3207 fi
3208
3209
3210     test -n "$CC" && break
3211   done
3212 fi
3213 if test -z "$CC"; then
3214   ac_ct_CC=$CC
3215   for ac_prog in cl.exe
3216 do
3217   # Extract the first word of "$ac_prog", so it can be a program name with args.
3218 set dummy $ac_prog; ac_word=$2
3219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3220 $as_echo_n "checking for $ac_word... " >&6; }
3221 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3222   $as_echo_n "(cached) " >&6
3223 else
3224   if test -n "$ac_ct_CC"; then
3225   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3226 else
3227 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3228 for as_dir in $PATH
3229 do
3230   IFS=$as_save_IFS
3231   test -z "$as_dir" && as_dir=.
3232     for ac_exec_ext in '' $ac_executable_extensions; do
3233   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3234     ac_cv_prog_ac_ct_CC="$ac_prog"
3235     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3236     break 2
3237   fi
3238 done
3239   done
3240 IFS=$as_save_IFS
3241
3242 fi
3243 fi
3244 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3245 if test -n "$ac_ct_CC"; then
3246   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3247 $as_echo "$ac_ct_CC" >&6; }
3248 else
3249   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3250 $as_echo "no" >&6; }
3251 fi
3252
3253
3254   test -n "$ac_ct_CC" && break
3255 done
3256
3257   if test "x$ac_ct_CC" = x; then
3258     CC=""
3259   else
3260     case $cross_compiling:$ac_tool_warned in
3261 yes:)
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3263 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3264 ac_tool_warned=yes ;;
3265 esac
3266     CC=$ac_ct_CC
3267   fi
3268 fi
3269
3270 fi
3271
3272
3273 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3274 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3275 as_fn_error $? "no acceptable C compiler found in \$PATH
3276 See \`config.log' for more details" "$LINENO" 5; }
3277
3278 # Provide some information about the compiler.
3279 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3280 set X $ac_compile
3281 ac_compiler=$2
3282 for ac_option in --version -v -V -qversion; do
3283   { { ac_try="$ac_compiler $ac_option >&5"
3284 case "(($ac_try" in
3285   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3286   *) ac_try_echo=$ac_try;;
3287 esac
3288 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3289 $as_echo "$ac_try_echo"; } >&5
3290   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3291   ac_status=$?
3292   if test -s conftest.err; then
3293     sed '10a\
3294 ... rest of stderr output deleted ...
3295          10q' conftest.err >conftest.er1
3296     cat conftest.er1 >&5
3297   fi
3298   rm -f conftest.er1 conftest.err
3299   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3300   test $ac_status = 0; }
3301 done
3302
3303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3304 /* end confdefs.h.  */
3305
3306 int
3307 main ()
3308 {
3309
3310   ;
3311   return 0;
3312 }
3313 _ACEOF
3314 ac_clean_files_save=$ac_clean_files
3315 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3316 # Try to create an executable without -o first, disregard a.out.
3317 # It will help us diagnose broken compilers, and finding out an intuition
3318 # of exeext.
3319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3320 $as_echo_n "checking whether the C compiler works... " >&6; }
3321 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3322
3323 # The possible output files:
3324 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3325
3326 ac_rmfiles=
3327 for ac_file in $ac_files
3328 do
3329   case $ac_file in
3330     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3331     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3332   esac
3333 done
3334 rm -f $ac_rmfiles
3335
3336 if { { ac_try="$ac_link_default"
3337 case "(($ac_try" in
3338   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3339   *) ac_try_echo=$ac_try;;
3340 esac
3341 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3342 $as_echo "$ac_try_echo"; } >&5
3343   (eval "$ac_link_default") 2>&5
3344   ac_status=$?
3345   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3346   test $ac_status = 0; }; then :
3347   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3348 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3349 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3350 # so that the user can short-circuit this test for compilers unknown to
3351 # Autoconf.
3352 for ac_file in $ac_files ''
3353 do
3354   test -f "$ac_file" || continue
3355   case $ac_file in
3356     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3357         ;;
3358     [ab].out )
3359         # We found the default executable, but exeext='' is most
3360         # certainly right.
3361         break;;
3362     *.* )
3363         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3364         then :; else
3365            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3366         fi
3367         # We set ac_cv_exeext here because the later test for it is not
3368         # safe: cross compilers may not add the suffix if given an `-o'
3369         # argument, so we may need to know it at that point already.
3370         # Even if this section looks crufty: it has the advantage of
3371         # actually working.
3372         break;;
3373     * )
3374         break;;
3375   esac
3376 done
3377 test "$ac_cv_exeext" = no && ac_cv_exeext=
3378
3379 else
3380   ac_file=''
3381 fi
3382 if test -z "$ac_file"; then :
3383   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3384 $as_echo "no" >&6; }
3385 $as_echo "$as_me: failed program was:" >&5
3386 sed 's/^/| /' conftest.$ac_ext >&5
3387
3388 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3389 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3390 as_fn_error 77 "C compiler cannot create executables
3391 See \`config.log' for more details" "$LINENO" 5; }
3392 else
3393   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3394 $as_echo "yes" >&6; }
3395 fi
3396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3397 $as_echo_n "checking for C compiler default output file name... " >&6; }
3398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3399 $as_echo "$ac_file" >&6; }
3400 ac_exeext=$ac_cv_exeext
3401
3402 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3403 ac_clean_files=$ac_clean_files_save
3404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3405 $as_echo_n "checking for suffix of executables... " >&6; }
3406 if { { ac_try="$ac_link"
3407 case "(($ac_try" in
3408   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3409   *) ac_try_echo=$ac_try;;
3410 esac
3411 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3412 $as_echo "$ac_try_echo"; } >&5
3413   (eval "$ac_link") 2>&5
3414   ac_status=$?
3415   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3416   test $ac_status = 0; }; then :
3417   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3418 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3419 # work properly (i.e., refer to `conftest.exe'), while it won't with
3420 # `rm'.
3421 for ac_file in conftest.exe conftest conftest.*; do
3422   test -f "$ac_file" || continue
3423   case $ac_file in
3424     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3425     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3426           break;;
3427     * ) break;;
3428   esac
3429 done
3430 else
3431   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3432 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3433 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3434 See \`config.log' for more details" "$LINENO" 5; }
3435 fi
3436 rm -f conftest conftest$ac_cv_exeext
3437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3438 $as_echo "$ac_cv_exeext" >&6; }
3439
3440 rm -f conftest.$ac_ext
3441 EXEEXT=$ac_cv_exeext
3442 ac_exeext=$EXEEXT
3443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3444 /* end confdefs.h.  */
3445 #include <stdio.h>
3446 int
3447 main ()
3448 {
3449 FILE *f = fopen ("conftest.out", "w");
3450  return ferror (f) || fclose (f) != 0;
3451
3452   ;
3453   return 0;
3454 }
3455 _ACEOF
3456 ac_clean_files="$ac_clean_files conftest.out"
3457 # Check that the compiler produces executables we can run.  If not, either
3458 # the compiler is broken, or we cross compile.
3459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3460 $as_echo_n "checking whether we are cross compiling... " >&6; }
3461 if test "$cross_compiling" != yes; then
3462   { { ac_try="$ac_link"
3463 case "(($ac_try" in
3464   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3465   *) ac_try_echo=$ac_try;;
3466 esac
3467 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3468 $as_echo "$ac_try_echo"; } >&5
3469   (eval "$ac_link") 2>&5
3470   ac_status=$?
3471   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3472   test $ac_status = 0; }
3473   if { ac_try='./conftest$ac_cv_exeext'
3474   { { case "(($ac_try" in
3475   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3476   *) ac_try_echo=$ac_try;;
3477 esac
3478 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3479 $as_echo "$ac_try_echo"; } >&5
3480   (eval "$ac_try") 2>&5
3481   ac_status=$?
3482   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3483   test $ac_status = 0; }; }; then
3484     cross_compiling=no
3485   else
3486     if test "$cross_compiling" = maybe; then
3487         cross_compiling=yes
3488     else
3489         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3490 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3491 as_fn_error $? "cannot run C compiled programs.
3492 If you meant to cross compile, use \`--host'.
3493 See \`config.log' for more details" "$LINENO" 5; }
3494     fi
3495   fi
3496 fi
3497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3498 $as_echo "$cross_compiling" >&6; }
3499
3500 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3501 ac_clean_files=$ac_clean_files_save
3502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3503 $as_echo_n "checking for suffix of object files... " >&6; }
3504 if ${ac_cv_objext+:} false; then :
3505   $as_echo_n "(cached) " >&6
3506 else
3507   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3508 /* end confdefs.h.  */
3509
3510 int
3511 main ()
3512 {
3513
3514   ;
3515   return 0;
3516 }
3517 _ACEOF
3518 rm -f conftest.o conftest.obj
3519 if { { ac_try="$ac_compile"
3520 case "(($ac_try" in
3521   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3522   *) ac_try_echo=$ac_try;;
3523 esac
3524 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3525 $as_echo "$ac_try_echo"; } >&5
3526   (eval "$ac_compile") 2>&5
3527   ac_status=$?
3528   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3529   test $ac_status = 0; }; then :
3530   for ac_file in conftest.o conftest.obj conftest.*; do
3531   test -f "$ac_file" || continue;
3532   case $ac_file in
3533     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3534     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3535        break;;
3536   esac
3537 done
3538 else
3539   $as_echo "$as_me: failed program was:" >&5
3540 sed 's/^/| /' conftest.$ac_ext >&5
3541
3542 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3543 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3544 as_fn_error $? "cannot compute suffix of object files: cannot compile
3545 See \`config.log' for more details" "$LINENO" 5; }
3546 fi
3547 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3548 fi
3549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3550 $as_echo "$ac_cv_objext" >&6; }
3551 OBJEXT=$ac_cv_objext
3552 ac_objext=$OBJEXT
3553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3554 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3555 if ${ac_cv_c_compiler_gnu+:} false; then :
3556   $as_echo_n "(cached) " >&6
3557 else
3558   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3559 /* end confdefs.h.  */
3560
3561 int
3562 main ()
3563 {
3564 #ifndef __GNUC__
3565        choke me
3566 #endif
3567
3568   ;
3569   return 0;
3570 }
3571 _ACEOF
3572 if ac_fn_c_try_compile "$LINENO"; then :
3573   ac_compiler_gnu=yes
3574 else
3575   ac_compiler_gnu=no
3576 fi
3577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3578 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3579
3580 fi
3581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3582 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3583 if test $ac_compiler_gnu = yes; then
3584   GCC=yes
3585 else
3586   GCC=
3587 fi
3588 ac_test_CFLAGS=${CFLAGS+set}
3589 ac_save_CFLAGS=$CFLAGS
3590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3591 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3592 if ${ac_cv_prog_cc_g+:} false; then :
3593   $as_echo_n "(cached) " >&6
3594 else
3595   ac_save_c_werror_flag=$ac_c_werror_flag
3596    ac_c_werror_flag=yes
3597    ac_cv_prog_cc_g=no
3598    CFLAGS="-g"
3599    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3600 /* end confdefs.h.  */
3601
3602 int
3603 main ()
3604 {
3605
3606   ;
3607   return 0;
3608 }
3609 _ACEOF
3610 if ac_fn_c_try_compile "$LINENO"; then :
3611   ac_cv_prog_cc_g=yes
3612 else
3613   CFLAGS=""
3614       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3615 /* end confdefs.h.  */
3616
3617 int
3618 main ()
3619 {
3620
3621   ;
3622   return 0;
3623 }
3624 _ACEOF
3625 if ac_fn_c_try_compile "$LINENO"; then :
3626
3627 else
3628   ac_c_werror_flag=$ac_save_c_werror_flag
3629          CFLAGS="-g"
3630          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3631 /* end confdefs.h.  */
3632
3633 int
3634 main ()
3635 {
3636
3637   ;
3638   return 0;
3639 }
3640 _ACEOF
3641 if ac_fn_c_try_compile "$LINENO"; then :
3642   ac_cv_prog_cc_g=yes
3643 fi
3644 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3645 fi
3646 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3647 fi
3648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3649    ac_c_werror_flag=$ac_save_c_werror_flag
3650 fi
3651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3652 $as_echo "$ac_cv_prog_cc_g" >&6; }
3653 if test "$ac_test_CFLAGS" = set; then
3654   CFLAGS=$ac_save_CFLAGS
3655 elif test $ac_cv_prog_cc_g = yes; then
3656   if test "$GCC" = yes; then
3657     CFLAGS="-g -O2"
3658   else
3659     CFLAGS="-g"
3660   fi
3661 else
3662   if test "$GCC" = yes; then
3663     CFLAGS="-O2"
3664   else
3665     CFLAGS=
3666   fi
3667 fi
3668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3669 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3670 if ${ac_cv_prog_cc_c89+:} false; then :
3671   $as_echo_n "(cached) " >&6
3672 else
3673   ac_cv_prog_cc_c89=no
3674 ac_save_CC=$CC
3675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3676 /* end confdefs.h.  */
3677 #include <stdarg.h>
3678 #include <stdio.h>
3679 struct stat;
3680 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3681 struct buf { int x; };
3682 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3683 static char *e (p, i)
3684      char **p;
3685      int i;
3686 {
3687   return p[i];
3688 }
3689 static char *f (char * (*g) (char **, int), char **p, ...)
3690 {
3691   char *s;
3692   va_list v;
3693   va_start (v,p);
3694   s = g (p, va_arg (v,int));
3695   va_end (v);
3696   return s;
3697 }
3698
3699 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3700    function prototypes and stuff, but not '\xHH' hex character constants.
3701    These don't provoke an error unfortunately, instead are silently treated
3702    as 'x'.  The following induces an error, until -std is added to get
3703    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3704    array size at least.  It's necessary to write '\x00'==0 to get something
3705    that's true only with -std.  */
3706 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3707
3708 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3709    inside strings and character constants.  */
3710 #define FOO(x) 'x'
3711 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3712
3713 int test (int i, double x);
3714 struct s1 {int (*f) (int a);};
3715 struct s2 {int (*f) (double a);};
3716 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3717 int argc;
3718 char **argv;
3719 int
3720 main ()
3721 {
3722 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3723   ;
3724   return 0;
3725 }
3726 _ACEOF
3727 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3728         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3729 do
3730   CC="$ac_save_CC $ac_arg"
3731   if ac_fn_c_try_compile "$LINENO"; then :
3732   ac_cv_prog_cc_c89=$ac_arg
3733 fi
3734 rm -f core conftest.err conftest.$ac_objext
3735   test "x$ac_cv_prog_cc_c89" != "xno" && break
3736 done
3737 rm -f conftest.$ac_ext
3738 CC=$ac_save_CC
3739
3740 fi
3741 # AC_CACHE_VAL
3742 case "x$ac_cv_prog_cc_c89" in
3743   x)
3744     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3745 $as_echo "none needed" >&6; } ;;
3746   xno)
3747     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3748 $as_echo "unsupported" >&6; } ;;
3749   *)
3750     CC="$CC $ac_cv_prog_cc_c89"
3751     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3752 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3753 esac
3754 if test "x$ac_cv_prog_cc_c89" != xno; then :
3755
3756 fi
3757
3758 ac_ext=c
3759 ac_cpp='$CPP $CPPFLAGS'
3760 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3761 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3762 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3763
3764
3765 ac_ext=c
3766 ac_cpp='$CPP $CPPFLAGS'
3767 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3768 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3769 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3771 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3772 # On Suns, sometimes $CPP names a directory.
3773 if test -n "$CPP" && test -d "$CPP"; then
3774   CPP=
3775 fi
3776 if test -z "$CPP"; then
3777   if ${ac_cv_prog_CPP+:} false; then :
3778   $as_echo_n "(cached) " >&6
3779 else
3780       # Double quotes because CPP needs to be expanded
3781     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3782     do
3783       ac_preproc_ok=false
3784 for ac_c_preproc_warn_flag in '' yes
3785 do
3786   # Use a header file that comes with gcc, so configuring glibc
3787   # with a fresh cross-compiler works.
3788   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3789   # <limits.h> exists even on freestanding compilers.
3790   # On the NeXT, cc -E runs the code through the compiler's parser,
3791   # not just through cpp. "Syntax error" is here to catch this case.
3792   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3793 /* end confdefs.h.  */
3794 #ifdef __STDC__
3795 # include <limits.h>
3796 #else
3797 # include <assert.h>
3798 #endif
3799                      Syntax error
3800 _ACEOF
3801 if ac_fn_c_try_cpp "$LINENO"; then :
3802
3803 else
3804   # Broken: fails on valid input.
3805 continue
3806 fi
3807 rm -f conftest.err conftest.i conftest.$ac_ext
3808
3809   # OK, works on sane cases.  Now check whether nonexistent headers
3810   # can be detected and how.
3811   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3812 /* end confdefs.h.  */
3813 #include <ac_nonexistent.h>
3814 _ACEOF
3815 if ac_fn_c_try_cpp "$LINENO"; then :
3816   # Broken: success on invalid input.
3817 continue
3818 else
3819   # Passes both tests.
3820 ac_preproc_ok=:
3821 break
3822 fi
3823 rm -f conftest.err conftest.i conftest.$ac_ext
3824
3825 done
3826 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3827 rm -f conftest.i conftest.err conftest.$ac_ext
3828 if $ac_preproc_ok; then :
3829   break
3830 fi
3831
3832     done
3833     ac_cv_prog_CPP=$CPP
3834
3835 fi
3836   CPP=$ac_cv_prog_CPP
3837 else
3838   ac_cv_prog_CPP=$CPP
3839 fi
3840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3841 $as_echo "$CPP" >&6; }
3842 ac_preproc_ok=false
3843 for ac_c_preproc_warn_flag in '' yes
3844 do
3845   # Use a header file that comes with gcc, so configuring glibc
3846   # with a fresh cross-compiler works.
3847   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3848   # <limits.h> exists even on freestanding compilers.
3849   # On the NeXT, cc -E runs the code through the compiler's parser,
3850   # not just through cpp. "Syntax error" is here to catch this case.
3851   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3852 /* end confdefs.h.  */
3853 #ifdef __STDC__
3854 # include <limits.h>
3855 #else
3856 # include <assert.h>
3857 #endif
3858                      Syntax error
3859 _ACEOF
3860 if ac_fn_c_try_cpp "$LINENO"; then :
3861
3862 else
3863   # Broken: fails on valid input.
3864 continue
3865 fi
3866 rm -f conftest.err conftest.i conftest.$ac_ext
3867
3868   # OK, works on sane cases.  Now check whether nonexistent headers
3869   # can be detected and how.
3870   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3871 /* end confdefs.h.  */
3872 #include <ac_nonexistent.h>
3873 _ACEOF
3874 if ac_fn_c_try_cpp "$LINENO"; then :
3875   # Broken: success on invalid input.
3876 continue
3877 else
3878   # Passes both tests.
3879 ac_preproc_ok=:
3880 break
3881 fi
3882 rm -f conftest.err conftest.i conftest.$ac_ext
3883
3884 done
3885 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3886 rm -f conftest.i conftest.err conftest.$ac_ext
3887 if $ac_preproc_ok; then :
3888
3889 else
3890   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3891 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3892 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3893 See \`config.log' for more details" "$LINENO" 5; }
3894 fi
3895
3896 ac_ext=c
3897 ac_cpp='$CPP $CPPFLAGS'
3898 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3899 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3900 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3901
3902
3903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3904 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3905 if ${ac_cv_path_GREP+:} false; then :
3906   $as_echo_n "(cached) " >&6
3907 else
3908   if test -z "$GREP"; then
3909   ac_path_GREP_found=false
3910   # Loop through the user's path and test for each of PROGNAME-LIST
3911   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3912 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3913 do
3914   IFS=$as_save_IFS
3915   test -z "$as_dir" && as_dir=.
3916     for ac_prog in grep ggrep; do
3917     for ac_exec_ext in '' $ac_executable_extensions; do
3918       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3919       as_fn_executable_p "$ac_path_GREP" || continue
3920 # Check for GNU ac_path_GREP and select it if it is found.
3921   # Check for GNU $ac_path_GREP
3922 case `"$ac_path_GREP" --version 2>&1` in
3923 *GNU*)
3924   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3925 *)
3926   ac_count=0
3927   $as_echo_n 0123456789 >"conftest.in"
3928   while :
3929   do
3930     cat "conftest.in" "conftest.in" >"conftest.tmp"
3931     mv "conftest.tmp" "conftest.in"
3932     cp "conftest.in" "conftest.nl"
3933     $as_echo 'GREP' >> "conftest.nl"
3934     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3935     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3936     as_fn_arith $ac_count + 1 && ac_count=$as_val
3937     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3938       # Best one so far, save it but keep looking for a better one
3939       ac_cv_path_GREP="$ac_path_GREP"
3940       ac_path_GREP_max=$ac_count
3941     fi
3942     # 10*(2^10) chars as input seems more than enough
3943     test $ac_count -gt 10 && break
3944   done
3945   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3946 esac
3947
3948       $ac_path_GREP_found && break 3
3949     done
3950   done
3951   done
3952 IFS=$as_save_IFS
3953   if test -z "$ac_cv_path_GREP"; then
3954     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3955   fi
3956 else
3957   ac_cv_path_GREP=$GREP
3958 fi
3959
3960 fi
3961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3962 $as_echo "$ac_cv_path_GREP" >&6; }
3963  GREP="$ac_cv_path_GREP"
3964
3965
3966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3967 $as_echo_n "checking for egrep... " >&6; }
3968 if ${ac_cv_path_EGREP+:} false; then :
3969   $as_echo_n "(cached) " >&6
3970 else
3971   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3972    then ac_cv_path_EGREP="$GREP -E"
3973    else
3974      if test -z "$EGREP"; then
3975   ac_path_EGREP_found=false
3976   # Loop through the user's path and test for each of PROGNAME-LIST
3977   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3978 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3979 do
3980   IFS=$as_save_IFS
3981   test -z "$as_dir" && as_dir=.
3982     for ac_prog in egrep; do
3983     for ac_exec_ext in '' $ac_executable_extensions; do
3984       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3985       as_fn_executable_p "$ac_path_EGREP" || continue
3986 # Check for GNU ac_path_EGREP and select it if it is found.
3987   # Check for GNU $ac_path_EGREP
3988 case `"$ac_path_EGREP" --version 2>&1` in
3989 *GNU*)
3990   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3991 *)
3992   ac_count=0
3993   $as_echo_n 0123456789 >"conftest.in"
3994   while :
3995   do
3996     cat "conftest.in" "conftest.in" >"conftest.tmp"
3997     mv "conftest.tmp" "conftest.in"
3998     cp "conftest.in" "conftest.nl"
3999     $as_echo 'EGREP' >> "conftest.nl"
4000     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4001     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4002     as_fn_arith $ac_count + 1 && ac_count=$as_val
4003     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4004       # Best one so far, save it but keep looking for a better one
4005       ac_cv_path_EGREP="$ac_path_EGREP"
4006       ac_path_EGREP_max=$ac_count
4007     fi
4008     # 10*(2^10) chars as input seems more than enough
4009     test $ac_count -gt 10 && break
4010   done
4011   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4012 esac
4013
4014       $ac_path_EGREP_found && break 3
4015     done
4016   done
4017   done
4018 IFS=$as_save_IFS
4019   if test -z "$ac_cv_path_EGREP"; then
4020     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4021   fi
4022 else
4023   ac_cv_path_EGREP=$EGREP
4024 fi
4025
4026    fi
4027 fi
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4029 $as_echo "$ac_cv_path_EGREP" >&6; }
4030  EGREP="$ac_cv_path_EGREP"
4031
4032
4033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4034 $as_echo_n "checking for ANSI C header files... " >&6; }
4035 if ${ac_cv_header_stdc+:} false; then :
4036   $as_echo_n "(cached) " >&6
4037 else
4038   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4039 /* end confdefs.h.  */
4040 #include <stdlib.h>
4041 #include <stdarg.h>
4042 #include <string.h>
4043 #include <float.h>
4044
4045 int
4046 main ()
4047 {
4048
4049   ;
4050   return 0;
4051 }
4052 _ACEOF
4053 if ac_fn_c_try_compile "$LINENO"; then :
4054   ac_cv_header_stdc=yes
4055 else
4056   ac_cv_header_stdc=no
4057 fi
4058 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4059
4060 if test $ac_cv_header_stdc = yes; then
4061   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4062   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4063 /* end confdefs.h.  */
4064 #include <string.h>
4065
4066 _ACEOF
4067 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4068   $EGREP "memchr" >/dev/null 2>&1; then :
4069
4070 else
4071   ac_cv_header_stdc=no
4072 fi
4073 rm -f conftest*
4074
4075 fi
4076
4077 if test $ac_cv_header_stdc = yes; then
4078   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4079   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4080 /* end confdefs.h.  */
4081 #include <stdlib.h>
4082
4083 _ACEOF
4084 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4085   $EGREP "free" >/dev/null 2>&1; then :
4086
4087 else
4088   ac_cv_header_stdc=no
4089 fi
4090 rm -f conftest*
4091
4092 fi
4093
4094 if test $ac_cv_header_stdc = yes; then
4095   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4096   if test "$cross_compiling" = yes; then :
4097   :
4098 else
4099   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4100 /* end confdefs.h.  */
4101 #include <ctype.h>
4102 #include <stdlib.h>
4103 #if ((' ' & 0x0FF) == 0x020)
4104 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4105 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4106 #else
4107 # define ISLOWER(c) \
4108                    (('a' <= (c) && (c) <= 'i') \
4109                      || ('j' <= (c) && (c) <= 'r') \
4110                      || ('s' <= (c) && (c) <= 'z'))
4111 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4112 #endif
4113
4114 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4115 int
4116 main ()
4117 {
4118   int i;
4119   for (i = 0; i < 256; i++)
4120     if (XOR (islower (i), ISLOWER (i))
4121         || toupper (i) != TOUPPER (i))
4122       return 2;
4123   return 0;
4124 }
4125 _ACEOF
4126 if ac_fn_c_try_run "$LINENO"; then :
4127
4128 else
4129   ac_cv_header_stdc=no
4130 fi
4131 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4132   conftest.$ac_objext conftest.beam conftest.$ac_ext
4133 fi
4134
4135 fi
4136 fi
4137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4138 $as_echo "$ac_cv_header_stdc" >&6; }
4139 if test $ac_cv_header_stdc = yes; then
4140
4141 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4142
4143 fi
4144
4145 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4146 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4147                   inttypes.h stdint.h unistd.h
4148 do :
4149   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4150 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4151 "
4152 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4153   cat >>confdefs.h <<_ACEOF
4154 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4155 _ACEOF
4156
4157 fi
4158
4159 done
4160
4161
4162
4163   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4164 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4165   MINIX=yes
4166 else
4167   MINIX=
4168 fi
4169
4170
4171   if test "$MINIX" = yes; then
4172
4173 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4174
4175
4176 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4177
4178
4179 $as_echo "#define _MINIX 1" >>confdefs.h
4180
4181   fi
4182
4183
4184   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4185 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4186 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4187   $as_echo_n "(cached) " >&6
4188 else
4189   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4190 /* end confdefs.h.  */
4191
4192 #         define __EXTENSIONS__ 1
4193           $ac_includes_default
4194 int
4195 main ()
4196 {
4197
4198   ;
4199   return 0;
4200 }
4201 _ACEOF
4202 if ac_fn_c_try_compile "$LINENO"; then :
4203   ac_cv_safe_to_define___extensions__=yes
4204 else
4205   ac_cv_safe_to_define___extensions__=no
4206 fi
4207 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4208 fi
4209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4210 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4211   test $ac_cv_safe_to_define___extensions__ = yes &&
4212     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4213
4214   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4215
4216   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4217
4218   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4219
4220   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4221
4222
4223 if test "$ac_cv_header_minix_config_h" = "yes"; then
4224
4225 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4226
4227 fi
4228
4229 case "$prefix" in
4230         NONE)
4231                 prefix="/usr/local"
4232         ;;
4233 esac
4234 case "$exec_prefix" in
4235         NONE)
4236                 exec_prefix="$prefix"
4237         ;;
4238 esac
4239
4240 # are we on MinGW?
4241 if uname -s 2>&1 | grep MINGW >/dev/null; then on_mingw="yes"
4242 else
4243         if echo $host | grep mingw >/dev/null; then on_mingw="yes"
4244         else on_mingw="no"; fi
4245 fi
4246
4247 #
4248 # Determine configuration file
4249 # the eval is to evaluate shell expansion twice
4250 UNBOUND_SBIN_DIR=`eval echo "${sbindir}"`
4251
4252 UNBOUND_SYSCONF_DIR=`eval echo "${sysconfdir}"`
4253
4254 UNBOUND_LOCALSTATE_DIR=`eval echo "${localstatedir}"`
4255
4256 if test $on_mingw = "no"; then
4257   ub_conf_file=`eval echo "${sysconfdir}/unbound/unbound.conf"`
4258 else
4259   ub_conf_file="C:\\Program Files\\Unbound\\service.conf"
4260 fi
4261
4262 # Check whether --with-conf_file was given.
4263 if test "${with_conf_file+set}" = set; then :
4264   withval=$with_conf_file; ub_conf_file="$withval"
4265 fi
4266
4267
4268 hdr_config="`echo $ub_conf_file | sed -e 's/\\\\/\\\\\\\\/g'`"
4269
4270
4271 cat >>confdefs.h <<_ACEOF
4272 #define CONFIGFILE "$hdr_config"
4273 _ACEOF
4274
4275 ub_conf_dir=`$as_dirname -- "$ub_conf_file" ||
4276 $as_expr X"$ub_conf_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4277          X"$ub_conf_file" : 'X\(//\)[^/]' \| \
4278          X"$ub_conf_file" : 'X\(//\)$' \| \
4279          X"$ub_conf_file" : 'X\(/\)' \| . 2>/dev/null ||
4280 $as_echo X"$ub_conf_file" |
4281     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
4282             s//\1/
4283             q
4284           }
4285           /^X\(\/\/\)[^/].*/{
4286             s//\1/
4287             q
4288           }
4289           /^X\(\/\/\)$/{
4290             s//\1/
4291             q
4292           }
4293           /^X\(\/\).*/{
4294             s//\1/
4295             q
4296           }
4297           s/.*/./; q'`
4298
4299
4300 # Determine run, chroot directory and pidfile locations
4301
4302 # Check whether --with-run-dir was given.
4303 if test "${with_run_dir+set}" = set; then :
4304   withval=$with_run_dir; UNBOUND_RUN_DIR="$withval"
4305 else
4306   if test $on_mingw = no; then
4307     UNBOUND_RUN_DIR=`dirname "$ub_conf_file"`
4308 else
4309     UNBOUND_RUN_DIR=""
4310 fi
4311
4312 fi
4313
4314
4315 hdr_run="`echo $UNBOUND_RUN_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4316
4317
4318 cat >>confdefs.h <<_ACEOF
4319 #define RUN_DIR "$hdr_run"
4320 _ACEOF
4321
4322
4323
4324 # Check whether --with-chroot-dir was given.
4325 if test "${with_chroot_dir+set}" = set; then :
4326   withval=$with_chroot_dir; UNBOUND_CHROOT_DIR="$withval"
4327 else
4328   if test $on_mingw = no; then
4329     UNBOUND_CHROOT_DIR="$UNBOUND_RUN_DIR"
4330 else
4331     UNBOUND_CHROOT_DIR=""
4332 fi
4333
4334 fi
4335
4336
4337 hdr_chroot="`echo $UNBOUND_CHROOT_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4338
4339
4340 cat >>confdefs.h <<_ACEOF
4341 #define CHROOT_DIR "$hdr_chroot"
4342 _ACEOF
4343
4344
4345
4346 # Check whether --with-share-dir was given.
4347 if test "${with_share_dir+set}" = set; then :
4348   withval=$with_share_dir; UNBOUND_SHARE_DIR="$withval"
4349 else
4350   UNBOUND_SHARE_DIR="$UNBOUND_RUN_DIR"
4351 fi
4352
4353
4354
4355 cat >>confdefs.h <<_ACEOF
4356 #define SHARE_DIR "$UNBOUND_SHARE_DIR"
4357 _ACEOF
4358
4359
4360
4361 # Check whether --with-pidfile was given.
4362 if test "${with_pidfile+set}" = set; then :
4363   withval=$with_pidfile; UNBOUND_PIDFILE="$withval"
4364 else
4365   if test $on_mingw = no; then
4366     UNBOUND_PIDFILE="$UNBOUND_RUN_DIR/unbound.pid"
4367 else
4368     UNBOUND_PIDFILE=""
4369 fi
4370
4371 fi
4372
4373
4374 hdr_pid="`echo $UNBOUND_PIDFILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4375
4376
4377 cat >>confdefs.h <<_ACEOF
4378 #define PIDFILE "$hdr_pid"
4379 _ACEOF
4380
4381
4382
4383 # Check whether --with-rootkey-file was given.
4384 if test "${with_rootkey_file+set}" = set; then :
4385   withval=$with_rootkey_file; UNBOUND_ROOTKEY_FILE="$withval"
4386 else
4387   if test $on_mingw = no; then
4388     UNBOUND_ROOTKEY_FILE="$UNBOUND_RUN_DIR/root.key"
4389 else
4390     UNBOUND_ROOTKEY_FILE="C:\\Program Files\\Unbound\\root.key"
4391 fi
4392
4393 fi
4394
4395
4396 hdr_rkey="`echo $UNBOUND_ROOTKEY_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4397
4398
4399 cat >>confdefs.h <<_ACEOF
4400 #define ROOT_ANCHOR_FILE "$hdr_rkey"
4401 _ACEOF
4402
4403
4404
4405 # Check whether --with-rootcert-file was given.
4406 if test "${with_rootcert_file+set}" = set; then :
4407   withval=$with_rootcert_file; UNBOUND_ROOTCERT_FILE="$withval"
4408 else
4409   if test $on_mingw = no; then
4410     UNBOUND_ROOTCERT_FILE="$UNBOUND_RUN_DIR/icannbundle.pem"
4411 else
4412     UNBOUND_ROOTCERT_FILE="C:\\Program Files\\Unbound\\icannbundle.pem"
4413 fi
4414
4415 fi
4416
4417
4418 hdr_rpem="`echo $UNBOUND_ROOTCERT_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4419
4420
4421 cat >>confdefs.h <<_ACEOF
4422 #define ROOT_CERT_FILE "$hdr_rpem"
4423 _ACEOF
4424
4425
4426
4427 # Check whether --with-username was given.
4428 if test "${with_username+set}" = set; then :
4429   withval=$with_username; UNBOUND_USERNAME="$withval"
4430 else
4431   UNBOUND_USERNAME="unbound"
4432 fi
4433
4434
4435
4436 cat >>confdefs.h <<_ACEOF
4437 #define UB_USERNAME "$UNBOUND_USERNAME"
4438 _ACEOF
4439
4440
4441
4442 $as_echo "#define WINVER 0x0502" >>confdefs.h
4443
4444 wnvs=`echo $PACKAGE_VERSION | sed -e 's/^[^0-9]*\([0-9][0-9]*\)[^0-9][^0-9]*\([0-9][0-9]*\)[^0-9][^0-9]*\([0-9][0-9]*\)[^0-9][^0-9]*\([0-9][0-9]*\).*$/\1,\2,\3,\4/' -e 's/^[^0-9]*\([0-9][0-9]*\)[^0-9][^0-9]*\([0-9][0-9]*\)[^0-9][^0-9]*\([0-9][0-9]*\)[^0-9]*$/\1,\2,\3,0/' `
4445
4446
4447 cat >>confdefs.h <<_ACEOF
4448 #define RSRC_PACKAGE_VERSION $wnvs
4449 _ACEOF
4450
4451
4452 # Checks for typedefs, structures, and compiler characteristics.
4453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
4454 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
4455 if ${ac_cv_c_const+:} false; then :
4456   $as_echo_n "(cached) " >&6
4457 else
4458   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4459 /* end confdefs.h.  */
4460
4461 int
4462 main ()
4463 {
4464
4465 #ifndef __cplusplus
4466   /* Ultrix mips cc rejects this sort of thing.  */
4467   typedef int charset[2];
4468   const charset cs = { 0, 0 };
4469   /* SunOS 4.1.1 cc rejects this.  */
4470   char const *const *pcpcc;
4471   char **ppc;
4472   /* NEC SVR4.0.2 mips cc rejects this.  */
4473   struct point {int x, y;};
4474   static struct point const zero = {0,0};
4475   /* AIX XL C 1.02.0.0 rejects this.
4476      It does not let you subtract one const X* pointer from another in
4477      an arm of an if-expression whose if-part is not a constant
4478      expression */
4479   const char *g = "string";
4480   pcpcc = &g + (g ? g-g : 0);
4481   /* HPUX 7.0 cc rejects these. */
4482   ++pcpcc;
4483   ppc = (char**) pcpcc;
4484   pcpcc = (char const *const *) ppc;
4485   { /* SCO 3.2v4 cc rejects this sort of thing.  */
4486     char tx;
4487     char *t = &tx;
4488     char const *s = 0 ? (char *) 0 : (char const *) 0;
4489
4490     *t++ = 0;
4491     if (s) return 0;
4492   }
4493   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
4494     int x[] = {25, 17};
4495     const int *foo = &x[0];
4496     ++foo;
4497   }
4498   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4499     typedef const int *iptr;
4500     iptr p = 0;
4501     ++p;
4502   }
4503   { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
4504        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4505     struct s { int j; const int *ap[3]; } bx;
4506     struct s *b = &bx; b->j = 5;
4507   }
4508   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4509     const int foo = 10;
4510     if (!foo) return 0;
4511   }
4512   return !cs[0] && !zero.x;
4513 #endif
4514
4515   ;
4516   return 0;
4517 }
4518 _ACEOF
4519 if ac_fn_c_try_compile "$LINENO"; then :
4520   ac_cv_c_const=yes
4521 else
4522   ac_cv_c_const=no
4523 fi
4524 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4525 fi
4526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
4527 $as_echo "$ac_cv_c_const" >&6; }
4528 if test $ac_cv_c_const = no; then
4529
4530 $as_echo "#define const /**/" >>confdefs.h
4531
4532 fi
4533
4534 ac_ext=c
4535 ac_cpp='$CPP $CPPFLAGS'
4536 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4537 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4538 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4539
4540 # allow user to override the -g -O2 flags.
4541 default_cflags=no
4542 if test "x$CFLAGS" = "x" ; then
4543
4544
4545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -g" >&5
4546 $as_echo_n "checking whether $CC supports -g... " >&6; }
4547 cache=`echo g | sed 'y%.=/+-%___p_%'`
4548 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4549   $as_echo_n "(cached) " >&6
4550 else
4551
4552 echo 'void f(void){}' >conftest.c
4553 if test -z "`$CC $CPPFLAGS $CFLAGS -g -c conftest.c 2>&1`"; then
4554 eval "cv_prog_cc_flag_$cache=yes"
4555 else
4556 eval "cv_prog_cc_flag_$cache=no"
4557 fi
4558 rm -f conftest conftest.o conftest.c
4559
4560 fi
4561
4562 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4564 $as_echo "yes" >&6; }
4565 :
4566 CFLAGS="$CFLAGS -g"
4567 else
4568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4569 $as_echo "no" >&6; }
4570 :
4571
4572 fi
4573
4574
4575
4576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -O2" >&5
4577 $as_echo_n "checking whether $CC supports -O2... " >&6; }
4578 cache=`echo O2 | sed 'y%.=/+-%___p_%'`
4579 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4580   $as_echo_n "(cached) " >&6
4581 else
4582
4583 echo 'void f(void){}' >conftest.c
4584 if test -z "`$CC $CPPFLAGS $CFLAGS -O2 -c conftest.c 2>&1`"; then
4585 eval "cv_prog_cc_flag_$cache=yes"
4586 else
4587 eval "cv_prog_cc_flag_$cache=no"
4588 fi
4589 rm -f conftest conftest.o conftest.c
4590
4591 fi
4592
4593 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4595 $as_echo "yes" >&6; }
4596 :
4597 CFLAGS="$CFLAGS -O2"
4598 else
4599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4600 $as_echo "no" >&6; }
4601 :
4602
4603 fi
4604
4605 default_cflags=yes
4606 fi
4607 ac_ext=c
4608 ac_cpp='$CPP $CPPFLAGS'
4609 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4610 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4611 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4612 if test -n "$ac_tool_prefix"; then
4613   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4614 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4616 $as_echo_n "checking for $ac_word... " >&6; }
4617 if ${ac_cv_prog_CC+:} false; then :
4618   $as_echo_n "(cached) " >&6
4619 else
4620   if test -n "$CC"; then
4621   ac_cv_prog_CC="$CC" # Let the user override the test.
4622 else
4623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4624 for as_dir in $PATH
4625 do
4626   IFS=$as_save_IFS
4627   test -z "$as_dir" && as_dir=.
4628     for ac_exec_ext in '' $ac_executable_extensions; do
4629   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4630     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4631     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4632     break 2
4633   fi
4634 done
4635   done
4636 IFS=$as_save_IFS
4637
4638 fi
4639 fi
4640 CC=$ac_cv_prog_CC
4641 if test -n "$CC"; then
4642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4643 $as_echo "$CC" >&6; }
4644 else
4645   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4646 $as_echo "no" >&6; }
4647 fi
4648
4649
4650 fi
4651 if test -z "$ac_cv_prog_CC"; then
4652   ac_ct_CC=$CC
4653   # Extract the first word of "gcc", so it can be a program name with args.
4654 set dummy gcc; ac_word=$2
4655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4656 $as_echo_n "checking for $ac_word... " >&6; }
4657 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4658   $as_echo_n "(cached) " >&6
4659 else
4660   if test -n "$ac_ct_CC"; then
4661   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4662 else
4663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4664 for as_dir in $PATH
4665 do
4666   IFS=$as_save_IFS
4667   test -z "$as_dir" && as_dir=.
4668     for ac_exec_ext in '' $ac_executable_extensions; do
4669   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4670     ac_cv_prog_ac_ct_CC="gcc"
4671     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4672     break 2
4673   fi
4674 done
4675   done
4676 IFS=$as_save_IFS
4677
4678 fi
4679 fi
4680 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4681 if test -n "$ac_ct_CC"; then
4682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4683 $as_echo "$ac_ct_CC" >&6; }
4684 else
4685   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4686 $as_echo "no" >&6; }
4687 fi
4688
4689   if test "x$ac_ct_CC" = x; then
4690     CC=""
4691   else
4692     case $cross_compiling:$ac_tool_warned in
4693 yes:)
4694 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4695 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4696 ac_tool_warned=yes ;;
4697 esac
4698     CC=$ac_ct_CC
4699   fi
4700 else
4701   CC="$ac_cv_prog_CC"
4702 fi
4703
4704 if test -z "$CC"; then
4705           if test -n "$ac_tool_prefix"; then
4706     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4707 set dummy ${ac_tool_prefix}cc; ac_word=$2
4708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4709 $as_echo_n "checking for $ac_word... " >&6; }
4710 if ${ac_cv_prog_CC+:} false; then :
4711   $as_echo_n "(cached) " >&6
4712 else
4713   if test -n "$CC"; then
4714   ac_cv_prog_CC="$CC" # Let the user override the test.
4715 else
4716 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4717 for as_dir in $PATH
4718 do
4719   IFS=$as_save_IFS
4720   test -z "$as_dir" && as_dir=.
4721     for ac_exec_ext in '' $ac_executable_extensions; do
4722   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4723     ac_cv_prog_CC="${ac_tool_prefix}cc"
4724     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4725     break 2
4726   fi
4727 done
4728   done
4729 IFS=$as_save_IFS
4730
4731 fi
4732 fi
4733 CC=$ac_cv_prog_CC
4734 if test -n "$CC"; then
4735   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4736 $as_echo "$CC" >&6; }
4737 else
4738   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4739 $as_echo "no" >&6; }
4740 fi
4741
4742
4743   fi
4744 fi
4745 if test -z "$CC"; then
4746   # Extract the first word of "cc", so it can be a program name with args.
4747 set dummy cc; ac_word=$2
4748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4749 $as_echo_n "checking for $ac_word... " >&6; }
4750 if ${ac_cv_prog_CC+:} false; then :
4751   $as_echo_n "(cached) " >&6
4752 else
4753   if test -n "$CC"; then
4754   ac_cv_prog_CC="$CC" # Let the user override the test.
4755 else
4756   ac_prog_rejected=no
4757 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4758 for as_dir in $PATH
4759 do
4760   IFS=$as_save_IFS
4761   test -z "$as_dir" && as_dir=.
4762     for ac_exec_ext in '' $ac_executable_extensions; do
4763   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4764     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4765        ac_prog_rejected=yes
4766        continue
4767      fi
4768     ac_cv_prog_CC="cc"
4769     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4770     break 2
4771   fi
4772 done
4773   done
4774 IFS=$as_save_IFS
4775
4776 if test $ac_prog_rejected = yes; then
4777   # We found a bogon in the path, so make sure we never use it.
4778   set dummy $ac_cv_prog_CC
4779   shift
4780   if test $# != 0; then
4781     # We chose a different compiler from the bogus one.
4782     # However, it has the same basename, so the bogon will be chosen
4783     # first if we set CC to just the basename; use the full file name.
4784     shift
4785     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4786   fi
4787 fi
4788 fi
4789 fi
4790 CC=$ac_cv_prog_CC
4791 if test -n "$CC"; then
4792   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4793 $as_echo "$CC" >&6; }
4794 else
4795   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4796 $as_echo "no" >&6; }
4797 fi
4798
4799
4800 fi
4801 if test -z "$CC"; then
4802   if test -n "$ac_tool_prefix"; then
4803   for ac_prog in cl.exe
4804   do
4805     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4806 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4808 $as_echo_n "checking for $ac_word... " >&6; }
4809 if ${ac_cv_prog_CC+:} false; then :
4810   $as_echo_n "(cached) " >&6
4811 else
4812   if test -n "$CC"; then
4813   ac_cv_prog_CC="$CC" # Let the user override the test.
4814 else
4815 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4816 for as_dir in $PATH
4817 do
4818   IFS=$as_save_IFS
4819   test -z "$as_dir" && as_dir=.
4820     for ac_exec_ext in '' $ac_executable_extensions; do
4821   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4822     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4823     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4824     break 2
4825   fi
4826 done
4827   done
4828 IFS=$as_save_IFS
4829
4830 fi
4831 fi
4832 CC=$ac_cv_prog_CC
4833 if test -n "$CC"; then
4834   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4835 $as_echo "$CC" >&6; }
4836 else
4837   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4838 $as_echo "no" >&6; }
4839 fi
4840
4841
4842     test -n "$CC" && break
4843   done
4844 fi
4845 if test -z "$CC"; then
4846   ac_ct_CC=$CC
4847   for ac_prog in cl.exe
4848 do
4849   # Extract the first word of "$ac_prog", so it can be a program name with args.
4850 set dummy $ac_prog; ac_word=$2
4851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4852 $as_echo_n "checking for $ac_word... " >&6; }
4853 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4854   $as_echo_n "(cached) " >&6
4855 else
4856   if test -n "$ac_ct_CC"; then
4857   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4858 else
4859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4860 for as_dir in $PATH
4861 do
4862   IFS=$as_save_IFS
4863   test -z "$as_dir" && as_dir=.
4864     for ac_exec_ext in '' $ac_executable_extensions; do
4865   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4866     ac_cv_prog_ac_ct_CC="$ac_prog"
4867     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4868     break 2
4869   fi
4870 done
4871   done
4872 IFS=$as_save_IFS
4873
4874 fi
4875 fi
4876 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4877 if test -n "$ac_ct_CC"; then
4878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4879 $as_echo "$ac_ct_CC" >&6; }
4880 else
4881   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4882 $as_echo "no" >&6; }
4883 fi
4884
4885
4886   test -n "$ac_ct_CC" && break
4887 done
4888
4889   if test "x$ac_ct_CC" = x; then
4890     CC=""
4891   else
4892     case $cross_compiling:$ac_tool_warned in
4893 yes:)
4894 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4895 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4896 ac_tool_warned=yes ;;
4897 esac
4898     CC=$ac_ct_CC
4899   fi
4900 fi
4901
4902 fi
4903
4904
4905 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4906 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4907 as_fn_error $? "no acceptable C compiler found in \$PATH
4908 See \`config.log' for more details" "$LINENO" 5; }
4909
4910 # Provide some information about the compiler.
4911 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4912 set X $ac_compile
4913 ac_compiler=$2
4914 for ac_option in --version -v -V -qversion; do
4915   { { ac_try="$ac_compiler $ac_option >&5"
4916 case "(($ac_try" in
4917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4918   *) ac_try_echo=$ac_try;;
4919 esac
4920 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4921 $as_echo "$ac_try_echo"; } >&5
4922   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4923   ac_status=$?
4924   if test -s conftest.err; then
4925     sed '10a\
4926 ... rest of stderr output deleted ...
4927          10q' conftest.err >conftest.er1
4928     cat conftest.er1 >&5
4929   fi
4930   rm -f conftest.er1 conftest.err
4931   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4932   test $ac_status = 0; }
4933 done
4934
4935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4936 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4937 if ${ac_cv_c_compiler_gnu+:} false; then :
4938   $as_echo_n "(cached) " >&6
4939 else
4940   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4941 /* end confdefs.h.  */
4942
4943 int
4944 main ()
4945 {
4946 #ifndef __GNUC__
4947        choke me
4948 #endif
4949
4950   ;
4951   return 0;
4952 }
4953 _ACEOF
4954 if ac_fn_c_try_compile "$LINENO"; then :
4955   ac_compiler_gnu=yes
4956 else
4957   ac_compiler_gnu=no
4958 fi
4959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4960 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4961
4962 fi
4963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4964 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4965 if test $ac_compiler_gnu = yes; then
4966   GCC=yes
4967 else
4968   GCC=
4969 fi
4970 ac_test_CFLAGS=${CFLAGS+set}
4971 ac_save_CFLAGS=$CFLAGS
4972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4973 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4974 if ${ac_cv_prog_cc_g+:} false; then :
4975   $as_echo_n "(cached) " >&6
4976 else
4977   ac_save_c_werror_flag=$ac_c_werror_flag
4978    ac_c_werror_flag=yes
4979    ac_cv_prog_cc_g=no
4980    CFLAGS="-g"
4981    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4982 /* end confdefs.h.  */
4983
4984 int
4985 main ()
4986 {
4987
4988   ;
4989   return 0;
4990 }
4991 _ACEOF
4992 if ac_fn_c_try_compile "$LINENO"; then :
4993   ac_cv_prog_cc_g=yes
4994 else
4995   CFLAGS=""
4996       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4997 /* end confdefs.h.  */
4998
4999 int
5000 main ()
5001 {
5002
5003   ;
5004   return 0;
5005 }
5006 _ACEOF
5007 if ac_fn_c_try_compile "$LINENO"; then :
5008
5009 else
5010   ac_c_werror_flag=$ac_save_c_werror_flag
5011          CFLAGS="-g"
5012          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5013 /* end confdefs.h.  */
5014
5015 int
5016 main ()
5017 {
5018
5019   ;
5020   return 0;
5021 }
5022 _ACEOF
5023 if ac_fn_c_try_compile "$LINENO"; then :
5024   ac_cv_prog_cc_g=yes
5025 fi
5026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5027 fi
5028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5029 fi
5030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5031    ac_c_werror_flag=$ac_save_c_werror_flag
5032 fi
5033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5034 $as_echo "$ac_cv_prog_cc_g" >&6; }
5035 if test "$ac_test_CFLAGS" = set; then
5036   CFLAGS=$ac_save_CFLAGS
5037 elif test $ac_cv_prog_cc_g = yes; then
5038   if test "$GCC" = yes; then
5039     CFLAGS="-g -O2"
5040   else
5041     CFLAGS="-g"
5042   fi
5043 else
5044   if test "$GCC" = yes; then
5045     CFLAGS="-O2"
5046   else
5047     CFLAGS=
5048   fi
5049 fi
5050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5051 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5052 if ${ac_cv_prog_cc_c89+:} false; then :
5053   $as_echo_n "(cached) " >&6
5054 else
5055   ac_cv_prog_cc_c89=no
5056 ac_save_CC=$CC
5057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5058 /* end confdefs.h.  */
5059 #include <stdarg.h>
5060 #include <stdio.h>
5061 struct stat;
5062 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5063 struct buf { int x; };
5064 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5065 static char *e (p, i)
5066      char **p;
5067      int i;
5068 {
5069   return p[i];
5070 }
5071 static char *f (char * (*g) (char **, int), char **p, ...)
5072 {
5073   char *s;
5074   va_list v;
5075   va_start (v,p);
5076   s = g (p, va_arg (v,int));
5077   va_end (v);
5078   return s;
5079 }
5080
5081 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5082    function prototypes and stuff, but not '\xHH' hex character constants.
5083    These don't provoke an error unfortunately, instead are silently treated
5084    as 'x'.  The following induces an error, until -std is added to get
5085    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5086    array size at least.  It's necessary to write '\x00'==0 to get something
5087    that's true only with -std.  */
5088 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5089
5090 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5091    inside strings and character constants.  */
5092 #define FOO(x) 'x'
5093 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5094
5095 int test (int i, double x);
5096 struct s1 {int (*f) (int a);};
5097 struct s2 {int (*f) (double a);};
5098 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5099 int argc;
5100 char **argv;
5101 int
5102 main ()
5103 {
5104 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5105   ;
5106   return 0;
5107 }
5108 _ACEOF
5109 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5110         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5111 do
5112   CC="$ac_save_CC $ac_arg"
5113   if ac_fn_c_try_compile "$LINENO"; then :
5114   ac_cv_prog_cc_c89=$ac_arg
5115 fi
5116 rm -f core conftest.err conftest.$ac_objext
5117   test "x$ac_cv_prog_cc_c89" != "xno" && break
5118 done
5119 rm -f conftest.$ac_ext
5120 CC=$ac_save_CC
5121
5122 fi
5123 # AC_CACHE_VAL
5124 case "x$ac_cv_prog_cc_c89" in
5125   x)
5126     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5127 $as_echo "none needed" >&6; } ;;
5128   xno)
5129     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5130 $as_echo "unsupported" >&6; } ;;
5131   *)
5132     CC="$CC $ac_cv_prog_cc_c89"
5133     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5134 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5135 esac
5136 if test "x$ac_cv_prog_cc_c89" != xno; then :
5137
5138 fi
5139
5140 ac_ext=c
5141 ac_cpp='$CPP $CPPFLAGS'
5142 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5143 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5144 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5145
5146
5147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $CC dependency flag" >&5
5148 $as_echo_n "checking $CC dependency flag... " >&6; }
5149 echo 'void f(void){}' >conftest.c
5150 if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5151         DEPFLAG="-MM"
5152 else
5153   if test "`$CC -xM1 conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5154         DEPFLAG="-xM1"
5155   else
5156         DEPFLAG="-MM"  # dunno do something
5157   fi
5158 fi
5159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEPFLAG" >&5
5160 $as_echo "$DEPFLAG" >&6; }
5161 rm -f conftest.c
5162
5163
5164
5165
5166
5167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Werror" >&5
5168 $as_echo_n "checking whether $CC supports -Werror... " >&6; }
5169 cache=`echo Werror | sed 'y%.=/+-%___p_%'`
5170 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5171   $as_echo_n "(cached) " >&6
5172 else
5173
5174 echo 'void f(void){}' >conftest.c
5175 if test -z "`$CC $CPPFLAGS $CFLAGS -Werror -c conftest.c 2>&1`"; then
5176 eval "cv_prog_cc_flag_$cache=yes"
5177 else
5178 eval "cv_prog_cc_flag_$cache=no"
5179 fi
5180 rm -f conftest conftest.o conftest.c
5181
5182 fi
5183
5184 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5186 $as_echo "yes" >&6; }
5187 :
5188 ERRFLAG="-Werror"
5189 else
5190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5191 $as_echo "no" >&6; }
5192 :
5193 ERRFLAG="-errwarn"
5194 fi
5195
5196
5197
5198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5199 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5200 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5201 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5202   $as_echo_n "(cached) " >&6
5203 else
5204
5205 echo 'void f(void){}' >conftest.c
5206 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5207 eval "cv_prog_cc_flag_$cache=yes"
5208 else
5209 eval "cv_prog_cc_flag_$cache=no"
5210 fi
5211 rm -f conftest conftest.o conftest.c
5212
5213 fi
5214
5215 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5217 $as_echo "yes" >&6; }
5218 :
5219 ERRFLAG="$ERRFLAG -Wall"
5220 else
5221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5222 $as_echo "no" >&6; }
5223 :
5224 ERRFLAG="$ERRFLAG -errfmt"
5225 fi
5226
5227
5228
5229
5230
5231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -std=c99" >&5
5232 $as_echo_n "checking whether $CC supports -std=c99... " >&6; }
5233 cache=`echo std=c99 | sed 'y%.=/+-%___p_%'`
5234 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5235   $as_echo_n "(cached) " >&6
5236 else
5237
5238 echo 'void f(void){}' >conftest.c
5239 if test -z "`$CC $CPPFLAGS $CFLAGS -std=c99 -c conftest.c 2>&1`"; then
5240 eval "cv_prog_cc_flag_$cache=yes"
5241 else
5242 eval "cv_prog_cc_flag_$cache=no"
5243 fi
5244 rm -f conftest conftest.o conftest.c
5245
5246 fi
5247
5248 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5250 $as_echo "yes" >&6; }
5251 :
5252 C99FLAG="-std=c99"
5253 else
5254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5255 $as_echo "no" >&6; }
5256 :
5257
5258 fi
5259
5260
5261
5262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -xc99" >&5
5263 $as_echo_n "checking whether $CC supports -xc99... " >&6; }
5264 cache=`echo xc99 | sed 'y%.=/+-%___p_%'`
5265 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5266   $as_echo_n "(cached) " >&6
5267 else
5268
5269 echo 'void f(void){}' >conftest.c
5270 if test -z "`$CC $CPPFLAGS $CFLAGS -xc99 -c conftest.c 2>&1`"; then
5271 eval "cv_prog_cc_flag_$cache=yes"
5272 else
5273 eval "cv_prog_cc_flag_$cache=no"
5274 fi
5275 rm -f conftest conftest.o conftest.c
5276
5277 fi
5278
5279 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5281 $as_echo "yes" >&6; }
5282 :
5283 C99FLAG="-xc99"
5284 else
5285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5286 $as_echo "no" >&6; }
5287 :
5288
5289 fi
5290
5291
5292 for ac_header in getopt.h time.h
5293 do :
5294   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5295 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5296 "
5297 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5298   cat >>confdefs.h <<_ACEOF
5299 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5300 _ACEOF
5301
5302 fi
5303
5304 done
5305
5306
5307
5308
5309
5310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE as a flag for $CC" >&5
5311 $as_echo_n "checking whether we need $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE as a flag for $CC... " >&6; }
5312 cache=`$as_echo "$C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE" | $as_tr_sh`
5313 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5314   $as_echo_n "(cached) " >&6
5315 else
5316
5317 echo '
5318 #include "confdefs.h"
5319 #include <stdlib.h>
5320 #include <ctype.h>
5321 #include <sys/time.h>
5322 #ifdef HAVE_TIME_H
5323 #include <time.h>
5324 #endif
5325 #include <unistd.h>
5326 #include <netdb.h>
5327 #ifdef HAVE_GETOPT_H
5328 #include <getopt.h>
5329 #endif
5330
5331 int test(void) {
5332         int a;
5333         char **opts = NULL;
5334         struct timeval tv;
5335         char *t;
5336         time_t time = 0;
5337         char *buf = NULL;
5338         const char* str = NULL;
5339         struct msghdr msg;
5340         msg.msg_control = 0;
5341         t = ctime_r(&time, buf);
5342         tv.tv_usec = 10;
5343         srandom(32);
5344         a = getopt(2, opts, "a");
5345         a = isascii(32);
5346         str = gai_strerror(0);
5347         if(str && t && tv.tv_usec && msg.msg_control)
5348                 a = 0;
5349         return a;
5350 }
5351 ' > conftest.c
5352 echo 'void f(void){}' >>conftest.c
5353 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5354 eval "cv_prog_cc_flag_needed_$cache=no"
5355 else
5356
5357 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5358 eval "cv_prog_cc_flag_needed_$cache=yes"
5359 else
5360 eval "cv_prog_cc_flag_needed_$cache=fail"
5361 #echo 'Test with flag fails too!'
5362 #cat conftest.c
5363 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1"
5364 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`
5365 #exit 1
5366 fi
5367
5368 fi
5369 rm -f conftest conftest.c conftest.o
5370
5371 fi
5372
5373 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5375 $as_echo "yes" >&6; }
5376 :
5377 CFLAGS="$CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE"
5378 else
5379 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5381 $as_echo "no" >&6; }
5382 #echo 'Test with flag is no!'
5383 #cat conftest.c
5384 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1"
5385 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_XOPEN_SOURCE_EXTENDED=1 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`
5386 #exit 1
5387 :
5388
5389 else
5390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5391 $as_echo "failed" >&6; }
5392 :
5393
5394 fi
5395 fi
5396
5397
5398
5399
5400
5401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE as a flag for $CC" >&5
5402 $as_echo_n "checking whether we need $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE as a flag for $CC... " >&6; }
5403 cache=`$as_echo "$C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE" | $as_tr_sh`
5404 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5405   $as_echo_n "(cached) " >&6
5406 else
5407
5408 echo '
5409 #include "confdefs.h"
5410 #include <stdlib.h>
5411 #include <ctype.h>
5412 #include <sys/time.h>
5413 #ifdef HAVE_TIME_H
5414 #include <time.h>
5415 #endif
5416 #include <unistd.h>
5417 #include <netdb.h>
5418 #ifdef HAVE_GETOPT_H
5419 #include <getopt.h>
5420 #endif
5421
5422 int test(void) {
5423         int a;
5424         char **opts = NULL;
5425         struct timeval tv;
5426         char *t;
5427         time_t time = 0;
5428         char *buf = NULL;
5429         const char* str = NULL;
5430         struct msghdr msg;
5431         msg.msg_control = 0;
5432         t = ctime_r(&time, buf);
5433         tv.tv_usec = 10;
5434         srandom(32);
5435         a = getopt(2, opts, "a");
5436         a = isascii(32);
5437         str = gai_strerror(0);
5438         if(str && t && tv.tv_usec && msg.msg_control)
5439                 a = 0;
5440         return a;
5441 }
5442 ' > conftest.c
5443 echo 'void f(void){}' >>conftest.c
5444 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5445 eval "cv_prog_cc_flag_needed_$cache=no"
5446 else
5447
5448 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5449 eval "cv_prog_cc_flag_needed_$cache=yes"
5450 else
5451 eval "cv_prog_cc_flag_needed_$cache=fail"
5452 #echo 'Test with flag fails too!'
5453 #cat conftest.c
5454 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1"
5455 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`
5456 #exit 1
5457 fi
5458
5459 fi
5460 rm -f conftest conftest.c conftest.o
5461
5462 fi
5463
5464 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5466 $as_echo "yes" >&6; }
5467 :
5468 CFLAGS="$CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE"
5469 else
5470 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5472 $as_echo "no" >&6; }
5473 #echo 'Test with flag is no!'
5474 #cat conftest.c
5475 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1"
5476 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE $ERRFLAG -c conftest.c 2>&1`
5477 #exit 1
5478 :
5479
5480 else
5481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5482 $as_echo "failed" >&6; }
5483 :
5484
5485 fi
5486 fi
5487
5488
5489
5490
5491
5492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG as a flag for $CC" >&5
5493 $as_echo_n "checking whether we need $C99FLAG as a flag for $CC... " >&6; }
5494 cache=`$as_echo "$C99FLAG" | $as_tr_sh`
5495 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5496   $as_echo_n "(cached) " >&6
5497 else
5498
5499 echo '
5500 #include <stdbool.h>
5501 #include <ctype.h>
5502 int test(void) {
5503         int a = 0;
5504         return a;
5505 }
5506 ' > conftest.c
5507 echo 'void f(void){}' >>conftest.c
5508 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5509 eval "cv_prog_cc_flag_needed_$cache=no"
5510 else
5511
5512 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`"; then
5513 eval "cv_prog_cc_flag_needed_$cache=yes"
5514 else
5515 eval "cv_prog_cc_flag_needed_$cache=fail"
5516 #echo 'Test with flag fails too!'
5517 #cat conftest.c
5518 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5519 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5520 #exit 1
5521 fi
5522
5523 fi
5524 rm -f conftest conftest.c conftest.o
5525
5526 fi
5527
5528 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5530 $as_echo "yes" >&6; }
5531 :
5532 CFLAGS="$CFLAGS $C99FLAG"
5533 else
5534 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5536 $as_echo "no" >&6; }
5537 #echo 'Test with flag is no!'
5538 #cat conftest.c
5539 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5540 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5541 #exit 1
5542 :
5543
5544 else
5545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5546 $as_echo "failed" >&6; }
5547 :
5548
5549 fi
5550 fi
5551
5552
5553
5554
5555
5556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC" >&5
5557 $as_echo_n "checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC... " >&6; }
5558 cache=_D_BSD_SOURCE__D_DEFAULT_SOURCE
5559 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5560   $as_echo_n "(cached) " >&6
5561 else
5562
5563 echo '
5564 #include <ctype.h>
5565
5566 int test(void) {
5567         int a;
5568         a = isascii(32);
5569         return a;
5570 }
5571 ' > conftest.c
5572 echo 'void f(void){}' >>conftest.c
5573 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5574 eval "cv_prog_cc_flag_needed_$cache=no"
5575 else
5576
5577 if test -z "`$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5578 eval "cv_prog_cc_flag_needed_$cache=yes"
5579 else
5580 eval "cv_prog_cc_flag_needed_$cache=fail"
5581 #echo 'Test with flag fails too!'
5582 #cat conftest.c
5583 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5584 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5585 #exit 1
5586 fi
5587
5588 fi
5589 rm -f conftest conftest.c conftest.o
5590
5591 fi
5592
5593 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5595 $as_echo "yes" >&6; }
5596 :
5597 CFLAGS="$CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE"
5598 else
5599 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5601 $as_echo "no" >&6; }
5602 #echo 'Test with flag is no!'
5603 #cat conftest.c
5604 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5605 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5606 #exit 1
5607 :
5608
5609 else
5610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5611 $as_echo "failed" >&6; }
5612 :
5613
5614 fi
5615 fi
5616
5617
5618
5619
5620
5621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE as a flag for $CC" >&5
5622 $as_echo_n "checking whether we need -D_GNU_SOURCE as a flag for $CC... " >&6; }
5623 cache=_D_GNU_SOURCE
5624 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5625   $as_echo_n "(cached) " >&6
5626 else
5627
5628 echo '
5629 #include <netinet/in.h>
5630
5631 int test(void) {
5632         struct in6_pktinfo inf;
5633         int a = (int)sizeof(inf);
5634         return a;
5635 }
5636 ' > conftest.c
5637 echo 'void f(void){}' >>conftest.c
5638 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5639 eval "cv_prog_cc_flag_needed_$cache=no"
5640 else
5641
5642 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5643 eval "cv_prog_cc_flag_needed_$cache=yes"
5644 else
5645 eval "cv_prog_cc_flag_needed_$cache=fail"
5646 #echo 'Test with flag fails too!'
5647 #cat conftest.c
5648 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5649 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5650 #exit 1
5651 fi
5652
5653 fi
5654 rm -f conftest conftest.c conftest.o
5655
5656 fi
5657
5658 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5660 $as_echo "yes" >&6; }
5661 :
5662 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5663 else
5664 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5666 $as_echo "no" >&6; }
5667 #echo 'Test with flag is no!'
5668 #cat conftest.c
5669 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5670 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5671 #exit 1
5672 :
5673
5674 else
5675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5676 $as_echo "failed" >&6; }
5677 :
5678
5679 fi
5680 fi
5681
5682
5683 # check again for GNU_SOURCE for setresgid. May fail if setresgid
5684 # is not available at all. -D_FRSRESGID is to make this check unique.
5685 # otherwise we would get the previous cached result.
5686
5687
5688
5689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC" >&5
5690 $as_echo_n "checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC... " >&6; }
5691 cache=_D_GNU_SOURCE__D_FRSRESGID
5692 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5693   $as_echo_n "(cached) " >&6
5694 else
5695
5696 echo '
5697 #include <unistd.h>
5698
5699 int test(void) {
5700         int a = setresgid(0,0,0);
5701         a = setresuid(0,0,0);
5702         return a;
5703 }
5704 ' > conftest.c
5705 echo 'void f(void){}' >>conftest.c
5706 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5707 eval "cv_prog_cc_flag_needed_$cache=no"
5708 else
5709
5710 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`"; then
5711 eval "cv_prog_cc_flag_needed_$cache=yes"
5712 else
5713 eval "cv_prog_cc_flag_needed_$cache=fail"
5714 #echo 'Test with flag fails too!'
5715 #cat conftest.c
5716 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5717 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5718 #exit 1
5719 fi
5720
5721 fi
5722 rm -f conftest conftest.c conftest.o
5723
5724 fi
5725
5726 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5728 $as_echo "yes" >&6; }
5729 :
5730 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5731 else
5732 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5734 $as_echo "no" >&6; }
5735 #echo 'Test with flag is no!'
5736 #cat conftest.c
5737 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5738 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5739 #exit 1
5740 :
5741
5742 else
5743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5744 $as_echo "failed" >&6; }
5745 :
5746
5747 fi
5748 fi
5749
5750
5751
5752
5753
5754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC" >&5
5755 $as_echo_n "checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC... " >&6; }
5756 cache=_D_POSIX_C_SOURCE_200112
5757 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5758   $as_echo_n "(cached) " >&6
5759 else
5760
5761 echo '
5762 #include "confdefs.h"
5763 #ifdef HAVE_TIME_H
5764 #include <time.h>
5765 #endif
5766 #include <netdb.h>
5767
5768 int test(void) {
5769         int a = 0;
5770         char *t;
5771         time_t time = 0;
5772         char *buf = NULL;
5773         const char* str = NULL;
5774         t = ctime_r(&time, buf);
5775         str = gai_strerror(0);
5776         if(t && str)
5777                 a = 0;
5778         return a;
5779 }
5780 ' > conftest.c
5781 echo 'void f(void){}' >>conftest.c
5782 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5783 eval "cv_prog_cc_flag_needed_$cache=no"
5784 else
5785
5786 if test -z "`$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`"; then
5787 eval "cv_prog_cc_flag_needed_$cache=yes"
5788 else
5789 eval "cv_prog_cc_flag_needed_$cache=fail"
5790 #echo 'Test with flag fails too!'
5791 #cat conftest.c
5792 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5793 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5794 #exit 1
5795 fi
5796
5797 fi
5798 rm -f conftest conftest.c conftest.o
5799
5800 fi
5801
5802 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5804 $as_echo "yes" >&6; }
5805 :
5806 CFLAGS="$CFLAGS -D_POSIX_C_SOURCE=200112"
5807 else
5808 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5810 $as_echo "no" >&6; }
5811 #echo 'Test with flag is no!'
5812 #cat conftest.c
5813 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5814 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5815 #exit 1
5816 :
5817
5818 else
5819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5820 $as_echo "failed" >&6; }
5821 :
5822
5823 fi
5824 fi
5825
5826
5827
5828
5829
5830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D__EXTENSIONS__ as a flag for $CC" >&5
5831 $as_echo_n "checking whether we need -D__EXTENSIONS__ as a flag for $CC... " >&6; }
5832 cache=_D__EXTENSIONS__
5833 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5834   $as_echo_n "(cached) " >&6
5835 else
5836
5837 echo '
5838 #include "confdefs.h"
5839 #include <stdlib.h>
5840 #include <ctype.h>
5841 #include <sys/time.h>
5842 #ifdef HAVE_TIME_H
5843 #include <time.h>
5844 #endif
5845 #include <unistd.h>
5846 #ifdef HAVE_GETOPT_H
5847 #include <getopt.h>
5848 #endif
5849
5850 int test(void) {
5851         int a;
5852         char **opts = NULL;
5853         struct timeval tv;
5854         tv.tv_usec = 10;
5855         srandom(32);
5856         a = getopt(2, opts, "a");
5857         a = isascii(32);
5858         if(tv.tv_usec)
5859                 a = 0;
5860         return a;
5861 }
5862 ' > conftest.c
5863 echo 'void f(void){}' >>conftest.c
5864 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5865 eval "cv_prog_cc_flag_needed_$cache=no"
5866 else
5867
5868 if test -z "`$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`"; then
5869 eval "cv_prog_cc_flag_needed_$cache=yes"
5870 else
5871 eval "cv_prog_cc_flag_needed_$cache=fail"
5872 #echo 'Test with flag fails too!'
5873 #cat conftest.c
5874 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5875 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5876 #exit 1
5877 fi
5878
5879 fi
5880 rm -f conftest conftest.c conftest.o
5881
5882 fi
5883
5884 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5886 $as_echo "yes" >&6; }
5887 :
5888 CFLAGS="$CFLAGS -D__EXTENSIONS__"
5889 else
5890 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5892 $as_echo "no" >&6; }
5893 #echo 'Test with flag is no!'
5894 #cat conftest.c
5895 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5896 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5897 #exit 1
5898 :
5899
5900 else
5901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5902 $as_echo "failed" >&6; }
5903 :
5904
5905 fi
5906 fi
5907
5908
5909
5910
5911 # debug mode flags warnings
5912 # Check whether --enable-checking was given.
5913 if test "${enable_checking+set}" = set; then :
5914   enableval=$enable_checking;
5915 fi
5916
5917 # Check whether --enable-debug was given.
5918 if test "${enable_debug+set}" = set; then :
5919   enableval=$enable_debug;
5920 fi
5921
5922 if test "$enable_debug" = "yes"; then debug_enabled="$enable_debug";
5923 else debug_enabled="$enable_checking"; fi
5924
5925 case "$debug_enabled" in
5926         yes)
5927
5928
5929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -W" >&5
5930 $as_echo_n "checking whether $CC supports -W... " >&6; }
5931 cache=`echo W | sed 'y%.=/+-%___p_%'`
5932 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5933   $as_echo_n "(cached) " >&6
5934 else
5935
5936 echo 'void f(void){}' >conftest.c
5937 if test -z "`$CC $CPPFLAGS $CFLAGS -W -c conftest.c 2>&1`"; then
5938 eval "cv_prog_cc_flag_$cache=yes"
5939 else
5940 eval "cv_prog_cc_flag_$cache=no"
5941 fi
5942 rm -f conftest conftest.o conftest.c
5943
5944 fi
5945
5946 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5948 $as_echo "yes" >&6; }
5949 :
5950 CFLAGS="$CFLAGS -W"
5951 else
5952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5953 $as_echo "no" >&6; }
5954 :
5955
5956 fi
5957
5958
5959
5960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5961 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5962 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5963 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5964   $as_echo_n "(cached) " >&6
5965 else
5966
5967 echo 'void f(void){}' >conftest.c
5968 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5969 eval "cv_prog_cc_flag_$cache=yes"
5970 else
5971 eval "cv_prog_cc_flag_$cache=no"
5972 fi
5973 rm -f conftest conftest.o conftest.c
5974
5975 fi
5976
5977 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5979 $as_echo "yes" >&6; }
5980 :
5981 CFLAGS="$CFLAGS -Wall"
5982 else
5983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5984 $as_echo "no" >&6; }
5985 :
5986
5987 fi
5988
5989
5990
5991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wextra" >&5
5992 $as_echo_n "checking whether $CC supports -Wextra... " >&6; }
5993 cache=`echo Wextra | sed 'y%.=/+-%___p_%'`
5994 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5995   $as_echo_n "(cached) " >&6
5996 else
5997
5998 echo 'void f(void){}' >conftest.c
5999 if test -z "`$CC $CPPFLAGS $CFLAGS -Wextra -c conftest.c 2>&1`"; then
6000 eval "cv_prog_cc_flag_$cache=yes"
6001 else
6002 eval "cv_prog_cc_flag_$cache=no"
6003 fi
6004 rm -f conftest conftest.o conftest.c
6005
6006 fi
6007
6008 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
6009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6010 $as_echo "yes" >&6; }
6011 :
6012 CFLAGS="$CFLAGS -Wextra"
6013 else
6014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6015 $as_echo "no" >&6; }
6016 :
6017
6018 fi
6019
6020
6021
6022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wdeclaration-after-statement" >&5
6023 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
6024 cache=`echo Wdeclaration-after-statement | sed 'y%.=/+-%___p_%'`
6025 if eval \${cv_prog_cc_flag_$cache+:} false; then :
6026   $as_echo_n "(cached) " >&6
6027 else
6028
6029 echo 'void f(void){}' >conftest.c
6030 if test -z "`$CC $CPPFLAGS $CFLAGS -Wdeclaration-after-statement -c conftest.c 2>&1`"; then
6031 eval "cv_prog_cc_flag_$cache=yes"
6032 else
6033 eval "cv_prog_cc_flag_$cache=no"
6034 fi
6035 rm -f conftest conftest.o conftest.c
6036
6037 fi
6038
6039 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
6040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6041 $as_echo "yes" >&6; }
6042 :
6043 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
6044 else
6045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6046 $as_echo "no" >&6; }
6047 :
6048
6049 fi
6050
6051
6052 $as_echo "#define UNBOUND_DEBUG /**/" >>confdefs.h
6053
6054                 ;;
6055         no|*)
6056                 # nothing to do.
6057                 ;;
6058 esac
6059 if test "$default_cflags" = "yes"; then
6060         # only when CFLAGS was "" at the start, if the users wants to
6061         # override we shouldn't add default cflags, because they wouldn't
6062         # be able to turn off these options and set the CFLAGS wanted.
6063
6064     # Check whether --enable-flto was given.
6065 if test "${enable_flto+set}" = set; then :
6066   enableval=$enable_flto;
6067 fi
6068
6069     if test "x$enable_flto" != "xno"; then :
6070
6071         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -flto" >&5
6072 $as_echo_n "checking if $CC supports -flto... " >&6; }
6073         BAKCFLAGS="$CFLAGS"
6074         CFLAGS="$CFLAGS -flto"
6075         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6076 /* end confdefs.h.  */
6077
6078 int
6079 main ()
6080 {
6081
6082   ;
6083   return 0;
6084 }
6085 _ACEOF
6086 if ac_fn_c_try_link "$LINENO"; then :
6087
6088             if $CC $CFLAGS -o conftest conftest.c 2>&1 | $GREP -e "warning: no debug symbols in executable" -e "warning: object" >/dev/null; then
6089                 CFLAGS="$BAKCFLAGS"
6090                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6091 $as_echo "no" >&6; }
6092             else
6093                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6094 $as_echo "yes" >&6; }
6095             fi
6096             rm -f conftest conftest.c conftest.o
6097
6098 else
6099   CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6100 $as_echo "no" >&6; }
6101 fi
6102 rm -f core conftest.err conftest.$ac_objext \
6103     conftest$ac_exeext conftest.$ac_ext
6104
6105 fi
6106
6107
6108     # Check whether --enable-pie was given.
6109 if test "${enable_pie+set}" = set; then :
6110   enableval=$enable_pie;
6111 fi
6112
6113     if test "x$enable_pie" = "xyes"; then :
6114
6115         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports PIE" >&5
6116 $as_echo_n "checking if $CC supports PIE... " >&6; }
6117         BAKLDFLAGS="$LDFLAGS"
6118         BAKCFLAGS="$CFLAGS"
6119         LDFLAGS="$LDFLAGS -pie"
6120         CFLAGS="$CFLAGS -fPIE"
6121         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6122 /* end confdefs.h.  */
6123
6124 int
6125 main ()
6126 {
6127
6128   ;
6129   return 0;
6130 }
6131 _ACEOF
6132 if ac_fn_c_try_link "$LINENO"; then :
6133
6134             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6135                 LDFLAGS="$BAKLDFLAGS"
6136                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6137 $as_echo "no" >&6; }
6138             else
6139                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6140 $as_echo "yes" >&6; }
6141             fi
6142             rm -f conftest conftest.c conftest.o
6143
6144 else
6145   LDFLAGS="$BAKLDFLAGS" ; CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6146 $as_echo "no" >&6; }
6147 fi
6148 rm -f core conftest.err conftest.$ac_objext \
6149     conftest$ac_exeext conftest.$ac_ext
6150
6151 fi
6152
6153
6154     # Check whether --enable-relro_now was given.
6155 if test "${enable_relro_now+set}" = set; then :
6156   enableval=$enable_relro_now;
6157 fi
6158
6159     if test "x$enable_relro_now" = "xyes"; then :
6160
6161         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wl,-z,relro,-z,now" >&5
6162 $as_echo_n "checking if $CC supports -Wl,-z,relro,-z,now... " >&6; }
6163         BAKLDFLAGS="$LDFLAGS"
6164         LDFLAGS="$LDFLAGS -Wl,-z,relro,-z,now"
6165         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6166 /* end confdefs.h.  */
6167
6168 int
6169 main ()
6170 {
6171
6172   ;
6173   return 0;
6174 }
6175 _ACEOF
6176 if ac_fn_c_try_link "$LINENO"; then :
6177
6178             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6179                 LDFLAGS="$BAKLDFLAGS"
6180                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6181 $as_echo "no" >&6; }
6182             else
6183                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6184 $as_echo "yes" >&6; }
6185             fi
6186             rm -f conftest conftest.c conftest.o
6187
6188 else
6189   LDFLAGS="$BAKLDFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6190 $as_echo "no" >&6; }
6191 fi
6192 rm -f core conftest.err conftest.$ac_objext \
6193     conftest$ac_exeext conftest.$ac_ext
6194
6195 fi
6196
6197 fi
6198
6199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
6200 $as_echo_n "checking for inline... " >&6; }
6201 if ${ac_cv_c_inline+:} false; then :
6202   $as_echo_n "(cached) " >&6
6203 else
6204   ac_cv_c_inline=no
6205 for ac_kw in inline __inline__ __inline; do
6206   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6207 /* end confdefs.h.  */
6208 #ifndef __cplusplus
6209 typedef int foo_t;
6210 static $ac_kw foo_t static_foo () {return 0; }
6211 $ac_kw foo_t foo () {return 0; }
6212 #endif
6213
6214 _ACEOF
6215 if ac_fn_c_try_compile "$LINENO"; then :
6216   ac_cv_c_inline=$ac_kw
6217 fi
6218 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6219   test "$ac_cv_c_inline" != no && break
6220 done
6221
6222 fi
6223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
6224 $as_echo "$ac_cv_c_inline" >&6; }
6225
6226 case $ac_cv_c_inline in
6227   inline | yes) ;;
6228   *)
6229     case $ac_cv_c_inline in
6230       no) ac_val=;;
6231       *) ac_val=$ac_cv_c_inline;;
6232     esac
6233     cat >>confdefs.h <<_ACEOF
6234 #ifndef __cplusplus
6235 #define inline $ac_val
6236 #endif
6237 _ACEOF
6238     ;;
6239 esac
6240
6241
6242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute" >&5
6243 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute... " >&6; }
6244 if ${ac_cv_c_format_attribute+:} false; then :
6245   $as_echo_n "(cached) " >&6
6246 else
6247   ac_cv_c_format_attribute=no
6248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6249 /* end confdefs.h.  */
6250 #include <stdio.h>
6251 void f (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6252 void (*pf) (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6253
6254 int
6255 main ()
6256 {
6257
6258    f ("%s", "str");
6259
6260   ;
6261   return 0;
6262 }
6263 _ACEOF
6264 if ac_fn_c_try_compile "$LINENO"; then :
6265   ac_cv_c_format_attribute="yes"
6266 else
6267   ac_cv_c_format_attribute="no"
6268 fi
6269 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6270
6271 fi
6272
6273
6274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_format_attribute" >&5
6275 $as_echo "$ac_cv_c_format_attribute" >&6; }
6276 if test $ac_cv_c_format_attribute = yes; then
6277
6278 $as_echo "#define HAVE_ATTR_FORMAT 1" >>confdefs.h
6279
6280 fi
6281
6282
6283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute" >&5
6284 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute... " >&6; }
6285 if ${ac_cv_c_unused_attribute+:} false; then :
6286   $as_echo_n "(cached) " >&6
6287 else
6288   ac_cv_c_unused_attribute=no
6289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6290 /* end confdefs.h.  */
6291 #include <stdio.h>
6292 void f (char *u __attribute__((unused)));
6293
6294 int
6295 main ()
6296 {
6297
6298    f ("x");
6299
6300   ;
6301   return 0;
6302 }
6303 _ACEOF
6304 if ac_fn_c_try_compile "$LINENO"; then :
6305   ac_cv_c_unused_attribute="yes"
6306 else
6307   ac_cv_c_unused_attribute="no"
6308 fi
6309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6310
6311 fi
6312
6313
6314
6315
6316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_unused_attribute" >&5
6317 $as_echo "$ac_cv_c_unused_attribute" >&6; }
6318 if test $ac_cv_c_unused_attribute = yes; then
6319
6320 $as_echo "#define HAVE_ATTR_UNUSED 1" >>confdefs.h
6321
6322 fi
6323
6324
6325
6326
6327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute" >&5
6328 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute... " >&6; }
6329 if ${ac_cv_c_weak_attribute+:} false; then :
6330   $as_echo_n "(cached) " >&6
6331 else
6332   ac_cv_c_weak_attribute=no
6333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6334 /* end confdefs.h.  */
6335  #include <stdio.h>
6336 __attribute__((weak)) void f(int x) { printf("%d", x); }
6337
6338 int
6339 main ()
6340 {
6341
6342    f(1);
6343
6344   ;
6345   return 0;
6346 }
6347 _ACEOF
6348 if ac_fn_c_try_compile "$LINENO"; then :
6349   ac_cv_c_weak_attribute="yes"
6350 else
6351   ac_cv_c_weak_attribute="no"
6352 fi
6353 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6354
6355 fi
6356
6357
6358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_weak_attribute" >&5
6359 $as_echo "$ac_cv_c_weak_attribute" >&6; }
6360 if test $ac_cv_c_weak_attribute = yes; then
6361
6362 $as_echo "#define HAVE_ATTR_WEAK 1" >>confdefs.h
6363
6364
6365 $as_echo "#define ATTR_WEAK __attribute__((weak))" >>confdefs.h
6366
6367 fi
6368
6369
6370
6371
6372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute" >&5
6373 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute... " >&6; }
6374 if ${ac_cv_c_noreturn_attribute+:} false; then :
6375   $as_echo_n "(cached) " >&6
6376 else
6377   ac_cv_c_noreturn_attribute=no
6378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6379 /* end confdefs.h.  */
6380  #include <stdio.h>
6381 __attribute__((noreturn)) void f(int x) { printf("%d", x); }
6382
6383 int
6384 main ()
6385 {
6386
6387    f(1);
6388
6389   ;
6390   return 0;
6391 }
6392 _ACEOF
6393 if ac_fn_c_try_compile "$LINENO"; then :
6394   ac_cv_c_noreturn_attribute="yes"
6395 else
6396   ac_cv_c_noreturn_attribute="no"
6397 fi
6398 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6399
6400 fi
6401
6402
6403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_noreturn_attribute" >&5
6404 $as_echo "$ac_cv_c_noreturn_attribute" >&6; }
6405 if test $ac_cv_c_noreturn_attribute = yes; then
6406
6407 $as_echo "#define HAVE_ATTR_NORETURN 1" >>confdefs.h
6408
6409
6410 $as_echo "#define ATTR_NORETURN __attribute__((__noreturn__))" >>confdefs.h
6411
6412 fi
6413
6414
6415 if test "$srcdir" != "."; then
6416         CPPFLAGS="$CPPFLAGS -I$srcdir"
6417 fi
6418
6419
6420
6421
6422
6423 for ac_prog in flex lex
6424 do
6425   # Extract the first word of "$ac_prog", so it can be a program name with args.
6426 set dummy $ac_prog; ac_word=$2
6427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6428 $as_echo_n "checking for $ac_word... " >&6; }
6429 if ${ac_cv_prog_LEX+:} false; then :
6430   $as_echo_n "(cached) " >&6
6431 else
6432   if test -n "$LEX"; then
6433   ac_cv_prog_LEX="$LEX" # Let the user override the test.
6434 else
6435 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6436 for as_dir in $PATH
6437 do
6438   IFS=$as_save_IFS
6439   test -z "$as_dir" && as_dir=.
6440     for ac_exec_ext in '' $ac_executable_extensions; do
6441   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6442     ac_cv_prog_LEX="$ac_prog"
6443     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6444     break 2
6445   fi
6446 done
6447   done
6448 IFS=$as_save_IFS
6449
6450 fi
6451 fi
6452 LEX=$ac_cv_prog_LEX
6453 if test -n "$LEX"; then
6454   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
6455 $as_echo "$LEX" >&6; }
6456 else
6457   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6458 $as_echo "no" >&6; }
6459 fi
6460
6461
6462   test -n "$LEX" && break
6463 done
6464 test -n "$LEX" || LEX=":"
6465
6466 if test "x$LEX" != "x:"; then
6467   cat >conftest.l <<_ACEOF
6468 %%
6469 a { ECHO; }
6470 b { REJECT; }
6471 c { yymore (); }
6472 d { yyless (1); }
6473 e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument.  */
6474     yyless ((input () != 0)); }
6475 f { unput (yytext[0]); }
6476 . { BEGIN INITIAL; }
6477 %%
6478 #ifdef YYTEXT_POINTER
6479 extern char *yytext;
6480 #endif
6481 int
6482 main (void)
6483 {
6484   return ! yylex () + ! yywrap ();
6485 }
6486 _ACEOF
6487 { { ac_try="$LEX conftest.l"
6488 case "(($ac_try" in
6489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6490   *) ac_try_echo=$ac_try;;
6491 esac
6492 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6493 $as_echo "$ac_try_echo"; } >&5
6494   (eval "$LEX conftest.l") 2>&5
6495   ac_status=$?
6496   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6497   test $ac_status = 0; }
6498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
6499 $as_echo_n "checking lex output file root... " >&6; }
6500 if ${ac_cv_prog_lex_root+:} false; then :
6501   $as_echo_n "(cached) " >&6
6502 else
6503
6504 if test -f lex.yy.c; then
6505   ac_cv_prog_lex_root=lex.yy
6506 elif test -f lexyy.c; then
6507   ac_cv_prog_lex_root=lexyy
6508 else
6509   as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
6510 fi
6511 fi
6512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
6513 $as_echo "$ac_cv_prog_lex_root" >&6; }
6514 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
6515
6516 if test -z "${LEXLIB+set}"; then
6517   { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
6518 $as_echo_n "checking lex library... " >&6; }
6519 if ${ac_cv_lib_lex+:} false; then :
6520   $as_echo_n "(cached) " >&6
6521 else
6522
6523     ac_save_LIBS=$LIBS
6524     ac_cv_lib_lex='none needed'
6525     for ac_lib in '' -lfl -ll; do
6526       LIBS="$ac_lib $ac_save_LIBS"
6527       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6528 /* end confdefs.h.  */
6529 `cat $LEX_OUTPUT_ROOT.c`
6530 _ACEOF
6531 if ac_fn_c_try_link "$LINENO"; then :
6532   ac_cv_lib_lex=$ac_lib
6533 fi
6534 rm -f core conftest.err conftest.$ac_objext \
6535     conftest$ac_exeext conftest.$ac_ext
6536       test "$ac_cv_lib_lex" != 'none needed' && break
6537     done
6538     LIBS=$ac_save_LIBS
6539
6540 fi
6541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
6542 $as_echo "$ac_cv_lib_lex" >&6; }
6543   test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
6544 fi
6545
6546
6547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
6548 $as_echo_n "checking whether yytext is a pointer... " >&6; }
6549 if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
6550   $as_echo_n "(cached) " >&6
6551 else
6552   # POSIX says lex can declare yytext either as a pointer or an array; the
6553 # default is implementation-dependent.  Figure out which it is, since
6554 # not all implementations provide the %pointer and %array declarations.
6555 ac_cv_prog_lex_yytext_pointer=no
6556 ac_save_LIBS=$LIBS
6557 LIBS="$LEXLIB $ac_save_LIBS"
6558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6559 /* end confdefs.h.  */
6560
6561   #define YYTEXT_POINTER 1
6562 `cat $LEX_OUTPUT_ROOT.c`
6563 _ACEOF
6564 if ac_fn_c_try_link "$LINENO"; then :
6565   ac_cv_prog_lex_yytext_pointer=yes
6566 fi
6567 rm -f core conftest.err conftest.$ac_objext \
6568     conftest$ac_exeext conftest.$ac_ext
6569 LIBS=$ac_save_LIBS
6570
6571 fi
6572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
6573 $as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
6574 if test $ac_cv_prog_lex_yytext_pointer = yes; then
6575
6576 $as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
6577
6578 fi
6579 rm -f conftest.l $LEX_OUTPUT_ROOT.c
6580
6581 fi
6582 if test "$LEX" != "" -a "$LEX" != ":"; then
6583
6584         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yylex_destroy" >&5
6585 $as_echo_n "checking for yylex_destroy... " >&6; }
6586         if echo %% | $LEX -t 2>&1 | grep yylex_destroy >/dev/null 2>&1; then
6587
6588 $as_echo "#define LEX_HAS_YYLEX_DESTROY 1" >>confdefs.h
6589
6590                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6591 $as_echo "yes" >&6; }
6592         else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6593 $as_echo "no" >&6; };
6594                 LEX=":"
6595         fi
6596
6597 fi
6598 if test "$LEX" != "" -a "$LEX" != ":"; then
6599
6600         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lex %option" >&5
6601 $as_echo_n "checking for lex %option... " >&6; }
6602         if cat <<EOF | $LEX -t 2>&1 | grep yy_delete_buffer >/dev/null 2>&1; then
6603 %option nounput
6604 %%
6605 EOF
6606                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6607 $as_echo "yes" >&6; }
6608         else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6609 $as_echo "no" >&6; };
6610                 LEX=":"
6611         fi
6612
6613 fi
6614 if test "$LEX" = "" -o "$LEX" = ":"; then
6615         if test ! -f util/configlexer.c; then
6616                 as_fn_error $? "no lex and no util/configlexer.c: need flex and bison to compile from source repository." "$LINENO" 5
6617         fi
6618 fi
6619 for ac_prog in 'bison -y' byacc
6620 do
6621   # Extract the first word of "$ac_prog", so it can be a program name with args.
6622 set dummy $ac_prog; ac_word=$2
6623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6624 $as_echo_n "checking for $ac_word... " >&6; }
6625 if ${ac_cv_prog_YACC+:} false; then :
6626   $as_echo_n "(cached) " >&6
6627 else
6628   if test -n "$YACC"; then
6629   ac_cv_prog_YACC="$YACC" # Let the user override the test.
6630 else
6631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6632 for as_dir in $PATH
6633 do
6634   IFS=$as_save_IFS
6635   test -z "$as_dir" && as_dir=.
6636     for ac_exec_ext in '' $ac_executable_extensions; do
6637   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6638     ac_cv_prog_YACC="$ac_prog"
6639     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6640     break 2
6641   fi
6642 done
6643   done
6644 IFS=$as_save_IFS
6645
6646 fi
6647 fi
6648 YACC=$ac_cv_prog_YACC
6649 if test -n "$YACC"; then
6650   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6651 $as_echo "$YACC" >&6; }
6652 else
6653   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6654 $as_echo "no" >&6; }
6655 fi
6656
6657
6658   test -n "$YACC" && break
6659 done
6660 test -n "$YACC" || YACC="yacc"
6661
6662 if test "$YACC" = "" -o "$YACC" = ":"; then
6663         if test ! -f util/configparser.c; then
6664                 as_fn_error $? "no yacc and no util/configparser.c: need flex and bison to compile from source repository." "$LINENO" 5
6665         fi
6666 fi
6667 # Extract the first word of "doxygen", so it can be a program name with args.
6668 set dummy doxygen; ac_word=$2
6669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6670 $as_echo_n "checking for $ac_word... " >&6; }
6671 if ${ac_cv_prog_doxygen+:} false; then :
6672   $as_echo_n "(cached) " >&6
6673 else
6674   if test -n "$doxygen"; then
6675   ac_cv_prog_doxygen="$doxygen" # Let the user override the test.
6676 else
6677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6678 for as_dir in $PATH
6679 do
6680   IFS=$as_save_IFS
6681   test -z "$as_dir" && as_dir=.
6682     for ac_exec_ext in '' $ac_executable_extensions; do
6683   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6684     ac_cv_prog_doxygen="doxygen"
6685     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6686     break 2
6687   fi
6688 done
6689   done
6690 IFS=$as_save_IFS
6691
6692 fi
6693 fi
6694 doxygen=$ac_cv_prog_doxygen
6695 if test -n "$doxygen"; then
6696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $doxygen" >&5
6697 $as_echo "$doxygen" >&6; }
6698 else
6699   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6700 $as_echo "no" >&6; }
6701 fi
6702
6703
6704 if test -n "$ac_tool_prefix"; then
6705   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6706 set dummy ${ac_tool_prefix}strip; ac_word=$2
6707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6708 $as_echo_n "checking for $ac_word... " >&6; }
6709 if ${ac_cv_prog_STRIP+:} false; then :
6710   $as_echo_n "(cached) " >&6
6711 else
6712   if test -n "$STRIP"; then
6713   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6714 else
6715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6716 for as_dir in $PATH
6717 do
6718   IFS=$as_save_IFS
6719   test -z "$as_dir" && as_dir=.
6720     for ac_exec_ext in '' $ac_executable_extensions; do
6721   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6722     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6723     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6724     break 2
6725   fi
6726 done
6727   done
6728 IFS=$as_save_IFS
6729
6730 fi
6731 fi
6732 STRIP=$ac_cv_prog_STRIP
6733 if test -n "$STRIP"; then
6734   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6735 $as_echo "$STRIP" >&6; }
6736 else
6737   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6738 $as_echo "no" >&6; }
6739 fi
6740
6741
6742 fi
6743 if test -z "$ac_cv_prog_STRIP"; then
6744   ac_ct_STRIP=$STRIP
6745   # Extract the first word of "strip", so it can be a program name with args.
6746 set dummy strip; ac_word=$2
6747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6748 $as_echo_n "checking for $ac_word... " >&6; }
6749 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6750   $as_echo_n "(cached) " >&6
6751 else
6752   if test -n "$ac_ct_STRIP"; then
6753   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6754 else
6755 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6756 for as_dir in $PATH
6757 do
6758   IFS=$as_save_IFS
6759   test -z "$as_dir" && as_dir=.
6760     for ac_exec_ext in '' $ac_executable_extensions; do
6761   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6762     ac_cv_prog_ac_ct_STRIP="strip"
6763     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6764     break 2
6765   fi
6766 done
6767   done
6768 IFS=$as_save_IFS
6769
6770 fi
6771 fi
6772 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6773 if test -n "$ac_ct_STRIP"; then
6774   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6775 $as_echo "$ac_ct_STRIP" >&6; }
6776 else
6777   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6778 $as_echo "no" >&6; }
6779 fi
6780
6781   if test "x$ac_ct_STRIP" = x; then
6782     STRIP=""
6783   else
6784     case $cross_compiling:$ac_tool_warned in
6785 yes:)
6786 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6787 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6788 ac_tool_warned=yes ;;
6789 esac
6790     STRIP=$ac_ct_STRIP
6791   fi
6792 else
6793   STRIP="$ac_cv_prog_STRIP"
6794 fi
6795
6796 ac_aux_dir=
6797 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
6798   if test -f "$ac_dir/install-sh"; then
6799     ac_aux_dir=$ac_dir
6800     ac_install_sh="$ac_aux_dir/install-sh -c"
6801     break
6802   elif test -f "$ac_dir/install.sh"; then
6803     ac_aux_dir=$ac_dir
6804     ac_install_sh="$ac_aux_dir/install.sh -c"
6805     break
6806   elif test -f "$ac_dir/shtool"; then
6807     ac_aux_dir=$ac_dir
6808     ac_install_sh="$ac_aux_dir/shtool install -c"
6809     break
6810   fi
6811 done
6812 if test -z "$ac_aux_dir"; then
6813   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
6814 fi
6815
6816 # These three variables are undocumented and unsupported,
6817 # and are intended to be withdrawn in a future Autoconf release.
6818 # They can cause serious problems if a builder's source tree is in a directory
6819 # whose full name contains unusual characters.
6820 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
6821 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
6822 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
6823
6824
6825 # Make sure we can run config.sub.
6826 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
6827   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
6828
6829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
6830 $as_echo_n "checking build system type... " >&6; }
6831 if ${ac_cv_build+:} false; then :
6832   $as_echo_n "(cached) " >&6
6833 else
6834   ac_build_alias=$build_alias
6835 test "x$ac_build_alias" = x &&
6836   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
6837 test "x$ac_build_alias" = x &&
6838   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
6839 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
6840   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
6841
6842 fi
6843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
6844 $as_echo "$ac_cv_build" >&6; }
6845 case $ac_cv_build in
6846 *-*-*) ;;
6847 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
6848 esac
6849 build=$ac_cv_build
6850 ac_save_IFS=$IFS; IFS='-'
6851 set x $ac_cv_build
6852 shift
6853 build_cpu=$1
6854 build_vendor=$2
6855 shift; shift
6856 # Remember, the first character of IFS is used to create $*,
6857 # except with old shells:
6858 build_os=$*
6859 IFS=$ac_save_IFS
6860 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
6861
6862
6863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
6864 $as_echo_n "checking host system type... " >&6; }
6865 if ${ac_cv_host+:} false; then :
6866   $as_echo_n "(cached) " >&6
6867 else
6868   if test "x$host_alias" = x; then
6869   ac_cv_host=$ac_cv_build
6870 else
6871   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
6872     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
6873 fi
6874
6875 fi
6876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
6877 $as_echo "$ac_cv_host" >&6; }
6878 case $ac_cv_host in
6879 *-*-*) ;;
6880 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
6881 esac
6882 host=$ac_cv_host
6883 ac_save_IFS=$IFS; IFS='-'
6884 set x $ac_cv_host
6885 shift
6886 host_cpu=$1
6887 host_vendor=$2
6888 shift; shift
6889 # Remember, the first character of IFS is used to create $*,
6890 # except with old shells:
6891 host_os=$*
6892 IFS=$ac_save_IFS
6893 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
6894
6895
6896
6897 # skip these tests, we do not need them.
6898
6899
6900
6901
6902
6903
6904
6905
6906 # always use ./libtool unless override from commandline (libtool=mylibtool)
6907 if test -z "$libtool"; then
6908         libtool="./libtool"
6909 fi
6910
6911 # avoid libtool max commandline length test on systems that fork slowly.
6912
6913 if echo "$host_os" | grep "sunos4" >/dev/null; then
6914         lt_cv_sys_max_cmd_len=32750;
6915 fi
6916 if test -n "$ac_tool_prefix"; then
6917   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6918 set dummy ${ac_tool_prefix}ar; ac_word=$2
6919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6920 $as_echo_n "checking for $ac_word... " >&6; }
6921 if ${ac_cv_path_AR+:} false; then :
6922   $as_echo_n "(cached) " >&6
6923 else
6924   case $AR in
6925   [\\/]* | ?:[\\/]*)
6926   ac_cv_path_AR="$AR" # Let the user override the test with a path.
6927   ;;
6928   *)
6929   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6930 for as_dir in $PATH
6931 do
6932   IFS=$as_save_IFS
6933   test -z "$as_dir" && as_dir=.
6934     for ac_exec_ext in '' $ac_executable_extensions; do
6935   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6936     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
6937     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6938     break 2
6939   fi
6940 done
6941   done
6942 IFS=$as_save_IFS
6943
6944   ;;
6945 esac
6946 fi
6947 AR=$ac_cv_path_AR
6948 if test -n "$AR"; then
6949   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6950 $as_echo "$AR" >&6; }
6951 else
6952   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6953 $as_echo "no" >&6; }
6954 fi
6955
6956
6957 fi
6958 if test -z "$ac_cv_path_AR"; then
6959   ac_pt_AR=$AR
6960   # Extract the first word of "ar", so it can be a program name with args.
6961 set dummy ar; ac_word=$2
6962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6963 $as_echo_n "checking for $ac_word... " >&6; }
6964 if ${ac_cv_path_ac_pt_AR+:} false; then :
6965   $as_echo_n "(cached) " >&6
6966 else
6967   case $ac_pt_AR in
6968   [\\/]* | ?:[\\/]*)
6969   ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
6970   ;;
6971   *)
6972   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6973 for as_dir in $PATH
6974 do
6975   IFS=$as_save_IFS
6976   test -z "$as_dir" && as_dir=.
6977     for ac_exec_ext in '' $ac_executable_extensions; do
6978   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6979     ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
6980     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6981     break 2
6982   fi
6983 done
6984   done
6985 IFS=$as_save_IFS
6986
6987   ;;
6988 esac
6989 fi
6990 ac_pt_AR=$ac_cv_path_ac_pt_AR
6991 if test -n "$ac_pt_AR"; then
6992   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
6993 $as_echo "$ac_pt_AR" >&6; }
6994 else
6995   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6996 $as_echo "no" >&6; }
6997 fi
6998
6999   if test "x$ac_pt_AR" = x; then
7000     AR="false"
7001   else
7002     case $cross_compiling:$ac_tool_warned in
7003 yes:)
7004 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7005 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7006 ac_tool_warned=yes ;;
7007 esac
7008     AR=$ac_pt_AR
7009   fi
7010 else
7011   AR="$ac_cv_path_AR"
7012 fi
7013
7014 if test $AR = false; then
7015         as_fn_error $? "Cannot find 'ar', please extend PATH to include it" "$LINENO" 5
7016 fi
7017
7018 case `pwd` in
7019   *\ * | *\     *)
7020     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
7021 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
7022 esac
7023
7024
7025
7026 macro_version='2.4.6'
7027 macro_revision='2.4.6'
7028
7029
7030
7031
7032
7033
7034
7035
7036
7037
7038
7039
7040
7041 ltmain=$ac_aux_dir/ltmain.sh
7042
7043 # Backslashify metacharacters that are still active within
7044 # double-quoted strings.
7045 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7046
7047 # Same as above, but do not quote variable references.
7048 double_quote_subst='s/\(["`\\]\)/\\\1/g'
7049
7050 # Sed substitution to delay expansion of an escaped shell variable in a
7051 # double_quote_subst'ed string.
7052 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7053
7054 # Sed substitution to delay expansion of an escaped single quote.
7055 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7056
7057 # Sed substitution to avoid accidental globbing in evaled expressions
7058 no_glob_subst='s/\*/\\\*/g'
7059
7060 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7061 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7062 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7063
7064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7065 $as_echo_n "checking how to print strings... " >&6; }
7066 # Test print first, because it will be a builtin if present.
7067 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7068    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7069   ECHO='print -r --'
7070 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7071   ECHO='printf %s\n'
7072 else
7073   # Use this function as a fallback that always works.
7074   func_fallback_echo ()
7075   {
7076     eval 'cat <<_LTECHO_EOF
7077 $1
7078 _LTECHO_EOF'
7079   }
7080   ECHO='func_fallback_echo'
7081 fi
7082
7083 # func_echo_all arg...
7084 # Invoke $ECHO with all args, space-separated.
7085 func_echo_all ()
7086 {
7087     $ECHO ""
7088 }
7089
7090 case $ECHO in
7091   printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7092 $as_echo "printf" >&6; } ;;
7093   print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7094 $as_echo "print -r" >&6; } ;;
7095   *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7096 $as_echo "cat" >&6; } ;;
7097 esac
7098
7099
7100
7101
7102
7103
7104
7105
7106
7107
7108
7109
7110
7111
7112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7113 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7114 if ${ac_cv_path_SED+:} false; then :
7115   $as_echo_n "(cached) " >&6
7116 else
7117             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7118      for ac_i in 1 2 3 4 5 6 7; do
7119        ac_script="$ac_script$as_nl$ac_script"
7120      done
7121      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7122      { ac_script=; unset ac_script;}
7123      if test -z "$SED"; then
7124   ac_path_SED_found=false
7125   # Loop through the user's path and test for each of PROGNAME-LIST
7126   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7127 for as_dir in $PATH
7128 do
7129   IFS=$as_save_IFS
7130   test -z "$as_dir" && as_dir=.
7131     for ac_prog in sed gsed; do
7132     for ac_exec_ext in '' $ac_executable_extensions; do
7133       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7134       as_fn_executable_p "$ac_path_SED" || continue
7135 # Check for GNU ac_path_SED and select it if it is found.
7136   # Check for GNU $ac_path_SED
7137 case `"$ac_path_SED" --version 2>&1` in
7138 *GNU*)
7139   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7140 *)
7141   ac_count=0
7142   $as_echo_n 0123456789 >"conftest.in"
7143   while :
7144   do
7145     cat "conftest.in" "conftest.in" >"conftest.tmp"
7146     mv "conftest.tmp" "conftest.in"
7147     cp "conftest.in" "conftest.nl"
7148     $as_echo '' >> "conftest.nl"
7149     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7150     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7151     as_fn_arith $ac_count + 1 && ac_count=$as_val
7152     if test $ac_count -gt ${ac_path_SED_max-0}; then
7153       # Best one so far, save it but keep looking for a better one
7154       ac_cv_path_SED="$ac_path_SED"
7155       ac_path_SED_max=$ac_count
7156     fi
7157     # 10*(2^10) chars as input seems more than enough
7158     test $ac_count -gt 10 && break
7159   done
7160   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7161 esac
7162
7163       $ac_path_SED_found && break 3
7164     done
7165   done
7166   done
7167 IFS=$as_save_IFS
7168   if test -z "$ac_cv_path_SED"; then
7169     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7170   fi
7171 else
7172   ac_cv_path_SED=$SED
7173 fi
7174
7175 fi
7176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7177 $as_echo "$ac_cv_path_SED" >&6; }
7178  SED="$ac_cv_path_SED"
7179   rm -f conftest.sed
7180
7181 test -z "$SED" && SED=sed
7182 Xsed="$SED -e 1s/^X//"
7183
7184
7185
7186
7187
7188
7189
7190
7191
7192
7193
7194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7195 $as_echo_n "checking for fgrep... " >&6; }
7196 if ${ac_cv_path_FGREP+:} false; then :
7197   $as_echo_n "(cached) " >&6
7198 else
7199   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7200    then ac_cv_path_FGREP="$GREP -F"
7201    else
7202      if test -z "$FGREP"; then
7203   ac_path_FGREP_found=false
7204   # Loop through the user's path and test for each of PROGNAME-LIST
7205   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7206 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7207 do
7208   IFS=$as_save_IFS
7209   test -z "$as_dir" && as_dir=.
7210     for ac_prog in fgrep; do
7211     for ac_exec_ext in '' $ac_executable_extensions; do
7212       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7213       as_fn_executable_p "$ac_path_FGREP" || continue
7214 # Check for GNU ac_path_FGREP and select it if it is found.
7215   # Check for GNU $ac_path_FGREP
7216 case `"$ac_path_FGREP" --version 2>&1` in
7217 *GNU*)
7218   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7219 *)
7220   ac_count=0
7221   $as_echo_n 0123456789 >"conftest.in"
7222   while :
7223   do
7224     cat "conftest.in" "conftest.in" >"conftest.tmp"
7225     mv "conftest.tmp" "conftest.in"
7226     cp "conftest.in" "conftest.nl"
7227     $as_echo 'FGREP' >> "conftest.nl"
7228     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7229     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7230     as_fn_arith $ac_count + 1 && ac_count=$as_val
7231     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7232       # Best one so far, save it but keep looking for a better one
7233       ac_cv_path_FGREP="$ac_path_FGREP"
7234       ac_path_FGREP_max=$ac_count
7235     fi
7236     # 10*(2^10) chars as input seems more than enough
7237     test $ac_count -gt 10 && break
7238   done
7239   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7240 esac
7241
7242       $ac_path_FGREP_found && break 3
7243     done
7244   done
7245   done
7246 IFS=$as_save_IFS
7247   if test -z "$ac_cv_path_FGREP"; then
7248     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7249   fi
7250 else
7251   ac_cv_path_FGREP=$FGREP
7252 fi
7253
7254    fi
7255 fi
7256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7257 $as_echo "$ac_cv_path_FGREP" >&6; }
7258  FGREP="$ac_cv_path_FGREP"
7259
7260
7261 test -z "$GREP" && GREP=grep
7262
7263
7264
7265
7266
7267
7268
7269
7270
7271
7272
7273
7274
7275
7276
7277
7278
7279
7280
7281 # Check whether --with-gnu-ld was given.
7282 if test "${with_gnu_ld+set}" = set; then :
7283   withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7284 else
7285   with_gnu_ld=no
7286 fi
7287
7288 ac_prog=ld
7289 if test yes = "$GCC"; then
7290   # Check if gcc -print-prog-name=ld gives a path.
7291   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7292 $as_echo_n "checking for ld used by $CC... " >&6; }
7293   case $host in
7294   *-*-mingw*)
7295     # gcc leaves a trailing carriage return, which upsets mingw
7296     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7297   *)
7298     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7299   esac
7300   case $ac_prog in
7301     # Accept absolute paths.
7302     [\\/]* | ?:[\\/]*)
7303       re_direlt='/[^/][^/]*/\.\./'
7304       # Canonicalize the pathname of ld
7305       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7306       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7307         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7308       done
7309       test -z "$LD" && LD=$ac_prog
7310       ;;
7311   "")
7312     # If it fails, then pretend we aren't using GCC.
7313     ac_prog=ld
7314     ;;
7315   *)
7316     # If it is relative, then search for the first ld in PATH.
7317     with_gnu_ld=unknown
7318     ;;
7319   esac
7320 elif test yes = "$with_gnu_ld"; then
7321   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7322 $as_echo_n "checking for GNU ld... " >&6; }
7323 else
7324   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7325 $as_echo_n "checking for non-GNU ld... " >&6; }
7326 fi
7327 if ${lt_cv_path_LD+:} false; then :
7328   $as_echo_n "(cached) " >&6
7329 else
7330   if test -z "$LD"; then
7331   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7332   for ac_dir in $PATH; do
7333     IFS=$lt_save_ifs
7334     test -z "$ac_dir" && ac_dir=.
7335     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7336       lt_cv_path_LD=$ac_dir/$ac_prog
7337       # Check to see if the program is GNU ld.  I'd rather use --version,
7338       # but apparently some variants of GNU ld only accept -v.
7339       # Break only if it was the GNU/non-GNU ld that we prefer.
7340       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7341       *GNU* | *'with BFD'*)
7342         test no != "$with_gnu_ld" && break
7343         ;;
7344       *)
7345         test yes != "$with_gnu_ld" && break
7346         ;;
7347       esac
7348     fi
7349   done
7350   IFS=$lt_save_ifs
7351 else
7352   lt_cv_path_LD=$LD # Let the user override the test with a path.
7353 fi
7354 fi
7355
7356 LD=$lt_cv_path_LD
7357 if test -n "$LD"; then
7358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7359 $as_echo "$LD" >&6; }
7360 else
7361   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7362 $as_echo "no" >&6; }
7363 fi
7364 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7366 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7367 if ${lt_cv_prog_gnu_ld+:} false; then :
7368   $as_echo_n "(cached) " >&6
7369 else
7370   # I'd rather use --version here, but apparently some GNU lds only accept -v.
7371 case `$LD -v 2>&1 </dev/null` in
7372 *GNU* | *'with BFD'*)
7373   lt_cv_prog_gnu_ld=yes
7374   ;;
7375 *)
7376   lt_cv_prog_gnu_ld=no
7377   ;;
7378 esac
7379 fi
7380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7381 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
7382 with_gnu_ld=$lt_cv_prog_gnu_ld
7383
7384
7385
7386
7387
7388
7389
7390
7391
7392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7393 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7394 if ${lt_cv_path_NM+:} false; then :
7395   $as_echo_n "(cached) " >&6
7396 else
7397   if test -n "$NM"; then
7398   # Let the user override the test.
7399   lt_cv_path_NM=$NM
7400 else
7401   lt_nm_to_check=${ac_tool_prefix}nm
7402   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7403     lt_nm_to_check="$lt_nm_to_check nm"
7404   fi
7405   for lt_tmp_nm in $lt_nm_to_check; do
7406     lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7407     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7408       IFS=$lt_save_ifs
7409       test -z "$ac_dir" && ac_dir=.
7410       tmp_nm=$ac_dir/$lt_tmp_nm
7411       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7412         # Check to see if the nm accepts a BSD-compat flag.
7413         # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7414         #   nm: unknown option "B" ignored
7415         # Tru64's nm complains that /dev/null is an invalid object file
7416         # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7417         case $build_os in
7418         mingw*) lt_bad_file=conftest.nm/nofile ;;
7419         *) lt_bad_file=/dev/null ;;
7420         esac
7421         case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7422         *$lt_bad_file* | *'Invalid file or object type'*)
7423           lt_cv_path_NM="$tmp_nm -B"
7424           break 2
7425           ;;
7426         *)
7427           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7428           */dev/null*)
7429             lt_cv_path_NM="$tmp_nm -p"
7430             break 2
7431             ;;
7432           *)
7433             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7434             continue # so that we can try to find one that supports BSD flags
7435             ;;
7436           esac
7437           ;;
7438         esac
7439       fi
7440     done
7441     IFS=$lt_save_ifs
7442   done
7443   : ${lt_cv_path_NM=no}
7444 fi
7445 fi
7446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7447 $as_echo "$lt_cv_path_NM" >&6; }
7448 if test no != "$lt_cv_path_NM"; then
7449   NM=$lt_cv_path_NM
7450 else
7451   # Didn't find any BSD compatible name lister, look for dumpbin.
7452   if test -n "$DUMPBIN"; then :
7453     # Let the user override the test.
7454   else
7455     if test -n "$ac_tool_prefix"; then
7456   for ac_prog in dumpbin "link -dump"
7457   do
7458     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7459 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7461 $as_echo_n "checking for $ac_word... " >&6; }
7462 if ${ac_cv_prog_DUMPBIN+:} false; then :
7463   $as_echo_n "(cached) " >&6
7464 else
7465   if test -n "$DUMPBIN"; then
7466   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7467 else
7468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7469 for as_dir in $PATH
7470 do
7471   IFS=$as_save_IFS
7472   test -z "$as_dir" && as_dir=.
7473     for ac_exec_ext in '' $ac_executable_extensions; do
7474   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7475     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7476     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7477     break 2
7478   fi
7479 done
7480   done
7481 IFS=$as_save_IFS
7482
7483 fi
7484 fi
7485 DUMPBIN=$ac_cv_prog_DUMPBIN
7486 if test -n "$DUMPBIN"; then
7487   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7488 $as_echo "$DUMPBIN" >&6; }
7489 else
7490   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7491 $as_echo "no" >&6; }
7492 fi
7493
7494
7495     test -n "$DUMPBIN" && break
7496   done
7497 fi
7498 if test -z "$DUMPBIN"; then
7499   ac_ct_DUMPBIN=$DUMPBIN
7500   for ac_prog in dumpbin "link -dump"
7501 do
7502   # Extract the first word of "$ac_prog", so it can be a program name with args.
7503 set dummy $ac_prog; ac_word=$2
7504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7505 $as_echo_n "checking for $ac_word... " >&6; }
7506 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7507   $as_echo_n "(cached) " >&6
7508 else
7509   if test -n "$ac_ct_DUMPBIN"; then
7510   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7511 else
7512 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7513 for as_dir in $PATH
7514 do
7515   IFS=$as_save_IFS
7516   test -z "$as_dir" && as_dir=.
7517     for ac_exec_ext in '' $ac_executable_extensions; do
7518   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7519     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7520     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7521     break 2
7522   fi
7523 done
7524   done
7525 IFS=$as_save_IFS
7526
7527 fi
7528 fi
7529 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7530 if test -n "$ac_ct_DUMPBIN"; then
7531   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7532 $as_echo "$ac_ct_DUMPBIN" >&6; }
7533 else
7534   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7535 $as_echo "no" >&6; }
7536 fi
7537
7538
7539   test -n "$ac_ct_DUMPBIN" && break
7540 done
7541
7542   if test "x$ac_ct_DUMPBIN" = x; then
7543     DUMPBIN=":"
7544   else
7545     case $cross_compiling:$ac_tool_warned in
7546 yes:)
7547 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7548 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7549 ac_tool_warned=yes ;;
7550 esac
7551     DUMPBIN=$ac_ct_DUMPBIN
7552   fi
7553 fi
7554
7555     case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7556     *COFF*)
7557       DUMPBIN="$DUMPBIN -symbols -headers"
7558       ;;
7559     *)
7560       DUMPBIN=:
7561       ;;
7562     esac
7563   fi
7564
7565   if test : != "$DUMPBIN"; then
7566     NM=$DUMPBIN
7567   fi
7568 fi
7569 test -z "$NM" && NM=nm
7570
7571
7572
7573
7574
7575
7576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7577 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
7578 if ${lt_cv_nm_interface+:} false; then :
7579   $as_echo_n "(cached) " >&6
7580 else
7581   lt_cv_nm_interface="BSD nm"
7582   echo "int some_variable = 0;" > conftest.$ac_ext
7583   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7584   (eval "$ac_compile" 2>conftest.err)
7585   cat conftest.err >&5
7586   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7587   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7588   cat conftest.err >&5
7589   (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7590   cat conftest.out >&5
7591   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7592     lt_cv_nm_interface="MS dumpbin"
7593   fi
7594   rm -f conftest*
7595 fi
7596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7597 $as_echo "$lt_cv_nm_interface" >&6; }
7598
7599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7600 $as_echo_n "checking whether ln -s works... " >&6; }
7601 LN_S=$as_ln_s
7602 if test "$LN_S" = "ln -s"; then
7603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7604 $as_echo "yes" >&6; }
7605 else
7606   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7607 $as_echo "no, using $LN_S" >&6; }
7608 fi
7609
7610 # find the maximum length of command line arguments
7611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7612 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
7613 if ${lt_cv_sys_max_cmd_len+:} false; then :
7614   $as_echo_n "(cached) " >&6
7615 else
7616     i=0
7617   teststring=ABCD
7618
7619   case $build_os in
7620   msdosdjgpp*)
7621     # On DJGPP, this test can blow up pretty badly due to problems in libc
7622     # (any single argument exceeding 2000 bytes causes a buffer overrun
7623     # during glob expansion).  Even if it were fixed, the result of this
7624     # check would be larger than it should be.
7625     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
7626     ;;
7627
7628   gnu*)
7629     # Under GNU Hurd, this test is not required because there is
7630     # no limit to the length of command line arguments.
7631     # Libtool will interpret -1 as no limit whatsoever
7632     lt_cv_sys_max_cmd_len=-1;
7633     ;;
7634
7635   cygwin* | mingw* | cegcc*)
7636     # On Win9x/ME, this test blows up -- it succeeds, but takes
7637     # about 5 minutes as the teststring grows exponentially.
7638     # Worse, since 9x/ME are not pre-emptively multitasking,
7639     # you end up with a "frozen" computer, even though with patience
7640     # the test eventually succeeds (with a max line length of 256k).
7641     # Instead, let's just punt: use the minimum linelength reported by
7642     # all of the supported platforms: 8192 (on NT/2K/XP).
7643     lt_cv_sys_max_cmd_len=8192;
7644     ;;
7645
7646   mint*)
7647     # On MiNT this can take a long time and run out of memory.
7648     lt_cv_sys_max_cmd_len=8192;
7649     ;;
7650
7651   amigaos*)
7652     # On AmigaOS with pdksh, this test takes hours, literally.
7653     # So we just punt and use a minimum line length of 8192.
7654     lt_cv_sys_max_cmd_len=8192;
7655     ;;
7656
7657   bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7658     # This has been around since 386BSD, at least.  Likely further.
7659     if test -x /sbin/sysctl; then
7660       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7661     elif test -x /usr/sbin/sysctl; then
7662       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7663     else
7664       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
7665     fi
7666     # And add a safety zone
7667     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7668     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7669     ;;
7670
7671   interix*)
7672     # We know the value 262144 and hardcode it with a safety zone (like BSD)
7673     lt_cv_sys_max_cmd_len=196608
7674     ;;
7675
7676   os2*)
7677     # The test takes a long time on OS/2.
7678     lt_cv_sys_max_cmd_len=8192
7679     ;;
7680
7681   osf*)
7682     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7683     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7684     # nice to cause kernel panics so lets avoid the loop below.
7685     # First set a reasonable default.
7686     lt_cv_sys_max_cmd_len=16384
7687     #
7688     if test -x /sbin/sysconfig; then
7689       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7690         *1*) lt_cv_sys_max_cmd_len=-1 ;;
7691       esac
7692     fi
7693     ;;
7694   sco3.2v5*)
7695     lt_cv_sys_max_cmd_len=102400
7696     ;;
7697   sysv5* | sco5v6* | sysv4.2uw2*)
7698     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7699     if test -n "$kargmax"; then
7700       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
7701     else
7702       lt_cv_sys_max_cmd_len=32768
7703     fi
7704     ;;
7705   *)
7706     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7707     if test -n "$lt_cv_sys_max_cmd_len" && \
7708        test undefined != "$lt_cv_sys_max_cmd_len"; then
7709       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7710       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7711     else
7712       # Make teststring a little bigger before we do anything with it.
7713       # a 1K string should be a reasonable start.
7714       for i in 1 2 3 4 5 6 7 8; do
7715         teststring=$teststring$teststring
7716       done
7717       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7718       # If test is not a shell built-in, we'll probably end up computing a
7719       # maximum length that is only half of the actual maximum length, but
7720       # we can't tell.
7721       while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7722                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7723               test 17 != "$i" # 1/2 MB should be enough
7724       do
7725         i=`expr $i + 1`
7726         teststring=$teststring$teststring
7727       done
7728       # Only check the string length outside the loop.
7729       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7730       teststring=
7731       # Add a significant safety factor because C++ compilers can tack on
7732       # massive amounts of additional arguments before passing them to the
7733       # linker.  It appears as though 1/2 is a usable value.
7734       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7735     fi
7736     ;;
7737   esac
7738
7739 fi
7740
7741 if test -n "$lt_cv_sys_max_cmd_len"; then
7742   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7743 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7744 else
7745   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7746 $as_echo "none" >&6; }
7747 fi
7748 max_cmd_len=$lt_cv_sys_max_cmd_len
7749
7750
7751
7752
7753
7754
7755 : ${CP="cp -f"}
7756 : ${MV="mv -f"}
7757 : ${RM="rm -f"}
7758
7759 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7760   lt_unset=unset
7761 else
7762   lt_unset=false
7763 fi
7764
7765
7766
7767
7768
7769 # test EBCDIC or ASCII
7770 case `echo X|tr X '\101'` in
7771  A) # ASCII based system
7772     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7773   lt_SP2NL='tr \040 \012'
7774   lt_NL2SP='tr \015\012 \040\040'
7775   ;;
7776  *) # EBCDIC based system
7777   lt_SP2NL='tr \100 \n'
7778   lt_NL2SP='tr \r\n \100\100'
7779   ;;
7780 esac
7781
7782
7783
7784
7785
7786
7787
7788
7789
7790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7791 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7792 if ${lt_cv_to_host_file_cmd+:} false; then :
7793   $as_echo_n "(cached) " >&6
7794 else
7795   case $host in
7796   *-*-mingw* )
7797     case $build in
7798       *-*-mingw* ) # actually msys
7799         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7800         ;;
7801       *-*-cygwin* )
7802         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7803         ;;
7804       * ) # otherwise, assume *nix
7805         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7806         ;;
7807     esac
7808     ;;
7809   *-*-cygwin* )
7810     case $build in
7811       *-*-mingw* ) # actually msys
7812         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7813         ;;
7814       *-*-cygwin* )
7815         lt_cv_to_host_file_cmd=func_convert_file_noop
7816         ;;
7817       * ) # otherwise, assume *nix
7818         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7819         ;;
7820     esac
7821     ;;
7822   * ) # unhandled hosts (and "normal" native builds)
7823     lt_cv_to_host_file_cmd=func_convert_file_noop
7824     ;;
7825 esac
7826
7827 fi
7828
7829 to_host_file_cmd=$lt_cv_to_host_file_cmd
7830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7831 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
7832
7833
7834
7835
7836
7837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7838 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7839 if ${lt_cv_to_tool_file_cmd+:} false; then :
7840   $as_echo_n "(cached) " >&6
7841 else
7842   #assume ordinary cross tools, or native build.
7843 lt_cv_to_tool_file_cmd=func_convert_file_noop
7844 case $host in
7845   *-*-mingw* )
7846     case $build in
7847       *-*-mingw* ) # actually msys
7848         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7849         ;;
7850     esac
7851     ;;
7852 esac
7853
7854 fi
7855
7856 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7858 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7859
7860
7861
7862
7863
7864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7865 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7866 if ${lt_cv_ld_reload_flag+:} false; then :
7867   $as_echo_n "(cached) " >&6
7868 else
7869   lt_cv_ld_reload_flag='-r'
7870 fi
7871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7872 $as_echo "$lt_cv_ld_reload_flag" >&6; }
7873 reload_flag=$lt_cv_ld_reload_flag
7874 case $reload_flag in
7875 "" | " "*) ;;
7876 *) reload_flag=" $reload_flag" ;;
7877 esac
7878 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7879 case $host_os in
7880   cygwin* | mingw* | pw32* | cegcc*)
7881     if test yes != "$GCC"; then
7882       reload_cmds=false
7883     fi
7884     ;;
7885   darwin*)
7886     if test yes = "$GCC"; then
7887       reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
7888     else
7889       reload_cmds='$LD$reload_flag -o $output$reload_objs'
7890     fi
7891     ;;
7892 esac
7893
7894
7895
7896
7897
7898
7899
7900
7901
7902 if test -n "$ac_tool_prefix"; then
7903   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7904 set dummy ${ac_tool_prefix}objdump; ac_word=$2
7905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7906 $as_echo_n "checking for $ac_word... " >&6; }
7907 if ${ac_cv_prog_OBJDUMP+:} false; then :
7908   $as_echo_n "(cached) " >&6
7909 else
7910   if test -n "$OBJDUMP"; then
7911   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7912 else
7913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7914 for as_dir in $PATH
7915 do
7916   IFS=$as_save_IFS
7917   test -z "$as_dir" && as_dir=.
7918     for ac_exec_ext in '' $ac_executable_extensions; do
7919   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7920     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7921     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7922     break 2
7923   fi
7924 done
7925   done
7926 IFS=$as_save_IFS
7927
7928 fi
7929 fi
7930 OBJDUMP=$ac_cv_prog_OBJDUMP
7931 if test -n "$OBJDUMP"; then
7932   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7933 $as_echo "$OBJDUMP" >&6; }
7934 else
7935   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7936 $as_echo "no" >&6; }
7937 fi
7938
7939
7940 fi
7941 if test -z "$ac_cv_prog_OBJDUMP"; then
7942   ac_ct_OBJDUMP=$OBJDUMP
7943   # Extract the first word of "objdump", so it can be a program name with args.
7944 set dummy objdump; ac_word=$2
7945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7946 $as_echo_n "checking for $ac_word... " >&6; }
7947 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7948   $as_echo_n "(cached) " >&6
7949 else
7950   if test -n "$ac_ct_OBJDUMP"; then
7951   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7952 else
7953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7954 for as_dir in $PATH
7955 do
7956   IFS=$as_save_IFS
7957   test -z "$as_dir" && as_dir=.
7958     for ac_exec_ext in '' $ac_executable_extensions; do
7959   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7960     ac_cv_prog_ac_ct_OBJDUMP="objdump"
7961     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7962     break 2
7963   fi
7964 done
7965   done
7966 IFS=$as_save_IFS
7967
7968 fi
7969 fi
7970 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7971 if test -n "$ac_ct_OBJDUMP"; then
7972   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7973 $as_echo "$ac_ct_OBJDUMP" >&6; }
7974 else
7975   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7976 $as_echo "no" >&6; }
7977 fi
7978
7979   if test "x$ac_ct_OBJDUMP" = x; then
7980     OBJDUMP="false"
7981   else
7982     case $cross_compiling:$ac_tool_warned in
7983 yes:)
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7985 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7986 ac_tool_warned=yes ;;
7987 esac
7988     OBJDUMP=$ac_ct_OBJDUMP
7989   fi
7990 else
7991   OBJDUMP="$ac_cv_prog_OBJDUMP"
7992 fi
7993
7994 test -z "$OBJDUMP" && OBJDUMP=objdump
7995
7996
7997
7998
7999
8000
8001
8002
8003
8004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
8005 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
8006 if ${lt_cv_deplibs_check_method+:} false; then :
8007   $as_echo_n "(cached) " >&6
8008 else
8009   lt_cv_file_magic_cmd='$MAGIC_CMD'
8010 lt_cv_file_magic_test_file=
8011 lt_cv_deplibs_check_method='unknown'
8012 # Need to set the preceding variable on all platforms that support
8013 # interlibrary dependencies.
8014 # 'none' -- dependencies not supported.
8015 # 'unknown' -- same as none, but documents that we really don't know.
8016 # 'pass_all' -- all dependencies passed with no checks.
8017 # 'test_compile' -- check by making test program.
8018 # 'file_magic [[regex]]' -- check by looking for files in library path
8019 # that responds to the $file_magic_cmd with a given extended regex.
8020 # If you have 'file' or equivalent on your system and you're not sure
8021 # whether 'pass_all' will *always* work, you probably want this one.
8022
8023 case $host_os in
8024 aix[4-9]*)
8025   lt_cv_deplibs_check_method=pass_all
8026   ;;
8027
8028 beos*)
8029   lt_cv_deplibs_check_method=pass_all
8030   ;;
8031
8032 bsdi[45]*)
8033   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
8034   lt_cv_file_magic_cmd='/usr/bin/file -L'
8035   lt_cv_file_magic_test_file=/shlib/libc.so
8036   ;;
8037
8038 cygwin*)
8039   # func_win32_libid is a shell function defined in ltmain.sh
8040   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8041   lt_cv_file_magic_cmd='func_win32_libid'
8042   ;;
8043
8044 mingw* | pw32*)
8045   # Base MSYS/MinGW do not provide the 'file' command needed by
8046   # func_win32_libid shell function, so use a weaker test based on 'objdump',
8047   # unless we find 'file', for example because we are cross-compiling.
8048   if ( file / ) >/dev/null 2>&1; then
8049     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8050     lt_cv_file_magic_cmd='func_win32_libid'
8051   else
8052     # Keep this pattern in sync with the one in func_win32_libid.
8053     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
8054     lt_cv_file_magic_cmd='$OBJDUMP -f'
8055   fi
8056   ;;
8057
8058 cegcc*)
8059   # use the weaker test based on 'objdump'. See mingw*.
8060   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
8061   lt_cv_file_magic_cmd='$OBJDUMP -f'
8062   ;;
8063
8064 darwin* | rhapsody*)
8065   lt_cv_deplibs_check_method=pass_all
8066   ;;
8067
8068 freebsd* | dragonfly*)
8069   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8070     case $host_cpu in
8071     i*86 )
8072       # Not sure whether the presence of OpenBSD here was a mistake.
8073       # Let's accept both of them until this is cleared up.
8074       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8075       lt_cv_file_magic_cmd=/usr/bin/file
8076       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8077       ;;
8078     esac
8079   else
8080     lt_cv_deplibs_check_method=pass_all
8081   fi
8082   ;;
8083
8084 haiku*)
8085   lt_cv_deplibs_check_method=pass_all
8086   ;;
8087
8088 hpux10.20* | hpux11*)
8089   lt_cv_file_magic_cmd=/usr/bin/file
8090   case $host_cpu in
8091   ia64*)
8092     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8093     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8094     ;;
8095   hppa*64*)
8096     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
8097     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8098     ;;
8099   *)
8100     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8101     lt_cv_file_magic_test_file=/usr/lib/libc.sl
8102     ;;
8103   esac
8104   ;;
8105
8106 interix[3-9]*)
8107   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8108   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8109   ;;
8110
8111 irix5* | irix6* | nonstopux*)
8112   case $LD in
8113   *-32|*"-32 ") libmagic=32-bit;;
8114   *-n32|*"-n32 ") libmagic=N32;;
8115   *-64|*"-64 ") libmagic=64-bit;;
8116   *) libmagic=never-match;;
8117   esac
8118   lt_cv_deplibs_check_method=pass_all
8119   ;;
8120
8121 # This must be glibc/ELF.
8122 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8123   lt_cv_deplibs_check_method=pass_all
8124   ;;
8125
8126 netbsd*)
8127   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8128     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8129   else
8130     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8131   fi
8132   ;;
8133
8134 newos6*)
8135   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8136   lt_cv_file_magic_cmd=/usr/bin/file
8137   lt_cv_file_magic_test_file=/usr/lib/libnls.so
8138   ;;
8139
8140 *nto* | *qnx*)
8141   lt_cv_deplibs_check_method=pass_all
8142   ;;
8143
8144 openbsd* | bitrig*)
8145   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8146     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8147   else
8148     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8149   fi
8150   ;;
8151
8152 osf3* | osf4* | osf5*)
8153   lt_cv_deplibs_check_method=pass_all
8154   ;;
8155
8156 rdos*)
8157   lt_cv_deplibs_check_method=pass_all
8158   ;;
8159
8160 solaris*)
8161   lt_cv_deplibs_check_method=pass_all
8162   ;;
8163
8164 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8165   lt_cv_deplibs_check_method=pass_all
8166   ;;
8167
8168 sysv4 | sysv4.3*)
8169   case $host_vendor in
8170   motorola)
8171     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
8172     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8173     ;;
8174   ncr)
8175     lt_cv_deplibs_check_method=pass_all
8176     ;;
8177   sequent)
8178     lt_cv_file_magic_cmd='/bin/file'
8179     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8180     ;;
8181   sni)
8182     lt_cv_file_magic_cmd='/bin/file'
8183     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8184     lt_cv_file_magic_test_file=/lib/libc.so
8185     ;;
8186   siemens)
8187     lt_cv_deplibs_check_method=pass_all
8188     ;;
8189   pc)
8190     lt_cv_deplibs_check_method=pass_all
8191     ;;
8192   esac
8193   ;;
8194
8195 tpf*)
8196   lt_cv_deplibs_check_method=pass_all
8197   ;;
8198 os2*)
8199   lt_cv_deplibs_check_method=pass_all
8200   ;;
8201 esac
8202
8203 fi
8204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8205 $as_echo "$lt_cv_deplibs_check_method" >&6; }
8206
8207 file_magic_glob=
8208 want_nocaseglob=no
8209 if test "$build" = "$host"; then
8210   case $host_os in
8211   mingw* | pw32*)
8212     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8213       want_nocaseglob=yes
8214     else
8215       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8216     fi
8217     ;;
8218   esac
8219 fi
8220
8221 file_magic_cmd=$lt_cv_file_magic_cmd
8222 deplibs_check_method=$lt_cv_deplibs_check_method
8223 test -z "$deplibs_check_method" && deplibs_check_method=unknown
8224
8225
8226
8227
8228
8229
8230
8231
8232
8233
8234
8235
8236
8237
8238
8239
8240
8241
8242
8243
8244
8245
8246 if test -n "$ac_tool_prefix"; then
8247   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8248 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8250 $as_echo_n "checking for $ac_word... " >&6; }
8251 if ${ac_cv_prog_DLLTOOL+:} false; then :
8252   $as_echo_n "(cached) " >&6
8253 else
8254   if test -n "$DLLTOOL"; then
8255   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8256 else
8257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8258 for as_dir in $PATH
8259 do
8260   IFS=$as_save_IFS
8261   test -z "$as_dir" && as_dir=.
8262     for ac_exec_ext in '' $ac_executable_extensions; do
8263   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8264     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8265     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8266     break 2
8267   fi
8268 done
8269   done
8270 IFS=$as_save_IFS
8271
8272 fi
8273 fi
8274 DLLTOOL=$ac_cv_prog_DLLTOOL
8275 if test -n "$DLLTOOL"; then
8276   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8277 $as_echo "$DLLTOOL" >&6; }
8278 else
8279   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8280 $as_echo "no" >&6; }
8281 fi
8282
8283
8284 fi
8285 if test -z "$ac_cv_prog_DLLTOOL"; then
8286   ac_ct_DLLTOOL=$DLLTOOL
8287   # Extract the first word of "dlltool", so it can be a program name with args.
8288 set dummy dlltool; ac_word=$2
8289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8290 $as_echo_n "checking for $ac_word... " >&6; }
8291 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8292   $as_echo_n "(cached) " >&6
8293 else
8294   if test -n "$ac_ct_DLLTOOL"; then
8295   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8296 else
8297 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8298 for as_dir in $PATH
8299 do
8300   IFS=$as_save_IFS
8301   test -z "$as_dir" && as_dir=.
8302     for ac_exec_ext in '' $ac_executable_extensions; do
8303   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8304     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8305     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8306     break 2
8307   fi
8308 done
8309   done
8310 IFS=$as_save_IFS
8311
8312 fi
8313 fi
8314 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8315 if test -n "$ac_ct_DLLTOOL"; then
8316   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8317 $as_echo "$ac_ct_DLLTOOL" >&6; }
8318 else
8319   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8320 $as_echo "no" >&6; }
8321 fi
8322
8323   if test "x$ac_ct_DLLTOOL" = x; then
8324     DLLTOOL="false"
8325   else
8326     case $cross_compiling:$ac_tool_warned in
8327 yes:)
8328 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8329 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8330 ac_tool_warned=yes ;;
8331 esac
8332     DLLTOOL=$ac_ct_DLLTOOL
8333   fi
8334 else
8335   DLLTOOL="$ac_cv_prog_DLLTOOL"
8336 fi
8337
8338 test -z "$DLLTOOL" && DLLTOOL=dlltool
8339
8340
8341
8342
8343
8344
8345
8346
8347
8348
8349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8350 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8351 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8352   $as_echo_n "(cached) " >&6
8353 else
8354   lt_cv_sharedlib_from_linklib_cmd='unknown'
8355
8356 case $host_os in
8357 cygwin* | mingw* | pw32* | cegcc*)
8358   # two different shell functions defined in ltmain.sh;
8359   # decide which one to use based on capabilities of $DLLTOOL
8360   case `$DLLTOOL --help 2>&1` in
8361   *--identify-strict*)
8362     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8363     ;;
8364   *)
8365     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8366     ;;
8367   esac
8368   ;;
8369 *)
8370   # fallback: assume linklib IS sharedlib
8371   lt_cv_sharedlib_from_linklib_cmd=$ECHO
8372   ;;
8373 esac
8374
8375 fi
8376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8377 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8378 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8379 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8380
8381
8382
8383
8384
8385
8386
8387 if test -n "$ac_tool_prefix"; then
8388   for ac_prog in ar
8389   do
8390     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8391 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8393 $as_echo_n "checking for $ac_word... " >&6; }
8394 if ${ac_cv_prog_AR+:} false; then :
8395   $as_echo_n "(cached) " >&6
8396 else
8397   if test -n "$AR"; then
8398   ac_cv_prog_AR="$AR" # Let the user override the test.
8399 else
8400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8401 for as_dir in $PATH
8402 do
8403   IFS=$as_save_IFS
8404   test -z "$as_dir" && as_dir=.
8405     for ac_exec_ext in '' $ac_executable_extensions; do
8406   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8407     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8408     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8409     break 2
8410   fi
8411 done
8412   done
8413 IFS=$as_save_IFS
8414
8415 fi
8416 fi
8417 AR=$ac_cv_prog_AR
8418 if test -n "$AR"; then
8419   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8420 $as_echo "$AR" >&6; }
8421 else
8422   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8423 $as_echo "no" >&6; }
8424 fi
8425
8426
8427     test -n "$AR" && break
8428   done
8429 fi
8430 if test -z "$AR"; then
8431   ac_ct_AR=$AR
8432   for ac_prog in ar
8433 do
8434   # Extract the first word of "$ac_prog", so it can be a program name with args.
8435 set dummy $ac_prog; ac_word=$2
8436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8437 $as_echo_n "checking for $ac_word... " >&6; }
8438 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8439   $as_echo_n "(cached) " >&6
8440 else
8441   if test -n "$ac_ct_AR"; then
8442   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8443 else
8444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8445 for as_dir in $PATH
8446 do
8447   IFS=$as_save_IFS
8448   test -z "$as_dir" && as_dir=.
8449     for ac_exec_ext in '' $ac_executable_extensions; do
8450   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8451     ac_cv_prog_ac_ct_AR="$ac_prog"
8452     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8453     break 2
8454   fi
8455 done
8456   done
8457 IFS=$as_save_IFS
8458
8459 fi
8460 fi
8461 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8462 if test -n "$ac_ct_AR"; then
8463   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8464 $as_echo "$ac_ct_AR" >&6; }
8465 else
8466   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8467 $as_echo "no" >&6; }
8468 fi
8469
8470
8471   test -n "$ac_ct_AR" && break
8472 done
8473
8474   if test "x$ac_ct_AR" = x; then
8475     AR="false"
8476   else
8477     case $cross_compiling:$ac_tool_warned in
8478 yes:)
8479 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8480 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8481 ac_tool_warned=yes ;;
8482 esac
8483     AR=$ac_ct_AR
8484   fi
8485 fi
8486
8487 : ${AR=ar}
8488 : ${AR_FLAGS=cru}
8489
8490
8491
8492
8493
8494
8495
8496
8497
8498
8499
8500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8501 $as_echo_n "checking for archiver @FILE support... " >&6; }
8502 if ${lt_cv_ar_at_file+:} false; then :
8503   $as_echo_n "(cached) " >&6
8504 else
8505   lt_cv_ar_at_file=no
8506    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8507 /* end confdefs.h.  */
8508
8509 int
8510 main ()
8511 {
8512
8513   ;
8514   return 0;
8515 }
8516 _ACEOF
8517 if ac_fn_c_try_compile "$LINENO"; then :
8518   echo conftest.$ac_objext > conftest.lst
8519       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8520       { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8521   (eval $lt_ar_try) 2>&5
8522   ac_status=$?
8523   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8524   test $ac_status = 0; }
8525       if test 0 -eq "$ac_status"; then
8526         # Ensure the archiver fails upon bogus file names.
8527         rm -f conftest.$ac_objext libconftest.a
8528         { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8529   (eval $lt_ar_try) 2>&5
8530   ac_status=$?
8531   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8532   test $ac_status = 0; }
8533         if test 0 -ne "$ac_status"; then
8534           lt_cv_ar_at_file=@
8535         fi
8536       fi
8537       rm -f conftest.* libconftest.a
8538
8539 fi
8540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8541
8542 fi
8543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8544 $as_echo "$lt_cv_ar_at_file" >&6; }
8545
8546 if test no = "$lt_cv_ar_at_file"; then
8547   archiver_list_spec=
8548 else
8549   archiver_list_spec=$lt_cv_ar_at_file
8550 fi
8551
8552
8553
8554
8555
8556
8557
8558 if test -n "$ac_tool_prefix"; then
8559   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8560 set dummy ${ac_tool_prefix}strip; ac_word=$2
8561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8562 $as_echo_n "checking for $ac_word... " >&6; }
8563 if ${ac_cv_prog_STRIP+:} false; then :
8564   $as_echo_n "(cached) " >&6
8565 else
8566   if test -n "$STRIP"; then
8567   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8568 else
8569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8570 for as_dir in $PATH
8571 do
8572   IFS=$as_save_IFS
8573   test -z "$as_dir" && as_dir=.
8574     for ac_exec_ext in '' $ac_executable_extensions; do
8575   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8576     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8577     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8578     break 2
8579   fi
8580 done
8581   done
8582 IFS=$as_save_IFS
8583
8584 fi
8585 fi
8586 STRIP=$ac_cv_prog_STRIP
8587 if test -n "$STRIP"; then
8588   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8589 $as_echo "$STRIP" >&6; }
8590 else
8591   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8592 $as_echo "no" >&6; }
8593 fi
8594
8595
8596 fi
8597 if test -z "$ac_cv_prog_STRIP"; then
8598   ac_ct_STRIP=$STRIP
8599   # Extract the first word of "strip", so it can be a program name with args.
8600 set dummy strip; ac_word=$2
8601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8602 $as_echo_n "checking for $ac_word... " >&6; }
8603 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8604   $as_echo_n "(cached) " >&6
8605 else
8606   if test -n "$ac_ct_STRIP"; then
8607   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8608 else
8609 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8610 for as_dir in $PATH
8611 do
8612   IFS=$as_save_IFS
8613   test -z "$as_dir" && as_dir=.
8614     for ac_exec_ext in '' $ac_executable_extensions; do
8615   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8616     ac_cv_prog_ac_ct_STRIP="strip"
8617     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8618     break 2
8619   fi
8620 done
8621   done
8622 IFS=$as_save_IFS
8623
8624 fi
8625 fi
8626 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8627 if test -n "$ac_ct_STRIP"; then
8628   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8629 $as_echo "$ac_ct_STRIP" >&6; }
8630 else
8631   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8632 $as_echo "no" >&6; }
8633 fi
8634
8635   if test "x$ac_ct_STRIP" = x; then
8636     STRIP=":"
8637   else
8638     case $cross_compiling:$ac_tool_warned in
8639 yes:)
8640 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8641 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8642 ac_tool_warned=yes ;;
8643 esac
8644     STRIP=$ac_ct_STRIP
8645   fi
8646 else
8647   STRIP="$ac_cv_prog_STRIP"
8648 fi
8649
8650 test -z "$STRIP" && STRIP=:
8651
8652
8653
8654
8655
8656
8657 if test -n "$ac_tool_prefix"; then
8658   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8659 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8661 $as_echo_n "checking for $ac_word... " >&6; }
8662 if ${ac_cv_prog_RANLIB+:} false; then :
8663   $as_echo_n "(cached) " >&6
8664 else
8665   if test -n "$RANLIB"; then
8666   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8667 else
8668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8669 for as_dir in $PATH
8670 do
8671   IFS=$as_save_IFS
8672   test -z "$as_dir" && as_dir=.
8673     for ac_exec_ext in '' $ac_executable_extensions; do
8674   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8675     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8676     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8677     break 2
8678   fi
8679 done
8680   done
8681 IFS=$as_save_IFS
8682
8683 fi
8684 fi
8685 RANLIB=$ac_cv_prog_RANLIB
8686 if test -n "$RANLIB"; then
8687   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8688 $as_echo "$RANLIB" >&6; }
8689 else
8690   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8691 $as_echo "no" >&6; }
8692 fi
8693
8694
8695 fi
8696 if test -z "$ac_cv_prog_RANLIB"; then
8697   ac_ct_RANLIB=$RANLIB
8698   # Extract the first word of "ranlib", so it can be a program name with args.
8699 set dummy ranlib; ac_word=$2
8700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8701 $as_echo_n "checking for $ac_word... " >&6; }
8702 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8703   $as_echo_n "(cached) " >&6
8704 else
8705   if test -n "$ac_ct_RANLIB"; then
8706   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8707 else
8708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8709 for as_dir in $PATH
8710 do
8711   IFS=$as_save_IFS
8712   test -z "$as_dir" && as_dir=.
8713     for ac_exec_ext in '' $ac_executable_extensions; do
8714   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8715     ac_cv_prog_ac_ct_RANLIB="ranlib"
8716     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8717     break 2
8718   fi
8719 done
8720   done
8721 IFS=$as_save_IFS
8722
8723 fi
8724 fi
8725 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8726 if test -n "$ac_ct_RANLIB"; then
8727   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8728 $as_echo "$ac_ct_RANLIB" >&6; }
8729 else
8730   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8731 $as_echo "no" >&6; }
8732 fi
8733
8734   if test "x$ac_ct_RANLIB" = x; then
8735     RANLIB=":"
8736   else
8737     case $cross_compiling:$ac_tool_warned in
8738 yes:)
8739 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8740 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8741 ac_tool_warned=yes ;;
8742 esac
8743     RANLIB=$ac_ct_RANLIB
8744   fi
8745 else
8746   RANLIB="$ac_cv_prog_RANLIB"
8747 fi
8748
8749 test -z "$RANLIB" && RANLIB=:
8750
8751
8752
8753
8754
8755
8756 # Determine commands to create old-style static archives.
8757 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8758 old_postinstall_cmds='chmod 644 $oldlib'
8759 old_postuninstall_cmds=
8760
8761 if test -n "$RANLIB"; then
8762   case $host_os in
8763   bitrig* | openbsd*)
8764     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8765     ;;
8766   *)
8767     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8768     ;;
8769   esac
8770   old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8771 fi
8772
8773 case $host_os in
8774   darwin*)
8775     lock_old_archive_extraction=yes ;;
8776   *)
8777     lock_old_archive_extraction=no ;;
8778 esac
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798
8799
8800 for ac_prog in gawk mawk nawk awk
8801 do
8802   # Extract the first word of "$ac_prog", so it can be a program name with args.
8803 set dummy $ac_prog; ac_word=$2
8804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8805 $as_echo_n "checking for $ac_word... " >&6; }
8806 if ${ac_cv_prog_AWK+:} false; then :
8807   $as_echo_n "(cached) " >&6
8808 else
8809   if test -n "$AWK"; then
8810   ac_cv_prog_AWK="$AWK" # Let the user override the test.
8811 else
8812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8813 for as_dir in $PATH
8814 do
8815   IFS=$as_save_IFS
8816   test -z "$as_dir" && as_dir=.
8817     for ac_exec_ext in '' $ac_executable_extensions; do
8818   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8819     ac_cv_prog_AWK="$ac_prog"
8820     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8821     break 2
8822   fi
8823 done
8824   done
8825 IFS=$as_save_IFS
8826
8827 fi
8828 fi
8829 AWK=$ac_cv_prog_AWK
8830 if test -n "$AWK"; then
8831   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
8832 $as_echo "$AWK" >&6; }
8833 else
8834   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8835 $as_echo "no" >&6; }
8836 fi
8837
8838
8839   test -n "$AWK" && break
8840 done
8841
8842
8843
8844
8845
8846
8847
8848
8849
8850
8851
8852
8853
8854
8855
8856
8857
8858
8859
8860 # If no C compiler was specified, use CC.
8861 LTCC=${LTCC-"$CC"}
8862
8863 # If no C compiler flags were specified, use CFLAGS.
8864 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8865
8866 # Allow CC to be a program name with arguments.
8867 compiler=$CC
8868
8869
8870 # Check for command to grab the raw symbol name followed by C symbol from nm.
8871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8872 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8873 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8874   $as_echo_n "(cached) " >&6
8875 else
8876
8877 # These are sane defaults that work on at least a few old systems.
8878 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
8879
8880 # Character class describing NM global symbol codes.
8881 symcode='[BCDEGRST]'
8882
8883 # Regexp to match symbols that can be accessed directly from C.
8884 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8885
8886 # Define system-specific variables.
8887 case $host_os in
8888 aix*)
8889   symcode='[BCDT]'
8890   ;;
8891 cygwin* | mingw* | pw32* | cegcc*)
8892   symcode='[ABCDGISTW]'
8893   ;;
8894 hpux*)
8895   if test ia64 = "$host_cpu"; then
8896     symcode='[ABCDEGRST]'
8897   fi
8898   ;;
8899 irix* | nonstopux*)
8900   symcode='[BCDEGRST]'
8901   ;;
8902 osf*)
8903   symcode='[BCDEGQRST]'
8904   ;;
8905 solaris*)
8906   symcode='[BDRT]'
8907   ;;
8908 sco3.2v5*)
8909   symcode='[DT]'
8910   ;;
8911 sysv4.2uw2*)
8912   symcode='[DT]'
8913   ;;
8914 sysv5* | sco5v6* | unixware* | OpenUNIX*)
8915   symcode='[ABDT]'
8916   ;;
8917 sysv4)
8918   symcode='[DFNSTU]'
8919   ;;
8920 esac
8921
8922 # If we're using GNU nm, then use its standard symbol codes.
8923 case `$NM -V 2>&1` in
8924 *GNU* | *'with BFD'*)
8925   symcode='[ABCDGIRSTW]' ;;
8926 esac
8927
8928 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8929   # Gets list of data symbols to import.
8930   lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
8931   # Adjust the below global symbol transforms to fixup imported variables.
8932   lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
8933   lt_c_name_hook=" -e 's/^I .* \(.*\)$/  {\"\1\", (void *) 0},/p'"
8934   lt_c_name_lib_hook="\
8935   -e 's/^I .* \(lib.*\)$/  {\"\1\", (void *) 0},/p'\
8936   -e 's/^I .* \(.*\)$/  {\"lib\1\", (void *) 0},/p'"
8937 else
8938   # Disable hooks by default.
8939   lt_cv_sys_global_symbol_to_import=
8940   lt_cdecl_hook=
8941   lt_c_name_hook=
8942   lt_c_name_lib_hook=
8943 fi
8944
8945 # Transform an extracted symbol line into a proper C declaration.
8946 # Some systems (esp. on ia64) link data and code symbols differently,
8947 # so use this general approach.
8948 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
8949 $lt_cdecl_hook\
8950 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
8951 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
8952
8953 # Transform an extracted symbol line into symbol name and symbol address
8954 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
8955 $lt_c_name_hook\
8956 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8957 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/p'"
8958
8959 # Transform an extracted symbol line into symbol name with lib prefix and
8960 # symbol address.
8961 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
8962 $lt_c_name_lib_hook\
8963 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8964 " -e 's/^$symcode$symcode* .* \(lib.*\)$/  {\"\1\", (void *) \&\1},/p'"\
8965 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"lib\1\", (void *) \&\1},/p'"
8966
8967 # Handle CRLF in mingw tool chain
8968 opt_cr=
8969 case $build_os in
8970 mingw*)
8971   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8972   ;;
8973 esac
8974
8975 # Try without a prefix underscore, then with it.
8976 for ac_symprfx in "" "_"; do
8977
8978   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8979   symxfrm="\\1 $ac_symprfx\\2 \\2"
8980
8981   # Write the raw and C identifiers.
8982   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8983     # Fake it for dumpbin and say T for any non-static function,
8984     # D for any global variable and I for any imported variable.
8985     # Also find C++ and __fastcall symbols from MSVC++,
8986     # which start with @ or ?.
8987     lt_cv_sys_global_symbol_pipe="$AWK '"\
8988 "     {last_section=section; section=\$ 3};"\
8989 "     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8990 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8991 "     /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
8992 "     /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
8993 "     /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
8994 "     \$ 0!~/External *\|/{next};"\
8995 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8996 "     {if(hide[section]) next};"\
8997 "     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
8998 "     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
8999 "     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
9000 "     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
9001 "     ' prfx=^$ac_symprfx"
9002   else
9003     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
9004   fi
9005   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
9006
9007   # Check to see that the pipe works correctly.
9008   pipe_works=no
9009
9010   rm -f conftest*
9011   cat > conftest.$ac_ext <<_LT_EOF
9012 #ifdef __cplusplus
9013 extern "C" {
9014 #endif
9015 char nm_test_var;
9016 void nm_test_func(void);
9017 void nm_test_func(void){}
9018 #ifdef __cplusplus
9019 }
9020 #endif
9021 int main(){nm_test_var='a';nm_test_func();return(0);}
9022 _LT_EOF
9023
9024   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9025   (eval $ac_compile) 2>&5
9026   ac_status=$?
9027   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9028   test $ac_status = 0; }; then
9029     # Now try to grab the symbols.
9030     nlist=conftest.nm
9031     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
9032   (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
9033   ac_status=$?
9034   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9035   test $ac_status = 0; } && test -s "$nlist"; then
9036       # Try sorting and uniquifying the output.
9037       if sort "$nlist" | uniq > "$nlist"T; then
9038         mv -f "$nlist"T "$nlist"
9039       else
9040         rm -f "$nlist"T
9041       fi
9042
9043       # Make sure that we snagged all the symbols we need.
9044       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
9045         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9046           cat <<_LT_EOF > conftest.$ac_ext
9047 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
9048 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
9049 /* DATA imports from DLLs on WIN32 can't be const, because runtime
9050    relocations are performed -- see ld's documentation on pseudo-relocs.  */
9051 # define LT_DLSYM_CONST
9052 #elif defined __osf__
9053 /* This system does not cope well with relocations in const data.  */
9054 # define LT_DLSYM_CONST
9055 #else
9056 # define LT_DLSYM_CONST const
9057 #endif
9058
9059 #ifdef __cplusplus
9060 extern "C" {
9061 #endif
9062
9063 _LT_EOF
9064           # Now generate the symbol file.
9065           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9066
9067           cat <<_LT_EOF >> conftest.$ac_ext
9068
9069 /* The mapping between symbol names and symbols.  */
9070 LT_DLSYM_CONST struct {
9071   const char *name;
9072   void       *address;
9073 }
9074 lt__PROGRAM__LTX_preloaded_symbols[] =
9075 {
9076   { "@PROGRAM@", (void *) 0 },
9077 _LT_EOF
9078           $SED "s/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9079           cat <<\_LT_EOF >> conftest.$ac_ext
9080   {0, (void *) 0}
9081 };
9082
9083 /* This works around a problem in FreeBSD linker */
9084 #ifdef FREEBSD_WORKAROUND
9085 static const void *lt_preloaded_setup() {
9086   return lt__PROGRAM__LTX_preloaded_symbols;
9087 }
9088 #endif
9089
9090 #ifdef __cplusplus
9091 }
9092 #endif
9093 _LT_EOF
9094           # Now try linking the two files.
9095           mv conftest.$ac_objext conftstm.$ac_objext
9096           lt_globsym_save_LIBS=$LIBS
9097           lt_globsym_save_CFLAGS=$CFLAGS
9098           LIBS=conftstm.$ac_objext
9099           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9100           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9101   (eval $ac_link) 2>&5
9102   ac_status=$?
9103   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9104   test $ac_status = 0; } && test -s conftest$ac_exeext; then
9105             pipe_works=yes
9106           fi
9107           LIBS=$lt_globsym_save_LIBS
9108           CFLAGS=$lt_globsym_save_CFLAGS
9109         else
9110           echo "cannot find nm_test_func in $nlist" >&5
9111         fi
9112       else
9113         echo "cannot find nm_test_var in $nlist" >&5
9114       fi
9115     else
9116       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9117     fi
9118   else
9119     echo "$progname: failed program was:" >&5
9120     cat conftest.$ac_ext >&5
9121   fi
9122   rm -rf conftest* conftst*
9123
9124   # Do not use the global_symbol_pipe unless it works.
9125   if test yes = "$pipe_works"; then
9126     break
9127   else
9128     lt_cv_sys_global_symbol_pipe=
9129   fi
9130 done
9131
9132 fi
9133
9134 if test -z "$lt_cv_sys_global_symbol_pipe"; then
9135   lt_cv_sys_global_symbol_to_cdecl=
9136 fi
9137 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9138   { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9139 $as_echo "failed" >&6; }
9140 else
9141   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9142 $as_echo "ok" >&6; }
9143 fi
9144
9145 # Response file support.
9146 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9147   nm_file_list_spec='@'
9148 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9149   nm_file_list_spec='@'
9150 fi
9151
9152
9153
9154
9155
9156
9157
9158
9159
9160
9161
9162
9163
9164
9165
9166
9167
9168
9169
9170
9171
9172
9173
9174
9175
9176
9177
9178
9179
9180
9181
9182
9183
9184
9185
9186
9187
9188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9189 $as_echo_n "checking for sysroot... " >&6; }
9190
9191 # Check whether --with-sysroot was given.
9192 if test "${with_sysroot+set}" = set; then :
9193   withval=$with_sysroot;
9194 else
9195   with_sysroot=no
9196 fi
9197
9198
9199 lt_sysroot=
9200 case $with_sysroot in #(
9201  yes)
9202    if test yes = "$GCC"; then
9203      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9204    fi
9205    ;; #(
9206  /*)
9207    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9208    ;; #(
9209  no|'')
9210    ;; #(
9211  *)
9212    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9213 $as_echo "$with_sysroot" >&6; }
9214    as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9215    ;;
9216 esac
9217
9218  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9219 $as_echo "${lt_sysroot:-no}" >&6; }
9220
9221
9222
9223
9224
9225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9226 $as_echo_n "checking for a working dd... " >&6; }
9227 if ${ac_cv_path_lt_DD+:} false; then :
9228   $as_echo_n "(cached) " >&6
9229 else
9230   printf 0123456789abcdef0123456789abcdef >conftest.i
9231 cat conftest.i conftest.i >conftest2.i
9232 : ${lt_DD:=$DD}
9233 if test -z "$lt_DD"; then
9234   ac_path_lt_DD_found=false
9235   # Loop through the user's path and test for each of PROGNAME-LIST
9236   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9237 for as_dir in $PATH
9238 do
9239   IFS=$as_save_IFS
9240   test -z "$as_dir" && as_dir=.
9241     for ac_prog in dd; do
9242     for ac_exec_ext in '' $ac_executable_extensions; do
9243       ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9244       as_fn_executable_p "$ac_path_lt_DD" || continue
9245 if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9246   cmp -s conftest.i conftest.out \
9247   && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9248 fi
9249       $ac_path_lt_DD_found && break 3
9250     done
9251   done
9252   done
9253 IFS=$as_save_IFS
9254   if test -z "$ac_cv_path_lt_DD"; then
9255     :
9256   fi
9257 else
9258   ac_cv_path_lt_DD=$lt_DD
9259 fi
9260
9261 rm -f conftest.i conftest2.i conftest.out
9262 fi
9263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9264 $as_echo "$ac_cv_path_lt_DD" >&6; }
9265
9266
9267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9268 $as_echo_n "checking how to truncate binary pipes... " >&6; }
9269 if ${lt_cv_truncate_bin+:} false; then :
9270   $as_echo_n "(cached) " >&6
9271 else
9272   printf 0123456789abcdef0123456789abcdef >conftest.i
9273 cat conftest.i conftest.i >conftest2.i
9274 lt_cv_truncate_bin=
9275 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9276   cmp -s conftest.i conftest.out \
9277   && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9278 fi
9279 rm -f conftest.i conftest2.i conftest.out
9280 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9281 fi
9282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9283 $as_echo "$lt_cv_truncate_bin" >&6; }
9284
9285
9286
9287
9288
9289
9290
9291 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
9292 func_cc_basename ()
9293 {
9294     for cc_temp in $*""; do
9295       case $cc_temp in
9296         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9297         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9298         \-*) ;;
9299         *) break;;
9300       esac
9301     done
9302     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9303 }
9304
9305 # Check whether --enable-libtool-lock was given.
9306 if test "${enable_libtool_lock+set}" = set; then :
9307   enableval=$enable_libtool_lock;
9308 fi
9309
9310 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9311
9312 # Some flags need to be propagated to the compiler or linker for good
9313 # libtool support.
9314 case $host in
9315 ia64-*-hpux*)
9316   # Find out what ABI is being produced by ac_compile, and set mode
9317   # options accordingly.
9318   echo 'int i;' > conftest.$ac_ext
9319   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9320   (eval $ac_compile) 2>&5
9321   ac_status=$?
9322   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9323   test $ac_status = 0; }; then
9324     case `/usr/bin/file conftest.$ac_objext` in
9325       *ELF-32*)
9326         HPUX_IA64_MODE=32
9327         ;;
9328       *ELF-64*)
9329         HPUX_IA64_MODE=64
9330         ;;
9331     esac
9332   fi
9333   rm -rf conftest*
9334   ;;
9335 *-*-irix6*)
9336   # Find out what ABI is being produced by ac_compile, and set linker
9337   # options accordingly.
9338   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9339   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9340   (eval $ac_compile) 2>&5
9341   ac_status=$?
9342   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9343   test $ac_status = 0; }; then
9344     if test yes = "$lt_cv_prog_gnu_ld"; then
9345       case `/usr/bin/file conftest.$ac_objext` in
9346         *32-bit*)
9347           LD="${LD-ld} -melf32bsmip"
9348           ;;
9349         *N32*)
9350           LD="${LD-ld} -melf32bmipn32"
9351           ;;
9352         *64-bit*)
9353           LD="${LD-ld} -melf64bmip"
9354         ;;
9355       esac
9356     else
9357       case `/usr/bin/file conftest.$ac_objext` in
9358         *32-bit*)
9359           LD="${LD-ld} -32"
9360           ;;
9361         *N32*)
9362           LD="${LD-ld} -n32"
9363           ;;
9364         *64-bit*)
9365           LD="${LD-ld} -64"
9366           ;;
9367       esac
9368     fi
9369   fi
9370   rm -rf conftest*
9371   ;;
9372
9373 mips64*-*linux*)
9374   # Find out what ABI is being produced by ac_compile, and set linker
9375   # options accordingly.
9376   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9377   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9378   (eval $ac_compile) 2>&5
9379   ac_status=$?
9380   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9381   test $ac_status = 0; }; then
9382     emul=elf
9383     case `/usr/bin/file conftest.$ac_objext` in
9384       *32-bit*)
9385         emul="${emul}32"
9386         ;;
9387       *64-bit*)
9388         emul="${emul}64"
9389         ;;
9390     esac
9391     case `/usr/bin/file conftest.$ac_objext` in
9392       *MSB*)
9393         emul="${emul}btsmip"
9394         ;;
9395       *LSB*)
9396         emul="${emul}ltsmip"
9397         ;;
9398     esac
9399     case `/usr/bin/file conftest.$ac_objext` in
9400       *N32*)
9401         emul="${emul}n32"
9402         ;;
9403     esac
9404     LD="${LD-ld} -m $emul"
9405   fi
9406   rm -rf conftest*
9407   ;;
9408
9409 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9410 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9411   # Find out what ABI is being produced by ac_compile, and set linker
9412   # options accordingly.  Note that the listed cases only cover the
9413   # situations where additional linker options are needed (such as when
9414   # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9415   # vice versa); the common cases where no linker options are needed do
9416   # not appear in the list.
9417   echo 'int i;' > conftest.$ac_ext
9418   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9419   (eval $ac_compile) 2>&5
9420   ac_status=$?
9421   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9422   test $ac_status = 0; }; then
9423     case `/usr/bin/file conftest.o` in
9424       *32-bit*)
9425         case $host in
9426           x86_64-*kfreebsd*-gnu)
9427             LD="${LD-ld} -m elf_i386_fbsd"
9428             ;;
9429           x86_64-*linux*)
9430             case `/usr/bin/file conftest.o` in
9431               *x86-64*)
9432                 LD="${LD-ld} -m elf32_x86_64"
9433                 ;;
9434               *)
9435                 LD="${LD-ld} -m elf_i386"
9436                 ;;
9437             esac
9438             ;;
9439           powerpc64le-*linux*)
9440             LD="${LD-ld} -m elf32lppclinux"
9441             ;;
9442           powerpc64-*linux*)
9443             LD="${LD-ld} -m elf32ppclinux"
9444             ;;
9445           s390x-*linux*)
9446             LD="${LD-ld} -m elf_s390"
9447             ;;
9448           sparc64-*linux*)
9449             LD="${LD-ld} -m elf32_sparc"
9450             ;;
9451         esac
9452         ;;
9453       *64-bit*)
9454         case $host in
9455           x86_64-*kfreebsd*-gnu)
9456             LD="${LD-ld} -m elf_x86_64_fbsd"
9457             ;;
9458           x86_64-*linux*)
9459             LD="${LD-ld} -m elf_x86_64"
9460             ;;
9461           powerpcle-*linux*)
9462             LD="${LD-ld} -m elf64lppc"
9463             ;;
9464           powerpc-*linux*)
9465             LD="${LD-ld} -m elf64ppc"
9466             ;;
9467           s390*-*linux*|s390*-*tpf*)
9468             LD="${LD-ld} -m elf64_s390"
9469             ;;
9470           sparc*-*linux*)
9471             LD="${LD-ld} -m elf64_sparc"
9472             ;;
9473         esac
9474         ;;
9475     esac
9476   fi
9477   rm -rf conftest*
9478   ;;
9479
9480 *-*-sco3.2v5*)
9481   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9482   SAVE_CFLAGS=$CFLAGS
9483   CFLAGS="$CFLAGS -belf"
9484   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9485 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9486 if ${lt_cv_cc_needs_belf+:} false; then :
9487   $as_echo_n "(cached) " >&6
9488 else
9489   ac_ext=c
9490 ac_cpp='$CPP $CPPFLAGS'
9491 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9492 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9493 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9494
9495      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9496 /* end confdefs.h.  */
9497
9498 int
9499 main ()
9500 {
9501
9502   ;
9503   return 0;
9504 }
9505 _ACEOF
9506 if ac_fn_c_try_link "$LINENO"; then :
9507   lt_cv_cc_needs_belf=yes
9508 else
9509   lt_cv_cc_needs_belf=no
9510 fi
9511 rm -f core conftest.err conftest.$ac_objext \
9512     conftest$ac_exeext conftest.$ac_ext
9513      ac_ext=c
9514 ac_cpp='$CPP $CPPFLAGS'
9515 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9516 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9517 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9518
9519 fi
9520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9521 $as_echo "$lt_cv_cc_needs_belf" >&6; }
9522   if test yes != "$lt_cv_cc_needs_belf"; then
9523     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9524     CFLAGS=$SAVE_CFLAGS
9525   fi
9526   ;;
9527 *-*solaris*)
9528   # Find out what ABI is being produced by ac_compile, and set linker
9529   # options accordingly.
9530   echo 'int i;' > conftest.$ac_ext
9531   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9532   (eval $ac_compile) 2>&5
9533   ac_status=$?
9534   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9535   test $ac_status = 0; }; then
9536     case `/usr/bin/file conftest.o` in
9537     *64-bit*)
9538       case $lt_cv_prog_gnu_ld in
9539       yes*)
9540         case $host in
9541         i?86-*-solaris*|x86_64-*-solaris*)
9542           LD="${LD-ld} -m elf_x86_64"
9543           ;;
9544         sparc*-*-solaris*)
9545           LD="${LD-ld} -m elf64_sparc"
9546           ;;
9547         esac
9548         # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
9549         if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9550           LD=${LD-ld}_sol2
9551         fi
9552         ;;
9553       *)
9554         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9555           LD="${LD-ld} -64"
9556         fi
9557         ;;
9558       esac
9559       ;;
9560     esac
9561   fi
9562   rm -rf conftest*
9563   ;;
9564 esac
9565
9566 need_locks=$enable_libtool_lock
9567
9568 if test -n "$ac_tool_prefix"; then
9569   # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9570 set dummy ${ac_tool_prefix}mt; ac_word=$2
9571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9572 $as_echo_n "checking for $ac_word... " >&6; }
9573 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9574   $as_echo_n "(cached) " >&6
9575 else
9576   if test -n "$MANIFEST_TOOL"; then
9577   ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9578 else
9579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9580 for as_dir in $PATH
9581 do
9582   IFS=$as_save_IFS
9583   test -z "$as_dir" && as_dir=.
9584     for ac_exec_ext in '' $ac_executable_extensions; do
9585   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9586     ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9587     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9588     break 2
9589   fi
9590 done
9591   done
9592 IFS=$as_save_IFS
9593
9594 fi
9595 fi
9596 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9597 if test -n "$MANIFEST_TOOL"; then
9598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9599 $as_echo "$MANIFEST_TOOL" >&6; }
9600 else
9601   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9602 $as_echo "no" >&6; }
9603 fi
9604
9605
9606 fi
9607 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9608   ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9609   # Extract the first word of "mt", so it can be a program name with args.
9610 set dummy mt; ac_word=$2
9611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9612 $as_echo_n "checking for $ac_word... " >&6; }
9613 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9614   $as_echo_n "(cached) " >&6
9615 else
9616   if test -n "$ac_ct_MANIFEST_TOOL"; then
9617   ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9618 else
9619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9620 for as_dir in $PATH
9621 do
9622   IFS=$as_save_IFS
9623   test -z "$as_dir" && as_dir=.
9624     for ac_exec_ext in '' $ac_executable_extensions; do
9625   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9626     ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9627     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9628     break 2
9629   fi
9630 done
9631   done
9632 IFS=$as_save_IFS
9633
9634 fi
9635 fi
9636 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9637 if test -n "$ac_ct_MANIFEST_TOOL"; then
9638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9639 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9640 else
9641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9642 $as_echo "no" >&6; }
9643 fi
9644
9645   if test "x$ac_ct_MANIFEST_TOOL" = x; then
9646     MANIFEST_TOOL=":"
9647   else
9648     case $cross_compiling:$ac_tool_warned in
9649 yes:)
9650 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9651 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9652 ac_tool_warned=yes ;;
9653 esac
9654     MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9655   fi
9656 else
9657   MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9658 fi
9659
9660 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9662 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9663 if ${lt_cv_path_mainfest_tool+:} false; then :
9664   $as_echo_n "(cached) " >&6
9665 else
9666   lt_cv_path_mainfest_tool=no
9667   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9668   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9669   cat conftest.err >&5
9670   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9671     lt_cv_path_mainfest_tool=yes
9672   fi
9673   rm -f conftest*
9674 fi
9675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9676 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
9677 if test yes != "$lt_cv_path_mainfest_tool"; then
9678   MANIFEST_TOOL=:
9679 fi
9680
9681
9682
9683
9684
9685
9686   case $host_os in
9687     rhapsody* | darwin*)
9688     if test -n "$ac_tool_prefix"; then
9689   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9690 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9692 $as_echo_n "checking for $ac_word... " >&6; }
9693 if ${ac_cv_prog_DSYMUTIL+:} false; then :
9694   $as_echo_n "(cached) " >&6
9695 else
9696   if test -n "$DSYMUTIL"; then
9697   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9698 else
9699 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9700 for as_dir in $PATH
9701 do
9702   IFS=$as_save_IFS
9703   test -z "$as_dir" && as_dir=.
9704     for ac_exec_ext in '' $ac_executable_extensions; do
9705   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9706     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9707     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9708     break 2
9709   fi
9710 done
9711   done
9712 IFS=$as_save_IFS
9713
9714 fi
9715 fi
9716 DSYMUTIL=$ac_cv_prog_DSYMUTIL
9717 if test -n "$DSYMUTIL"; then
9718   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9719 $as_echo "$DSYMUTIL" >&6; }
9720 else
9721   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9722 $as_echo "no" >&6; }
9723 fi
9724
9725
9726 fi
9727 if test -z "$ac_cv_prog_DSYMUTIL"; then
9728   ac_ct_DSYMUTIL=$DSYMUTIL
9729   # Extract the first word of "dsymutil", so it can be a program name with args.
9730 set dummy dsymutil; ac_word=$2
9731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9732 $as_echo_n "checking for $ac_word... " >&6; }
9733 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9734   $as_echo_n "(cached) " >&6
9735 else
9736   if test -n "$ac_ct_DSYMUTIL"; then
9737   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9738 else
9739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9740 for as_dir in $PATH
9741 do
9742   IFS=$as_save_IFS
9743   test -z "$as_dir" && as_dir=.
9744     for ac_exec_ext in '' $ac_executable_extensions; do
9745   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9746     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9747     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9748     break 2
9749   fi
9750 done
9751   done
9752 IFS=$as_save_IFS
9753
9754 fi
9755 fi
9756 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9757 if test -n "$ac_ct_DSYMUTIL"; then
9758   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9759 $as_echo "$ac_ct_DSYMUTIL" >&6; }
9760 else
9761   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9762 $as_echo "no" >&6; }
9763 fi
9764
9765   if test "x$ac_ct_DSYMUTIL" = x; then
9766     DSYMUTIL=":"
9767   else
9768     case $cross_compiling:$ac_tool_warned in
9769 yes:)
9770 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9771 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9772 ac_tool_warned=yes ;;
9773 esac
9774     DSYMUTIL=$ac_ct_DSYMUTIL
9775   fi
9776 else
9777   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9778 fi
9779
9780     if test -n "$ac_tool_prefix"; then
9781   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9782 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9784 $as_echo_n "checking for $ac_word... " >&6; }
9785 if ${ac_cv_prog_NMEDIT+:} false; then :
9786   $as_echo_n "(cached) " >&6
9787 else
9788   if test -n "$NMEDIT"; then
9789   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9790 else
9791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9792 for as_dir in $PATH
9793 do
9794   IFS=$as_save_IFS
9795   test -z "$as_dir" && as_dir=.
9796     for ac_exec_ext in '' $ac_executable_extensions; do
9797   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9798     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9799     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9800     break 2
9801   fi
9802 done
9803   done
9804 IFS=$as_save_IFS
9805
9806 fi
9807 fi
9808 NMEDIT=$ac_cv_prog_NMEDIT
9809 if test -n "$NMEDIT"; then
9810   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9811 $as_echo "$NMEDIT" >&6; }
9812 else
9813   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9814 $as_echo "no" >&6; }
9815 fi
9816
9817
9818 fi
9819 if test -z "$ac_cv_prog_NMEDIT"; then
9820   ac_ct_NMEDIT=$NMEDIT
9821   # Extract the first word of "nmedit", so it can be a program name with args.
9822 set dummy nmedit; ac_word=$2
9823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9824 $as_echo_n "checking for $ac_word... " >&6; }
9825 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9826   $as_echo_n "(cached) " >&6
9827 else
9828   if test -n "$ac_ct_NMEDIT"; then
9829   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9830 else
9831 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9832 for as_dir in $PATH
9833 do
9834   IFS=$as_save_IFS
9835   test -z "$as_dir" && as_dir=.
9836     for ac_exec_ext in '' $ac_executable_extensions; do
9837   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9838     ac_cv_prog_ac_ct_NMEDIT="nmedit"
9839     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9840     break 2
9841   fi
9842 done
9843   done
9844 IFS=$as_save_IFS
9845
9846 fi
9847 fi
9848 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9849 if test -n "$ac_ct_NMEDIT"; then
9850   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9851 $as_echo "$ac_ct_NMEDIT" >&6; }
9852 else
9853   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9854 $as_echo "no" >&6; }
9855 fi
9856
9857   if test "x$ac_ct_NMEDIT" = x; then
9858     NMEDIT=":"
9859   else
9860     case $cross_compiling:$ac_tool_warned in
9861 yes:)
9862 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9863 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9864 ac_tool_warned=yes ;;
9865 esac
9866     NMEDIT=$ac_ct_NMEDIT
9867   fi
9868 else
9869   NMEDIT="$ac_cv_prog_NMEDIT"
9870 fi
9871
9872     if test -n "$ac_tool_prefix"; then
9873   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9874 set dummy ${ac_tool_prefix}lipo; ac_word=$2
9875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9876 $as_echo_n "checking for $ac_word... " >&6; }
9877 if ${ac_cv_prog_LIPO+:} false; then :
9878   $as_echo_n "(cached) " >&6
9879 else
9880   if test -n "$LIPO"; then
9881   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9882 else
9883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9884 for as_dir in $PATH
9885 do
9886   IFS=$as_save_IFS
9887   test -z "$as_dir" && as_dir=.
9888     for ac_exec_ext in '' $ac_executable_extensions; do
9889   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9890     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9891     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9892     break 2
9893   fi
9894 done
9895   done
9896 IFS=$as_save_IFS
9897
9898 fi
9899 fi
9900 LIPO=$ac_cv_prog_LIPO
9901 if test -n "$LIPO"; then
9902   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9903 $as_echo "$LIPO" >&6; }
9904 else
9905   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9906 $as_echo "no" >&6; }
9907 fi
9908
9909
9910 fi
9911 if test -z "$ac_cv_prog_LIPO"; then
9912   ac_ct_LIPO=$LIPO
9913   # Extract the first word of "lipo", so it can be a program name with args.
9914 set dummy lipo; ac_word=$2
9915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9916 $as_echo_n "checking for $ac_word... " >&6; }
9917 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9918   $as_echo_n "(cached) " >&6
9919 else
9920   if test -n "$ac_ct_LIPO"; then
9921   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9922 else
9923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9924 for as_dir in $PATH
9925 do
9926   IFS=$as_save_IFS
9927   test -z "$as_dir" && as_dir=.
9928     for ac_exec_ext in '' $ac_executable_extensions; do
9929   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9930     ac_cv_prog_ac_ct_LIPO="lipo"
9931     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9932     break 2
9933   fi
9934 done
9935   done
9936 IFS=$as_save_IFS
9937
9938 fi
9939 fi
9940 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9941 if test -n "$ac_ct_LIPO"; then
9942   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9943 $as_echo "$ac_ct_LIPO" >&6; }
9944 else
9945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9946 $as_echo "no" >&6; }
9947 fi
9948
9949   if test "x$ac_ct_LIPO" = x; then
9950     LIPO=":"
9951   else
9952     case $cross_compiling:$ac_tool_warned in
9953 yes:)
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9955 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9956 ac_tool_warned=yes ;;
9957 esac
9958     LIPO=$ac_ct_LIPO
9959   fi
9960 else
9961   LIPO="$ac_cv_prog_LIPO"
9962 fi
9963
9964     if test -n "$ac_tool_prefix"; then
9965   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9966 set dummy ${ac_tool_prefix}otool; ac_word=$2
9967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9968 $as_echo_n "checking for $ac_word... " >&6; }
9969 if ${ac_cv_prog_OTOOL+:} false; then :
9970   $as_echo_n "(cached) " >&6
9971 else
9972   if test -n "$OTOOL"; then
9973   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9974 else
9975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9976 for as_dir in $PATH
9977 do
9978   IFS=$as_save_IFS
9979   test -z "$as_dir" && as_dir=.
9980     for ac_exec_ext in '' $ac_executable_extensions; do
9981   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9982     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9983     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9984     break 2
9985   fi
9986 done
9987   done
9988 IFS=$as_save_IFS
9989
9990 fi
9991 fi
9992 OTOOL=$ac_cv_prog_OTOOL
9993 if test -n "$OTOOL"; then
9994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9995 $as_echo "$OTOOL" >&6; }
9996 else
9997   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9998 $as_echo "no" >&6; }
9999 fi
10000
10001
10002 fi
10003 if test -z "$ac_cv_prog_OTOOL"; then
10004   ac_ct_OTOOL=$OTOOL
10005   # Extract the first word of "otool", so it can be a program name with args.
10006 set dummy otool; ac_word=$2
10007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10008 $as_echo_n "checking for $ac_word... " >&6; }
10009 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
10010   $as_echo_n "(cached) " >&6
10011 else
10012   if test -n "$ac_ct_OTOOL"; then
10013   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
10014 else
10015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10016 for as_dir in $PATH
10017 do
10018   IFS=$as_save_IFS
10019   test -z "$as_dir" && as_dir=.
10020     for ac_exec_ext in '' $ac_executable_extensions; do
10021   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10022     ac_cv_prog_ac_ct_OTOOL="otool"
10023     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10024     break 2
10025   fi
10026 done
10027   done
10028 IFS=$as_save_IFS
10029
10030 fi
10031 fi
10032 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
10033 if test -n "$ac_ct_OTOOL"; then
10034   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
10035 $as_echo "$ac_ct_OTOOL" >&6; }
10036 else
10037   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10038 $as_echo "no" >&6; }
10039 fi
10040
10041   if test "x$ac_ct_OTOOL" = x; then
10042     OTOOL=":"
10043   else
10044     case $cross_compiling:$ac_tool_warned in
10045 yes:)
10046 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10047 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10048 ac_tool_warned=yes ;;
10049 esac
10050     OTOOL=$ac_ct_OTOOL
10051   fi
10052 else
10053   OTOOL="$ac_cv_prog_OTOOL"
10054 fi
10055
10056     if test -n "$ac_tool_prefix"; then
10057   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
10058 set dummy ${ac_tool_prefix}otool64; ac_word=$2
10059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10060 $as_echo_n "checking for $ac_word... " >&6; }
10061 if ${ac_cv_prog_OTOOL64+:} false; then :
10062   $as_echo_n "(cached) " >&6
10063 else
10064   if test -n "$OTOOL64"; then
10065   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10066 else
10067 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10068 for as_dir in $PATH
10069 do
10070   IFS=$as_save_IFS
10071   test -z "$as_dir" && as_dir=.
10072     for ac_exec_ext in '' $ac_executable_extensions; do
10073   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10074     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10075     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10076     break 2
10077   fi
10078 done
10079   done
10080 IFS=$as_save_IFS
10081
10082 fi
10083 fi
10084 OTOOL64=$ac_cv_prog_OTOOL64
10085 if test -n "$OTOOL64"; then
10086   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10087 $as_echo "$OTOOL64" >&6; }
10088 else
10089   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10090 $as_echo "no" >&6; }
10091 fi
10092
10093
10094 fi
10095 if test -z "$ac_cv_prog_OTOOL64"; then
10096   ac_ct_OTOOL64=$OTOOL64
10097   # Extract the first word of "otool64", so it can be a program name with args.
10098 set dummy otool64; ac_word=$2
10099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10100 $as_echo_n "checking for $ac_word... " >&6; }
10101 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10102   $as_echo_n "(cached) " >&6
10103 else
10104   if test -n "$ac_ct_OTOOL64"; then
10105   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10106 else
10107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10108 for as_dir in $PATH
10109 do
10110   IFS=$as_save_IFS
10111   test -z "$as_dir" && as_dir=.
10112     for ac_exec_ext in '' $ac_executable_extensions; do
10113   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10114     ac_cv_prog_ac_ct_OTOOL64="otool64"
10115     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10116     break 2
10117   fi
10118 done
10119   done
10120 IFS=$as_save_IFS
10121
10122 fi
10123 fi
10124 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10125 if test -n "$ac_ct_OTOOL64"; then
10126   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10127 $as_echo "$ac_ct_OTOOL64" >&6; }
10128 else
10129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10130 $as_echo "no" >&6; }
10131 fi
10132
10133   if test "x$ac_ct_OTOOL64" = x; then
10134     OTOOL64=":"
10135   else
10136     case $cross_compiling:$ac_tool_warned in
10137 yes:)
10138 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10139 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10140 ac_tool_warned=yes ;;
10141 esac
10142     OTOOL64=$ac_ct_OTOOL64
10143   fi
10144 else
10145   OTOOL64="$ac_cv_prog_OTOOL64"
10146 fi
10147
10148
10149
10150
10151
10152
10153
10154
10155
10156
10157
10158
10159
10160
10161
10162
10163
10164
10165
10166
10167
10168
10169
10170
10171
10172
10173
10174     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10175 $as_echo_n "checking for -single_module linker flag... " >&6; }
10176 if ${lt_cv_apple_cc_single_mod+:} false; then :
10177   $as_echo_n "(cached) " >&6
10178 else
10179   lt_cv_apple_cc_single_mod=no
10180       if test -z "$LT_MULTI_MODULE"; then
10181         # By default we will add the -single_module flag. You can override
10182         # by either setting the environment variable LT_MULTI_MODULE
10183         # non-empty at configure time, or by adding -multi_module to the
10184         # link flags.
10185         rm -rf libconftest.dylib*
10186         echo "int foo(void){return 1;}" > conftest.c
10187         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10188 -dynamiclib -Wl,-single_module conftest.c" >&5
10189         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10190           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10191         _lt_result=$?
10192         # If there is a non-empty error log, and "single_module"
10193         # appears in it, assume the flag caused a linker warning
10194         if test -s conftest.err && $GREP single_module conftest.err; then
10195           cat conftest.err >&5
10196         # Otherwise, if the output was created with a 0 exit code from
10197         # the compiler, it worked.
10198         elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10199           lt_cv_apple_cc_single_mod=yes
10200         else
10201           cat conftest.err >&5
10202         fi
10203         rm -rf libconftest.dylib*
10204         rm -f conftest.*
10205       fi
10206 fi
10207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10208 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10209
10210     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10211 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10212 if ${lt_cv_ld_exported_symbols_list+:} false; then :
10213   $as_echo_n "(cached) " >&6
10214 else
10215   lt_cv_ld_exported_symbols_list=no
10216       save_LDFLAGS=$LDFLAGS
10217       echo "_main" > conftest.sym
10218       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10219       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10220 /* end confdefs.h.  */
10221
10222 int
10223 main ()
10224 {
10225
10226   ;
10227   return 0;
10228 }
10229 _ACEOF
10230 if ac_fn_c_try_link "$LINENO"; then :
10231   lt_cv_ld_exported_symbols_list=yes
10232 else
10233   lt_cv_ld_exported_symbols_list=no
10234 fi
10235 rm -f core conftest.err conftest.$ac_objext \
10236     conftest$ac_exeext conftest.$ac_ext
10237         LDFLAGS=$save_LDFLAGS
10238
10239 fi
10240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10241 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10242
10243     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10244 $as_echo_n "checking for -force_load linker flag... " >&6; }
10245 if ${lt_cv_ld_force_load+:} false; then :
10246   $as_echo_n "(cached) " >&6
10247 else
10248   lt_cv_ld_force_load=no
10249       cat > conftest.c << _LT_EOF
10250 int forced_loaded() { return 2;}
10251 _LT_EOF
10252       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10253       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10254       echo "$AR cru libconftest.a conftest.o" >&5
10255       $AR cru libconftest.a conftest.o 2>&5
10256       echo "$RANLIB libconftest.a" >&5
10257       $RANLIB libconftest.a 2>&5
10258       cat > conftest.c << _LT_EOF
10259 int main() { return 0;}
10260 _LT_EOF
10261       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10262       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10263       _lt_result=$?
10264       if test -s conftest.err && $GREP force_load conftest.err; then
10265         cat conftest.err >&5
10266       elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10267         lt_cv_ld_force_load=yes
10268       else
10269         cat conftest.err >&5
10270       fi
10271         rm -f conftest.err libconftest.a conftest conftest.c
10272         rm -rf conftest.dSYM
10273
10274 fi
10275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10276 $as_echo "$lt_cv_ld_force_load" >&6; }
10277     case $host_os in
10278     rhapsody* | darwin1.[012])
10279       _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10280     darwin1.*)
10281       _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10282     darwin*) # darwin 5.x on
10283       # if running on 10.5 or later, the deployment target defaults
10284       # to the OS version, if on x86, and 10.4, the deployment
10285       # target defaults to 10.4. Don't you love it?
10286       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10287         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10288           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10289         10.[012][,.]*)
10290           _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10291         10.*)
10292           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10293       esac
10294     ;;
10295   esac
10296     if test yes = "$lt_cv_apple_cc_single_mod"; then
10297       _lt_dar_single_mod='$single_module'
10298     fi
10299     if test yes = "$lt_cv_ld_exported_symbols_list"; then
10300       _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10301     else
10302       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10303     fi
10304     if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10305       _lt_dsymutil='~$DSYMUTIL $lib || :'
10306     else
10307       _lt_dsymutil=
10308     fi
10309     ;;
10310   esac
10311
10312 # func_munge_path_list VARIABLE PATH
10313 # -----------------------------------
10314 # VARIABLE is name of variable containing _space_ separated list of
10315 # directories to be munged by the contents of PATH, which is string
10316 # having a format:
10317 # "DIR[:DIR]:"
10318 #       string "DIR[ DIR]" will be prepended to VARIABLE
10319 # ":DIR[:DIR]"
10320 #       string "DIR[ DIR]" will be appended to VARIABLE
10321 # "DIRP[:DIRP]::[DIRA:]DIRA"
10322 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10323 #       "DIRA[ DIRA]" will be appended to VARIABLE
10324 # "DIR[:DIR]"
10325 #       VARIABLE will be replaced by "DIR[ DIR]"
10326 func_munge_path_list ()
10327 {
10328     case x$2 in
10329     x)
10330         ;;
10331     *:)
10332         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10333         ;;
10334     x:*)
10335         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10336         ;;
10337     *::*)
10338         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10339         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10340         ;;
10341     *)
10342         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10343         ;;
10344     esac
10345 }
10346
10347 for ac_header in dlfcn.h
10348 do :
10349   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10350 "
10351 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10352   cat >>confdefs.h <<_ACEOF
10353 #define HAVE_DLFCN_H 1
10354 _ACEOF
10355
10356 fi
10357
10358 done
10359
10360
10361
10362
10363
10364
10365
10366 # Set options
10367
10368
10369
10370         enable_dlopen=no
10371
10372
10373   enable_win32_dll=no
10374
10375
10376             # Check whether --enable-shared was given.
10377 if test "${enable_shared+set}" = set; then :
10378   enableval=$enable_shared; p=${PACKAGE-default}
10379     case $enableval in
10380     yes) enable_shared=yes ;;
10381     no) enable_shared=no ;;
10382     *)
10383       enable_shared=no
10384       # Look at the argument we got.  We use all the common list separators.
10385       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10386       for pkg in $enableval; do
10387         IFS=$lt_save_ifs
10388         if test "X$pkg" = "X$p"; then
10389           enable_shared=yes
10390         fi
10391       done
10392       IFS=$lt_save_ifs
10393       ;;
10394     esac
10395 else
10396   enable_shared=yes
10397 fi
10398
10399
10400
10401
10402
10403
10404
10405
10406
10407   # Check whether --enable-static was given.
10408 if test "${enable_static+set}" = set; then :
10409   enableval=$enable_static; p=${PACKAGE-default}
10410     case $enableval in
10411     yes) enable_static=yes ;;
10412     no) enable_static=no ;;
10413     *)
10414      enable_static=no
10415       # Look at the argument we got.  We use all the common list separators.
10416       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10417       for pkg in $enableval; do
10418         IFS=$lt_save_ifs
10419         if test "X$pkg" = "X$p"; then
10420           enable_static=yes
10421         fi
10422       done
10423       IFS=$lt_save_ifs
10424       ;;
10425     esac
10426 else
10427   enable_static=yes
10428 fi
10429
10430
10431
10432
10433
10434
10435
10436
10437
10438
10439 # Check whether --with-pic was given.
10440 if test "${with_pic+set}" = set; then :
10441   withval=$with_pic; lt_p=${PACKAGE-default}
10442     case $withval in
10443     yes|no) pic_mode=$withval ;;
10444     *)
10445       pic_mode=default
10446       # Look at the argument we got.  We use all the common list separators.
10447       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10448       for lt_pkg in $withval; do
10449         IFS=$lt_save_ifs
10450         if test "X$lt_pkg" = "X$lt_p"; then
10451           pic_mode=yes
10452         fi
10453       done
10454       IFS=$lt_save_ifs
10455       ;;
10456     esac
10457 else
10458   pic_mode=default
10459 fi
10460
10461
10462
10463
10464
10465
10466
10467
10468   # Check whether --enable-fast-install was given.
10469 if test "${enable_fast_install+set}" = set; then :
10470   enableval=$enable_fast_install; p=${PACKAGE-default}
10471     case $enableval in
10472     yes) enable_fast_install=yes ;;
10473     no) enable_fast_install=no ;;
10474     *)
10475       enable_fast_install=no
10476       # Look at the argument we got.  We use all the common list separators.
10477       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10478       for pkg in $enableval; do
10479         IFS=$lt_save_ifs
10480         if test "X$pkg" = "X$p"; then
10481           enable_fast_install=yes
10482         fi
10483       done
10484       IFS=$lt_save_ifs
10485       ;;
10486     esac
10487 else
10488   enable_fast_install=yes
10489 fi
10490
10491
10492
10493
10494
10495
10496
10497
10498   shared_archive_member_spec=
10499 case $host,$enable_shared in
10500 power*-*-aix[5-9]*,yes)
10501   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
10502 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
10503
10504 # Check whether --with-aix-soname was given.
10505 if test "${with_aix_soname+set}" = set; then :
10506   withval=$with_aix_soname; case $withval in
10507     aix|svr4|both)
10508       ;;
10509     *)
10510       as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
10511       ;;
10512     esac
10513     lt_cv_with_aix_soname=$with_aix_soname
10514 else
10515   if ${lt_cv_with_aix_soname+:} false; then :
10516   $as_echo_n "(cached) " >&6
10517 else
10518   lt_cv_with_aix_soname=aix
10519 fi
10520
10521     with_aix_soname=$lt_cv_with_aix_soname
10522 fi
10523
10524   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
10525 $as_echo "$with_aix_soname" >&6; }
10526   if test aix != "$with_aix_soname"; then
10527     # For the AIX way of multilib, we name the shared archive member
10528     # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
10529     # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
10530     # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
10531     # the AIX toolchain works better with OBJECT_MODE set (default 32).
10532     if test 64 = "${OBJECT_MODE-32}"; then
10533       shared_archive_member_spec=shr_64
10534     else
10535       shared_archive_member_spec=shr
10536     fi
10537   fi
10538   ;;
10539 *)
10540   with_aix_soname=aix
10541   ;;
10542 esac
10543
10544
10545
10546
10547
10548
10549
10550
10551
10552
10553 # This can be used to rebuild libtool when needed
10554 LIBTOOL_DEPS=$ltmain
10555
10556 # Always use our own libtool.
10557 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10558
10559
10560
10561
10562
10563
10564
10565
10566
10567
10568
10569
10570
10571
10572
10573
10574
10575
10576
10577
10578
10579
10580
10581
10582
10583
10584
10585
10586
10587
10588 test -z "$LN_S" && LN_S="ln -s"
10589
10590
10591
10592
10593
10594
10595
10596
10597
10598
10599
10600
10601
10602
10603 if test -n "${ZSH_VERSION+set}"; then
10604    setopt NO_GLOB_SUBST
10605 fi
10606
10607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10608 $as_echo_n "checking for objdir... " >&6; }
10609 if ${lt_cv_objdir+:} false; then :
10610   $as_echo_n "(cached) " >&6
10611 else
10612   rm -f .libs 2>/dev/null
10613 mkdir .libs 2>/dev/null
10614 if test -d .libs; then
10615   lt_cv_objdir=.libs
10616 else
10617   # MS-DOS does not allow filenames that begin with a dot.
10618   lt_cv_objdir=_libs
10619 fi
10620 rmdir .libs 2>/dev/null
10621 fi
10622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10623 $as_echo "$lt_cv_objdir" >&6; }
10624 objdir=$lt_cv_objdir
10625
10626
10627
10628
10629
10630 cat >>confdefs.h <<_ACEOF
10631 #define LT_OBJDIR "$lt_cv_objdir/"
10632 _ACEOF
10633
10634
10635
10636
10637 case $host_os in
10638 aix3*)
10639   # AIX sometimes has problems with the GCC collect2 program.  For some
10640   # reason, if we set the COLLECT_NAMES environment variable, the problems
10641   # vanish in a puff of smoke.
10642   if test set != "${COLLECT_NAMES+set}"; then
10643     COLLECT_NAMES=
10644     export COLLECT_NAMES
10645   fi
10646   ;;
10647 esac
10648
10649 # Global variables:
10650 ofile=libtool
10651 can_build_shared=yes
10652
10653 # All known linkers require a '.a' archive for static linking (except MSVC,
10654 # which needs '.lib').
10655 libext=a
10656
10657 with_gnu_ld=$lt_cv_prog_gnu_ld
10658
10659 old_CC=$CC
10660 old_CFLAGS=$CFLAGS
10661
10662 # Set sane defaults for various variables
10663 test -z "$CC" && CC=cc
10664 test -z "$LTCC" && LTCC=$CC
10665 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10666 test -z "$LD" && LD=ld
10667 test -z "$ac_objext" && ac_objext=o
10668
10669 func_cc_basename $compiler
10670 cc_basename=$func_cc_basename_result
10671
10672
10673 # Only perform the check for file, if the check method requires it
10674 test -z "$MAGIC_CMD" && MAGIC_CMD=file
10675 case $deplibs_check_method in
10676 file_magic*)
10677   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10678     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10679 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10680 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10681   $as_echo_n "(cached) " >&6
10682 else
10683   case $MAGIC_CMD in
10684 [\\/*] |  ?:[\\/]*)
10685   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10686   ;;
10687 *)
10688   lt_save_MAGIC_CMD=$MAGIC_CMD
10689   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10690   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10691   for ac_dir in $ac_dummy; do
10692     IFS=$lt_save_ifs
10693     test -z "$ac_dir" && ac_dir=.
10694     if test -f "$ac_dir/${ac_tool_prefix}file"; then
10695       lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
10696       if test -n "$file_magic_test_file"; then
10697         case $deplibs_check_method in
10698         "file_magic "*)
10699           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10700           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10701           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10702             $EGREP "$file_magic_regex" > /dev/null; then
10703             :
10704           else
10705             cat <<_LT_EOF 1>&2
10706
10707 *** Warning: the command libtool uses to detect shared libraries,
10708 *** $file_magic_cmd, produces output that libtool cannot recognize.
10709 *** The result is that libtool may fail to recognize shared libraries
10710 *** as such.  This will affect the creation of libtool libraries that
10711 *** depend on shared libraries, but programs linked with such libtool
10712 *** libraries will work regardless of this problem.  Nevertheless, you
10713 *** may want to report the problem to your system manager and/or to
10714 *** bug-libtool@gnu.org
10715
10716 _LT_EOF
10717           fi ;;
10718         esac
10719       fi
10720       break
10721     fi
10722   done
10723   IFS=$lt_save_ifs
10724   MAGIC_CMD=$lt_save_MAGIC_CMD
10725   ;;
10726 esac
10727 fi
10728
10729 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10730 if test -n "$MAGIC_CMD"; then
10731   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10732 $as_echo "$MAGIC_CMD" >&6; }
10733 else
10734   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10735 $as_echo "no" >&6; }
10736 fi
10737
10738
10739
10740
10741
10742 if test -z "$lt_cv_path_MAGIC_CMD"; then
10743   if test -n "$ac_tool_prefix"; then
10744     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10745 $as_echo_n "checking for file... " >&6; }
10746 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10747   $as_echo_n "(cached) " >&6
10748 else
10749   case $MAGIC_CMD in
10750 [\\/*] |  ?:[\\/]*)
10751   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10752   ;;
10753 *)
10754   lt_save_MAGIC_CMD=$MAGIC_CMD
10755   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10756   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10757   for ac_dir in $ac_dummy; do
10758     IFS=$lt_save_ifs
10759     test -z "$ac_dir" && ac_dir=.
10760     if test -f "$ac_dir/file"; then
10761       lt_cv_path_MAGIC_CMD=$ac_dir/"file"
10762       if test -n "$file_magic_test_file"; then
10763         case $deplibs_check_method in
10764         "file_magic "*)
10765           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10766           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10767           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10768             $EGREP "$file_magic_regex" > /dev/null; then
10769             :
10770           else
10771             cat <<_LT_EOF 1>&2
10772
10773 *** Warning: the command libtool uses to detect shared libraries,
10774 *** $file_magic_cmd, produces output that libtool cannot recognize.
10775 *** The result is that libtool may fail to recognize shared libraries
10776 *** as such.  This will affect the creation of libtool libraries that
10777 *** depend on shared libraries, but programs linked with such libtool
10778 *** libraries will work regardless of this problem.  Nevertheless, you
10779 *** may want to report the problem to your system manager and/or to
10780 *** bug-libtool@gnu.org
10781
10782 _LT_EOF
10783           fi ;;
10784         esac
10785       fi
10786       break
10787     fi
10788   done
10789   IFS=$lt_save_ifs
10790   MAGIC_CMD=$lt_save_MAGIC_CMD
10791   ;;
10792 esac
10793 fi
10794
10795 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10796 if test -n "$MAGIC_CMD"; then
10797   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10798 $as_echo "$MAGIC_CMD" >&6; }
10799 else
10800   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10801 $as_echo "no" >&6; }
10802 fi
10803
10804
10805   else
10806     MAGIC_CMD=:
10807   fi
10808 fi
10809
10810   fi
10811   ;;
10812 esac
10813
10814 # Use C for the default configuration in the libtool script
10815
10816 lt_save_CC=$CC
10817 ac_ext=c
10818 ac_cpp='$CPP $CPPFLAGS'
10819 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10820 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10821 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10822
10823
10824 # Source file extension for C test sources.
10825 ac_ext=c
10826
10827 # Object file extension for compiled C test sources.
10828 objext=o
10829 objext=$objext
10830
10831 # Code to be used in simple compile tests
10832 lt_simple_compile_test_code="int some_variable = 0;"
10833
10834 # Code to be used in simple link tests
10835 lt_simple_link_test_code='int main(){return(0);}'
10836
10837
10838
10839
10840
10841
10842
10843 # If no C compiler was specified, use CC.
10844 LTCC=${LTCC-"$CC"}
10845
10846 # If no C compiler flags were specified, use CFLAGS.
10847 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10848
10849 # Allow CC to be a program name with arguments.
10850 compiler=$CC
10851
10852 # Save the default compiler, since it gets overwritten when the other
10853 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10854 compiler_DEFAULT=$CC
10855
10856 # save warnings/boilerplate of simple test code
10857 ac_outfile=conftest.$ac_objext
10858 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10859 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10860 _lt_compiler_boilerplate=`cat conftest.err`
10861 $RM conftest*
10862
10863 ac_outfile=conftest.$ac_objext
10864 echo "$lt_simple_link_test_code" >conftest.$ac_ext
10865 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10866 _lt_linker_boilerplate=`cat conftest.err`
10867 $RM -r conftest*
10868
10869
10870 if test -n "$compiler"; then
10871
10872 lt_prog_compiler_no_builtin_flag=
10873
10874 if test yes = "$GCC"; then
10875   case $cc_basename in
10876   nvcc*)
10877     lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10878   *)
10879     lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10880   esac
10881
10882   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10883 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10884 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10885   $as_echo_n "(cached) " >&6
10886 else
10887   lt_cv_prog_compiler_rtti_exceptions=no
10888    ac_outfile=conftest.$ac_objext
10889    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10890    lt_compiler_flag="-fno-rtti -fno-exceptions"  ## exclude from sc_useless_quotes_in_assignment
10891    # Insert the option either (1) after the last *FLAGS variable, or
10892    # (2) before a word containing "conftest.", or (3) at the end.
10893    # Note that $ac_compile itself does not contain backslashes and begins
10894    # with a dollar sign (not a hyphen), so the echo should work correctly.
10895    # The option is referenced via a variable to avoid confusing sed.
10896    lt_compile=`echo "$ac_compile" | $SED \
10897    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10898    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10899    -e 's:$: $lt_compiler_flag:'`
10900    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10901    (eval "$lt_compile" 2>conftest.err)
10902    ac_status=$?
10903    cat conftest.err >&5
10904    echo "$as_me:$LINENO: \$? = $ac_status" >&5
10905    if (exit $ac_status) && test -s "$ac_outfile"; then
10906      # The compiler can only warn and ignore the option if not recognized
10907      # So say no if there are warnings other than the usual output.
10908      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10909      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10910      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10911        lt_cv_prog_compiler_rtti_exceptions=yes
10912      fi
10913    fi
10914    $RM conftest*
10915
10916 fi
10917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10918 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10919
10920 if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
10921     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10922 else
10923     :
10924 fi
10925
10926 fi
10927
10928
10929
10930
10931
10932
10933   lt_prog_compiler_wl=
10934 lt_prog_compiler_pic=
10935 lt_prog_compiler_static=
10936
10937
10938   if test yes = "$GCC"; then
10939     lt_prog_compiler_wl='-Wl,'
10940     lt_prog_compiler_static='-static'
10941
10942     case $host_os in
10943       aix*)
10944       # All AIX code is PIC.
10945       if test ia64 = "$host_cpu"; then
10946         # AIX 5 now supports IA64 processor
10947         lt_prog_compiler_static='-Bstatic'
10948       fi
10949       lt_prog_compiler_pic='-fPIC'
10950       ;;
10951
10952     amigaos*)
10953       case $host_cpu in
10954       powerpc)
10955             # see comment about AmigaOS4 .so support
10956             lt_prog_compiler_pic='-fPIC'
10957         ;;
10958       m68k)
10959             # FIXME: we need at least 68020 code to build shared libraries, but
10960             # adding the '-m68020' flag to GCC prevents building anything better,
10961             # like '-m68040'.
10962             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10963         ;;
10964       esac
10965       ;;
10966
10967     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10968       # PIC is the default for these OSes.
10969       ;;
10970
10971     mingw* | cygwin* | pw32* | os2* | cegcc*)
10972       # This hack is so that the source file can tell whether it is being
10973       # built for inclusion in a dll (and should export symbols for example).
10974       # Although the cygwin gcc ignores -fPIC, still need this for old-style
10975       # (--disable-auto-import) libraries
10976       lt_prog_compiler_pic='-DDLL_EXPORT'
10977       case $host_os in
10978       os2*)
10979         lt_prog_compiler_static='$wl-static'
10980         ;;
10981       esac
10982       ;;
10983
10984     darwin* | rhapsody*)
10985       # PIC is the default on this platform
10986       # Common symbols not allowed in MH_DYLIB files
10987       lt_prog_compiler_pic='-fno-common'
10988       ;;
10989
10990     haiku*)
10991       # PIC is the default for Haiku.
10992       # The "-static" flag exists, but is broken.
10993       lt_prog_compiler_static=
10994       ;;
10995
10996     hpux*)
10997       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10998       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
10999       # sets the default TLS model and affects inlining.
11000       case $host_cpu in
11001       hppa*64*)
11002         # +Z the default
11003         ;;
11004       *)
11005         lt_prog_compiler_pic='-fPIC'
11006         ;;
11007       esac
11008       ;;
11009
11010     interix[3-9]*)
11011       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
11012       # Instead, we relocate shared libraries at runtime.
11013       ;;
11014
11015     msdosdjgpp*)
11016       # Just because we use GCC doesn't mean we suddenly get shared libraries
11017       # on systems that don't support them.
11018       lt_prog_compiler_can_build_shared=no
11019       enable_shared=no
11020       ;;
11021
11022     *nto* | *qnx*)
11023       # QNX uses GNU C++, but need to define -shared option too, otherwise
11024       # it will coredump.
11025       lt_prog_compiler_pic='-fPIC -shared'
11026       ;;
11027
11028     sysv4*MP*)
11029       if test -d /usr/nec; then
11030         lt_prog_compiler_pic=-Kconform_pic
11031       fi
11032       ;;
11033
11034     *)
11035       lt_prog_compiler_pic='-fPIC'
11036       ;;
11037     esac
11038
11039     case $cc_basename in
11040     nvcc*) # Cuda Compiler Driver 2.2
11041       lt_prog_compiler_wl='-Xlinker '
11042       if test -n "$lt_prog_compiler_pic"; then
11043         lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
11044       fi
11045       ;;
11046     esac
11047   else
11048     # PORTME Check for flag to pass linker flags through the system compiler.
11049     case $host_os in
11050     aix*)
11051       lt_prog_compiler_wl='-Wl,'
11052       if test ia64 = "$host_cpu"; then
11053         # AIX 5 now supports IA64 processor
11054         lt_prog_compiler_static='-Bstatic'
11055       else
11056         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
11057       fi
11058       ;;
11059
11060     darwin* | rhapsody*)
11061       # PIC is the default on this platform
11062       # Common symbols not allowed in MH_DYLIB files
11063       lt_prog_compiler_pic='-fno-common'
11064       case $cc_basename in
11065       nagfor*)
11066         # NAG Fortran compiler
11067         lt_prog_compiler_wl='-Wl,-Wl,,'
11068         lt_prog_compiler_pic='-PIC'
11069         lt_prog_compiler_static='-Bstatic'
11070         ;;
11071       esac
11072       ;;
11073
11074     mingw* | cygwin* | pw32* | os2* | cegcc*)
11075       # This hack is so that the source file can tell whether it is being
11076       # built for inclusion in a dll (and should export symbols for example).
11077       lt_prog_compiler_pic='-DDLL_EXPORT'
11078       case $host_os in
11079       os2*)
11080         lt_prog_compiler_static='$wl-static'
11081         ;;
11082       esac
11083       ;;
11084
11085     hpux9* | hpux10* | hpux11*)
11086       lt_prog_compiler_wl='-Wl,'
11087       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11088       # not for PA HP-UX.
11089       case $host_cpu in
11090       hppa*64*|ia64*)
11091         # +Z the default
11092         ;;
11093       *)
11094         lt_prog_compiler_pic='+Z'
11095         ;;
11096       esac
11097       # Is there a better lt_prog_compiler_static that works with the bundled CC?
11098       lt_prog_compiler_static='$wl-a ${wl}archive'
11099       ;;
11100
11101     irix5* | irix6* | nonstopux*)
11102       lt_prog_compiler_wl='-Wl,'
11103       # PIC (with -KPIC) is the default.
11104       lt_prog_compiler_static='-non_shared'
11105       ;;
11106
11107     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11108       case $cc_basename in
11109       # old Intel for x86_64, which still supported -KPIC.
11110       ecc*)
11111         lt_prog_compiler_wl='-Wl,'
11112         lt_prog_compiler_pic='-KPIC'
11113         lt_prog_compiler_static='-static'
11114         ;;
11115       # icc used to be incompatible with GCC.
11116       # ICC 10 doesn't accept -KPIC any more.
11117       icc* | ifort*)
11118         lt_prog_compiler_wl='-Wl,'
11119         lt_prog_compiler_pic='-fPIC'
11120         lt_prog_compiler_static='-static'
11121         ;;
11122       # Lahey Fortran 8.1.
11123       lf95*)
11124         lt_prog_compiler_wl='-Wl,'
11125         lt_prog_compiler_pic='--shared'
11126         lt_prog_compiler_static='--static'
11127         ;;
11128       nagfor*)
11129         # NAG Fortran compiler
11130         lt_prog_compiler_wl='-Wl,-Wl,,'
11131         lt_prog_compiler_pic='-PIC'
11132         lt_prog_compiler_static='-Bstatic'
11133         ;;
11134       tcc*)
11135         # Fabrice Bellard et al's Tiny C Compiler
11136         lt_prog_compiler_wl='-Wl,'
11137         lt_prog_compiler_pic='-fPIC'
11138         lt_prog_compiler_static='-static'
11139         ;;
11140       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11141         # Portland Group compilers (*not* the Pentium gcc compiler,
11142         # which looks to be a dead project)
11143         lt_prog_compiler_wl='-Wl,'
11144         lt_prog_compiler_pic='-fpic'
11145         lt_prog_compiler_static='-Bstatic'
11146         ;;
11147       ccc*)
11148         lt_prog_compiler_wl='-Wl,'
11149         # All Alpha code is PIC.
11150         lt_prog_compiler_static='-non_shared'
11151         ;;
11152       xl* | bgxl* | bgf* | mpixl*)
11153         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11154         lt_prog_compiler_wl='-Wl,'
11155         lt_prog_compiler_pic='-qpic'
11156         lt_prog_compiler_static='-qstaticlink'
11157         ;;
11158       *)
11159         case `$CC -V 2>&1 | sed 5q` in
11160         *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11161           # Sun Fortran 8.3 passes all unrecognized flags to the linker
11162           lt_prog_compiler_pic='-KPIC'
11163           lt_prog_compiler_static='-Bstatic'
11164           lt_prog_compiler_wl=''
11165           ;;
11166         *Sun\ F* | *Sun*Fortran*)
11167           lt_prog_compiler_pic='-KPIC'
11168           lt_prog_compiler_static='-Bstatic'
11169           lt_prog_compiler_wl='-Qoption ld '
11170           ;;
11171         *Sun\ C*)
11172           # Sun C 5.9
11173           lt_prog_compiler_pic='-KPIC'
11174           lt_prog_compiler_static='-Bstatic'
11175           lt_prog_compiler_wl='-Wl,'
11176           ;;
11177         *Intel*\ [CF]*Compiler*)
11178           lt_prog_compiler_wl='-Wl,'
11179           lt_prog_compiler_pic='-fPIC'
11180           lt_prog_compiler_static='-static'
11181           ;;
11182         *Portland\ Group*)
11183           lt_prog_compiler_wl='-Wl,'
11184           lt_prog_compiler_pic='-fpic'
11185           lt_prog_compiler_static='-Bstatic'
11186           ;;
11187         esac
11188         ;;
11189       esac
11190       ;;
11191
11192     newsos6)
11193       lt_prog_compiler_pic='-KPIC'
11194       lt_prog_compiler_static='-Bstatic'
11195       ;;
11196
11197     *nto* | *qnx*)
11198       # QNX uses GNU C++, but need to define -shared option too, otherwise
11199       # it will coredump.
11200       lt_prog_compiler_pic='-fPIC -shared'
11201       ;;
11202
11203     osf3* | osf4* | osf5*)
11204       lt_prog_compiler_wl='-Wl,'
11205       # All OSF/1 code is PIC.
11206       lt_prog_compiler_static='-non_shared'
11207       ;;
11208
11209     rdos*)
11210       lt_prog_compiler_static='-non_shared'
11211       ;;
11212
11213     solaris*)
11214       lt_prog_compiler_pic='-KPIC'
11215       lt_prog_compiler_static='-Bstatic'
11216       case $cc_basename in
11217       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11218         lt_prog_compiler_wl='-Qoption ld ';;
11219       *)
11220         lt_prog_compiler_wl='-Wl,';;
11221       esac
11222       ;;
11223
11224     sunos4*)
11225       lt_prog_compiler_wl='-Qoption ld '
11226       lt_prog_compiler_pic='-PIC'
11227       lt_prog_compiler_static='-Bstatic'
11228       ;;
11229
11230     sysv4 | sysv4.2uw2* | sysv4.3*)
11231       lt_prog_compiler_wl='-Wl,'
11232       lt_prog_compiler_pic='-KPIC'
11233       lt_prog_compiler_static='-Bstatic'
11234       ;;
11235
11236     sysv4*MP*)
11237       if test -d /usr/nec; then
11238         lt_prog_compiler_pic='-Kconform_pic'
11239         lt_prog_compiler_static='-Bstatic'
11240       fi
11241       ;;
11242
11243     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11244       lt_prog_compiler_wl='-Wl,'
11245       lt_prog_compiler_pic='-KPIC'
11246       lt_prog_compiler_static='-Bstatic'
11247       ;;
11248
11249     unicos*)
11250       lt_prog_compiler_wl='-Wl,'
11251       lt_prog_compiler_can_build_shared=no
11252       ;;
11253
11254     uts4*)
11255       lt_prog_compiler_pic='-pic'
11256       lt_prog_compiler_static='-Bstatic'
11257       ;;
11258
11259     *)
11260       lt_prog_compiler_can_build_shared=no
11261       ;;
11262     esac
11263   fi
11264
11265 case $host_os in
11266   # For platforms that do not support PIC, -DPIC is meaningless:
11267   *djgpp*)
11268     lt_prog_compiler_pic=
11269     ;;
11270   *)
11271     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11272     ;;
11273 esac
11274
11275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11276 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11277 if ${lt_cv_prog_compiler_pic+:} false; then :
11278   $as_echo_n "(cached) " >&6
11279 else
11280   lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11281 fi
11282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11283 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
11284 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11285
11286 #
11287 # Check to make sure the PIC flag actually works.
11288 #
11289 if test -n "$lt_prog_compiler_pic"; then
11290   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
11291 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
11292 if ${lt_cv_prog_compiler_pic_works+:} false; then :
11293   $as_echo_n "(cached) " >&6
11294 else
11295   lt_cv_prog_compiler_pic_works=no
11296    ac_outfile=conftest.$ac_objext
11297    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11298    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"  ## exclude from sc_useless_quotes_in_assignment
11299    # Insert the option either (1) after the last *FLAGS variable, or
11300    # (2) before a word containing "conftest.", or (3) at the end.
11301    # Note that $ac_compile itself does not contain backslashes and begins
11302    # with a dollar sign (not a hyphen), so the echo should work correctly.
11303    # The option is referenced via a variable to avoid confusing sed.
11304    lt_compile=`echo "$ac_compile" | $SED \
11305    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11306    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11307    -e 's:$: $lt_compiler_flag:'`
11308    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11309    (eval "$lt_compile" 2>conftest.err)
11310    ac_status=$?
11311    cat conftest.err >&5
11312    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11313    if (exit $ac_status) && test -s "$ac_outfile"; then
11314      # The compiler can only warn and ignore the option if not recognized
11315      # So say no if there are warnings other than the usual output.
11316      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11317      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11318      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11319        lt_cv_prog_compiler_pic_works=yes
11320      fi
11321    fi
11322    $RM conftest*
11323
11324 fi
11325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
11326 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
11327
11328 if test yes = "$lt_cv_prog_compiler_pic_works"; then
11329     case $lt_prog_compiler_pic in
11330      "" | " "*) ;;
11331      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
11332      esac
11333 else
11334     lt_prog_compiler_pic=
11335      lt_prog_compiler_can_build_shared=no
11336 fi
11337
11338 fi
11339
11340
11341
11342
11343
11344
11345
11346
11347
11348
11349
11350 #
11351 # Check to make sure the static flag actually works.
11352 #
11353 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
11354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
11355 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
11356 if ${lt_cv_prog_compiler_static_works+:} false; then :
11357   $as_echo_n "(cached) " >&6
11358 else
11359   lt_cv_prog_compiler_static_works=no
11360    save_LDFLAGS=$LDFLAGS
11361    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
11362    echo "$lt_simple_link_test_code" > conftest.$ac_ext
11363    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11364      # The linker can only warn and ignore the option if not recognized
11365      # So say no if there are warnings
11366      if test -s conftest.err; then
11367        # Append any errors to the config.log.
11368        cat conftest.err 1>&5
11369        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11370        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11371        if diff conftest.exp conftest.er2 >/dev/null; then
11372          lt_cv_prog_compiler_static_works=yes
11373        fi
11374      else
11375        lt_cv_prog_compiler_static_works=yes
11376      fi
11377    fi
11378    $RM -r conftest*
11379    LDFLAGS=$save_LDFLAGS
11380
11381 fi
11382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
11383 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
11384
11385 if test yes = "$lt_cv_prog_compiler_static_works"; then
11386     :
11387 else
11388     lt_prog_compiler_static=
11389 fi
11390
11391
11392
11393
11394
11395
11396
11397   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11398 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11399 if ${lt_cv_prog_compiler_c_o+:} false; then :
11400   $as_echo_n "(cached) " >&6
11401 else
11402   lt_cv_prog_compiler_c_o=no
11403    $RM -r conftest 2>/dev/null
11404    mkdir conftest
11405    cd conftest
11406    mkdir out
11407    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11408
11409    lt_compiler_flag="-o out/conftest2.$ac_objext"
11410    # Insert the option either (1) after the last *FLAGS variable, or
11411    # (2) before a word containing "conftest.", or (3) at the end.
11412    # Note that $ac_compile itself does not contain backslashes and begins
11413    # with a dollar sign (not a hyphen), so the echo should work correctly.
11414    lt_compile=`echo "$ac_compile" | $SED \
11415    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11416    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11417    -e 's:$: $lt_compiler_flag:'`
11418    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11419    (eval "$lt_compile" 2>out/conftest.err)
11420    ac_status=$?
11421    cat out/conftest.err >&5
11422    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11423    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11424    then
11425      # The compiler can only warn and ignore the option if not recognized
11426      # So say no if there are warnings
11427      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11428      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11429      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11430        lt_cv_prog_compiler_c_o=yes
11431      fi
11432    fi
11433    chmod u+w . 2>&5
11434    $RM conftest*
11435    # SGI C++ compiler will create directory out/ii_files/ for
11436    # template instantiation
11437    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11438    $RM out/* && rmdir out
11439    cd ..
11440    $RM -r conftest
11441    $RM conftest*
11442
11443 fi
11444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11445 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11446
11447
11448
11449
11450
11451
11452   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11453 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11454 if ${lt_cv_prog_compiler_c_o+:} false; then :
11455   $as_echo_n "(cached) " >&6
11456 else
11457   lt_cv_prog_compiler_c_o=no
11458    $RM -r conftest 2>/dev/null
11459    mkdir conftest
11460    cd conftest
11461    mkdir out
11462    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11463
11464    lt_compiler_flag="-o out/conftest2.$ac_objext"
11465    # Insert the option either (1) after the last *FLAGS variable, or
11466    # (2) before a word containing "conftest.", or (3) at the end.
11467    # Note that $ac_compile itself does not contain backslashes and begins
11468    # with a dollar sign (not a hyphen), so the echo should work correctly.
11469    lt_compile=`echo "$ac_compile" | $SED \
11470    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11471    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11472    -e 's:$: $lt_compiler_flag:'`
11473    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11474    (eval "$lt_compile" 2>out/conftest.err)
11475    ac_status=$?
11476    cat out/conftest.err >&5
11477    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11478    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11479    then
11480      # The compiler can only warn and ignore the option if not recognized
11481      # So say no if there are warnings
11482      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11483      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11484      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11485        lt_cv_prog_compiler_c_o=yes
11486      fi
11487    fi
11488    chmod u+w . 2>&5
11489    $RM conftest*
11490    # SGI C++ compiler will create directory out/ii_files/ for
11491    # template instantiation
11492    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11493    $RM out/* && rmdir out
11494    cd ..
11495    $RM -r conftest
11496    $RM conftest*
11497
11498 fi
11499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11500 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11501
11502
11503
11504
11505 hard_links=nottested
11506 if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
11507   # do not overwrite the value of need_locks provided by the user
11508   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11509 $as_echo_n "checking if we can lock with hard links... " >&6; }
11510   hard_links=yes
11511   $RM conftest*
11512   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11513   touch conftest.a
11514   ln conftest.a conftest.b 2>&5 || hard_links=no
11515   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11516   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11517 $as_echo "$hard_links" >&6; }
11518   if test no = "$hard_links"; then
11519     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
11520 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
11521     need_locks=warn
11522   fi
11523 else
11524   need_locks=no
11525 fi
11526
11527
11528
11529
11530
11531
11532   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11533 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11534
11535   runpath_var=
11536   allow_undefined_flag=
11537   always_export_symbols=no
11538   archive_cmds=
11539   archive_expsym_cmds=
11540   compiler_needs_object=no
11541   enable_shared_with_static_runtimes=no
11542   export_dynamic_flag_spec=
11543   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11544   hardcode_automatic=no
11545   hardcode_direct=no
11546   hardcode_direct_absolute=no
11547   hardcode_libdir_flag_spec=
11548   hardcode_libdir_separator=
11549   hardcode_minus_L=no
11550   hardcode_shlibpath_var=unsupported
11551   inherit_rpath=no
11552   link_all_deplibs=unknown
11553   module_cmds=
11554   module_expsym_cmds=
11555   old_archive_from_new_cmds=
11556   old_archive_from_expsyms_cmds=
11557   thread_safe_flag_spec=
11558   whole_archive_flag_spec=
11559   # include_expsyms should be a list of space-separated symbols to be *always*
11560   # included in the symbol list
11561   include_expsyms=
11562   # exclude_expsyms can be an extended regexp of symbols to exclude
11563   # it will be wrapped by ' (' and ')$', so one must not match beginning or
11564   # end of line.  Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
11565   # as well as any symbol that contains 'd'.
11566   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11567   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11568   # platforms (ab)use it in PIC code, but their linkers get confused if
11569   # the symbol is explicitly referenced.  Since portable code cannot
11570   # rely on this symbol name, it's probably fine to never include it in
11571   # preloaded symbol tables.
11572   # Exclude shared library initialization/finalization symbols.
11573   extract_expsyms_cmds=
11574
11575   case $host_os in
11576   cygwin* | mingw* | pw32* | cegcc*)
11577     # FIXME: the MSVC++ port hasn't been tested in a loooong time
11578     # When not using gcc, we currently assume that we are using
11579     # Microsoft Visual C++.
11580     if test yes != "$GCC"; then
11581       with_gnu_ld=no
11582     fi
11583     ;;
11584   interix*)
11585     # we just hope/assume this is gcc and not c89 (= MSVC++)
11586     with_gnu_ld=yes
11587     ;;
11588   openbsd* | bitrig*)
11589     with_gnu_ld=no
11590     ;;
11591   esac
11592
11593   ld_shlibs=yes
11594
11595   # On some targets, GNU ld is compatible enough with the native linker
11596   # that we're better off using the native interface for both.
11597   lt_use_gnu_ld_interface=no
11598   if test yes = "$with_gnu_ld"; then
11599     case $host_os in
11600       aix*)
11601         # The AIX port of GNU ld has always aspired to compatibility
11602         # with the native linker.  However, as the warning in the GNU ld
11603         # block says, versions before 2.19.5* couldn't really create working
11604         # shared libraries, regardless of the interface used.
11605         case `$LD -v 2>&1` in
11606           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11607           *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11608           *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11609           *)
11610             lt_use_gnu_ld_interface=yes
11611             ;;
11612         esac
11613         ;;
11614       *)
11615         lt_use_gnu_ld_interface=yes
11616         ;;
11617     esac
11618   fi
11619
11620   if test yes = "$lt_use_gnu_ld_interface"; then
11621     # If archive_cmds runs LD, not CC, wlarc should be empty
11622     wlarc='$wl'
11623
11624     # Set some defaults for GNU ld with shared library support. These
11625     # are reset later if shared libraries are not supported. Putting them
11626     # here allows them to be overridden if necessary.
11627     runpath_var=LD_RUN_PATH
11628     hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11629     export_dynamic_flag_spec='$wl--export-dynamic'
11630     # ancient GNU ld didn't support --whole-archive et. al.
11631     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11632       whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
11633     else
11634       whole_archive_flag_spec=
11635     fi
11636     supports_anon_versioning=no
11637     case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
11638       *GNU\ gold*) supports_anon_versioning=yes ;;
11639       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11640       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11641       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11642       *\ 2.11.*) ;; # other 2.11 versions
11643       *) supports_anon_versioning=yes ;;
11644     esac
11645
11646     # See if GNU ld supports shared libraries.
11647     case $host_os in
11648     aix[3-9]*)
11649       # On AIX/PPC, the GNU linker is very broken
11650       if test ia64 != "$host_cpu"; then
11651         ld_shlibs=no
11652         cat <<_LT_EOF 1>&2
11653
11654 *** Warning: the GNU linker, at least up to release 2.19, is reported
11655 *** to be unable to reliably create shared libraries on AIX.
11656 *** Therefore, libtool is disabling shared libraries support.  If you
11657 *** really care for shared libraries, you may want to install binutils
11658 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11659 *** You will then need to restart the configuration process.
11660
11661 _LT_EOF
11662       fi
11663       ;;
11664
11665     amigaos*)
11666       case $host_cpu in
11667       powerpc)
11668             # see comment about AmigaOS4 .so support
11669             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11670             archive_expsym_cmds=''
11671         ;;
11672       m68k)
11673             archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
11674             hardcode_libdir_flag_spec='-L$libdir'
11675             hardcode_minus_L=yes
11676         ;;
11677       esac
11678       ;;
11679
11680     beos*)
11681       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11682         allow_undefined_flag=unsupported
11683         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
11684         # support --undefined.  This deserves some investigation.  FIXME
11685         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11686       else
11687         ld_shlibs=no
11688       fi
11689       ;;
11690
11691     cygwin* | mingw* | pw32* | cegcc*)
11692       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11693       # as there is no search path for DLLs.
11694       hardcode_libdir_flag_spec='-L$libdir'
11695       export_dynamic_flag_spec='$wl--export-all-symbols'
11696       allow_undefined_flag=unsupported
11697       always_export_symbols=no
11698       enable_shared_with_static_runtimes=yes
11699       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
11700       exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11701
11702       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11703         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11704         # If the export-symbols file already is a .def file, use it as
11705         # is; otherwise, prepend EXPORTS...
11706         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
11707           cp $export_symbols $output_objdir/$soname.def;
11708         else
11709           echo EXPORTS > $output_objdir/$soname.def;
11710           cat $export_symbols >> $output_objdir/$soname.def;
11711         fi~
11712         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11713       else
11714         ld_shlibs=no
11715       fi
11716       ;;
11717
11718     haiku*)
11719       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11720       link_all_deplibs=yes
11721       ;;
11722
11723     os2*)
11724       hardcode_libdir_flag_spec='-L$libdir'
11725       hardcode_minus_L=yes
11726       allow_undefined_flag=unsupported
11727       shrext_cmds=.dll
11728       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11729         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11730         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11731         $ECHO EXPORTS >> $output_objdir/$libname.def~
11732         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
11733         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11734         emximp -o $lib $output_objdir/$libname.def'
11735       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11736         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11737         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11738         $ECHO EXPORTS >> $output_objdir/$libname.def~
11739         prefix_cmds="$SED"~
11740         if test EXPORTS = "`$SED 1q $export_symbols`"; then
11741           prefix_cmds="$prefix_cmds -e 1d";
11742         fi~
11743         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
11744         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
11745         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11746         emximp -o $lib $output_objdir/$libname.def'
11747       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
11748       enable_shared_with_static_runtimes=yes
11749       ;;
11750
11751     interix[3-9]*)
11752       hardcode_direct=no
11753       hardcode_shlibpath_var=no
11754       hardcode_libdir_flag_spec='$wl-rpath,$libdir'
11755       export_dynamic_flag_spec='$wl-E'
11756       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11757       # Instead, shared libraries are loaded at an image base (0x10000000 by
11758       # default) and relocated if they conflict, which is a slow very memory
11759       # consuming and fragmenting process.  To avoid this, we pick a random,
11760       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11761       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
11762       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11763       archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11764       ;;
11765
11766     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11767       tmp_diet=no
11768       if test linux-dietlibc = "$host_os"; then
11769         case $cc_basename in
11770           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
11771         esac
11772       fi
11773       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11774          && test no = "$tmp_diet"
11775       then
11776         tmp_addflag=' $pic_flag'
11777         tmp_sharedflag='-shared'
11778         case $cc_basename,$host_cpu in
11779         pgcc*)                          # Portland Group C compiler
11780           whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
11781           tmp_addflag=' $pic_flag'
11782           ;;
11783         pgf77* | pgf90* | pgf95* | pgfortran*)
11784                                         # Portland Group f77 and f90 compilers
11785           whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
11786           tmp_addflag=' $pic_flag -Mnomain' ;;
11787         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
11788           tmp_addflag=' -i_dynamic' ;;
11789         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
11790           tmp_addflag=' -i_dynamic -nofor_main' ;;
11791         ifc* | ifort*)                  # Intel Fortran compiler
11792           tmp_addflag=' -nofor_main' ;;
11793         lf95*)                          # Lahey Fortran 8.1
11794           whole_archive_flag_spec=
11795           tmp_sharedflag='--shared' ;;
11796         nagfor*)                        # NAGFOR 5.3
11797           tmp_sharedflag='-Wl,-shared' ;;
11798         xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11799           tmp_sharedflag='-qmkshrobj'
11800           tmp_addflag= ;;
11801         nvcc*)  # Cuda Compiler Driver 2.2
11802           whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
11803           compiler_needs_object=yes
11804           ;;
11805         esac
11806         case `$CC -V 2>&1 | sed 5q` in
11807         *Sun\ C*)                       # Sun C 5.9
11808           whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
11809           compiler_needs_object=yes
11810           tmp_sharedflag='-G' ;;
11811         *Sun\ F*)                       # Sun Fortran 8.3
11812           tmp_sharedflag='-G' ;;
11813         esac
11814         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11815
11816         if test yes = "$supports_anon_versioning"; then
11817           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11818             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11819             echo "local: *; };" >> $output_objdir/$libname.ver~
11820             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
11821         fi
11822
11823         case $cc_basename in
11824         tcc*)
11825           export_dynamic_flag_spec='-rdynamic'
11826           ;;
11827         xlf* | bgf* | bgxlf* | mpixlf*)
11828           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11829           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11830           hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11831           archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11832           if test yes = "$supports_anon_versioning"; then
11833             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11834               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11835               echo "local: *; };" >> $output_objdir/$libname.ver~
11836               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11837           fi
11838           ;;
11839         esac
11840       else
11841         ld_shlibs=no
11842       fi
11843       ;;
11844
11845     netbsd*)
11846       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11847         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11848         wlarc=
11849       else
11850         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11851         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11852       fi
11853       ;;
11854
11855     solaris*)
11856       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11857         ld_shlibs=no
11858         cat <<_LT_EOF 1>&2
11859
11860 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
11861 *** create shared libraries on Solaris systems.  Therefore, libtool
11862 *** is disabling shared libraries support.  We urge you to upgrade GNU
11863 *** binutils to release 2.9.1 or newer.  Another option is to modify
11864 *** your PATH or compiler configuration so that the native linker is
11865 *** used, and then restart.
11866
11867 _LT_EOF
11868       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11869         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11870         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11871       else
11872         ld_shlibs=no
11873       fi
11874       ;;
11875
11876     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11877       case `$LD -v 2>&1` in
11878         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11879         ld_shlibs=no
11880         cat <<_LT_EOF 1>&2
11881
11882 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
11883 *** reliably create shared libraries on SCO systems.  Therefore, libtool
11884 *** is disabling shared libraries support.  We urge you to upgrade GNU
11885 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
11886 *** your PATH or compiler configuration so that the native linker is
11887 *** used, and then restart.
11888
11889 _LT_EOF
11890         ;;
11891         *)
11892           # For security reasons, it is highly recommended that you always
11893           # use absolute paths for naming shared libraries, and exclude the
11894           # DT_RUNPATH tag from executables and libraries.  But doing so
11895           # requires that you compile everything twice, which is a pain.
11896           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11897             hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11898             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11899             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11900           else
11901             ld_shlibs=no
11902           fi
11903         ;;
11904       esac
11905       ;;
11906
11907     sunos4*)
11908       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11909       wlarc=
11910       hardcode_direct=yes
11911       hardcode_shlibpath_var=no
11912       ;;
11913
11914     *)
11915       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11916         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11917         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11918       else
11919         ld_shlibs=no
11920       fi
11921       ;;
11922     esac
11923
11924     if test no = "$ld_shlibs"; then
11925       runpath_var=
11926       hardcode_libdir_flag_spec=
11927       export_dynamic_flag_spec=
11928       whole_archive_flag_spec=
11929     fi
11930   else
11931     # PORTME fill in a description of your system's linker (not GNU ld)
11932     case $host_os in
11933     aix3*)
11934       allow_undefined_flag=unsupported
11935       always_export_symbols=yes
11936       archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
11937       # Note: this linker hardcodes the directories in LIBPATH if there
11938       # are no directories specified by -L.
11939       hardcode_minus_L=yes
11940       if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
11941         # Neither direct hardcoding nor static linking is supported with a
11942         # broken collect2.
11943         hardcode_direct=unsupported
11944       fi
11945       ;;
11946
11947     aix[4-9]*)
11948       if test ia64 = "$host_cpu"; then
11949         # On IA64, the linker does run time linking by default, so we don't
11950         # have to do anything special.
11951         aix_use_runtimelinking=no
11952         exp_sym_flag='-Bexport'
11953         no_entry_flag=
11954       else
11955         # If we're using GNU nm, then we don't want the "-C" option.
11956         # -C means demangle to GNU nm, but means don't demangle to AIX nm.
11957         # Without the "-l" option, or with the "-B" option, AIX nm treats
11958         # weak defined symbols like other global defined symbols, whereas
11959         # GNU nm marks them as "W".
11960         # While the 'weak' keyword is ignored in the Export File, we need
11961         # it in the Import File for the 'aix-soname' feature, so we have
11962         # to replace the "-B" option with "-P" for AIX nm.
11963         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11964           export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
11965         else
11966           export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
11967         fi
11968         aix_use_runtimelinking=no
11969
11970         # Test if we are trying to use run time linking or normal
11971         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
11972         # have runtime linking enabled, and use it for executables.
11973         # For shared libraries, we enable/disable runtime linking
11974         # depending on the kind of the shared library created -
11975         # when "with_aix_soname,aix_use_runtimelinking" is:
11976         # "aix,no"   lib.a(lib.so.V) shared, rtl:no,  for executables
11977         # "aix,yes"  lib.so          shared, rtl:yes, for executables
11978         #            lib.a           static archive
11979         # "both,no"  lib.so.V(shr.o) shared, rtl:yes
11980         #            lib.a(lib.so.V) shared, rtl:no,  for executables
11981         # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
11982         #            lib.a(lib.so.V) shared, rtl:no
11983         # "svr4,*"   lib.so.V(shr.o) shared, rtl:yes, for executables
11984         #            lib.a           static archive
11985         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11986           for ld_flag in $LDFLAGS; do
11987           if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
11988             aix_use_runtimelinking=yes
11989             break
11990           fi
11991           done
11992           if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
11993             # With aix-soname=svr4, we create the lib.so.V shared archives only,
11994             # so we don't have lib.a shared libs to link our executables.
11995             # We have to force runtime linking in this case.
11996             aix_use_runtimelinking=yes
11997             LDFLAGS="$LDFLAGS -Wl,-brtl"
11998           fi
11999           ;;
12000         esac
12001
12002         exp_sym_flag='-bexport'
12003         no_entry_flag='-bnoentry'
12004       fi
12005
12006       # When large executables or shared objects are built, AIX ld can
12007       # have problems creating the table of contents.  If linking a library
12008       # or program results in "error TOC overflow" add -mminimal-toc to
12009       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
12010       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
12011
12012       archive_cmds=''
12013       hardcode_direct=yes
12014       hardcode_direct_absolute=yes
12015       hardcode_libdir_separator=':'
12016       link_all_deplibs=yes
12017       file_list_spec='$wl-f,'
12018       case $with_aix_soname,$aix_use_runtimelinking in
12019       aix,*) ;; # traditional, no import file
12020       svr4,* | *,yes) # use import file
12021         # The Import File defines what to hardcode.
12022         hardcode_direct=no
12023         hardcode_direct_absolute=no
12024         ;;
12025       esac
12026
12027       if test yes = "$GCC"; then
12028         case $host_os in aix4.[012]|aix4.[012].*)
12029         # We only want to do this on AIX 4.2 and lower, the check
12030         # below for broken collect2 doesn't work under 4.3+
12031           collect2name=`$CC -print-prog-name=collect2`
12032           if test -f "$collect2name" &&
12033            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12034           then
12035           # We have reworked collect2
12036           :
12037           else
12038           # We have old collect2
12039           hardcode_direct=unsupported
12040           # It fails to find uninstalled libraries when the uninstalled
12041           # path is not listed in the libpath.  Setting hardcode_minus_L
12042           # to unsupported forces relinking
12043           hardcode_minus_L=yes
12044           hardcode_libdir_flag_spec='-L$libdir'
12045           hardcode_libdir_separator=
12046           fi
12047           ;;
12048         esac
12049         shared_flag='-shared'
12050         if test yes = "$aix_use_runtimelinking"; then
12051           shared_flag="$shared_flag "'$wl-G'
12052         fi
12053         # Need to ensure runtime linking is disabled for the traditional
12054         # shared library, or the linker may eventually find shared libraries
12055         # /with/ Import File - we do not want to mix them.
12056         shared_flag_aix='-shared'
12057         shared_flag_svr4='-shared $wl-G'
12058       else
12059         # not using gcc
12060         if test ia64 = "$host_cpu"; then
12061         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12062         # chokes on -Wl,-G. The following line is correct:
12063           shared_flag='-G'
12064         else
12065           if test yes = "$aix_use_runtimelinking"; then
12066             shared_flag='$wl-G'
12067           else
12068             shared_flag='$wl-bM:SRE'
12069           fi
12070           shared_flag_aix='$wl-bM:SRE'
12071           shared_flag_svr4='$wl-G'
12072         fi
12073       fi
12074
12075       export_dynamic_flag_spec='$wl-bexpall'
12076       # It seems that -bexpall does not export symbols beginning with
12077       # underscore (_), so it is better to generate a list of symbols to export.
12078       always_export_symbols=yes
12079       if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12080         # Warning - without using the other runtime loading flags (-brtl),
12081         # -berok will link without error, but may produce a broken library.
12082         allow_undefined_flag='-berok'
12083         # Determine the default libpath from the value encoded in an
12084         # empty executable.
12085         if test set = "${lt_cv_aix_libpath+set}"; then
12086   aix_libpath=$lt_cv_aix_libpath
12087 else
12088   if ${lt_cv_aix_libpath_+:} false; then :
12089   $as_echo_n "(cached) " >&6
12090 else
12091   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12092 /* end confdefs.h.  */
12093
12094 int
12095 main ()
12096 {
12097
12098   ;
12099   return 0;
12100 }
12101 _ACEOF
12102 if ac_fn_c_try_link "$LINENO"; then :
12103
12104   lt_aix_libpath_sed='
12105       /Import File Strings/,/^$/ {
12106           /^0/ {
12107               s/^0  *\([^ ]*\) *$/\1/
12108               p
12109           }
12110       }'
12111   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12112   # Check for a 64-bit object if we didn't find anything.
12113   if test -z "$lt_cv_aix_libpath_"; then
12114     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12115   fi
12116 fi
12117 rm -f core conftest.err conftest.$ac_objext \
12118     conftest$ac_exeext conftest.$ac_ext
12119   if test -z "$lt_cv_aix_libpath_"; then
12120     lt_cv_aix_libpath_=/usr/lib:/lib
12121   fi
12122
12123 fi
12124
12125   aix_libpath=$lt_cv_aix_libpath_
12126 fi
12127
12128         hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12129         archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
12130       else
12131         if test ia64 = "$host_cpu"; then
12132           hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12133           allow_undefined_flag="-z nodefs"
12134           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
12135         else
12136          # Determine the default libpath from the value encoded in an
12137          # empty executable.
12138          if test set = "${lt_cv_aix_libpath+set}"; then
12139   aix_libpath=$lt_cv_aix_libpath
12140 else
12141   if ${lt_cv_aix_libpath_+:} false; then :
12142   $as_echo_n "(cached) " >&6
12143 else
12144   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12145 /* end confdefs.h.  */
12146
12147 int
12148 main ()
12149 {
12150
12151   ;
12152   return 0;
12153 }
12154 _ACEOF
12155 if ac_fn_c_try_link "$LINENO"; then :
12156
12157   lt_aix_libpath_sed='
12158       /Import File Strings/,/^$/ {
12159           /^0/ {
12160               s/^0  *\([^ ]*\) *$/\1/
12161               p
12162           }
12163       }'
12164   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12165   # Check for a 64-bit object if we didn't find anything.
12166   if test -z "$lt_cv_aix_libpath_"; then
12167     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12168   fi
12169 fi
12170 rm -f core conftest.err conftest.$ac_objext \
12171     conftest$ac_exeext conftest.$ac_ext
12172   if test -z "$lt_cv_aix_libpath_"; then
12173     lt_cv_aix_libpath_=/usr/lib:/lib
12174   fi
12175
12176 fi
12177
12178   aix_libpath=$lt_cv_aix_libpath_
12179 fi
12180
12181          hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12182           # Warning - without using the other run time loading flags,
12183           # -berok will link without error, but may produce a broken library.
12184           no_undefined_flag=' $wl-bernotok'
12185           allow_undefined_flag=' $wl-berok'
12186           if test yes = "$with_gnu_ld"; then
12187             # We only use this code for GNU lds that support --whole-archive.
12188             whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12189           else
12190             # Exported symbols can be pulled into shared objects from archives
12191             whole_archive_flag_spec='$convenience'
12192           fi
12193           archive_cmds_need_lc=yes
12194           archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12195           # -brtl affects multiple linker settings, -berok does not and is overridden later
12196           compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12197           if test svr4 != "$with_aix_soname"; then
12198             # This is similar to how AIX traditionally builds its shared libraries.
12199             archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
12200           fi
12201           if test aix != "$with_aix_soname"; then
12202             archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
12203           else
12204             # used by -dlpreopen to get the symbols
12205             archive_expsym_cmds="$archive_expsym_cmds"'~$MV  $output_objdir/$realname.d/$soname $output_objdir'
12206           fi
12207           archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12208         fi
12209       fi
12210       ;;
12211
12212     amigaos*)
12213       case $host_cpu in
12214       powerpc)
12215             # see comment about AmigaOS4 .so support
12216             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12217             archive_expsym_cmds=''
12218         ;;
12219       m68k)
12220             archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
12221             hardcode_libdir_flag_spec='-L$libdir'
12222             hardcode_minus_L=yes
12223         ;;
12224       esac
12225       ;;
12226
12227     bsdi[45]*)
12228       export_dynamic_flag_spec=-rdynamic
12229       ;;
12230
12231     cygwin* | mingw* | pw32* | cegcc*)
12232       # When not using gcc, we currently assume that we are using
12233       # Microsoft Visual C++.
12234       # hardcode_libdir_flag_spec is actually meaningless, as there is
12235       # no search path for DLLs.
12236       case $cc_basename in
12237       cl*)
12238         # Native MSVC
12239         hardcode_libdir_flag_spec=' '
12240         allow_undefined_flag=unsupported
12241         always_export_symbols=yes
12242         file_list_spec='@'
12243         # Tell ltmain to make .lib files, not .a files.
12244         libext=lib
12245         # Tell ltmain to make .dll files, not .so files.
12246         shrext_cmds=.dll
12247         # FIXME: Setting linknames here is a bad hack.
12248         archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12249         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
12250             cp "$export_symbols" "$output_objdir/$soname.def";
12251             echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12252           else
12253             $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12254           fi~
12255           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12256           linknames='
12257         # The linker will not automatically build a static lib if we build a DLL.
12258         # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12259         enable_shared_with_static_runtimes=yes
12260         exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12261         export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12262         # Don't use ranlib
12263         old_postinstall_cmds='chmod 644 $oldlib'
12264         postlink_cmds='lt_outputfile="@OUTPUT@"~
12265           lt_tool_outputfile="@TOOL_OUTPUT@"~
12266           case $lt_outputfile in
12267             *.exe|*.EXE) ;;
12268             *)
12269               lt_outputfile=$lt_outputfile.exe
12270               lt_tool_outputfile=$lt_tool_outputfile.exe
12271               ;;
12272           esac~
12273           if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
12274             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12275             $RM "$lt_outputfile.manifest";
12276           fi'
12277         ;;
12278       *)
12279         # Assume MSVC wrapper
12280         hardcode_libdir_flag_spec=' '
12281         allow_undefined_flag=unsupported
12282         # Tell ltmain to make .lib files, not .a files.
12283         libext=lib
12284         # Tell ltmain to make .dll files, not .so files.
12285         shrext_cmds=.dll
12286         # FIXME: Setting linknames here is a bad hack.
12287         archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12288         # The linker will automatically build a .lib file if we build a DLL.
12289         old_archive_from_new_cmds='true'
12290         # FIXME: Should let the user specify the lib program.
12291         old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12292         enable_shared_with_static_runtimes=yes
12293         ;;
12294       esac
12295       ;;
12296
12297     darwin* | rhapsody*)
12298
12299
12300   archive_cmds_need_lc=no
12301   hardcode_direct=no
12302   hardcode_automatic=yes
12303   hardcode_shlibpath_var=unsupported
12304   if test yes = "$lt_cv_ld_force_load"; then
12305     whole_archive_flag_spec='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
12306
12307   else
12308     whole_archive_flag_spec=''
12309   fi
12310   link_all_deplibs=yes
12311   allow_undefined_flag=$_lt_dar_allow_undefined
12312   case $cc_basename in
12313      ifort*|nagfor*) _lt_dar_can_shared=yes ;;
12314      *) _lt_dar_can_shared=$GCC ;;
12315   esac
12316   if test yes = "$_lt_dar_can_shared"; then
12317     output_verbose_link_cmd=func_echo_all
12318     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
12319     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
12320     archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
12321     module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
12322
12323   else
12324   ld_shlibs=no
12325   fi
12326
12327       ;;
12328
12329     dgux*)
12330       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12331       hardcode_libdir_flag_spec='-L$libdir'
12332       hardcode_shlibpath_var=no
12333       ;;
12334
12335     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
12336     # support.  Future versions do this automatically, but an explicit c++rt0.o
12337     # does not break anything, and helps significantly (at the cost of a little
12338     # extra space).
12339     freebsd2.2*)
12340       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
12341       hardcode_libdir_flag_spec='-R$libdir'
12342       hardcode_direct=yes
12343       hardcode_shlibpath_var=no
12344       ;;
12345
12346     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
12347     freebsd2.*)
12348       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12349       hardcode_direct=yes
12350       hardcode_minus_L=yes
12351       hardcode_shlibpath_var=no
12352       ;;
12353
12354     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12355     freebsd* | dragonfly*)
12356       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12357       hardcode_libdir_flag_spec='-R$libdir'
12358       hardcode_direct=yes
12359       hardcode_shlibpath_var=no
12360       ;;
12361
12362     hpux9*)
12363       if test yes = "$GCC"; then
12364         archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
12365       else
12366         archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
12367       fi
12368       hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12369       hardcode_libdir_separator=:
12370       hardcode_direct=yes
12371
12372       # hardcode_minus_L: Not really in the search PATH,
12373       # but as the default location of the library.
12374       hardcode_minus_L=yes
12375       export_dynamic_flag_spec='$wl-E'
12376       ;;
12377
12378     hpux10*)
12379       if test yes,no = "$GCC,$with_gnu_ld"; then
12380         archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12381       else
12382         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12383       fi
12384       if test no = "$with_gnu_ld"; then
12385         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12386         hardcode_libdir_separator=:
12387         hardcode_direct=yes
12388         hardcode_direct_absolute=yes
12389         export_dynamic_flag_spec='$wl-E'
12390         # hardcode_minus_L: Not really in the search PATH,
12391         # but as the default location of the library.
12392         hardcode_minus_L=yes
12393       fi
12394       ;;
12395
12396     hpux11*)
12397       if test yes,no = "$GCC,$with_gnu_ld"; then
12398         case $host_cpu in
12399         hppa*64*)
12400           archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12401           ;;
12402         ia64*)
12403           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12404           ;;
12405         *)
12406           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12407           ;;
12408         esac
12409       else
12410         case $host_cpu in
12411         hppa*64*)
12412           archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12413           ;;
12414         ia64*)
12415           archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12416           ;;
12417         *)
12418
12419           # Older versions of the 11.00 compiler do not understand -b yet
12420           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
12421           { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
12422 $as_echo_n "checking if $CC understands -b... " >&6; }
12423 if ${lt_cv_prog_compiler__b+:} false; then :
12424   $as_echo_n "(cached) " >&6
12425 else
12426   lt_cv_prog_compiler__b=no
12427    save_LDFLAGS=$LDFLAGS
12428    LDFLAGS="$LDFLAGS -b"
12429    echo "$lt_simple_link_test_code" > conftest.$ac_ext
12430    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12431      # The linker can only warn and ignore the option if not recognized
12432      # So say no if there are warnings
12433      if test -s conftest.err; then
12434        # Append any errors to the config.log.
12435        cat conftest.err 1>&5
12436        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12437        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12438        if diff conftest.exp conftest.er2 >/dev/null; then
12439          lt_cv_prog_compiler__b=yes
12440        fi
12441      else
12442        lt_cv_prog_compiler__b=yes
12443      fi
12444    fi
12445    $RM -r conftest*
12446    LDFLAGS=$save_LDFLAGS
12447
12448 fi
12449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
12450 $as_echo "$lt_cv_prog_compiler__b" >&6; }
12451
12452 if test yes = "$lt_cv_prog_compiler__b"; then
12453     archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12454 else
12455     archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12456 fi
12457
12458           ;;
12459         esac
12460       fi
12461       if test no = "$with_gnu_ld"; then
12462         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12463         hardcode_libdir_separator=:
12464
12465         case $host_cpu in
12466         hppa*64*|ia64*)
12467           hardcode_direct=no
12468           hardcode_shlibpath_var=no
12469           ;;
12470         *)
12471           hardcode_direct=yes
12472           hardcode_direct_absolute=yes
12473           export_dynamic_flag_spec='$wl-E'
12474
12475           # hardcode_minus_L: Not really in the search PATH,
12476           # but as the default location of the library.
12477           hardcode_minus_L=yes
12478           ;;
12479         esac
12480       fi
12481       ;;
12482
12483     irix5* | irix6* | nonstopux*)
12484       if test yes = "$GCC"; then
12485         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
12486         # Try to use the -exported_symbol ld option, if it does not
12487         # work, assume that -exports_file does not work either and
12488         # implicitly export all symbols.
12489         # This should be the same for all languages, so no per-tag cache variable.
12490         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12491 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12492 if ${lt_cv_irix_exported_symbol+:} false; then :
12493   $as_echo_n "(cached) " >&6
12494 else
12495   save_LDFLAGS=$LDFLAGS
12496            LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
12497            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12498 /* end confdefs.h.  */
12499 int foo (void) { return 0; }
12500 _ACEOF
12501 if ac_fn_c_try_link "$LINENO"; then :
12502   lt_cv_irix_exported_symbol=yes
12503 else
12504   lt_cv_irix_exported_symbol=no
12505 fi
12506 rm -f core conftest.err conftest.$ac_objext \
12507     conftest$ac_exeext conftest.$ac_ext
12508            LDFLAGS=$save_LDFLAGS
12509 fi
12510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12511 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
12512         if test yes = "$lt_cv_irix_exported_symbol"; then
12513           archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
12514         fi
12515       else
12516         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
12517         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
12518       fi
12519       archive_cmds_need_lc='no'
12520       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12521       hardcode_libdir_separator=:
12522       inherit_rpath=yes
12523       link_all_deplibs=yes
12524       ;;
12525
12526     linux*)
12527       case $cc_basename in
12528       tcc*)
12529         # Fabrice Bellard et al's Tiny C Compiler
12530         ld_shlibs=yes
12531         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12532         ;;
12533       esac
12534       ;;
12535
12536     netbsd*)
12537       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12538         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
12539       else
12540         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
12541       fi
12542       hardcode_libdir_flag_spec='-R$libdir'
12543       hardcode_direct=yes
12544       hardcode_shlibpath_var=no
12545       ;;
12546
12547     newsos6)
12548       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12549       hardcode_direct=yes
12550       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12551       hardcode_libdir_separator=:
12552       hardcode_shlibpath_var=no
12553       ;;
12554
12555     *nto* | *qnx*)
12556       ;;
12557
12558     openbsd* | bitrig*)
12559       if test -f /usr/libexec/ld.so; then
12560         hardcode_direct=yes
12561         hardcode_shlibpath_var=no
12562         hardcode_direct_absolute=yes
12563         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
12564           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12565           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
12566           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12567           export_dynamic_flag_spec='$wl-E'
12568         else
12569           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12570           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12571         fi
12572       else
12573         ld_shlibs=no
12574       fi
12575       ;;
12576
12577     os2*)
12578       hardcode_libdir_flag_spec='-L$libdir'
12579       hardcode_minus_L=yes
12580       allow_undefined_flag=unsupported
12581       shrext_cmds=.dll
12582       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12583         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12584         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12585         $ECHO EXPORTS >> $output_objdir/$libname.def~
12586         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12587         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12588         emximp -o $lib $output_objdir/$libname.def'
12589       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12590         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12591         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12592         $ECHO EXPORTS >> $output_objdir/$libname.def~
12593         prefix_cmds="$SED"~
12594         if test EXPORTS = "`$SED 1q $export_symbols`"; then
12595           prefix_cmds="$prefix_cmds -e 1d";
12596         fi~
12597         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12598         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12599         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12600         emximp -o $lib $output_objdir/$libname.def'
12601       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12602       enable_shared_with_static_runtimes=yes
12603       ;;
12604
12605     osf3*)
12606       if test yes = "$GCC"; then
12607         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12608         archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
12609       else
12610         allow_undefined_flag=' -expect_unresolved \*'
12611         archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
12612       fi
12613       archive_cmds_need_lc='no'
12614       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12615       hardcode_libdir_separator=:
12616       ;;
12617
12618     osf4* | osf5*)      # as osf3* with the addition of -msym flag
12619       if test yes = "$GCC"; then
12620         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12621         archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
12622         hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12623       else
12624         allow_undefined_flag=' -expect_unresolved \*'
12625         archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
12626         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
12627           $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
12628
12629         # Both c and cxx compiler support -rpath directly
12630         hardcode_libdir_flag_spec='-rpath $libdir'
12631       fi
12632       archive_cmds_need_lc='no'
12633       hardcode_libdir_separator=:
12634       ;;
12635
12636     solaris*)
12637       no_undefined_flag=' -z defs'
12638       if test yes = "$GCC"; then
12639         wlarc='$wl'
12640         archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12641         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12642           $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12643       else
12644         case `$CC -V 2>&1` in
12645         *"Compilers 5.0"*)
12646           wlarc=''
12647           archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
12648           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12649             $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12650           ;;
12651         *)
12652           wlarc='$wl'
12653           archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12654           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12655             $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12656           ;;
12657         esac
12658       fi
12659       hardcode_libdir_flag_spec='-R$libdir'
12660       hardcode_shlibpath_var=no
12661       case $host_os in
12662       solaris2.[0-5] | solaris2.[0-5].*) ;;
12663       *)
12664         # The compiler driver will combine and reorder linker options,
12665         # but understands '-z linker_flag'.  GCC discards it without '$wl',
12666         # but is careful enough not to reorder.
12667         # Supported since Solaris 2.6 (maybe 2.5.1?)
12668         if test yes = "$GCC"; then
12669           whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
12670         else
12671           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12672         fi
12673         ;;
12674       esac
12675       link_all_deplibs=yes
12676       ;;
12677
12678     sunos4*)
12679       if test sequent = "$host_vendor"; then
12680         # Use $CC to link under sequent, because it throws in some extra .o
12681         # files that make .init and .fini sections work.
12682         archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12683       else
12684         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12685       fi
12686       hardcode_libdir_flag_spec='-L$libdir'
12687       hardcode_direct=yes
12688       hardcode_minus_L=yes
12689       hardcode_shlibpath_var=no
12690       ;;
12691
12692     sysv4)
12693       case $host_vendor in
12694         sni)
12695           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12696           hardcode_direct=yes # is this really true???
12697         ;;
12698         siemens)
12699           ## LD is ld it makes a PLAMLIB
12700           ## CC just makes a GrossModule.
12701           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12702           reload_cmds='$CC -r -o $output$reload_objs'
12703           hardcode_direct=no
12704         ;;
12705         motorola)
12706           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12707           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12708         ;;
12709       esac
12710       runpath_var='LD_RUN_PATH'
12711       hardcode_shlibpath_var=no
12712       ;;
12713
12714     sysv4.3*)
12715       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12716       hardcode_shlibpath_var=no
12717       export_dynamic_flag_spec='-Bexport'
12718       ;;
12719
12720     sysv4*MP*)
12721       if test -d /usr/nec; then
12722         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12723         hardcode_shlibpath_var=no
12724         runpath_var=LD_RUN_PATH
12725         hardcode_runpath_var=yes
12726         ld_shlibs=yes
12727       fi
12728       ;;
12729
12730     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12731       no_undefined_flag='$wl-z,text'
12732       archive_cmds_need_lc=no
12733       hardcode_shlibpath_var=no
12734       runpath_var='LD_RUN_PATH'
12735
12736       if test yes = "$GCC"; then
12737         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12738         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12739       else
12740         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12741         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12742       fi
12743       ;;
12744
12745     sysv5* | sco3.2v5* | sco5v6*)
12746       # Note: We CANNOT use -z defs as we might desire, because we do not
12747       # link with -lc, and that would cause any symbols used from libc to
12748       # always be unresolved, which means just about no library would
12749       # ever link correctly.  If we're not using GNU ld we use -z text
12750       # though, which does catch some bad symbols but isn't as heavy-handed
12751       # as -z defs.
12752       no_undefined_flag='$wl-z,text'
12753       allow_undefined_flag='$wl-z,nodefs'
12754       archive_cmds_need_lc=no
12755       hardcode_shlibpath_var=no
12756       hardcode_libdir_flag_spec='$wl-R,$libdir'
12757       hardcode_libdir_separator=':'
12758       link_all_deplibs=yes
12759       export_dynamic_flag_spec='$wl-Bexport'
12760       runpath_var='LD_RUN_PATH'
12761
12762       if test yes = "$GCC"; then
12763         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12764         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12765       else
12766         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12767         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12768       fi
12769       ;;
12770
12771     uts4*)
12772       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12773       hardcode_libdir_flag_spec='-L$libdir'
12774       hardcode_shlibpath_var=no
12775       ;;
12776
12777     *)
12778       ld_shlibs=no
12779       ;;
12780     esac
12781
12782     if test sni = "$host_vendor"; then
12783       case $host in
12784       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12785         export_dynamic_flag_spec='$wl-Blargedynsym'
12786         ;;
12787       esac
12788     fi
12789   fi
12790
12791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12792 $as_echo "$ld_shlibs" >&6; }
12793 test no = "$ld_shlibs" && can_build_shared=no
12794
12795 with_gnu_ld=$with_gnu_ld
12796
12797
12798
12799
12800
12801
12802
12803
12804
12805
12806
12807
12808
12809
12810
12811 #
12812 # Do we need to explicitly link libc?
12813 #
12814 case "x$archive_cmds_need_lc" in
12815 x|xyes)
12816   # Assume -lc should be added
12817   archive_cmds_need_lc=yes
12818
12819   if test yes,yes = "$GCC,$enable_shared"; then
12820     case $archive_cmds in
12821     *'~'*)
12822       # FIXME: we may have to deal with multi-command sequences.
12823       ;;
12824     '$CC '*)
12825       # Test whether the compiler implicitly links with -lc since on some
12826       # systems, -lgcc has to come before -lc. If gcc already passes -lc
12827       # to ld, don't add -lc before -lgcc.
12828       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12829 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12830 if ${lt_cv_archive_cmds_need_lc+:} false; then :
12831   $as_echo_n "(cached) " >&6
12832 else
12833   $RM conftest*
12834         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12835
12836         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12837   (eval $ac_compile) 2>&5
12838   ac_status=$?
12839   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12840   test $ac_status = 0; } 2>conftest.err; then
12841           soname=conftest
12842           lib=conftest
12843           libobjs=conftest.$ac_objext
12844           deplibs=
12845           wl=$lt_prog_compiler_wl
12846           pic_flag=$lt_prog_compiler_pic
12847           compiler_flags=-v
12848           linker_flags=-v
12849           verstring=
12850           output_objdir=.
12851           libname=conftest
12852           lt_save_allow_undefined_flag=$allow_undefined_flag
12853           allow_undefined_flag=
12854           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12855   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12856   ac_status=$?
12857   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12858   test $ac_status = 0; }
12859           then
12860             lt_cv_archive_cmds_need_lc=no
12861           else
12862             lt_cv_archive_cmds_need_lc=yes
12863           fi
12864           allow_undefined_flag=$lt_save_allow_undefined_flag
12865         else
12866           cat conftest.err 1>&5
12867         fi
12868         $RM conftest*
12869
12870 fi
12871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12872 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12873       archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12874       ;;
12875     esac
12876   fi
12877   ;;
12878 esac
12879
12880
12881
12882
12883
12884
12885
12886
12887
12888
12889
12890
12891
12892
12893
12894
12895
12896
12897
12898
12899
12900
12901
12902
12903
12904
12905
12906
12907
12908
12909
12910
12911
12912
12913
12914
12915
12916
12917
12918
12919
12920
12921
12922
12923
12924
12925
12926
12927
12928
12929
12930
12931
12932
12933
12934
12935
12936
12937
12938
12939
12940
12941
12942
12943
12944
12945
12946
12947
12948
12949
12950
12951
12952
12953
12954
12955
12956
12957
12958
12959
12960
12961
12962
12963
12964
12965
12966
12967
12968
12969
12970
12971
12972
12973
12974
12975
12976
12977
12978
12979
12980
12981
12982
12983
12984
12985
12986
12987
12988
12989
12990
12991
12992
12993
12994
12995
12996
12997
12998
12999
13000
13001
13002
13003
13004
13005
13006
13007
13008
13009
13010
13011
13012
13013
13014
13015
13016
13017
13018
13019
13020
13021
13022
13023
13024
13025
13026
13027
13028
13029
13030
13031   { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
13032 $as_echo_n "checking dynamic linker characteristics... " >&6; }
13033
13034 if test yes = "$GCC"; then
13035   case $host_os in
13036     darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
13037     *) lt_awk_arg='/^libraries:/' ;;
13038   esac
13039   case $host_os in
13040     mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
13041     *) lt_sed_strip_eq='s|=/|/|g' ;;
13042   esac
13043   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
13044   case $lt_search_path_spec in
13045   *\;*)
13046     # if the path contains ";" then we assume it to be the separator
13047     # otherwise default to the standard path separator (i.e. ":") - it is
13048     # assumed that no part of a normal pathname contains ";" but that should
13049     # okay in the real world where ";" in dirpaths is itself problematic.
13050     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
13051     ;;
13052   *)
13053     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
13054     ;;
13055   esac
13056   # Ok, now we have the path, separated by spaces, we can step through it
13057   # and add multilib dir if necessary...
13058   lt_tmp_lt_search_path_spec=
13059   lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
13060   # ...but if some path component already ends with the multilib dir we assume
13061   # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
13062   case "$lt_multi_os_dir; $lt_search_path_spec " in
13063   "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
13064     lt_multi_os_dir=
13065     ;;
13066   esac
13067   for lt_sys_path in $lt_search_path_spec; do
13068     if test -d "$lt_sys_path$lt_multi_os_dir"; then
13069       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
13070     elif test -n "$lt_multi_os_dir"; then
13071       test -d "$lt_sys_path" && \
13072         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
13073     fi
13074   done
13075   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13076 BEGIN {RS = " "; FS = "/|\n";} {
13077   lt_foo = "";
13078   lt_count = 0;
13079   for (lt_i = NF; lt_i > 0; lt_i--) {
13080     if ($lt_i != "" && $lt_i != ".") {
13081       if ($lt_i == "..") {
13082         lt_count++;
13083       } else {
13084         if (lt_count == 0) {
13085           lt_foo = "/" $lt_i lt_foo;
13086         } else {
13087           lt_count--;
13088         }
13089       }
13090     }
13091   }
13092   if (lt_foo != "") { lt_freq[lt_foo]++; }
13093   if (lt_freq[lt_foo] == 1) { print lt_foo; }
13094 }'`
13095   # AWK program above erroneously prepends '/' to C:/dos/paths
13096   # for these hosts.
13097   case $host_os in
13098     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13099       $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13100   esac
13101   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13102 else
13103   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13104 fi
13105 library_names_spec=
13106 libname_spec='lib$name'
13107 soname_spec=
13108 shrext_cmds=.so
13109 postinstall_cmds=
13110 postuninstall_cmds=
13111 finish_cmds=
13112 finish_eval=
13113 shlibpath_var=
13114 shlibpath_overrides_runpath=unknown
13115 version_type=none
13116 dynamic_linker="$host_os ld.so"
13117 sys_lib_dlsearch_path_spec="/lib /usr/lib"
13118 need_lib_prefix=unknown
13119 hardcode_into_libs=no
13120
13121 # when you set need_version to no, make sure it does not cause -set_version
13122 # flags to be left without arguments
13123 need_version=unknown
13124
13125
13126
13127 case $host_os in
13128 aix3*)
13129   version_type=linux # correct to gnu/linux during the next big refactor
13130   library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13131   shlibpath_var=LIBPATH
13132
13133   # AIX 3 has no versioning support, so we append a major version to the name.
13134   soname_spec='$libname$release$shared_ext$major'
13135   ;;
13136
13137 aix[4-9]*)
13138   version_type=linux # correct to gnu/linux during the next big refactor
13139   need_lib_prefix=no
13140   need_version=no
13141   hardcode_into_libs=yes
13142   if test ia64 = "$host_cpu"; then
13143     # AIX 5 supports IA64
13144     library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13145     shlibpath_var=LD_LIBRARY_PATH
13146   else
13147     # With GCC up to 2.95.x, collect2 would create an import file
13148     # for dependence libraries.  The import file would start with
13149     # the line '#! .'.  This would cause the generated library to
13150     # depend on '.', always an invalid library.  This was fixed in
13151     # development snapshots of GCC prior to 3.0.
13152     case $host_os in
13153       aix4 | aix4.[01] | aix4.[01].*)
13154       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13155            echo ' yes '
13156            echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13157         :
13158       else
13159         can_build_shared=no
13160       fi
13161       ;;
13162     esac
13163     # Using Import Files as archive members, it is possible to support
13164     # filename-based versioning of shared library archives on AIX. While
13165     # this would work for both with and without runtime linking, it will
13166     # prevent static linking of such archives. So we do filename-based
13167     # shared library versioning with .so extension only, which is used
13168     # when both runtime linking and shared linking is enabled.
13169     # Unfortunately, runtime linking may impact performance, so we do
13170     # not want this to be the default eventually. Also, we use the
13171     # versioned .so libs for executables only if there is the -brtl
13172     # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13173     # To allow for filename-based versioning support, we need to create
13174     # libNAME.so.V as an archive file, containing:
13175     # *) an Import File, referring to the versioned filename of the
13176     #    archive as well as the shared archive member, telling the
13177     #    bitwidth (32 or 64) of that shared object, and providing the
13178     #    list of exported symbols of that shared object, eventually
13179     #    decorated with the 'weak' keyword
13180     # *) the shared object with the F_LOADONLY flag set, to really avoid
13181     #    it being seen by the linker.
13182     # At run time we better use the real file rather than another symlink,
13183     # but for link time we create the symlink libNAME.so -> libNAME.so.V
13184
13185     case $with_aix_soname,$aix_use_runtimelinking in
13186     # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13187     # soname into executable. Probably we can add versioning support to
13188     # collect2, so additional links can be useful in future.
13189     aix,yes) # traditional libtool
13190       dynamic_linker='AIX unversionable lib.so'
13191       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13192       # instead of lib<name>.a to let people know that these are not
13193       # typical AIX shared libraries.
13194       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13195       ;;
13196     aix,no) # traditional AIX only
13197       dynamic_linker='AIX lib.a(lib.so.V)'
13198       # We preserve .a as extension for shared libraries through AIX4.2
13199       # and later when we are not doing run time linking.
13200       library_names_spec='$libname$release.a $libname.a'
13201       soname_spec='$libname$release$shared_ext$major'
13202       ;;
13203     svr4,*) # full svr4 only
13204       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13205       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13206       # We do not specify a path in Import Files, so LIBPATH fires.
13207       shlibpath_overrides_runpath=yes
13208       ;;
13209     *,yes) # both, prefer svr4
13210       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13211       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13212       # unpreferred sharedlib libNAME.a needs extra handling
13213       postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
13214       postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
13215       # We do not specify a path in Import Files, so LIBPATH fires.
13216       shlibpath_overrides_runpath=yes
13217       ;;
13218     *,no) # both, prefer aix
13219       dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13220       library_names_spec='$libname$release.a $libname.a'
13221       soname_spec='$libname$release$shared_ext$major'
13222       # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13223       postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
13224       postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
13225       ;;
13226     esac
13227     shlibpath_var=LIBPATH
13228   fi
13229   ;;
13230
13231 amigaos*)
13232   case $host_cpu in
13233   powerpc)
13234     # Since July 2007 AmigaOS4 officially supports .so libraries.
13235     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13236     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13237     ;;
13238   m68k)
13239     library_names_spec='$libname.ixlibrary $libname.a'
13240     # Create ${libname}_ixlibrary.a entries in /sys/libs.
13241     finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
13242     ;;
13243   esac
13244   ;;
13245
13246 beos*)
13247   library_names_spec='$libname$shared_ext'
13248   dynamic_linker="$host_os ld.so"
13249   shlibpath_var=LIBRARY_PATH
13250   ;;
13251
13252 bsdi[45]*)
13253   version_type=linux # correct to gnu/linux during the next big refactor
13254   need_version=no
13255   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13256   soname_spec='$libname$release$shared_ext$major'
13257   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13258   shlibpath_var=LD_LIBRARY_PATH
13259   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13260   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13261   # the default ld.so.conf also contains /usr/contrib/lib and
13262   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13263   # libtool to hard-code these into programs
13264   ;;
13265
13266 cygwin* | mingw* | pw32* | cegcc*)
13267   version_type=windows
13268   shrext_cmds=.dll
13269   need_version=no
13270   need_lib_prefix=no
13271
13272   case $GCC,$cc_basename in
13273   yes,*)
13274     # gcc
13275     library_names_spec='$libname.dll.a'
13276     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13277     postinstall_cmds='base_file=`basename \$file`~
13278       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13279       dldir=$destdir/`dirname \$dlpath`~
13280       test -d \$dldir || mkdir -p \$dldir~
13281       $install_prog $dir/$dlname \$dldir/$dlname~
13282       chmod a+x \$dldir/$dlname~
13283       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13284         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13285       fi'
13286     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13287       dlpath=$dir/\$dldll~
13288        $RM \$dlpath'
13289     shlibpath_overrides_runpath=yes
13290
13291     case $host_os in
13292     cygwin*)
13293       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
13294       soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13295
13296       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
13297       ;;
13298     mingw* | cegcc*)
13299       # MinGW DLLs use traditional 'lib' prefix
13300       soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13301       ;;
13302     pw32*)
13303       # pw32 DLLs use 'pw' prefix rather than 'lib'
13304       library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13305       ;;
13306     esac
13307     dynamic_linker='Win32 ld.exe'
13308     ;;
13309
13310   *,cl*)
13311     # Native MSVC
13312     libname_spec='$name'
13313     soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13314     library_names_spec='$libname.dll.lib'
13315
13316     case $build_os in
13317     mingw*)
13318       sys_lib_search_path_spec=
13319       lt_save_ifs=$IFS
13320       IFS=';'
13321       for lt_path in $LIB
13322       do
13323         IFS=$lt_save_ifs
13324         # Let DOS variable expansion print the short 8.3 style file name.
13325         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
13326         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
13327       done
13328       IFS=$lt_save_ifs
13329       # Convert to MSYS style.
13330       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
13331       ;;
13332     cygwin*)
13333       # Convert to unix form, then to dos form, then back to unix form
13334       # but this time dos style (no spaces!) so that the unix form looks
13335       # like /cygdrive/c/PROGRA~1:/cygdr...
13336       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
13337       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
13338       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13339       ;;
13340     *)
13341       sys_lib_search_path_spec=$LIB
13342       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
13343         # It is most probably a Windows format PATH.
13344         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
13345       else
13346         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13347       fi
13348       # FIXME: find the short name or the path components, as spaces are
13349       # common. (e.g. "Program Files" -> "PROGRA~1")
13350       ;;
13351     esac
13352
13353     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13354     postinstall_cmds='base_file=`basename \$file`~
13355       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13356       dldir=$destdir/`dirname \$dlpath`~
13357       test -d \$dldir || mkdir -p \$dldir~
13358       $install_prog $dir/$dlname \$dldir/$dlname'
13359     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13360       dlpath=$dir/\$dldll~
13361        $RM \$dlpath'
13362     shlibpath_overrides_runpath=yes
13363     dynamic_linker='Win32 link.exe'
13364     ;;
13365
13366   *)
13367     # Assume MSVC wrapper
13368     library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
13369     dynamic_linker='Win32 ld.exe'
13370     ;;
13371   esac
13372   # FIXME: first we should search . and the directory the executable is in
13373   shlibpath_var=PATH
13374   ;;
13375
13376 darwin* | rhapsody*)
13377   dynamic_linker="$host_os dyld"
13378   version_type=darwin
13379   need_lib_prefix=no
13380   need_version=no
13381   library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
13382   soname_spec='$libname$release$major$shared_ext'
13383   shlibpath_overrides_runpath=yes
13384   shlibpath_var=DYLD_LIBRARY_PATH
13385   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
13386
13387   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
13388   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
13389   ;;
13390
13391 dgux*)
13392   version_type=linux # correct to gnu/linux during the next big refactor
13393   need_lib_prefix=no
13394   need_version=no
13395   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13396   soname_spec='$libname$release$shared_ext$major'
13397   shlibpath_var=LD_LIBRARY_PATH
13398   ;;
13399
13400 freebsd* | dragonfly*)
13401   # DragonFly does not have aout.  When/if they implement a new
13402   # versioning mechanism, adjust this.
13403   if test -x /usr/bin/objformat; then
13404     objformat=`/usr/bin/objformat`
13405   else
13406     case $host_os in
13407     freebsd[23].*) objformat=aout ;;
13408     *) objformat=elf ;;
13409     esac
13410   fi
13411   version_type=freebsd-$objformat
13412   case $version_type in
13413     freebsd-elf*)
13414       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13415       soname_spec='$libname$release$shared_ext$major'
13416       need_version=no
13417       need_lib_prefix=no
13418       ;;
13419     freebsd-*)
13420       library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13421       need_version=yes
13422       ;;
13423   esac
13424   shlibpath_var=LD_LIBRARY_PATH
13425   case $host_os in
13426   freebsd2.*)
13427     shlibpath_overrides_runpath=yes
13428     ;;
13429   freebsd3.[01]* | freebsdelf3.[01]*)
13430     shlibpath_overrides_runpath=yes
13431     hardcode_into_libs=yes
13432     ;;
13433   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
13434   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
13435     shlibpath_overrides_runpath=no
13436     hardcode_into_libs=yes
13437     ;;
13438   *) # from 4.6 on, and DragonFly
13439     shlibpath_overrides_runpath=yes
13440     hardcode_into_libs=yes
13441     ;;
13442   esac
13443   ;;
13444
13445 haiku*)
13446   version_type=linux # correct to gnu/linux during the next big refactor
13447   need_lib_prefix=no
13448   need_version=no
13449   dynamic_linker="$host_os runtime_loader"
13450   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13451   soname_spec='$libname$release$shared_ext$major'
13452   shlibpath_var=LIBRARY_PATH
13453   shlibpath_overrides_runpath=no
13454   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
13455   hardcode_into_libs=yes
13456   ;;
13457
13458 hpux9* | hpux10* | hpux11*)
13459   # Give a soname corresponding to the major version so that dld.sl refuses to
13460   # link against other versions.
13461   version_type=sunos
13462   need_lib_prefix=no
13463   need_version=no
13464   case $host_cpu in
13465   ia64*)
13466     shrext_cmds='.so'
13467     hardcode_into_libs=yes
13468     dynamic_linker="$host_os dld.so"
13469     shlibpath_var=LD_LIBRARY_PATH
13470     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13471     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13472     soname_spec='$libname$release$shared_ext$major'
13473     if test 32 = "$HPUX_IA64_MODE"; then
13474       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
13475       sys_lib_dlsearch_path_spec=/usr/lib/hpux32
13476     else
13477       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
13478       sys_lib_dlsearch_path_spec=/usr/lib/hpux64
13479     fi
13480     ;;
13481   hppa*64*)
13482     shrext_cmds='.sl'
13483     hardcode_into_libs=yes
13484     dynamic_linker="$host_os dld.sl"
13485     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
13486     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13487     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13488     soname_spec='$libname$release$shared_ext$major'
13489     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
13490     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13491     ;;
13492   *)
13493     shrext_cmds='.sl'
13494     dynamic_linker="$host_os dld.sl"
13495     shlibpath_var=SHLIB_PATH
13496     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
13497     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13498     soname_spec='$libname$release$shared_ext$major'
13499     ;;
13500   esac
13501   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
13502   postinstall_cmds='chmod 555 $lib'
13503   # or fails outright, so override atomically:
13504   install_override_mode=555
13505   ;;
13506
13507 interix[3-9]*)
13508   version_type=linux # correct to gnu/linux during the next big refactor
13509   need_lib_prefix=no
13510   need_version=no
13511   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13512   soname_spec='$libname$release$shared_ext$major'
13513   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
13514   shlibpath_var=LD_LIBRARY_PATH
13515   shlibpath_overrides_runpath=no
13516   hardcode_into_libs=yes
13517   ;;
13518
13519 irix5* | irix6* | nonstopux*)
13520   case $host_os in
13521     nonstopux*) version_type=nonstopux ;;
13522     *)
13523         if test yes = "$lt_cv_prog_gnu_ld"; then
13524                 version_type=linux # correct to gnu/linux during the next big refactor
13525         else
13526                 version_type=irix
13527         fi ;;
13528   esac
13529   need_lib_prefix=no
13530   need_version=no
13531   soname_spec='$libname$release$shared_ext$major'
13532   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
13533   case $host_os in
13534   irix5* | nonstopux*)
13535     libsuff= shlibsuff=
13536     ;;
13537   *)
13538     case $LD in # libtool.m4 will add one of these switches to LD
13539     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
13540       libsuff= shlibsuff= libmagic=32-bit;;
13541     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
13542       libsuff=32 shlibsuff=N32 libmagic=N32;;
13543     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
13544       libsuff=64 shlibsuff=64 libmagic=64-bit;;
13545     *) libsuff= shlibsuff= libmagic=never-match;;
13546     esac
13547     ;;
13548   esac
13549   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
13550   shlibpath_overrides_runpath=no
13551   sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
13552   sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
13553   hardcode_into_libs=yes
13554   ;;
13555
13556 # No shared lib support for Linux oldld, aout, or coff.
13557 linux*oldld* | linux*aout* | linux*coff*)
13558   dynamic_linker=no
13559   ;;
13560
13561 linux*android*)
13562   version_type=none # Android doesn't support versioned libraries.
13563   need_lib_prefix=no
13564   need_version=no
13565   library_names_spec='$libname$release$shared_ext'
13566   soname_spec='$libname$release$shared_ext'
13567   finish_cmds=
13568   shlibpath_var=LD_LIBRARY_PATH
13569   shlibpath_overrides_runpath=yes
13570
13571   # This implies no fast_install, which is unacceptable.
13572   # Some rework will be needed to allow for fast_install
13573   # before this can be enabled.
13574   hardcode_into_libs=yes
13575
13576   dynamic_linker='Android linker'
13577   # Don't embed -rpath directories since the linker doesn't support them.
13578   hardcode_libdir_flag_spec='-L$libdir'
13579   ;;
13580
13581 # This must be glibc/ELF.
13582 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
13583   version_type=linux # correct to gnu/linux during the next big refactor
13584   need_lib_prefix=no
13585   need_version=no
13586   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13587   soname_spec='$libname$release$shared_ext$major'
13588   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
13589   shlibpath_var=LD_LIBRARY_PATH
13590   shlibpath_overrides_runpath=no
13591
13592   # Some binutils ld are patched to set DT_RUNPATH
13593   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
13594   $as_echo_n "(cached) " >&6
13595 else
13596   lt_cv_shlibpath_overrides_runpath=no
13597     save_LDFLAGS=$LDFLAGS
13598     save_libdir=$libdir
13599     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
13600          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
13601     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13602 /* end confdefs.h.  */
13603
13604 int
13605 main ()
13606 {
13607
13608   ;
13609   return 0;
13610 }
13611 _ACEOF
13612 if ac_fn_c_try_link "$LINENO"; then :
13613   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
13614   lt_cv_shlibpath_overrides_runpath=yes
13615 fi
13616 fi
13617 rm -f core conftest.err conftest.$ac_objext \
13618     conftest$ac_exeext conftest.$ac_ext
13619     LDFLAGS=$save_LDFLAGS
13620     libdir=$save_libdir
13621
13622 fi
13623
13624   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
13625
13626   # This implies no fast_install, which is unacceptable.
13627   # Some rework will be needed to allow for fast_install
13628   # before this can be enabled.
13629   hardcode_into_libs=yes
13630
13631   # Add ABI-specific directories to the system library path.
13632   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
13633
13634   # Ideally, we could use ldconfig to report *all* directores which are
13635   # searched for libraries, however this is still not possible.  Aside from not
13636   # being certain /sbin/ldconfig is available, command
13637   # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
13638   # even though it is searched at run-time.  Try to do the best guess by
13639   # appending ld.so.conf contents (and includes) to the search path.
13640   if test -f /etc/ld.so.conf; then
13641     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[       ]*hwcap[        ]/d;s/[:,      ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
13642     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
13643   fi
13644
13645   # We used to test for /lib/ld.so.1 and disable shared libraries on
13646   # powerpc, because MkLinux only supported shared libraries with the
13647   # GNU dynamic linker.  Since this was broken with cross compilers,
13648   # most powerpc-linux boxes support dynamic linking these days and
13649   # people can always --disable-shared, the test was removed, and we
13650   # assume the GNU/Linux dynamic linker is in use.
13651   dynamic_linker='GNU/Linux ld.so'
13652   ;;
13653
13654 netbsd*)
13655   version_type=sunos
13656   need_lib_prefix=no
13657   need_version=no
13658   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13659     library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13660     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13661     dynamic_linker='NetBSD (a.out) ld.so'
13662   else
13663     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13664     soname_spec='$libname$release$shared_ext$major'
13665     dynamic_linker='NetBSD ld.elf_so'
13666   fi
13667   shlibpath_var=LD_LIBRARY_PATH
13668   shlibpath_overrides_runpath=yes
13669   hardcode_into_libs=yes
13670   ;;
13671
13672 newsos6)
13673   version_type=linux # correct to gnu/linux during the next big refactor
13674   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13675   shlibpath_var=LD_LIBRARY_PATH
13676   shlibpath_overrides_runpath=yes
13677   ;;
13678
13679 *nto* | *qnx*)
13680   version_type=qnx
13681   need_lib_prefix=no
13682   need_version=no
13683   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13684   soname_spec='$libname$release$shared_ext$major'
13685   shlibpath_var=LD_LIBRARY_PATH
13686   shlibpath_overrides_runpath=no
13687   hardcode_into_libs=yes
13688   dynamic_linker='ldqnx.so'
13689   ;;
13690
13691 openbsd* | bitrig*)
13692   version_type=sunos
13693   sys_lib_dlsearch_path_spec=/usr/lib
13694   need_lib_prefix=no
13695   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13696     need_version=no
13697   else
13698     need_version=yes
13699   fi
13700   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13701   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13702   shlibpath_var=LD_LIBRARY_PATH
13703   shlibpath_overrides_runpath=yes
13704   ;;
13705
13706 os2*)
13707   libname_spec='$name'
13708   version_type=windows
13709   shrext_cmds=.dll
13710   need_version=no
13711   need_lib_prefix=no
13712   # OS/2 can only load a DLL with a base name of 8 characters or less.
13713   soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
13714     v=$($ECHO $release$versuffix | tr -d .-);
13715     n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
13716     $ECHO $n$v`$shared_ext'
13717   library_names_spec='${libname}_dll.$libext'
13718   dynamic_linker='OS/2 ld.exe'
13719   shlibpath_var=BEGINLIBPATH
13720   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13721   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13722   postinstall_cmds='base_file=`basename \$file`~
13723     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
13724     dldir=$destdir/`dirname \$dlpath`~
13725     test -d \$dldir || mkdir -p \$dldir~
13726     $install_prog $dir/$dlname \$dldir/$dlname~
13727     chmod a+x \$dldir/$dlname~
13728     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13729       eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13730     fi'
13731   postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
13732     dlpath=$dir/\$dldll~
13733     $RM \$dlpath'
13734   ;;
13735
13736 osf3* | osf4* | osf5*)
13737   version_type=osf
13738   need_lib_prefix=no
13739   need_version=no
13740   soname_spec='$libname$release$shared_ext$major'
13741   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13742   shlibpath_var=LD_LIBRARY_PATH
13743   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13744   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13745   ;;
13746
13747 rdos*)
13748   dynamic_linker=no
13749   ;;
13750
13751 solaris*)
13752   version_type=linux # correct to gnu/linux during the next big refactor
13753   need_lib_prefix=no
13754   need_version=no
13755   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13756   soname_spec='$libname$release$shared_ext$major'
13757   shlibpath_var=LD_LIBRARY_PATH
13758   shlibpath_overrides_runpath=yes
13759   hardcode_into_libs=yes
13760   # ldd complains unless libraries are executable
13761   postinstall_cmds='chmod +x $lib'
13762   ;;
13763
13764 sunos4*)
13765   version_type=sunos
13766   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13767   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13768   shlibpath_var=LD_LIBRARY_PATH
13769   shlibpath_overrides_runpath=yes
13770   if test yes = "$with_gnu_ld"; then
13771     need_lib_prefix=no
13772   fi
13773   need_version=yes
13774   ;;
13775
13776 sysv4 | sysv4.3*)
13777   version_type=linux # correct to gnu/linux during the next big refactor
13778   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13779   soname_spec='$libname$release$shared_ext$major'
13780   shlibpath_var=LD_LIBRARY_PATH
13781   case $host_vendor in
13782     sni)
13783       shlibpath_overrides_runpath=no
13784       need_lib_prefix=no
13785       runpath_var=LD_RUN_PATH
13786       ;;
13787     siemens)
13788       need_lib_prefix=no
13789       ;;
13790     motorola)
13791       need_lib_prefix=no
13792       need_version=no
13793       shlibpath_overrides_runpath=no
13794       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13795       ;;
13796   esac
13797   ;;
13798
13799 sysv4*MP*)
13800   if test -d /usr/nec; then
13801     version_type=linux # correct to gnu/linux during the next big refactor
13802     library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
13803     soname_spec='$libname$shared_ext.$major'
13804     shlibpath_var=LD_LIBRARY_PATH
13805   fi
13806   ;;
13807
13808 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13809   version_type=sco
13810   need_lib_prefix=no
13811   need_version=no
13812   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
13813   soname_spec='$libname$release$shared_ext$major'
13814   shlibpath_var=LD_LIBRARY_PATH
13815   shlibpath_overrides_runpath=yes
13816   hardcode_into_libs=yes
13817   if test yes = "$with_gnu_ld"; then
13818     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13819   else
13820     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13821     case $host_os in
13822       sco3.2v5*)
13823         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13824         ;;
13825     esac
13826   fi
13827   sys_lib_dlsearch_path_spec='/usr/lib'
13828   ;;
13829
13830 tpf*)
13831   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
13832   version_type=linux # correct to gnu/linux during the next big refactor
13833   need_lib_prefix=no
13834   need_version=no
13835   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13836   shlibpath_var=LD_LIBRARY_PATH
13837   shlibpath_overrides_runpath=no
13838   hardcode_into_libs=yes
13839   ;;
13840
13841 uts4*)
13842   version_type=linux # correct to gnu/linux during the next big refactor
13843   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13844   soname_spec='$libname$release$shared_ext$major'
13845   shlibpath_var=LD_LIBRARY_PATH
13846   ;;
13847
13848 *)
13849   dynamic_linker=no
13850   ;;
13851 esac
13852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13853 $as_echo "$dynamic_linker" >&6; }
13854 test no = "$dynamic_linker" && can_build_shared=no
13855
13856 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13857 if test yes = "$GCC"; then
13858   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13859 fi
13860
13861 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
13862   sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
13863 fi
13864
13865 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
13866   sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
13867 fi
13868
13869 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
13870 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
13871
13872 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
13873 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
13874
13875 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
13876 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
13877
13878
13879
13880
13881
13882
13883
13884
13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905
13906
13907
13908
13909
13910
13911
13912
13913
13914
13915
13916
13917
13918
13919
13920
13921
13922
13923
13924
13925
13926
13927
13928
13929
13930
13931
13932
13933
13934
13935
13936
13937
13938
13939
13940
13941
13942
13943
13944
13945
13946
13947
13948
13949
13950
13951
13952
13953
13954
13955
13956
13957
13958
13959
13960
13961
13962
13963
13964
13965
13966
13967
13968
13969
13970
13971
13972
13973
13974   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13975 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13976 hardcode_action=
13977 if test -n "$hardcode_libdir_flag_spec" ||
13978    test -n "$runpath_var" ||
13979    test yes = "$hardcode_automatic"; then
13980
13981   # We can hardcode non-existent directories.
13982   if test no != "$hardcode_direct" &&
13983      # If the only mechanism to avoid hardcoding is shlibpath_var, we
13984      # have to relink, otherwise we might link with an installed library
13985      # when we should be linking with a yet-to-be-installed one
13986      ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
13987      test no != "$hardcode_minus_L"; then
13988     # Linking always hardcodes the temporary library directory.
13989     hardcode_action=relink
13990   else
13991     # We can link without hardcoding, and we can hardcode nonexisting dirs.
13992     hardcode_action=immediate
13993   fi
13994 else
13995   # We cannot hardcode anything, or else we can only hardcode existing
13996   # directories.
13997   hardcode_action=unsupported
13998 fi
13999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
14000 $as_echo "$hardcode_action" >&6; }
14001
14002 if test relink = "$hardcode_action" ||
14003    test yes = "$inherit_rpath"; then
14004   # Fast installation is not supported
14005   enable_fast_install=no
14006 elif test yes = "$shlibpath_overrides_runpath" ||
14007      test no = "$enable_shared"; then
14008   # Fast installation is not necessary
14009   enable_fast_install=needless
14010 fi
14011
14012
14013
14014
14015
14016
14017   if test yes != "$enable_dlopen"; then
14018   enable_dlopen=unknown
14019   enable_dlopen_self=unknown
14020   enable_dlopen_self_static=unknown
14021 else
14022   lt_cv_dlopen=no
14023   lt_cv_dlopen_libs=
14024
14025   case $host_os in
14026   beos*)
14027     lt_cv_dlopen=load_add_on
14028     lt_cv_dlopen_libs=
14029     lt_cv_dlopen_self=yes
14030     ;;
14031
14032   mingw* | pw32* | cegcc*)
14033     lt_cv_dlopen=LoadLibrary
14034     lt_cv_dlopen_libs=
14035     ;;
14036
14037   cygwin*)
14038     lt_cv_dlopen=dlopen
14039     lt_cv_dlopen_libs=
14040     ;;
14041
14042   darwin*)
14043     # if libdl is installed we need to link against it
14044     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14045 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14046 if ${ac_cv_lib_dl_dlopen+:} false; then :
14047   $as_echo_n "(cached) " >&6
14048 else
14049   ac_check_lib_save_LIBS=$LIBS
14050 LIBS="-ldl  $LIBS"
14051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14052 /* end confdefs.h.  */
14053
14054 /* Override any GCC internal prototype to avoid an error.
14055    Use char because int might match the return type of a GCC
14056    builtin and then its argument prototype would still apply.  */
14057 #ifdef __cplusplus
14058 extern "C"
14059 #endif
14060 char dlopen ();
14061 int
14062 main ()
14063 {
14064 return dlopen ();
14065   ;
14066   return 0;
14067 }
14068 _ACEOF
14069 if ac_fn_c_try_link "$LINENO"; then :
14070   ac_cv_lib_dl_dlopen=yes
14071 else
14072   ac_cv_lib_dl_dlopen=no
14073 fi
14074 rm -f core conftest.err conftest.$ac_objext \
14075     conftest$ac_exeext conftest.$ac_ext
14076 LIBS=$ac_check_lib_save_LIBS
14077 fi
14078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14079 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14080 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14081   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14082 else
14083
14084     lt_cv_dlopen=dyld
14085     lt_cv_dlopen_libs=
14086     lt_cv_dlopen_self=yes
14087
14088 fi
14089
14090     ;;
14091
14092   tpf*)
14093     # Don't try to run any link tests for TPF.  We know it's impossible
14094     # because TPF is a cross-compiler, and we know how we open DSOs.
14095     lt_cv_dlopen=dlopen
14096     lt_cv_dlopen_libs=
14097     lt_cv_dlopen_self=no
14098     ;;
14099
14100   *)
14101     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14102 if test "x$ac_cv_func_shl_load" = xyes; then :
14103   lt_cv_dlopen=shl_load
14104 else
14105   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14106 $as_echo_n "checking for shl_load in -ldld... " >&6; }
14107 if ${ac_cv_lib_dld_shl_load+:} false; then :
14108   $as_echo_n "(cached) " >&6
14109 else
14110   ac_check_lib_save_LIBS=$LIBS
14111 LIBS="-ldld  $LIBS"
14112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14113 /* end confdefs.h.  */
14114
14115 /* Override any GCC internal prototype to avoid an error.
14116    Use char because int might match the return type of a GCC
14117    builtin and then its argument prototype would still apply.  */
14118 #ifdef __cplusplus
14119 extern "C"
14120 #endif
14121 char shl_load ();
14122 int
14123 main ()
14124 {
14125 return shl_load ();
14126   ;
14127   return 0;
14128 }
14129 _ACEOF
14130 if ac_fn_c_try_link "$LINENO"; then :
14131   ac_cv_lib_dld_shl_load=yes
14132 else
14133   ac_cv_lib_dld_shl_load=no
14134 fi
14135 rm -f core conftest.err conftest.$ac_objext \
14136     conftest$ac_exeext conftest.$ac_ext
14137 LIBS=$ac_check_lib_save_LIBS
14138 fi
14139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14140 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14141 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14142   lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14143 else
14144   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14145 if test "x$ac_cv_func_dlopen" = xyes; then :
14146   lt_cv_dlopen=dlopen
14147 else
14148   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14149 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14150 if ${ac_cv_lib_dl_dlopen+:} false; then :
14151   $as_echo_n "(cached) " >&6
14152 else
14153   ac_check_lib_save_LIBS=$LIBS
14154 LIBS="-ldl  $LIBS"
14155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14156 /* end confdefs.h.  */
14157
14158 /* Override any GCC internal prototype to avoid an error.
14159    Use char because int might match the return type of a GCC
14160    builtin and then its argument prototype would still apply.  */
14161 #ifdef __cplusplus
14162 extern "C"
14163 #endif
14164 char dlopen ();
14165 int
14166 main ()
14167 {
14168 return dlopen ();
14169   ;
14170   return 0;
14171 }
14172 _ACEOF
14173 if ac_fn_c_try_link "$LINENO"; then :
14174   ac_cv_lib_dl_dlopen=yes
14175 else
14176   ac_cv_lib_dl_dlopen=no
14177 fi
14178 rm -f core conftest.err conftest.$ac_objext \
14179     conftest$ac_exeext conftest.$ac_ext
14180 LIBS=$ac_check_lib_save_LIBS
14181 fi
14182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14183 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14184 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14185   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14186 else
14187   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14188 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
14189 if ${ac_cv_lib_svld_dlopen+:} false; then :
14190   $as_echo_n "(cached) " >&6
14191 else
14192   ac_check_lib_save_LIBS=$LIBS
14193 LIBS="-lsvld  $LIBS"
14194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14195 /* end confdefs.h.  */
14196
14197 /* Override any GCC internal prototype to avoid an error.
14198    Use char because int might match the return type of a GCC
14199    builtin and then its argument prototype would still apply.  */
14200 #ifdef __cplusplus
14201 extern "C"
14202 #endif
14203 char dlopen ();
14204 int
14205 main ()
14206 {
14207 return dlopen ();
14208   ;
14209   return 0;
14210 }
14211 _ACEOF
14212 if ac_fn_c_try_link "$LINENO"; then :
14213   ac_cv_lib_svld_dlopen=yes
14214 else
14215   ac_cv_lib_svld_dlopen=no
14216 fi
14217 rm -f core conftest.err conftest.$ac_objext \
14218     conftest$ac_exeext conftest.$ac_ext
14219 LIBS=$ac_check_lib_save_LIBS
14220 fi
14221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14222 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14223 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14224   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14225 else
14226   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14227 $as_echo_n "checking for dld_link in -ldld... " >&6; }
14228 if ${ac_cv_lib_dld_dld_link+:} false; then :
14229   $as_echo_n "(cached) " >&6
14230 else
14231   ac_check_lib_save_LIBS=$LIBS
14232 LIBS="-ldld  $LIBS"
14233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14234 /* end confdefs.h.  */
14235
14236 /* Override any GCC internal prototype to avoid an error.
14237    Use char because int might match the return type of a GCC
14238    builtin and then its argument prototype would still apply.  */
14239 #ifdef __cplusplus
14240 extern "C"
14241 #endif
14242 char dld_link ();
14243 int
14244 main ()
14245 {
14246 return dld_link ();
14247   ;
14248   return 0;
14249 }
14250 _ACEOF
14251 if ac_fn_c_try_link "$LINENO"; then :
14252   ac_cv_lib_dld_dld_link=yes
14253 else
14254   ac_cv_lib_dld_dld_link=no
14255 fi
14256 rm -f core conftest.err conftest.$ac_objext \
14257     conftest$ac_exeext conftest.$ac_ext
14258 LIBS=$ac_check_lib_save_LIBS
14259 fi
14260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14261 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14262 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14263   lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14264 fi
14265
14266
14267 fi
14268
14269
14270 fi
14271
14272
14273 fi
14274
14275
14276 fi
14277
14278
14279 fi
14280
14281     ;;
14282   esac
14283
14284   if test no = "$lt_cv_dlopen"; then
14285     enable_dlopen=no
14286   else
14287     enable_dlopen=yes
14288   fi
14289
14290   case $lt_cv_dlopen in
14291   dlopen)
14292     save_CPPFLAGS=$CPPFLAGS
14293     test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
14294
14295     save_LDFLAGS=$LDFLAGS
14296     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
14297
14298     save_LIBS=$LIBS
14299     LIBS="$lt_cv_dlopen_libs $LIBS"
14300
14301     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
14302 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
14303 if ${lt_cv_dlopen_self+:} false; then :
14304   $as_echo_n "(cached) " >&6
14305 else
14306           if test yes = "$cross_compiling"; then :
14307   lt_cv_dlopen_self=cross
14308 else
14309   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14310   lt_status=$lt_dlunknown
14311   cat > conftest.$ac_ext <<_LT_EOF
14312 #line $LINENO "configure"
14313 #include "confdefs.h"
14314
14315 #if HAVE_DLFCN_H
14316 #include <dlfcn.h>
14317 #endif
14318
14319 #include <stdio.h>
14320
14321 #ifdef RTLD_GLOBAL
14322 #  define LT_DLGLOBAL           RTLD_GLOBAL
14323 #else
14324 #  ifdef DL_GLOBAL
14325 #    define LT_DLGLOBAL         DL_GLOBAL
14326 #  else
14327 #    define LT_DLGLOBAL         0
14328 #  endif
14329 #endif
14330
14331 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14332    find out it does not work in some platform. */
14333 #ifndef LT_DLLAZY_OR_NOW
14334 #  ifdef RTLD_LAZY
14335 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14336 #  else
14337 #    ifdef DL_LAZY
14338 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14339 #    else
14340 #      ifdef RTLD_NOW
14341 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14342 #      else
14343 #        ifdef DL_NOW
14344 #          define LT_DLLAZY_OR_NOW      DL_NOW
14345 #        else
14346 #          define LT_DLLAZY_OR_NOW      0
14347 #        endif
14348 #      endif
14349 #    endif
14350 #  endif
14351 #endif
14352
14353 /* When -fvisibility=hidden is used, assume the code has been annotated
14354    correspondingly for the symbols needed.  */
14355 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14356 int fnord () __attribute__((visibility("default")));
14357 #endif
14358
14359 int fnord () { return 42; }
14360 int main ()
14361 {
14362   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14363   int status = $lt_dlunknown;
14364
14365   if (self)
14366     {
14367       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14368       else
14369         {
14370           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14371           else puts (dlerror ());
14372         }
14373       /* dlclose (self); */
14374     }
14375   else
14376     puts (dlerror ());
14377
14378   return status;
14379 }
14380 _LT_EOF
14381   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14382   (eval $ac_link) 2>&5
14383   ac_status=$?
14384   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14385   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14386     (./conftest; exit; ) >&5 2>/dev/null
14387     lt_status=$?
14388     case x$lt_status in
14389       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
14390       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
14391       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
14392     esac
14393   else :
14394     # compilation failed
14395     lt_cv_dlopen_self=no
14396   fi
14397 fi
14398 rm -fr conftest*
14399
14400
14401 fi
14402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
14403 $as_echo "$lt_cv_dlopen_self" >&6; }
14404
14405     if test yes = "$lt_cv_dlopen_self"; then
14406       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
14407       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
14408 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
14409 if ${lt_cv_dlopen_self_static+:} false; then :
14410   $as_echo_n "(cached) " >&6
14411 else
14412           if test yes = "$cross_compiling"; then :
14413   lt_cv_dlopen_self_static=cross
14414 else
14415   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14416   lt_status=$lt_dlunknown
14417   cat > conftest.$ac_ext <<_LT_EOF
14418 #line $LINENO "configure"
14419 #include "confdefs.h"
14420
14421 #if HAVE_DLFCN_H
14422 #include <dlfcn.h>
14423 #endif
14424
14425 #include <stdio.h>
14426
14427 #ifdef RTLD_GLOBAL
14428 #  define LT_DLGLOBAL           RTLD_GLOBAL
14429 #else
14430 #  ifdef DL_GLOBAL
14431 #    define LT_DLGLOBAL         DL_GLOBAL
14432 #  else
14433 #    define LT_DLGLOBAL         0
14434 #  endif
14435 #endif
14436
14437 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14438    find out it does not work in some platform. */
14439 #ifndef LT_DLLAZY_OR_NOW
14440 #  ifdef RTLD_LAZY
14441 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14442 #  else
14443 #    ifdef DL_LAZY
14444 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14445 #    else
14446 #      ifdef RTLD_NOW
14447 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14448 #      else
14449 #        ifdef DL_NOW
14450 #          define LT_DLLAZY_OR_NOW      DL_NOW
14451 #        else
14452 #          define LT_DLLAZY_OR_NOW      0
14453 #        endif
14454 #      endif
14455 #    endif
14456 #  endif
14457 #endif
14458
14459 /* When -fvisibility=hidden is used, assume the code has been annotated
14460    correspondingly for the symbols needed.  */
14461 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14462 int fnord () __attribute__((visibility("default")));
14463 #endif
14464
14465 int fnord () { return 42; }
14466 int main ()
14467 {
14468   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14469   int status = $lt_dlunknown;
14470
14471   if (self)
14472     {
14473       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14474       else
14475         {
14476           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14477           else puts (dlerror ());
14478         }
14479       /* dlclose (self); */
14480     }
14481   else
14482     puts (dlerror ());
14483
14484   return status;
14485 }
14486 _LT_EOF
14487   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14488   (eval $ac_link) 2>&5
14489   ac_status=$?
14490   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14491   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14492     (./conftest; exit; ) >&5 2>/dev/null
14493     lt_status=$?
14494     case x$lt_status in
14495       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
14496       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
14497       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
14498     esac
14499   else :
14500     # compilation failed
14501     lt_cv_dlopen_self_static=no
14502   fi
14503 fi
14504 rm -fr conftest*
14505
14506
14507 fi
14508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
14509 $as_echo "$lt_cv_dlopen_self_static" >&6; }
14510     fi
14511
14512     CPPFLAGS=$save_CPPFLAGS
14513     LDFLAGS=$save_LDFLAGS
14514     LIBS=$save_LIBS
14515     ;;
14516   esac
14517
14518   case $lt_cv_dlopen_self in
14519   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
14520   *) enable_dlopen_self=unknown ;;
14521   esac
14522
14523   case $lt_cv_dlopen_self_static in
14524   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
14525   *) enable_dlopen_self_static=unknown ;;
14526   esac
14527 fi
14528
14529
14530
14531
14532
14533
14534
14535
14536
14537
14538
14539
14540
14541
14542
14543
14544
14545 striplib=
14546 old_striplib=
14547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
14548 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
14549 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
14550   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
14551   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
14552   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14553 $as_echo "yes" >&6; }
14554 else
14555 # FIXME - insert some real tests, host_os isn't really good enough
14556   case $host_os in
14557   darwin*)
14558     if test -n "$STRIP"; then
14559       striplib="$STRIP -x"
14560       old_striplib="$STRIP -S"
14561       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14562 $as_echo "yes" >&6; }
14563     else
14564       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14565 $as_echo "no" >&6; }
14566     fi
14567     ;;
14568   *)
14569     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14570 $as_echo "no" >&6; }
14571     ;;
14572   esac
14573 fi
14574
14575
14576
14577
14578
14579
14580
14581
14582
14583
14584
14585
14586   # Report what library types will actually be built
14587   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
14588 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
14589   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
14590 $as_echo "$can_build_shared" >&6; }
14591
14592   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
14593 $as_echo_n "checking whether to build shared libraries... " >&6; }
14594   test no = "$can_build_shared" && enable_shared=no
14595
14596   # On AIX, shared libraries and static libraries use the same namespace, and
14597   # are all built from PIC.
14598   case $host_os in
14599   aix3*)
14600     test yes = "$enable_shared" && enable_static=no
14601     if test -n "$RANLIB"; then
14602       archive_cmds="$archive_cmds~\$RANLIB \$lib"
14603       postinstall_cmds='$RANLIB $lib'
14604     fi
14605     ;;
14606
14607   aix[4-9]*)
14608     if test ia64 != "$host_cpu"; then
14609       case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
14610       yes,aix,yes) ;;                   # shared object as lib.so file only
14611       yes,svr4,*) ;;                    # shared object as lib.so archive member only
14612       yes,*) enable_static=no ;;        # shared object in lib.a archive as well
14613       esac
14614     fi
14615     ;;
14616   esac
14617   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
14618 $as_echo "$enable_shared" >&6; }
14619
14620   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
14621 $as_echo_n "checking whether to build static libraries... " >&6; }
14622   # Make sure either enable_shared or enable_static is yes.
14623   test yes = "$enable_shared" || enable_static=yes
14624   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
14625 $as_echo "$enable_static" >&6; }
14626
14627
14628
14629
14630 fi
14631 ac_ext=c
14632 ac_cpp='$CPP $CPPFLAGS'
14633 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14634 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14635 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14636
14637 CC=$lt_save_CC
14638
14639
14640
14641
14642
14643
14644
14645
14646
14647
14648
14649
14650
14651
14652
14653         ac_config_commands="$ac_config_commands libtool"
14654
14655
14656
14657
14658 # Only expand once:
14659
14660
14661
14662
14663 # pkg-config is only needed for these options, do not require it otherwise
14664 if test "$enable_systemd" = "yes" -o "$with_pyunbound" = "yes" -o "$with_pythonmod" = "yes"; then
14665
14666
14667
14668
14669
14670
14671
14672 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
14673         if test -n "$ac_tool_prefix"; then
14674   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
14675 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
14676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14677 $as_echo_n "checking for $ac_word... " >&6; }
14678 if ${ac_cv_path_PKG_CONFIG+:} false; then :
14679   $as_echo_n "(cached) " >&6
14680 else
14681   case $PKG_CONFIG in
14682   [\\/]* | ?:[\\/]*)
14683   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
14684   ;;
14685   *)
14686   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14687 for as_dir in $PATH
14688 do
14689   IFS=$as_save_IFS
14690   test -z "$as_dir" && as_dir=.
14691     for ac_exec_ext in '' $ac_executable_extensions; do
14692   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14693     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14694     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14695     break 2
14696   fi
14697 done
14698   done
14699 IFS=$as_save_IFS
14700
14701   ;;
14702 esac
14703 fi
14704 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
14705 if test -n "$PKG_CONFIG"; then
14706   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
14707 $as_echo "$PKG_CONFIG" >&6; }
14708 else
14709   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14710 $as_echo "no" >&6; }
14711 fi
14712
14713
14714 fi
14715 if test -z "$ac_cv_path_PKG_CONFIG"; then
14716   ac_pt_PKG_CONFIG=$PKG_CONFIG
14717   # Extract the first word of "pkg-config", so it can be a program name with args.
14718 set dummy pkg-config; ac_word=$2
14719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14720 $as_echo_n "checking for $ac_word... " >&6; }
14721 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
14722   $as_echo_n "(cached) " >&6
14723 else
14724   case $ac_pt_PKG_CONFIG in
14725   [\\/]* | ?:[\\/]*)
14726   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
14727   ;;
14728   *)
14729   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14730 for as_dir in $PATH
14731 do
14732   IFS=$as_save_IFS
14733   test -z "$as_dir" && as_dir=.
14734     for ac_exec_ext in '' $ac_executable_extensions; do
14735   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14736     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14737     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14738     break 2
14739   fi
14740 done
14741   done
14742 IFS=$as_save_IFS
14743
14744   ;;
14745 esac
14746 fi
14747 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
14748 if test -n "$ac_pt_PKG_CONFIG"; then
14749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
14750 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
14751 else
14752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14753 $as_echo "no" >&6; }
14754 fi
14755
14756   if test "x$ac_pt_PKG_CONFIG" = x; then
14757     PKG_CONFIG=""
14758   else
14759     case $cross_compiling:$ac_tool_warned in
14760 yes:)
14761 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
14762 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
14763 ac_tool_warned=yes ;;
14764 esac
14765     PKG_CONFIG=$ac_pt_PKG_CONFIG
14766   fi
14767 else
14768   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
14769 fi
14770
14771 fi
14772 if test -n "$PKG_CONFIG"; then
14773         _pkg_min_version=0.9.0
14774         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
14775 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
14776         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
14777                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14778 $as_echo "yes" >&6; }
14779         else
14780                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14781 $as_echo "no" >&6; }
14782                 PKG_CONFIG=""
14783         fi
14784 fi
14785 fi
14786
14787 # Checks for header files.
14788 for ac_header in stdarg.h stdbool.h netinet/in.h netinet/tcp.h sys/param.h sys/select.h sys/socket.h sys/un.h sys/uio.h sys/resource.h arpa/inet.h syslog.h netdb.h sys/wait.h pwd.h glob.h grp.h login_cap.h winsock2.h ws2tcpip.h endian.h sys/endian.h libkern/OSByteOrder.h sys/ipc.h sys/shm.h ifaddrs.h poll.h
14789 do :
14790   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14791 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
14792 "
14793 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14794   cat >>confdefs.h <<_ACEOF
14795 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14796 _ACEOF
14797
14798 fi
14799
14800 done
14801
14802 # net/if.h portability for Darwin see:
14803 # https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Header-Portability.html
14804 for ac_header in net/if.h
14805 do :
14806   ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
14807 #include <stdio.h>
14808 #ifdef STDC_HEADERS
14809 # include <stdlib.h>
14810 # include <stddef.h>
14811 #else
14812 # ifdef HAVE_STDLIB_H
14813 #  include <stdlib.h>
14814 # endif
14815 #endif
14816 #ifdef HAVE_SYS_SOCKET_H
14817 # include <sys/socket.h>
14818 #endif
14819
14820 "
14821 if test "x$ac_cv_header_net_if_h" = xyes; then :
14822   cat >>confdefs.h <<_ACEOF
14823 #define HAVE_NET_IF_H 1
14824 _ACEOF
14825
14826 fi
14827
14828 done
14829
14830
14831 # Check for Apple header. This uncovers TARGET_OS_IPHONE, TARGET_OS_TV or TARGET_OS_WATCH
14832 for ac_header in TargetConditionals.h
14833 do :
14834   ac_fn_c_check_header_compile "$LINENO" "TargetConditionals.h" "ac_cv_header_TargetConditionals_h" "$ac_includes_default
14835 "
14836 if test "x$ac_cv_header_TargetConditionals_h" = xyes; then :
14837   cat >>confdefs.h <<_ACEOF
14838 #define HAVE_TARGETCONDITIONALS_H 1
14839 _ACEOF
14840
14841 fi
14842
14843 done
14844
14845 for ac_header in netioapi.h
14846 do :
14847   ac_fn_c_check_header_compile "$LINENO" "netioapi.h" "ac_cv_header_netioapi_h" "$ac_includes_default
14848 #if HAVE_SYS_PARAM_H
14849 #include <sys/param.h>
14850 #endif
14851
14852 #ifdef HAVE_SYS_SOCKET_H
14853 #include <sys/socket.h>
14854 #endif
14855
14856 #ifdef HAVE_SYS_UIO_H
14857 #include <sys/uio.h>
14858 #endif
14859
14860 #ifdef HAVE_NETINET_IN_H
14861 #include <netinet/in.h>
14862 #endif
14863
14864 #ifdef HAVE_NETINET_TCP_H
14865 #include <netinet/tcp.h>
14866 #endif
14867
14868 #ifdef HAVE_ARPA_INET_H
14869 #include <arpa/inet.h>
14870 #endif
14871
14872 #ifdef HAVE_WINSOCK2_H
14873 #include <winsock2.h>
14874 #endif
14875
14876 #ifdef HAVE_WS2TCPIP_H
14877 #include <ws2tcpip.h>
14878 #endif
14879
14880 "
14881 if test "x$ac_cv_header_netioapi_h" = xyes; then :
14882   cat >>confdefs.h <<_ACEOF
14883 #define HAVE_NETIOAPI_H 1
14884 _ACEOF
14885
14886 fi
14887
14888 done
14889
14890
14891 # Check for Linux timestamping headers
14892 for ac_header in linux/net_tstamp.h
14893 do :
14894   ac_fn_c_check_header_compile "$LINENO" "linux/net_tstamp.h" "ac_cv_header_linux_net_tstamp_h" "$ac_includes_default
14895 "
14896 if test "x$ac_cv_header_linux_net_tstamp_h" = xyes; then :
14897   cat >>confdefs.h <<_ACEOF
14898 #define HAVE_LINUX_NET_TSTAMP_H 1
14899 _ACEOF
14900
14901 fi
14902
14903 done
14904
14905
14906 # check for types.
14907 # Using own tests for int64* because autoconf builtin only give 32bit.
14908 ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
14909 if test "x$ac_cv_type_int8_t" = xyes; then :
14910
14911 else
14912
14913 cat >>confdefs.h <<_ACEOF
14914 #define int8_t signed char
14915 _ACEOF
14916
14917 fi
14918
14919 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
14920 if test "x$ac_cv_type_int16_t" = xyes; then :
14921
14922 else
14923
14924 cat >>confdefs.h <<_ACEOF
14925 #define int16_t short
14926 _ACEOF
14927
14928 fi
14929
14930 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
14931 if test "x$ac_cv_type_int32_t" = xyes; then :
14932
14933 else
14934
14935 cat >>confdefs.h <<_ACEOF
14936 #define int32_t int
14937 _ACEOF
14938
14939 fi
14940
14941 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
14942 if test "x$ac_cv_type_int64_t" = xyes; then :
14943
14944 else
14945
14946 cat >>confdefs.h <<_ACEOF
14947 #define int64_t long long
14948 _ACEOF
14949
14950 fi
14951
14952 ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
14953 if test "x$ac_cv_type_uint8_t" = xyes; then :
14954
14955 else
14956
14957 cat >>confdefs.h <<_ACEOF
14958 #define uint8_t unsigned char
14959 _ACEOF
14960
14961 fi
14962
14963 ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
14964 if test "x$ac_cv_type_uint16_t" = xyes; then :
14965
14966 else
14967
14968 cat >>confdefs.h <<_ACEOF
14969 #define uint16_t unsigned short
14970 _ACEOF
14971
14972 fi
14973
14974 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
14975 if test "x$ac_cv_type_uint32_t" = xyes; then :
14976
14977 else
14978
14979 cat >>confdefs.h <<_ACEOF
14980 #define uint32_t unsigned int
14981 _ACEOF
14982
14983 fi
14984
14985 ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
14986 if test "x$ac_cv_type_uint64_t" = xyes; then :
14987
14988 else
14989
14990 cat >>confdefs.h <<_ACEOF
14991 #define uint64_t unsigned long long
14992 _ACEOF
14993
14994 fi
14995
14996 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
14997 if test "x$ac_cv_type_size_t" = xyes; then :
14998
14999 else
15000
15001 cat >>confdefs.h <<_ACEOF
15002 #define size_t unsigned int
15003 _ACEOF
15004
15005 fi
15006
15007 ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
15008 if test "x$ac_cv_type_ssize_t" = xyes; then :
15009
15010 else
15011
15012 cat >>confdefs.h <<_ACEOF
15013 #define ssize_t int
15014 _ACEOF
15015
15016 fi
15017
15018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
15019 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
15020 if ${ac_cv_type_uid_t+:} false; then :
15021   $as_echo_n "(cached) " >&6
15022 else
15023   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15024 /* end confdefs.h.  */
15025 #include <sys/types.h>
15026
15027 _ACEOF
15028 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15029   $EGREP "uid_t" >/dev/null 2>&1; then :
15030   ac_cv_type_uid_t=yes
15031 else
15032   ac_cv_type_uid_t=no
15033 fi
15034 rm -f conftest*
15035
15036 fi
15037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
15038 $as_echo "$ac_cv_type_uid_t" >&6; }
15039 if test $ac_cv_type_uid_t = no; then
15040
15041 $as_echo "#define uid_t int" >>confdefs.h
15042
15043
15044 $as_echo "#define gid_t int" >>confdefs.h
15045
15046 fi
15047
15048 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15049 if test "x$ac_cv_type_pid_t" = xyes; then :
15050
15051 else
15052
15053 cat >>confdefs.h <<_ACEOF
15054 #define pid_t int
15055 _ACEOF
15056
15057 fi
15058
15059 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
15060 if test "x$ac_cv_type_off_t" = xyes; then :
15061
15062 else
15063
15064 cat >>confdefs.h <<_ACEOF
15065 #define off_t long int
15066 _ACEOF
15067
15068 fi
15069
15070 ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "
15071 $ac_includes_default
15072 #ifdef HAVE_WINSOCK2_H
15073 #  include <winsock2.h>
15074 #endif
15075
15076 "
15077 if test "x$ac_cv_type_u_char" = xyes; then :
15078
15079 else
15080
15081 $as_echo "#define u_char unsigned char" >>confdefs.h
15082
15083 fi
15084
15085 ac_fn_c_check_type "$LINENO" "rlim_t" "ac_cv_type_rlim_t" "
15086 $ac_includes_default
15087 #ifdef HAVE_SYS_RESOURCE_H
15088 #  include <sys/resource.h>
15089 #endif
15090
15091 "
15092 if test "x$ac_cv_type_rlim_t" = xyes; then :
15093
15094 else
15095
15096 $as_echo "#define rlim_t unsigned long" >>confdefs.h
15097
15098 fi
15099
15100
15101 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
15102 $ac_includes_default
15103 #ifdef HAVE_SYS_SOCKET_H
15104 #  include <sys/socket.h>
15105 #endif
15106 #ifdef HAVE_WS2TCPIP_H
15107 #  include <ws2tcpip.h>
15108 #endif
15109
15110 "
15111 if test "x$ac_cv_type_socklen_t" = xyes; then :
15112
15113 else
15114
15115 $as_echo "#define socklen_t int" >>confdefs.h
15116
15117 fi
15118
15119  ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
15120 $ac_includes_default
15121 #ifdef HAVE_SYS_TYPES_H
15122 # include <sys/types.h>
15123 #endif
15124 #ifdef HAVE_NETINET_IN_H
15125 # include <netinet/in.h>
15126 #endif
15127
15128 "
15129 if test "x$ac_cv_type_in_addr_t" = xyes; then :
15130
15131 else
15132
15133 $as_echo "#define in_addr_t uint32_t" >>confdefs.h
15134
15135 fi
15136
15137  ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "
15138 $ac_includes_default
15139 #ifdef HAVE_SYS_TYPES_H
15140 # include <sys/types.h>
15141 #endif
15142 #ifdef HAVE_NETINET_IN_H
15143 # include <netinet/in.h>
15144 #endif
15145
15146 "
15147 if test "x$ac_cv_type_in_port_t" = xyes; then :
15148
15149 else
15150
15151 $as_echo "#define in_port_t uint16_t" >>confdefs.h
15152
15153 fi
15154
15155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memcmp compares unsigned" >&5
15156 $as_echo_n "checking if memcmp compares unsigned... " >&6; }
15157 if test "$cross_compiling" = yes; then :
15158    { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile no" >&5
15159 $as_echo "cross-compile no" >&6; }
15160
15161 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15162
15163   case " $LIBOBJS " in
15164   *" memcmp.$ac_objext "* ) ;;
15165   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15166  ;;
15167 esac
15168
15169
15170 else
15171   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15172 /* end confdefs.h.  */
15173
15174 #include <stdio.h>
15175 #include <stdlib.h>
15176 #include <string.h>
15177 int main(void)
15178 {
15179         char a = 255, b = 0;
15180         if(memcmp(&a, &b, 1) < 0)
15181                 return 1;
15182         return 0;
15183 }
15184
15185 _ACEOF
15186 if ac_fn_c_try_run "$LINENO"; then :
15187   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15188 $as_echo "yes" >&6; }
15189 else
15190    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15191 $as_echo "no" >&6; }
15192
15193 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15194
15195   case " $LIBOBJS " in
15196   *" memcmp.$ac_objext "* ) ;;
15197   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15198  ;;
15199 esac
15200
15201
15202 fi
15203 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15204   conftest.$ac_objext conftest.beam conftest.$ac_ext
15205 fi
15206
15207
15208 # The cast to long int works around a bug in the HP C Compiler
15209 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15210 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15211 # This bug is HP SR number 8606223364.
15212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
15213 $as_echo_n "checking size of time_t... " >&6; }
15214 if ${ac_cv_sizeof_time_t+:} false; then :
15215   $as_echo_n "(cached) " >&6
15216 else
15217   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "
15218 $ac_includes_default
15219 #ifdef TIME_WITH_SYS_TIME
15220 # include <sys/time.h>
15221 # include <time.h>
15222 #else
15223 # ifdef HAVE_SYS_TIME_H
15224 #  include <sys/time.h>
15225 # else
15226 #  include <time.h>
15227 # endif
15228 #endif
15229
15230 "; then :
15231
15232 else
15233   if test "$ac_cv_type_time_t" = yes; then
15234      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15235 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15236 as_fn_error 77 "cannot compute sizeof (time_t)
15237 See \`config.log' for more details" "$LINENO" 5; }
15238    else
15239      ac_cv_sizeof_time_t=0
15240    fi
15241 fi
15242
15243 fi
15244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
15245 $as_echo "$ac_cv_sizeof_time_t" >&6; }
15246
15247
15248
15249 cat >>confdefs.h <<_ACEOF
15250 #define SIZEOF_TIME_T $ac_cv_sizeof_time_t
15251 _ACEOF
15252
15253
15254 # The cast to long int works around a bug in the HP C Compiler
15255 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15256 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15257 # This bug is HP SR number 8606223364.
15258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
15259 $as_echo_n "checking size of size_t... " >&6; }
15260 if ${ac_cv_sizeof_size_t+:} false; then :
15261   $as_echo_n "(cached) " >&6
15262 else
15263   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t"        "$ac_includes_default"; then :
15264
15265 else
15266   if test "$ac_cv_type_size_t" = yes; then
15267      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15268 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15269 as_fn_error 77 "cannot compute sizeof (size_t)
15270 See \`config.log' for more details" "$LINENO" 5; }
15271    else
15272      ac_cv_sizeof_size_t=0
15273    fi
15274 fi
15275
15276 fi
15277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
15278 $as_echo "$ac_cv_sizeof_size_t" >&6; }
15279
15280
15281
15282 cat >>confdefs.h <<_ACEOF
15283 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
15284 _ACEOF
15285
15286
15287
15288 # add option to disable the evil rpath
15289
15290 # Check whether --enable-rpath was given.
15291 if test "${enable_rpath+set}" = set; then :
15292   enableval=$enable_rpath; enable_rpath=$enableval
15293 else
15294   enable_rpath=yes
15295 fi
15296
15297 if test "x$enable_rpath" = xno; then
15298                 ac_config_commands="$ac_config_commands disable-rpath"
15299
15300 fi
15301
15302
15303
15304 # check to see if libraries are needed for these functions.
15305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
15306 $as_echo_n "checking for library containing inet_pton... " >&6; }
15307 if ${ac_cv_search_inet_pton+:} false; then :
15308   $as_echo_n "(cached) " >&6
15309 else
15310   ac_func_search_save_LIBS=$LIBS
15311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15312 /* end confdefs.h.  */
15313
15314 /* Override any GCC internal prototype to avoid an error.
15315    Use char because int might match the return type of a GCC
15316    builtin and then its argument prototype would still apply.  */
15317 #ifdef __cplusplus
15318 extern "C"
15319 #endif
15320 char inet_pton ();
15321 int
15322 main ()
15323 {
15324 return inet_pton ();
15325   ;
15326   return 0;
15327 }
15328 _ACEOF
15329 for ac_lib in '' nsl; do
15330   if test -z "$ac_lib"; then
15331     ac_res="none required"
15332   else
15333     ac_res=-l$ac_lib
15334     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15335   fi
15336   if ac_fn_c_try_link "$LINENO"; then :
15337   ac_cv_search_inet_pton=$ac_res
15338 fi
15339 rm -f core conftest.err conftest.$ac_objext \
15340     conftest$ac_exeext
15341   if ${ac_cv_search_inet_pton+:} false; then :
15342   break
15343 fi
15344 done
15345 if ${ac_cv_search_inet_pton+:} false; then :
15346
15347 else
15348   ac_cv_search_inet_pton=no
15349 fi
15350 rm conftest.$ac_ext
15351 LIBS=$ac_func_search_save_LIBS
15352 fi
15353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
15354 $as_echo "$ac_cv_search_inet_pton" >&6; }
15355 ac_res=$ac_cv_search_inet_pton
15356 if test "$ac_res" != no; then :
15357   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15358
15359 fi
15360
15361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
15362 $as_echo_n "checking for library containing socket... " >&6; }
15363 if ${ac_cv_search_socket+:} false; then :
15364   $as_echo_n "(cached) " >&6
15365 else
15366   ac_func_search_save_LIBS=$LIBS
15367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15368 /* end confdefs.h.  */
15369
15370 /* Override any GCC internal prototype to avoid an error.
15371    Use char because int might match the return type of a GCC
15372    builtin and then its argument prototype would still apply.  */
15373 #ifdef __cplusplus
15374 extern "C"
15375 #endif
15376 char socket ();
15377 int
15378 main ()
15379 {
15380 return socket ();
15381   ;
15382   return 0;
15383 }
15384 _ACEOF
15385 for ac_lib in '' socket; do
15386   if test -z "$ac_lib"; then
15387     ac_res="none required"
15388   else
15389     ac_res=-l$ac_lib
15390     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15391   fi
15392   if ac_fn_c_try_link "$LINENO"; then :
15393   ac_cv_search_socket=$ac_res
15394 fi
15395 rm -f core conftest.err conftest.$ac_objext \
15396     conftest$ac_exeext
15397   if ${ac_cv_search_socket+:} false; then :
15398   break
15399 fi
15400 done
15401 if ${ac_cv_search_socket+:} false; then :
15402
15403 else
15404   ac_cv_search_socket=no
15405 fi
15406 rm conftest.$ac_ext
15407 LIBS=$ac_func_search_save_LIBS
15408 fi
15409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
15410 $as_echo "$ac_cv_search_socket" >&6; }
15411 ac_res=$ac_cv_search_socket
15412 if test "$ac_res" != no; then :
15413   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15414
15415 fi
15416
15417
15418 # check whether strptime also works
15419
15420 # check some functions of the OS before linking libs (while still runnable).
15421 for ac_header in unistd.h
15422 do :
15423   ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
15424 if test "x$ac_cv_header_unistd_h" = xyes; then :
15425   cat >>confdefs.h <<_ACEOF
15426 #define HAVE_UNISTD_H 1
15427 _ACEOF
15428
15429 fi
15430
15431 done
15432
15433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
15434 $as_echo_n "checking for working chown... " >&6; }
15435 if ${ac_cv_func_chown_works+:} false; then :
15436   $as_echo_n "(cached) " >&6
15437 else
15438   if test "$cross_compiling" = yes; then :
15439   ac_cv_func_chown_works=no
15440 else
15441   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15442 /* end confdefs.h.  */
15443 $ac_includes_default
15444 #include <fcntl.h>
15445
15446 int
15447 main ()
15448 {
15449   char *f = "conftest.chown";
15450   struct stat before, after;
15451
15452   if (creat (f, 0600) < 0)
15453     return 1;
15454   if (stat (f, &before) < 0)
15455     return 1;
15456   if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
15457     return 1;
15458   if (stat (f, &after) < 0)
15459     return 1;
15460   return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
15461
15462   ;
15463   return 0;
15464 }
15465 _ACEOF
15466 if ac_fn_c_try_run "$LINENO"; then :
15467   ac_cv_func_chown_works=yes
15468 else
15469   ac_cv_func_chown_works=no
15470 fi
15471 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15472   conftest.$ac_objext conftest.beam conftest.$ac_ext
15473 fi
15474
15475 rm -f conftest.chown
15476
15477 fi
15478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
15479 $as_echo "$ac_cv_func_chown_works" >&6; }
15480 if test $ac_cv_func_chown_works = yes; then
15481
15482 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
15483
15484 fi
15485
15486 for ac_header in vfork.h
15487 do :
15488   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15489 if test "x$ac_cv_header_vfork_h" = xyes; then :
15490   cat >>confdefs.h <<_ACEOF
15491 #define HAVE_VFORK_H 1
15492 _ACEOF
15493
15494 fi
15495
15496 done
15497
15498 for ac_func in fork vfork
15499 do :
15500   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15501 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15502 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15503   cat >>confdefs.h <<_ACEOF
15504 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15505 _ACEOF
15506
15507 fi
15508 done
15509
15510 if test "x$ac_cv_func_fork" = xyes; then
15511   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15512 $as_echo_n "checking for working fork... " >&6; }
15513 if ${ac_cv_func_fork_works+:} false; then :
15514   $as_echo_n "(cached) " >&6
15515 else
15516   if test "$cross_compiling" = yes; then :
15517   ac_cv_func_fork_works=cross
15518 else
15519   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15520 /* end confdefs.h.  */
15521 $ac_includes_default
15522 int
15523 main ()
15524 {
15525
15526           /* By Ruediger Kuhlmann. */
15527           return fork () < 0;
15528
15529   ;
15530   return 0;
15531 }
15532 _ACEOF
15533 if ac_fn_c_try_run "$LINENO"; then :
15534   ac_cv_func_fork_works=yes
15535 else
15536   ac_cv_func_fork_works=no
15537 fi
15538 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15539   conftest.$ac_objext conftest.beam conftest.$ac_ext
15540 fi
15541
15542 fi
15543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15544 $as_echo "$ac_cv_func_fork_works" >&6; }
15545
15546 else
15547   ac_cv_func_fork_works=$ac_cv_func_fork
15548 fi
15549 if test "x$ac_cv_func_fork_works" = xcross; then
15550   case $host in
15551     *-*-amigaos* | *-*-msdosdjgpp*)
15552       # Override, as these systems have only a dummy fork() stub
15553       ac_cv_func_fork_works=no
15554       ;;
15555     *)
15556       ac_cv_func_fork_works=yes
15557       ;;
15558   esac
15559   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15560 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15561 fi
15562 ac_cv_func_vfork_works=$ac_cv_func_vfork
15563 if test "x$ac_cv_func_vfork" = xyes; then
15564   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15565 $as_echo_n "checking for working vfork... " >&6; }
15566 if ${ac_cv_func_vfork_works+:} false; then :
15567   $as_echo_n "(cached) " >&6
15568 else
15569   if test "$cross_compiling" = yes; then :
15570   ac_cv_func_vfork_works=cross
15571 else
15572   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15573 /* end confdefs.h.  */
15574 /* Thanks to Paul Eggert for this test.  */
15575 $ac_includes_default
15576 #include <sys/wait.h>
15577 #ifdef HAVE_VFORK_H
15578 # include <vfork.h>
15579 #endif
15580 /* On some sparc systems, changes by the child to local and incoming
15581    argument registers are propagated back to the parent.  The compiler
15582    is told about this with #include <vfork.h>, but some compilers
15583    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
15584    static variable whose address is put into a register that is
15585    clobbered by the vfork.  */
15586 static void
15587 #ifdef __cplusplus
15588 sparc_address_test (int arg)
15589 # else
15590 sparc_address_test (arg) int arg;
15591 #endif
15592 {
15593   static pid_t child;
15594   if (!child) {
15595     child = vfork ();
15596     if (child < 0) {
15597       perror ("vfork");
15598       _exit(2);
15599     }
15600     if (!child) {
15601       arg = getpid();
15602       write(-1, "", 0);
15603       _exit (arg);
15604     }
15605   }
15606 }
15607
15608 int
15609 main ()
15610 {
15611   pid_t parent = getpid ();
15612   pid_t child;
15613
15614   sparc_address_test (0);
15615
15616   child = vfork ();
15617
15618   if (child == 0) {
15619     /* Here is another test for sparc vfork register problems.  This
15620        test uses lots of local variables, at least as many local
15621        variables as main has allocated so far including compiler
15622        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
15623        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
15624        reuse the register of parent for one of the local variables,
15625        since it will think that parent can't possibly be used any more
15626        in this routine.  Assigning to the local variable will thus
15627        munge parent in the parent process.  */
15628     pid_t
15629       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15630       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15631     /* Convince the compiler that p..p7 are live; otherwise, it might
15632        use the same hardware register for all 8 local variables.  */
15633     if (p != p1 || p != p2 || p != p3 || p != p4
15634         || p != p5 || p != p6 || p != p7)
15635       _exit(1);
15636
15637     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15638        from child file descriptors.  If the child closes a descriptor
15639        before it execs or exits, this munges the parent's descriptor
15640        as well.  Test for this by closing stdout in the child.  */
15641     _exit(close(fileno(stdout)) != 0);
15642   } else {
15643     int status;
15644     struct stat st;
15645
15646     while (wait(&status) != child)
15647       ;
15648     return (
15649          /* Was there some problem with vforking?  */
15650          child < 0
15651
15652          /* Did the child fail?  (This shouldn't happen.)  */
15653          || status
15654
15655          /* Did the vfork/compiler bug occur?  */
15656          || parent != getpid()
15657
15658          /* Did the file descriptor bug occur?  */
15659          || fstat(fileno(stdout), &st) != 0
15660          );
15661   }
15662 }
15663 _ACEOF
15664 if ac_fn_c_try_run "$LINENO"; then :
15665   ac_cv_func_vfork_works=yes
15666 else
15667   ac_cv_func_vfork_works=no
15668 fi
15669 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15670   conftest.$ac_objext conftest.beam conftest.$ac_ext
15671 fi
15672
15673 fi
15674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15675 $as_echo "$ac_cv_func_vfork_works" >&6; }
15676
15677 fi;
15678 if test "x$ac_cv_func_fork_works" = xcross; then
15679   ac_cv_func_vfork_works=$ac_cv_func_vfork
15680   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15681 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15682 fi
15683
15684 if test "x$ac_cv_func_vfork_works" = xyes; then
15685
15686 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15687
15688 else
15689
15690 $as_echo "#define vfork fork" >>confdefs.h
15691
15692 fi
15693 if test "x$ac_cv_func_fork_works" = xyes; then
15694
15695 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15696
15697 fi
15698
15699
15700 $as_echo "#define RETSIGTYPE void" >>confdefs.h
15701
15702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15703 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15704 if ${ac_cv_sys_largefile_source+:} false; then :
15705   $as_echo_n "(cached) " >&6
15706 else
15707   while :; do
15708   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15709 /* end confdefs.h.  */
15710 #include <sys/types.h> /* for off_t */
15711      #include <stdio.h>
15712 int
15713 main ()
15714 {
15715 int (*fp) (FILE *, off_t, int) = fseeko;
15716      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15717   ;
15718   return 0;
15719 }
15720 _ACEOF
15721 if ac_fn_c_try_link "$LINENO"; then :
15722   ac_cv_sys_largefile_source=no; break
15723 fi
15724 rm -f core conftest.err conftest.$ac_objext \
15725     conftest$ac_exeext conftest.$ac_ext
15726   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15727 /* end confdefs.h.  */
15728 #define _LARGEFILE_SOURCE 1
15729 #include <sys/types.h> /* for off_t */
15730      #include <stdio.h>
15731 int
15732 main ()
15733 {
15734 int (*fp) (FILE *, off_t, int) = fseeko;
15735      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15736   ;
15737   return 0;
15738 }
15739 _ACEOF
15740 if ac_fn_c_try_link "$LINENO"; then :
15741   ac_cv_sys_largefile_source=1; break
15742 fi
15743 rm -f core conftest.err conftest.$ac_objext \
15744     conftest$ac_exeext conftest.$ac_ext
15745   ac_cv_sys_largefile_source=unknown
15746   break
15747 done
15748 fi
15749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15750 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15751 case $ac_cv_sys_largefile_source in #(
15752   no | unknown) ;;
15753   *)
15754 cat >>confdefs.h <<_ACEOF
15755 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15756 _ACEOF
15757 ;;
15758 esac
15759 rm -rf conftest*
15760
15761 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15762 # in glibc 2.1.3, but that breaks too many other things.
15763 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15764 if test $ac_cv_sys_largefile_source != unknown; then
15765
15766 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15767
15768 fi
15769
15770
15771 # Check whether --enable-largefile was given.
15772 if test "${enable_largefile+set}" = set; then :
15773   enableval=$enable_largefile;
15774 fi
15775
15776 if test "$enable_largefile" != no; then
15777
15778   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15779 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
15780 if ${ac_cv_sys_largefile_CC+:} false; then :
15781   $as_echo_n "(cached) " >&6
15782 else
15783   ac_cv_sys_largefile_CC=no
15784      if test "$GCC" != yes; then
15785        ac_save_CC=$CC
15786        while :; do
15787          # IRIX 6.2 and later do not support large files by default,
15788          # so use the C compiler's -n32 option if that helps.
15789          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15790 /* end confdefs.h.  */
15791 #include <sys/types.h>
15792  /* Check that off_t can represent 2**63 - 1 correctly.
15793     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15794     since some C++ compilers masquerading as C compilers
15795     incorrectly reject 9223372036854775807.  */
15796 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15797   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15798                        && LARGE_OFF_T % 2147483647 == 1)
15799                       ? 1 : -1];
15800 int
15801 main ()
15802 {
15803
15804   ;
15805   return 0;
15806 }
15807 _ACEOF
15808          if ac_fn_c_try_compile "$LINENO"; then :
15809   break
15810 fi
15811 rm -f core conftest.err conftest.$ac_objext
15812          CC="$CC -n32"
15813          if ac_fn_c_try_compile "$LINENO"; then :
15814   ac_cv_sys_largefile_CC=' -n32'; break
15815 fi
15816 rm -f core conftest.err conftest.$ac_objext
15817          break
15818        done
15819        CC=$ac_save_CC
15820        rm -f conftest.$ac_ext
15821     fi
15822 fi
15823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15824 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
15825   if test "$ac_cv_sys_largefile_CC" != no; then
15826     CC=$CC$ac_cv_sys_largefile_CC
15827   fi
15828
15829   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15830 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15831 if ${ac_cv_sys_file_offset_bits+:} false; then :
15832   $as_echo_n "(cached) " >&6
15833 else
15834   while :; do
15835   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15836 /* end confdefs.h.  */
15837 #include <sys/types.h>
15838  /* Check that off_t can represent 2**63 - 1 correctly.
15839     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15840     since some C++ compilers masquerading as C compilers
15841     incorrectly reject 9223372036854775807.  */
15842 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15843   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15844                        && LARGE_OFF_T % 2147483647 == 1)
15845                       ? 1 : -1];
15846 int
15847 main ()
15848 {
15849
15850   ;
15851   return 0;
15852 }
15853 _ACEOF
15854 if ac_fn_c_try_compile "$LINENO"; then :
15855   ac_cv_sys_file_offset_bits=no; break
15856 fi
15857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15858   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15859 /* end confdefs.h.  */
15860 #define _FILE_OFFSET_BITS 64
15861 #include <sys/types.h>
15862  /* Check that off_t can represent 2**63 - 1 correctly.
15863     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15864     since some C++ compilers masquerading as C compilers
15865     incorrectly reject 9223372036854775807.  */
15866 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15867   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15868                        && LARGE_OFF_T % 2147483647 == 1)
15869                       ? 1 : -1];
15870 int
15871 main ()
15872 {
15873
15874   ;
15875   return 0;
15876 }
15877 _ACEOF
15878 if ac_fn_c_try_compile "$LINENO"; then :
15879   ac_cv_sys_file_offset_bits=64; break
15880 fi
15881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15882   ac_cv_sys_file_offset_bits=unknown
15883   break
15884 done
15885 fi
15886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15887 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
15888 case $ac_cv_sys_file_offset_bits in #(
15889   no | unknown) ;;
15890   *)
15891 cat >>confdefs.h <<_ACEOF
15892 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
15893 _ACEOF
15894 ;;
15895 esac
15896 rm -rf conftest*
15897   if test $ac_cv_sys_file_offset_bits = unknown; then
15898     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15899 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
15900 if ${ac_cv_sys_large_files+:} false; then :
15901   $as_echo_n "(cached) " >&6
15902 else
15903   while :; do
15904   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15905 /* end confdefs.h.  */
15906 #include <sys/types.h>
15907  /* Check that off_t can represent 2**63 - 1 correctly.
15908     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15909     since some C++ compilers masquerading as C compilers
15910     incorrectly reject 9223372036854775807.  */
15911 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15912   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15913                        && LARGE_OFF_T % 2147483647 == 1)
15914                       ? 1 : -1];
15915 int
15916 main ()
15917 {
15918
15919   ;
15920   return 0;
15921 }
15922 _ACEOF
15923 if ac_fn_c_try_compile "$LINENO"; then :
15924   ac_cv_sys_large_files=no; break
15925 fi
15926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15927   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15928 /* end confdefs.h.  */
15929 #define _LARGE_FILES 1
15930 #include <sys/types.h>
15931  /* Check that off_t can represent 2**63 - 1 correctly.
15932     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15933     since some C++ compilers masquerading as C compilers
15934     incorrectly reject 9223372036854775807.  */
15935 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15936   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15937                        && LARGE_OFF_T % 2147483647 == 1)
15938                       ? 1 : -1];
15939 int
15940 main ()
15941 {
15942
15943   ;
15944   return 0;
15945 }
15946 _ACEOF
15947 if ac_fn_c_try_compile "$LINENO"; then :
15948   ac_cv_sys_large_files=1; break
15949 fi
15950 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15951   ac_cv_sys_large_files=unknown
15952   break
15953 done
15954 fi
15955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15956 $as_echo "$ac_cv_sys_large_files" >&6; }
15957 case $ac_cv_sys_large_files in #(
15958   no | unknown) ;;
15959   *)
15960 cat >>confdefs.h <<_ACEOF
15961 #define _LARGE_FILES $ac_cv_sys_large_files
15962 _ACEOF
15963 ;;
15964 esac
15965 rm -rf conftest*
15966   fi
15967
15968
15969 fi
15970
15971
15972
15973
15974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC" >&5
15975 $as_echo_n "checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC... " >&6; }
15976 cache=_D_LARGEFILE_SOURCE_1
15977 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
15978   $as_echo_n "(cached) " >&6
15979 else
15980
15981 echo '
15982 #include <stdio.h>
15983 int test(void) {
15984         int a = fseeko(stdin, 0, 0);
15985         return a;
15986 }
15987 ' > conftest.c
15988 echo 'void f(void){}' >>conftest.c
15989 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
15990 eval "cv_prog_cc_flag_needed_$cache=no"
15991 else
15992
15993 if test -z "`$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`"; then
15994 eval "cv_prog_cc_flag_needed_$cache=yes"
15995 else
15996 eval "cv_prog_cc_flag_needed_$cache=fail"
15997 #echo 'Test with flag fails too!'
15998 #cat conftest.c
15999 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
16000 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
16001 #exit 1
16002 fi
16003
16004 fi
16005 rm -f conftest conftest.c conftest.o
16006
16007 fi
16008
16009 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
16010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16011 $as_echo "yes" >&6; }
16012 :
16013 CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE=1"
16014 else
16015 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
16016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16017 $as_echo "no" >&6; }
16018 #echo 'Test with flag is no!'
16019 #cat conftest.c
16020 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
16021 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
16022 #exit 1
16023 :
16024
16025 else
16026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
16027 $as_echo "failed" >&6; }
16028 :
16029
16030 fi
16031 fi
16032
16033
16034
16035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nonblocking sockets work" >&5
16036 $as_echo_n "checking if nonblocking sockets work... " >&6; }
16037 if echo $host | grep mingw >/dev/null; then
16038         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (windows)" >&5
16039 $as_echo "no (windows)" >&6; }
16040
16041 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
16042
16043 else
16044 if test "$cross_compiling" = yes; then :
16045
16046         { $as_echo "$as_me:${as_lineno-$LINENO}: result: crosscompile(yes)" >&5
16047 $as_echo "crosscompile(yes)" >&6; }
16048
16049 else
16050   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16051 /* end confdefs.h.  */
16052
16053
16054 #include <stdio.h>
16055 #include <string.h>
16056 #include <stdlib.h>
16057 #include <fcntl.h>
16058 #include <errno.h>
16059 #ifdef HAVE_SYS_TYPES_H
16060 #include <sys/types.h>
16061 #endif
16062 #ifdef HAVE_SYS_SELECT_H
16063 #include <sys/select.h>
16064 #endif
16065 #ifdef HAVE_SYS_SOCKET_H
16066 #include <sys/socket.h>
16067 #endif
16068 #ifdef HAVE_NETINET_IN_H
16069 #include <netinet/in.h>
16070 #endif
16071 #ifdef HAVE_ARPA_INET_H
16072 #include <arpa/inet.h>
16073 #endif
16074 #ifdef HAVE_UNISTD_H
16075 #include <unistd.h>
16076 #endif
16077 #ifdef HAVE_TIME_H
16078 #include <time.h>
16079 #endif
16080
16081 int main(void)
16082 {
16083         int port;
16084         int sfd, cfd;
16085         int num = 10;
16086         int i, p;
16087         struct sockaddr_in a;
16088         /* test if select and nonblocking reads work well together */
16089         /* open port.
16090            fork child to send 10 messages.
16091            select to read.
16092            then try to nonblocking read the 10 messages
16093            then, nonblocking read must give EAGAIN
16094         */
16095
16096         port = 12345 + (time(0)%32);
16097         sfd = socket(PF_INET, SOCK_DGRAM, 0);
16098         if(sfd == -1) {
16099                 perror("socket");
16100                 return 1;
16101         }
16102         memset(&a, 0, sizeof(a));
16103         a.sin_family = AF_INET;
16104         a.sin_port = htons(port);
16105         a.sin_addr.s_addr = inet_addr("127.0.0.1");
16106         if(bind(sfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
16107                 perror("bind");
16108                 return 1;
16109         }
16110         if(fcntl(sfd, F_SETFL, O_NONBLOCK) == -1) {
16111                 perror("fcntl");
16112                 return 1;
16113         }
16114
16115         cfd = socket(PF_INET, SOCK_DGRAM, 0);
16116         if(cfd == -1) {
16117                 perror("client socket");
16118                 return 1;
16119         }
16120         a.sin_port = 0;
16121         if(bind(cfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
16122                 perror("client bind");
16123                 return 1;
16124         }
16125         a.sin_port = htons(port);
16126
16127         /* no handler, causes exit in 10 seconds */
16128         alarm(10);
16129
16130         /* send and receive on the socket */
16131         if((p=fork()) == 0) {
16132                 for(i=0; i<num; i++) {
16133                         if(sendto(cfd, &i, sizeof(i), 0,
16134                                 (struct sockaddr*)&a, sizeof(a)) < 0) {
16135                                 perror("sendto");
16136                                 return 1;
16137                         }
16138                 }
16139         } else {
16140                 /* parent */
16141                 fd_set rset;
16142                 int x;
16143                 if(p == -1) {
16144                         perror("fork");
16145                         return 1;
16146                 }
16147                 FD_ZERO(&rset);
16148                 FD_SET(sfd, &rset);
16149                 if(select(sfd+1, &rset, NULL, NULL, NULL) < 1) {
16150                         perror("select");
16151                         return 1;
16152                 }
16153                 i = 0;
16154                 while(i < num) {
16155                         if(recv(sfd, &x, sizeof(x), 0) != sizeof(x)) {
16156                                 if(errno == EAGAIN)
16157                                         continue;
16158                                 perror("recv");
16159                                 return 1;
16160                         }
16161                         i++;
16162                 }
16163                 /* now we want to get EAGAIN: nonblocking goodness */
16164                 errno = 0;
16165                 recv(sfd, &x, sizeof(x), 0);
16166                 if(errno != EAGAIN) {
16167                         perror("trying to recv again");
16168                         return 1;
16169                 }
16170                 /* EAGAIN encountered */
16171         }
16172
16173         close(sfd);
16174         close(cfd);
16175         return 0;
16176 }
16177
16178 _ACEOF
16179 if ac_fn_c_try_run "$LINENO"; then :
16180
16181         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16182 $as_echo "yes" >&6; }
16183
16184 else
16185
16186         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16187 $as_echo "no" >&6; }
16188
16189 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
16190
16191
16192 fi
16193 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16194   conftest.$ac_objext conftest.beam conftest.$ac_ext
16195 fi
16196
16197 fi
16198
16199
16200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir has one arg" >&5
16201 $as_echo_n "checking whether mkdir has one arg... " >&6; }
16202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16203 /* end confdefs.h.  */
16204
16205 #include <stdio.h>
16206 #include <unistd.h>
16207 #ifdef HAVE_WINSOCK2_H
16208 #include <winsock2.h>
16209 #endif
16210 #ifdef HAVE_SYS_STAT_H
16211 #include <sys/stat.h>
16212 #endif
16213
16214 int
16215 main ()
16216 {
16217
16218         (void)mkdir("directory");
16219
16220   ;
16221   return 0;
16222 }
16223 _ACEOF
16224 if ac_fn_c_try_compile "$LINENO"; then :
16225   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16226 $as_echo "yes" >&6; }
16227
16228 $as_echo "#define MKDIR_HAS_ONE_ARG 1" >>confdefs.h
16229
16230
16231 else
16232   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16233 $as_echo "no" >&6; }
16234
16235 fi
16236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16237
16238 for ac_func in strptime
16239 do :
16240   ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
16241 if test "x$ac_cv_func_strptime" = xyes; then :
16242   cat >>confdefs.h <<_ACEOF
16243 #define HAVE_STRPTIME 1
16244 _ACEOF
16245
16246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strptime works" >&5
16247 $as_echo_n "checking whether strptime works... " >&6; }
16248 if test c${cross_compiling} = cno; then
16249 if test "$cross_compiling" = yes; then :
16250   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16251 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16252 as_fn_error $? "cannot run test program while cross compiling
16253 See \`config.log' for more details" "$LINENO" 5; }
16254 else
16255   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16256 /* end confdefs.h.  */
16257
16258 #define _XOPEN_SOURCE 600
16259 #include <time.h>
16260 int main(void) { struct tm tm; char *res;
16261 res = strptime("2010-07-15T00:00:00+00:00", "%t%Y%t-%t%m%t-%t%d%tT%t%H%t:%t%M%t:%t%S%t", &tm);
16262 if (!res) return 2;
16263 res = strptime("20070207111842", "%Y%m%d%H%M%S", &tm);
16264 if (!res) return 1; return 0; }
16265
16266 _ACEOF
16267 if ac_fn_c_try_run "$LINENO"; then :
16268   eval "ac_cv_c_strptime_works=yes"
16269 else
16270   eval "ac_cv_c_strptime_works=no"
16271 fi
16272 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16273   conftest.$ac_objext conftest.beam conftest.$ac_ext
16274 fi
16275
16276 else
16277 eval "ac_cv_c_strptime_works=maybe"
16278 fi
16279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_strptime_works" >&5
16280 $as_echo "$ac_cv_c_strptime_works" >&6; }
16281 if test $ac_cv_c_strptime_works = no; then
16282 case " $LIBOBJS " in
16283   *" strptime.$ac_objext "* ) ;;
16284   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16285  ;;
16286 esac
16287
16288 else
16289
16290 cat >>confdefs.h <<_ACEOF
16291 #define STRPTIME_WORKS 1
16292 _ACEOF
16293
16294 fi
16295
16296 else
16297   case " $LIBOBJS " in
16298   *" strptime.$ac_objext "* ) ;;
16299   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16300  ;;
16301 esac
16302
16303 fi
16304 done
16305
16306
16307 # check if we can use SO_REUSEPORT
16308 reuseport_default=0
16309 if echo "$host" | $GREP -i -e linux >/dev/null; then reuseport_default=1; fi
16310 if echo "$host" | $GREP -i -e dragonfly >/dev/null; then reuseport_default=1; fi
16311 if test "$reuseport_default" = 1; then
16312
16313 $as_echo "#define REUSEPORT_DEFAULT 1" >>confdefs.h
16314
16315 else
16316
16317 $as_echo "#define REUSEPORT_DEFAULT 0" >>confdefs.h
16318
16319 fi
16320
16321 # Include systemd.m4 - begin
16322 #   macros for configuring systemd
16323 #   Copyright 2015, Sami Kerola, CloudFlare.
16324 #   BSD licensed.
16325 # Check whether --enable-systemd was given.
16326 if test "${enable_systemd+set}" = set; then :
16327   enableval=$enable_systemd;
16328 else
16329   enable_systemd=no
16330 fi
16331
16332 have_systemd=no
16333 if test "x$enable_systemd" != xno; then :
16334
16335
16336
16337 pkg_failed=no
16338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD" >&5
16339 $as_echo_n "checking for SYSTEMD... " >&6; }
16340
16341 if test -n "$SYSTEMD_CFLAGS"; then
16342     pkg_cv_SYSTEMD_CFLAGS="$SYSTEMD_CFLAGS"
16343  elif test -n "$PKG_CONFIG"; then
16344     if test -n "$PKG_CONFIG" && \
16345     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16346   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16347   ac_status=$?
16348   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16349   test $ac_status = 0; }; then
16350   pkg_cv_SYSTEMD_CFLAGS=`$PKG_CONFIG --cflags "libsystemd" 2>/dev/null`
16351                       test "x$?" != "x0" && pkg_failed=yes
16352 else
16353   pkg_failed=yes
16354 fi
16355  else
16356     pkg_failed=untried
16357 fi
16358 if test -n "$SYSTEMD_LIBS"; then
16359     pkg_cv_SYSTEMD_LIBS="$SYSTEMD_LIBS"
16360  elif test -n "$PKG_CONFIG"; then
16361     if test -n "$PKG_CONFIG" && \
16362     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16363   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16364   ac_status=$?
16365   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16366   test $ac_status = 0; }; then
16367   pkg_cv_SYSTEMD_LIBS=`$PKG_CONFIG --libs "libsystemd" 2>/dev/null`
16368                       test "x$?" != "x0" && pkg_failed=yes
16369 else
16370   pkg_failed=yes
16371 fi
16372  else
16373     pkg_failed=untried
16374 fi
16375
16376
16377
16378 if test $pkg_failed = yes; then
16379         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16380 $as_echo "no" >&6; }
16381
16382 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16383         _pkg_short_errors_supported=yes
16384 else
16385         _pkg_short_errors_supported=no
16386 fi
16387         if test $_pkg_short_errors_supported = yes; then
16388                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd" 2>&1`
16389         else
16390                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd" 2>&1`
16391         fi
16392         # Put the nasty error message in config.log where it belongs
16393         echo "$SYSTEMD_PKG_ERRORS" >&5
16394
16395         have_systemd=no
16396 elif test $pkg_failed = untried; then
16397         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16398 $as_echo "no" >&6; }
16399         have_systemd=no
16400 else
16401         SYSTEMD_CFLAGS=$pkg_cv_SYSTEMD_CFLAGS
16402         SYSTEMD_LIBS=$pkg_cv_SYSTEMD_LIBS
16403         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16404 $as_echo "yes" >&6; }
16405         have_systemd=yes
16406 fi
16407                 if test "x$have_systemd" != "xyes"; then :
16408
16409
16410 pkg_failed=no
16411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD_DAEMON" >&5
16412 $as_echo_n "checking for SYSTEMD_DAEMON... " >&6; }
16413
16414 if test -n "$SYSTEMD_DAEMON_CFLAGS"; then
16415     pkg_cv_SYSTEMD_DAEMON_CFLAGS="$SYSTEMD_DAEMON_CFLAGS"
16416  elif test -n "$PKG_CONFIG"; then
16417     if test -n "$PKG_CONFIG" && \
16418     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16419   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16420   ac_status=$?
16421   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16422   test $ac_status = 0; }; then
16423   pkg_cv_SYSTEMD_DAEMON_CFLAGS=`$PKG_CONFIG --cflags "libsystemd-daemon" 2>/dev/null`
16424                       test "x$?" != "x0" && pkg_failed=yes
16425 else
16426   pkg_failed=yes
16427 fi
16428  else
16429     pkg_failed=untried
16430 fi
16431 if test -n "$SYSTEMD_DAEMON_LIBS"; then
16432     pkg_cv_SYSTEMD_DAEMON_LIBS="$SYSTEMD_DAEMON_LIBS"
16433  elif test -n "$PKG_CONFIG"; then
16434     if test -n "$PKG_CONFIG" && \
16435     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16436   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16437   ac_status=$?
16438   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16439   test $ac_status = 0; }; then
16440   pkg_cv_SYSTEMD_DAEMON_LIBS=`$PKG_CONFIG --libs "libsystemd-daemon" 2>/dev/null`
16441                       test "x$?" != "x0" && pkg_failed=yes
16442 else
16443   pkg_failed=yes
16444 fi
16445  else
16446     pkg_failed=untried
16447 fi
16448
16449
16450
16451 if test $pkg_failed = yes; then
16452         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16453 $as_echo "no" >&6; }
16454
16455 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16456         _pkg_short_errors_supported=yes
16457 else
16458         _pkg_short_errors_supported=no
16459 fi
16460         if test $_pkg_short_errors_supported = yes; then
16461                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16462         else
16463                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16464         fi
16465         # Put the nasty error message in config.log where it belongs
16466         echo "$SYSTEMD_DAEMON_PKG_ERRORS" >&5
16467
16468         have_systemd_daemon=no
16469 elif test $pkg_failed = untried; then
16470         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16471 $as_echo "no" >&6; }
16472         have_systemd_daemon=no
16473 else
16474         SYSTEMD_DAEMON_CFLAGS=$pkg_cv_SYSTEMD_DAEMON_CFLAGS
16475         SYSTEMD_DAEMON_LIBS=$pkg_cv_SYSTEMD_DAEMON_LIBS
16476         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16477 $as_echo "yes" >&6; }
16478         have_systemd_daemon=yes
16479 fi
16480                 if test "x$have_systemd_daemon" = "xyes"; then :
16481   have_systemd=yes
16482 fi
16483
16484 fi
16485         case $enable_systemd:$have_systemd in #(
16486   yes:no) :
16487     as_fn_error $? "systemd enabled but libsystemd not found" "$LINENO" 5 ;; #(
16488   *:yes) :
16489
16490 $as_echo "#define HAVE_SYSTEMD 1" >>confdefs.h
16491
16492                 LIBS="$LIBS $SYSTEMD_LIBS"
16493
16494          ;; #(
16495   *) :
16496      ;;
16497 esac
16498
16499
16500 fi
16501  if test "x$have_systemd" = xyes; then
16502   USE_SYSTEMD_TRUE=
16503   USE_SYSTEMD_FALSE='#'
16504 else
16505   USE_SYSTEMD_TRUE='#'
16506   USE_SYSTEMD_FALSE=
16507 fi
16508
16509
16510 # Include systemd.m4 - end
16511
16512 # set memory allocation checking if requested
16513 # Check whether --enable-alloc-checks was given.
16514 if test "${enable_alloc_checks+set}" = set; then :
16515   enableval=$enable_alloc_checks;
16516 fi
16517
16518 # Check whether --enable-alloc-lite was given.
16519 if test "${enable_alloc_lite+set}" = set; then :
16520   enableval=$enable_alloc_lite;
16521 fi
16522
16523 # Check whether --enable-alloc-nonregional was given.
16524 if test "${enable_alloc_nonregional+set}" = set; then :
16525   enableval=$enable_alloc_nonregional;
16526 fi
16527
16528 if test x_$enable_alloc_nonregional = x_yes; then
16529
16530 $as_echo "#define UNBOUND_ALLOC_NONREGIONAL 1" >>confdefs.h
16531
16532 fi
16533 if test x_$enable_alloc_checks = x_yes; then
16534
16535 $as_echo "#define UNBOUND_ALLOC_STATS 1" >>confdefs.h
16536
16537         SLDNS_ALLOCCHECK_EXTRA_OBJ="alloc.lo log.lo"
16538
16539         ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ="alloc.lo"
16540
16541 else
16542         if test x_$enable_alloc_lite = x_yes; then
16543
16544 $as_echo "#define UNBOUND_ALLOC_LITE 1" >>confdefs.h
16545
16546         else
16547
16548         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
16549 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
16550         if test "$cross_compiling" = yes; then :
16551   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (crosscompile)" >&5
16552 $as_echo "no (crosscompile)" >&6; }
16553         case " $LIBOBJS " in
16554   *" malloc.$ac_objext "* ) ;;
16555   *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
16556  ;;
16557 esac
16558
16559
16560 cat >>confdefs.h <<_ACEOF
16561 #define malloc rpl_malloc_unbound
16562 _ACEOF
16563
16564 else
16565   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16566 /* end confdefs.h.  */
16567 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
16568 #include <stdlib.h>
16569 #else
16570 char *malloc ();
16571 #endif
16572
16573 int
16574 main ()
16575 {
16576  if(malloc(0) != 0) return 1;
16577   ;
16578   return 0;
16579 }
16580
16581 _ACEOF
16582 if ac_fn_c_try_run "$LINENO"; then :
16583   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16584 $as_echo "no" >&6; }
16585         case " $LIBOBJS " in
16586   *" malloc.$ac_objext "* ) ;;
16587   *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
16588  ;;
16589 esac
16590
16591
16592 cat >>confdefs.h <<_ACEOF
16593 #define malloc rpl_malloc_unbound
16594 _ACEOF
16595
16596 else
16597   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16598 $as_echo "yes" >&6; }
16599
16600 $as_echo "#define HAVE_MALLOC 1" >>confdefs.h
16601
16602 fi
16603 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16604   conftest.$ac_objext conftest.beam conftest.$ac_ext
16605 fi
16606
16607
16608         fi
16609 fi
16610
16611 # check windows threads (we use them, not pthreads, on windows).
16612 if test "$on_mingw" = "yes"; then
16613 # check windows threads
16614         for ac_header in windows.h
16615 do :
16616   ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
16617 "
16618 if test "x$ac_cv_header_windows_h" = xyes; then :
16619   cat >>confdefs.h <<_ACEOF
16620 #define HAVE_WINDOWS_H 1
16621 _ACEOF
16622
16623 fi
16624
16625 done
16626
16627         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CreateThread" >&5
16628 $as_echo_n "checking for CreateThread... " >&6; }
16629         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16630 /* end confdefs.h.  */
16631
16632 #ifdef HAVE_WINDOWS_H
16633 #include <windows.h>
16634 #endif
16635
16636 int
16637 main ()
16638 {
16639
16640         HANDLE t = CreateThread(NULL, 0, NULL, NULL, 0, NULL);
16641
16642   ;
16643   return 0;
16644 }
16645 _ACEOF
16646 if ac_fn_c_try_compile "$LINENO"; then :
16647   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16648 $as_echo "yes" >&6; }
16649
16650 $as_echo "#define HAVE_WINDOWS_THREADS 1" >>confdefs.h
16651
16652
16653 else
16654   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16655 $as_echo "no" >&6; }
16656
16657 fi
16658 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16659
16660 else
16661 # not on mingw, check thread libraries.
16662
16663 # check for thread library.
16664 # check this first, so that the pthread lib does not get linked in via
16665 # libssl or libpython, and thus distorts the tests, and we end up using
16666 # the non-threadsafe C libraries.
16667
16668 # Check whether --with-pthreads was given.
16669 if test "${with_pthreads+set}" = set; then :
16670   withval=$with_pthreads;
16671 else
16672    withval="yes"
16673 fi
16674
16675 ub_have_pthreads=no
16676 if test x_$withval != x_no; then
16677
16678
16679 ac_ext=c
16680 ac_cpp='$CPP $CPPFLAGS'
16681 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16682 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16683 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16684
16685 ax_pthread_ok=no
16686
16687 # We used to check for pthread.h first, but this fails if pthread.h
16688 # requires special compiler flags (e.g. on True64 or Sequent).
16689 # It gets checked for in the link test anyway.
16690
16691 # First of all, check if the user has set any of the PTHREAD_LIBS,
16692 # etcetera environment variables, and if threads linking works using
16693 # them:
16694 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16695         save_CFLAGS="$CFLAGS"
16696         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16697         save_LIBS="$LIBS"
16698         LIBS="$PTHREAD_LIBS $LIBS"
16699         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16700 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
16701         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16702 /* end confdefs.h.  */
16703
16704 /* Override any GCC internal prototype to avoid an error.
16705    Use char because int might match the return type of a GCC
16706    builtin and then its argument prototype would still apply.  */
16707 #ifdef __cplusplus
16708 extern "C"
16709 #endif
16710 char pthread_join ();
16711 int
16712 main ()
16713 {
16714 return pthread_join ();
16715   ;
16716   return 0;
16717 }
16718 _ACEOF
16719 if ac_fn_c_try_link "$LINENO"; then :
16720   ax_pthread_ok=yes
16721 fi
16722 rm -f core conftest.err conftest.$ac_objext \
16723     conftest$ac_exeext conftest.$ac_ext
16724         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16725 $as_echo "$ax_pthread_ok" >&6; }
16726         if test x"$ax_pthread_ok" = xno; then
16727                 PTHREAD_LIBS=""
16728                 PTHREAD_CFLAGS=""
16729         fi
16730         LIBS="$save_LIBS"
16731         CFLAGS="$save_CFLAGS"
16732 fi
16733
16734 # We must check for the threads library under a number of different
16735 # names; the ordering is very important because some systems
16736 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16737 # libraries is broken (non-POSIX).
16738
16739 # Create a list of thread flags to try.  Items starting with a "-" are
16740 # C compiler flags, and other items are library names, except for "none"
16741 # which indicates that we try without any flags at all, and "pthread-config"
16742 # which is a program returning the flags for the Pth emulation library.
16743
16744 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
16745
16746 # The ordering *is* (sometimes) important.  Some notes on the
16747 # individual items follow:
16748
16749 # pthreads: AIX (must check this before -lpthread)
16750 # none: in case threads are in libc; should be tried before -Kthread and
16751 #       other compiler flags to prevent continual compiler warnings
16752 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16753 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16754 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16755 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16756 # -pthreads: Solaris/gcc
16757 # -mthreads: Mingw32/gcc, Lynx/gcc
16758 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16759 #      doesn't hurt to check since this sometimes defines pthreads too;
16760 #      also defines -D_REENTRANT)
16761 #      ... -mt is also the pthreads flag for HP/aCC
16762 # pthread: Linux, etcetera
16763 # --thread-safe: KAI C++
16764 # pthread-config: use pthread-config program (for GNU Pth library)
16765
16766 case ${host_os} in
16767         solaris*)
16768
16769         # On Solaris (at least, for some versions), libc contains stubbed
16770         # (non-functional) versions of the pthreads routines, so link-based
16771         # tests will erroneously succeed.  (We need to link with -pthreads/-mt/
16772         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
16773         # a function called by this macro, so we could check for that, but
16774         # who knows whether they'll stub that too in a future libc.)  So,
16775         # we'll just look for -pthreads and -lpthread first:
16776
16777         ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
16778         ;;
16779
16780         darwin*)
16781         ax_pthread_flags="-pthread $ax_pthread_flags"
16782         ;;
16783 esac
16784
16785 # Clang doesn't consider unrecognized options an error unless we specify
16786 # -Werror. We throw in some extra Clang-specific options to ensure that
16787 # this doesn't happen for GCC, which also accepts -Werror.
16788
16789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs -Werror to reject unknown flags" >&5
16790 $as_echo_n "checking if compiler needs -Werror to reject unknown flags... " >&6; }
16791 save_CFLAGS="$CFLAGS"
16792 ax_pthread_extra_flags="-Werror"
16793 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wunknown-warning-option -Wsizeof-array-argument"
16794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16795 /* end confdefs.h.  */
16796 int foo(void);
16797 int
16798 main ()
16799 {
16800 foo()
16801   ;
16802   return 0;
16803 }
16804 _ACEOF
16805 if ac_fn_c_try_compile "$LINENO"; then :
16806   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16807 $as_echo "yes" >&6; }
16808 else
16809   ax_pthread_extra_flags=
16810                    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16811 $as_echo "no" >&6; }
16812 fi
16813 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16814 CFLAGS="$save_CFLAGS"
16815
16816 if test x"$ax_pthread_ok" = xno; then
16817 for flag in $ax_pthread_flags; do
16818
16819         case $flag in
16820                 none)
16821                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
16822 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
16823                 ;;
16824
16825                 -*)
16826                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
16827 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
16828                 PTHREAD_CFLAGS="$flag"
16829                 ;;
16830
16831                 pthread-config)
16832                 # Extract the first word of "pthread-config", so it can be a program name with args.
16833 set dummy pthread-config; ac_word=$2
16834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16835 $as_echo_n "checking for $ac_word... " >&6; }
16836 if ${ac_cv_prog_ax_pthread_config+:} false; then :
16837   $as_echo_n "(cached) " >&6
16838 else
16839   if test -n "$ax_pthread_config"; then
16840   ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
16841 else
16842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16843 for as_dir in $PATH
16844 do
16845   IFS=$as_save_IFS
16846   test -z "$as_dir" && as_dir=.
16847     for ac_exec_ext in '' $ac_executable_extensions; do
16848   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16849     ac_cv_prog_ax_pthread_config="yes"
16850     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16851     break 2
16852   fi
16853 done
16854   done
16855 IFS=$as_save_IFS
16856
16857   test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
16858 fi
16859 fi
16860 ax_pthread_config=$ac_cv_prog_ax_pthread_config
16861 if test -n "$ax_pthread_config"; then
16862   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
16863 $as_echo "$ax_pthread_config" >&6; }
16864 else
16865   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16866 $as_echo "no" >&6; }
16867 fi
16868
16869
16870                 if test x"$ax_pthread_config" = xno; then continue; fi
16871                 PTHREAD_CFLAGS="`pthread-config --cflags`"
16872                 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16873                 ;;
16874
16875                 *)
16876                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
16877 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
16878                 PTHREAD_LIBS="-l$flag"
16879                 ;;
16880         esac
16881
16882         save_LIBS="$LIBS"
16883         save_CFLAGS="$CFLAGS"
16884         LIBS="$PTHREAD_LIBS $LIBS"
16885         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
16886
16887         # Check for various functions.  We must include pthread.h,
16888         # since some functions may be macros.  (On the Sequent, we
16889         # need a special flag -Kthread to make this header compile.)
16890         # We check for pthread_join because it is in -lpthread on IRIX
16891         # while pthread_create is in libc.  We check for pthread_attr_init
16892         # due to DEC craziness with -lpthreads.  We check for
16893         # pthread_cleanup_push because it is one of the few pthread
16894         # functions on Solaris that doesn't have a non-functional libc stub.
16895         # We try pthread_create on general principles.
16896         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16897 /* end confdefs.h.  */
16898 #include <pthread.h>
16899                         static void routine(void *a) { *((int*)a) = 0; }
16900                         static void *start_routine(void *a) { return a; }
16901 int
16902 main ()
16903 {
16904 pthread_t th; pthread_attr_t attr;
16905                         pthread_create(&th, 0, start_routine, 0);
16906                         pthread_join(th, 0);
16907                         pthread_attr_init(&attr);
16908                         pthread_cleanup_push(routine, 0);
16909                         pthread_cleanup_pop(0) /* ; */
16910   ;
16911   return 0;
16912 }
16913 _ACEOF
16914 if ac_fn_c_try_link "$LINENO"; then :
16915   ax_pthread_ok=yes
16916 fi
16917 rm -f core conftest.err conftest.$ac_objext \
16918     conftest$ac_exeext conftest.$ac_ext
16919
16920         LIBS="$save_LIBS"
16921         CFLAGS="$save_CFLAGS"
16922
16923         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16924 $as_echo "$ax_pthread_ok" >&6; }
16925         if test "x$ax_pthread_ok" = xyes; then
16926                 break;
16927         fi
16928
16929         PTHREAD_LIBS=""
16930         PTHREAD_CFLAGS=""
16931 done
16932 fi
16933
16934 # Various other checks:
16935 if test "x$ax_pthread_ok" = xyes; then
16936         save_LIBS="$LIBS"
16937         LIBS="$PTHREAD_LIBS $LIBS"
16938         save_CFLAGS="$CFLAGS"
16939         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16940
16941         # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
16942         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
16943 $as_echo_n "checking for joinable pthread attribute... " >&6; }
16944         attr_name=unknown
16945         for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
16946             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16947 /* end confdefs.h.  */
16948 #include <pthread.h>
16949 int
16950 main ()
16951 {
16952 int attr = $attr; return attr /* ; */
16953   ;
16954   return 0;
16955 }
16956 _ACEOF
16957 if ac_fn_c_try_link "$LINENO"; then :
16958   attr_name=$attr; break
16959 fi
16960 rm -f core conftest.err conftest.$ac_objext \
16961     conftest$ac_exeext conftest.$ac_ext
16962         done
16963         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
16964 $as_echo "$attr_name" >&6; }
16965         if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
16966
16967 cat >>confdefs.h <<_ACEOF
16968 #define PTHREAD_CREATE_JOINABLE $attr_name
16969 _ACEOF
16970
16971         fi
16972
16973         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
16974 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
16975         flag=no
16976         case ${host_os} in
16977             aix* | freebsd* | darwin*) flag="-D_THREAD_SAFE";;
16978             osf* | hpux*) flag="-D_REENTRANT";;
16979             solaris*)
16980             if test "$GCC" = "yes"; then
16981                 flag="-D_REENTRANT"
16982             else
16983                 # TODO: What about Clang on Solaris?
16984                 flag="-mt -D_REENTRANT"
16985             fi
16986             ;;
16987         esac
16988         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $flag" >&5
16989 $as_echo "$flag" >&6; }
16990         if test "x$flag" != xno; then
16991             PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16992         fi
16993
16994         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
16995 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
16996 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
16997   $as_echo_n "(cached) " >&6
16998 else
16999
17000                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17001 /* end confdefs.h.  */
17002 #include <pthread.h>
17003 int
17004 main ()
17005 {
17006 int i = PTHREAD_PRIO_INHERIT;
17007   ;
17008   return 0;
17009 }
17010 _ACEOF
17011 if ac_fn_c_try_link "$LINENO"; then :
17012   ax_cv_PTHREAD_PRIO_INHERIT=yes
17013 else
17014   ax_cv_PTHREAD_PRIO_INHERIT=no
17015 fi
17016 rm -f core conftest.err conftest.$ac_objext \
17017     conftest$ac_exeext conftest.$ac_ext
17018
17019 fi
17020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
17021 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
17022         if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
17023
17024 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
17025
17026 fi
17027
17028         LIBS="$save_LIBS"
17029         CFLAGS="$save_CFLAGS"
17030
17031         # More AIX lossage: compile with *_r variant
17032         if test "x$GCC" != xyes; then
17033             case $host_os in
17034                 aix*)
17035                 case "x/$CC" in #(
17036   x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
17037     #handle absolute path differently from PATH based program lookup
17038                    case "x$CC" in #(
17039   x/*) :
17040     if as_fn_executable_p ${CC}_r; then :
17041   PTHREAD_CC="${CC}_r"
17042 fi ;; #(
17043   *) :
17044     for ac_prog in ${CC}_r
17045 do
17046   # Extract the first word of "$ac_prog", so it can be a program name with args.
17047 set dummy $ac_prog; ac_word=$2
17048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17049 $as_echo_n "checking for $ac_word... " >&6; }
17050 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
17051   $as_echo_n "(cached) " >&6
17052 else
17053   if test -n "$PTHREAD_CC"; then
17054   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
17055 else
17056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17057 for as_dir in $PATH
17058 do
17059   IFS=$as_save_IFS
17060   test -z "$as_dir" && as_dir=.
17061     for ac_exec_ext in '' $ac_executable_extensions; do
17062   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17063     ac_cv_prog_PTHREAD_CC="$ac_prog"
17064     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17065     break 2
17066   fi
17067 done
17068   done
17069 IFS=$as_save_IFS
17070
17071 fi
17072 fi
17073 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
17074 if test -n "$PTHREAD_CC"; then
17075   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
17076 $as_echo "$PTHREAD_CC" >&6; }
17077 else
17078   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17079 $as_echo "no" >&6; }
17080 fi
17081
17082
17083   test -n "$PTHREAD_CC" && break
17084 done
17085 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
17086  ;;
17087 esac ;; #(
17088   *) :
17089      ;;
17090 esac
17091                 ;;
17092             esac
17093         fi
17094 fi
17095
17096 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
17097
17098
17099
17100
17101
17102 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
17103 if test x"$ax_pthread_ok" = xyes; then
17104
17105
17106 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
17107
17108                 if test -n "$PTHREAD_LIBS"; then
17109                   LIBS="$PTHREAD_LIBS $LIBS"
17110                 fi
17111                 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
17112                 CC="$PTHREAD_CC"
17113                 ub_have_pthreads=yes
17114                 ac_fn_c_check_type "$LINENO" "pthread_spinlock_t" "ac_cv_type_pthread_spinlock_t" "#include <pthread.h>
17115 "
17116 if test "x$ac_cv_type_pthread_spinlock_t" = xyes; then :
17117
17118 cat >>confdefs.h <<_ACEOF
17119 #define HAVE_PTHREAD_SPINLOCK_T 1
17120 _ACEOF
17121
17122
17123 fi
17124 ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
17125 "
17126 if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then :
17127
17128 cat >>confdefs.h <<_ACEOF
17129 #define HAVE_PTHREAD_RWLOCK_T 1
17130 _ACEOF
17131
17132
17133 fi
17134
17135                 # The cast to long int works around a bug in the HP C Compiler
17136 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17137 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17138 # This bug is HP SR number 8606223364.
17139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
17140 $as_echo_n "checking size of unsigned long... " >&6; }
17141 if ${ac_cv_sizeof_unsigned_long+:} false; then :
17142   $as_echo_n "(cached) " >&6
17143 else
17144   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long"        "$ac_includes_default"; then :
17145
17146 else
17147   if test "$ac_cv_type_unsigned_long" = yes; then
17148      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17149 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17150 as_fn_error 77 "cannot compute sizeof (unsigned long)
17151 See \`config.log' for more details" "$LINENO" 5; }
17152    else
17153      ac_cv_sizeof_unsigned_long=0
17154    fi
17155 fi
17156
17157 fi
17158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
17159 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
17160
17161
17162
17163 cat >>confdefs.h <<_ACEOF
17164 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
17165 _ACEOF
17166
17167
17168                 # The cast to long int works around a bug in the HP C Compiler
17169 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17170 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17171 # This bug is HP SR number 8606223364.
17172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
17173 $as_echo_n "checking size of pthread_t... " >&6; }
17174 if ${ac_cv_sizeof_pthread_t+:} false; then :
17175   $as_echo_n "(cached) " >&6
17176 else
17177   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t"        "$ac_includes_default"; then :
17178
17179 else
17180   if test "$ac_cv_type_pthread_t" = yes; then
17181      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17182 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17183 as_fn_error 77 "cannot compute sizeof (pthread_t)
17184 See \`config.log' for more details" "$LINENO" 5; }
17185    else
17186      ac_cv_sizeof_pthread_t=0
17187    fi
17188 fi
17189
17190 fi
17191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
17192 $as_echo "$ac_cv_sizeof_pthread_t" >&6; }
17193
17194
17195
17196 cat >>confdefs.h <<_ACEOF
17197 #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
17198 _ACEOF
17199
17200
17201
17202                 if echo "$CFLAGS" | $GREP -e "-pthread" >/dev/null; then
17203                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread unused during linking" >&5
17204 $as_echo_n "checking if -pthread unused during linking... " >&6; }
17205                 # catch clang warning 'argument unused during compilation'
17206                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17207 /* end confdefs.h.  */
17208 $ac_includes_default
17209
17210 int main(void) {return 0;}
17211
17212 _ACEOF
17213                 pthread_unused="yes"
17214                 # first compile
17215                 echo "$CC $CFLAGS -c conftest.c -o conftest.o" >&5
17216                 $CC $CFLAGS -c conftest.c -o conftest.o 2>&5 >&5
17217                 if test $? = 0; then
17218                         # then link
17219                         echo "$CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest contest.o" >&5
17220                         $CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest conftest.o 2>&5 >&5
17221                         if test $? -ne 0; then
17222                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17223 $as_echo "yes" >&6; }
17224                                 CFLAGS=`echo "$CFLAGS" | sed -e 's/-pthread//'`
17225                                 PTHREAD_CFLAGS_ONLY="-pthread"
17226
17227                         else
17228                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17229 $as_echo "no" >&6; }
17230                         fi
17231                 else
17232                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17233 $as_echo "no" >&6; }
17234                 fi # endif cc successful
17235                 rm -f conftest conftest.c conftest.o
17236                 fi # endif -pthread in CFLAGS
17237
17238
17239         :
17240 else
17241         ax_pthread_ok=no
17242
17243 fi
17244 ac_ext=c
17245 ac_cpp='$CPP $CPPFLAGS'
17246 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17247 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17248 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17249
17250
17251 fi
17252
17253 # check solaris thread library
17254
17255 # Check whether --with-solaris-threads was given.
17256 if test "${with_solaris_threads+set}" = set; then :
17257   withval=$with_solaris_threads;
17258 else
17259    withval="no"
17260 fi
17261
17262 ub_have_sol_threads=no
17263 if test x_$withval != x_no; then
17264         if test x_$ub_have_pthreads != x_no; then
17265             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&5
17266 $as_echo "$as_me: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&2;}
17267         else
17268         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing thr_create" >&5
17269 $as_echo_n "checking for library containing thr_create... " >&6; }
17270 if ${ac_cv_search_thr_create+:} false; then :
17271   $as_echo_n "(cached) " >&6
17272 else
17273   ac_func_search_save_LIBS=$LIBS
17274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17275 /* end confdefs.h.  */
17276
17277 /* Override any GCC internal prototype to avoid an error.
17278    Use char because int might match the return type of a GCC
17279    builtin and then its argument prototype would still apply.  */
17280 #ifdef __cplusplus
17281 extern "C"
17282 #endif
17283 char thr_create ();
17284 int
17285 main ()
17286 {
17287 return thr_create ();
17288   ;
17289   return 0;
17290 }
17291 _ACEOF
17292 for ac_lib in '' thread; do
17293   if test -z "$ac_lib"; then
17294     ac_res="none required"
17295   else
17296     ac_res=-l$ac_lib
17297     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17298   fi
17299   if ac_fn_c_try_link "$LINENO"; then :
17300   ac_cv_search_thr_create=$ac_res
17301 fi
17302 rm -f core conftest.err conftest.$ac_objext \
17303     conftest$ac_exeext
17304   if ${ac_cv_search_thr_create+:} false; then :
17305   break
17306 fi
17307 done
17308 if ${ac_cv_search_thr_create+:} false; then :
17309
17310 else
17311   ac_cv_search_thr_create=no
17312 fi
17313 rm conftest.$ac_ext
17314 LIBS=$ac_func_search_save_LIBS
17315 fi
17316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_thr_create" >&5
17317 $as_echo "$ac_cv_search_thr_create" >&6; }
17318 ac_res=$ac_cv_search_thr_create
17319 if test "$ac_res" != no; then :
17320   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17321
17322
17323 $as_echo "#define HAVE_SOLARIS_THREADS 1" >>confdefs.h
17324
17325
17326
17327
17328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -mt" >&5
17329 $as_echo_n "checking whether $CC supports -mt... " >&6; }
17330 cache=`echo mt | sed 'y%.=/+-%___p_%'`
17331 if eval \${cv_prog_cc_flag_$cache+:} false; then :
17332   $as_echo_n "(cached) " >&6
17333 else
17334
17335 echo 'void f(void){}' >conftest.c
17336 if test -z "`$CC $CPPFLAGS $CFLAGS -mt -c conftest.c 2>&1`"; then
17337 eval "cv_prog_cc_flag_$cache=yes"
17338 else
17339 eval "cv_prog_cc_flag_$cache=no"
17340 fi
17341 rm -f conftest conftest.o conftest.c
17342
17343 fi
17344
17345 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
17346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17347 $as_echo "yes" >&6; }
17348 :
17349 CFLAGS="$CFLAGS -mt"
17350 else
17351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17352 $as_echo "no" >&6; }
17353 :
17354 CFLAGS="$CFLAGS -D_REENTRANT"
17355 fi
17356
17357                 ub_have_sol_threads=yes
17358
17359 else
17360
17361                 as_fn_error $? "no solaris threads found." "$LINENO" 5
17362
17363 fi
17364
17365         fi
17366 fi
17367
17368 fi # end of non-mingw check of thread libraries
17369
17370 # Check for SYSLOG_FACILITY
17371
17372 # Check whether --with-syslog-facility was given.
17373 if test "${with_syslog_facility+set}" = set; then :
17374   withval=$with_syslog_facility;  UNBOUND_SYSLOG_FACILITY="$withval"
17375 fi
17376
17377 case "${UNBOUND_SYSLOG_FACILITY}" in
17378
17379   LOCAL[0-7]) UNBOUND_SYSLOG_FACILITY="LOG_${UNBOUND_SYSLOG_FACILITY}" ;;
17380
17381            *) UNBOUND_SYSLOG_FACILITY="LOG_DAEMON" ;;
17382
17383 esac
17384
17385 cat >>confdefs.h <<_ACEOF
17386 #define UB_SYSLOG_FACILITY ${UNBOUND_SYSLOG_FACILITY}
17387 _ACEOF
17388
17389
17390 # Check for dynamic library module
17391
17392 # Check whether --with-dynlibmodule was given.
17393 if test "${with_dynlibmodule+set}" = set; then :
17394   withval=$with_dynlibmodule;
17395 else
17396    withval="no"
17397 fi
17398
17399
17400 if test x_$withval != x_no; then
17401
17402 $as_echo "#define WITH_DYNLIBMODULE 1" >>confdefs.h
17403
17404   WITH_DYNLIBMODULE=yes
17405
17406   DYNLIBMOD_OBJ="dynlibmod.lo"
17407
17408   DYNLIBMOD_HEADER='$(srcdir)/dynlibmod/dynlibmod.h'
17409
17410   if test $on_mingw = "no"; then
17411     # link with -ldl if not already there, for all executables because
17412     # dlopen call is in the dynlib module.  For unbound executable, also
17413     # export symbols.
17414     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
17415 $as_echo_n "checking for library containing dlopen... " >&6; }
17416 if ${ac_cv_search_dlopen+:} false; then :
17417   $as_echo_n "(cached) " >&6
17418 else
17419   ac_func_search_save_LIBS=$LIBS
17420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17421 /* end confdefs.h.  */
17422
17423 /* Override any GCC internal prototype to avoid an error.
17424    Use char because int might match the return type of a GCC
17425    builtin and then its argument prototype would still apply.  */
17426 #ifdef __cplusplus
17427 extern "C"
17428 #endif
17429 char dlopen ();
17430 int
17431 main ()
17432 {
17433 return dlopen ();
17434   ;
17435   return 0;
17436 }
17437 _ACEOF
17438 for ac_lib in '' dl; do
17439   if test -z "$ac_lib"; then
17440     ac_res="none required"
17441   else
17442     ac_res=-l$ac_lib
17443     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17444   fi
17445   if ac_fn_c_try_link "$LINENO"; then :
17446   ac_cv_search_dlopen=$ac_res
17447 fi
17448 rm -f core conftest.err conftest.$ac_objext \
17449     conftest$ac_exeext
17450   if ${ac_cv_search_dlopen+:} false; then :
17451   break
17452 fi
17453 done
17454 if ${ac_cv_search_dlopen+:} false; then :
17455
17456 else
17457   ac_cv_search_dlopen=no
17458 fi
17459 rm conftest.$ac_ext
17460 LIBS=$ac_func_search_save_LIBS
17461 fi
17462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
17463 $as_echo "$ac_cv_search_dlopen" >&6; }
17464 ac_res=$ac_cv_search_dlopen
17465 if test "$ac_res" != no; then :
17466   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17467
17468 fi
17469
17470     DYNLIBMOD_EXTRALIBS="-export-dynamic"
17471   else
17472     DYNLIBMOD_EXTRALIBS="-Wl,--export-all-symbols,--out-implib,libunbound.dll.a"
17473   fi
17474
17475 fi
17476
17477 # Check for PyUnbound
17478
17479 # Check whether --with-pyunbound was given.
17480 if test "${with_pyunbound+set}" = set; then :
17481   withval=$with_pyunbound;
17482 else
17483    withval="no"
17484 fi
17485
17486
17487 ub_test_python=no
17488 ub_with_pyunbound=no
17489 if test x_$withval != x_no; then
17490    ub_with_pyunbound=yes
17491    ub_test_python=yes
17492 fi
17493
17494 # Check for Python module
17495
17496 # Check whether --with-pythonmodule was given.
17497 if test "${with_pythonmodule+set}" = set; then :
17498   withval=$with_pythonmodule;
17499 else
17500    withval="no"
17501 fi
17502
17503
17504 ub_with_pythonmod=no
17505 if test x_$withval != x_no; then
17506    ub_with_pythonmod=yes
17507    ub_test_python=yes
17508 fi
17509
17510 # Check for Python & SWIG only on PyUnbound or PyModule
17511 if test x_$ub_test_python != x_no; then
17512
17513    # Check for Python
17514    ub_have_python=no
17515    ac_save_LIBS="$LIBS"
17516         #
17517         # Allow the use of a (user set) custom python version
17518         #
17519
17520
17521         # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
17522 set dummy python$PYTHON_VERSION; ac_word=$2
17523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17524 $as_echo_n "checking for $ac_word... " >&6; }
17525 if ${ac_cv_path_PYTHON+:} false; then :
17526   $as_echo_n "(cached) " >&6
17527 else
17528   case $PYTHON in
17529   [\\/]* | ?:[\\/]*)
17530   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
17531   ;;
17532   *)
17533   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17534 for as_dir in $PATH
17535 do
17536   IFS=$as_save_IFS
17537   test -z "$as_dir" && as_dir=.
17538     for ac_exec_ext in '' $ac_executable_extensions; do
17539   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17540     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
17541     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17542     break 2
17543   fi
17544 done
17545   done
17546 IFS=$as_save_IFS
17547
17548   ;;
17549 esac
17550 fi
17551 PYTHON=$ac_cv_path_PYTHON
17552 if test -n "$PYTHON"; then
17553   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
17554 $as_echo "$PYTHON" >&6; }
17555 else
17556   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17557 $as_echo "no" >&6; }
17558 fi
17559
17560
17561         if test -z "$PYTHON"; then
17562            as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
17563            PYTHON_VERSION=""
17564         fi
17565
17566         if test -z "$PYTHON_VERSION"; then
17567                 PYTHON_VERSION=`$PYTHON -c "import sys; \
17568                         print(sys.version.split()[0])"`
17569         fi
17570         # calculate the version number components.
17571
17572         v="$PYTHON_VERSION"
17573         PYTHON_VERSION_MAJOR=`echo $v | sed 's/[^0-9].*//'`
17574         if test -z "$PYTHON_VERSION_MAJOR"; then PYTHON_VERSION_MAJOR="0"; fi
17575         v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'`
17576         PYTHON_VERSION_MINOR=`echo $v | sed 's/[^0-9].*//'`
17577         if test -z "$PYTHON_VERSION_MINOR"; then PYTHON_VERSION_MINOR="0"; fi
17578         v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'`
17579         PYTHON_VERSION_PATCH=`echo $v | sed 's/[^0-9].*//'`
17580         if test -z "$PYTHON_VERSION_PATCH"; then PYTHON_VERSION_PATCH="0"; fi
17581
17582
17583         # For some systems, sysconfig exists, but has the wrong paths,
17584         # on Debian 10, for python 2.7 and 3.7. So, we check the version,
17585         # and for older versions try distutils.sysconfig first. For newer
17586         # versions>=3.10, where distutils.sysconfig is deprecated, use
17587         # sysconfig first and then attempt the other one.
17588         py_distutils_first="no"
17589         if test $PYTHON_VERSION_MAJOR -lt 3; then
17590                 py_distutils_first="yes"
17591         fi
17592         if test $PYTHON_VERSION_MAJOR -eq 3 -a $PYTHON_VERSION_MINOR -lt 10; then
17593                 py_distutils_first="yes"
17594         fi
17595
17596         # Check if you have the first module
17597         if test "$py_distutils_first" = "yes"; then m="distutils"; else m="sysconfig"; fi
17598         sysconfig_module=""
17599         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the $m Python module" >&5
17600 $as_echo_n "checking for the $m Python module... " >&6; }
17601         if ac_modulecheck_result1=`$PYTHON -c "import $m" 2>&1`; then
17602                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17603 $as_echo "yes" >&6; }
17604                 sysconfig_module="$m"
17605         else
17606                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17607 $as_echo "no" >&6; }
17608         fi
17609
17610         # if not found, try the other one.
17611         if test -z "$sysconfig_module"; then
17612                 if test "$py_distutils_first" = "yes"; then m2="sysconfig"; else m2="distutils"; fi
17613                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the $m2 Python module" >&5
17614 $as_echo_n "checking for the $m2 Python module... " >&6; }
17615                 if ac_modulecheck_result2=`$PYTHON -c "import $m2" 2>&1`; then
17616                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17617 $as_echo "yes" >&6; }
17618                         sysconfig_module="$m2"
17619                 else
17620                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17621 $as_echo "no" >&6; }
17622                         as_fn_error $? "cannot import Python module \"$m\", or \"$m2\".
17623         Please check your Python installation. The errors are:
17624         $m
17625         $ac_modulecheck_result1
17626         $m2
17627         $ac_modulecheck_result2" "$LINENO" 5
17628                         PYTHON_VERSION=""
17629                 fi
17630         fi
17631         if test "$sysconfig_module" = "distutils"; then sysconfig_module="distutils.sysconfig"; fi
17632
17633         #
17634         # Check for Python include path
17635         #
17636         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
17637 $as_echo_n "checking for Python include path... " >&6; }
17638         if test -z "$PYTHON_CPPFLAGS"; then
17639                 if test "$sysconfig_module" = "sysconfig"; then
17640                         python_path=`$PYTHON -c 'import sysconfig; \
17641                                 print(sysconfig.get_path("include"));'`
17642                 else
17643                         python_path=`$PYTHON -c "import distutils.sysconfig; \
17644                                 print(distutils.sysconfig.get_python_inc());"`
17645                 fi
17646                 if test -n "${python_path}"; then
17647                         python_path="-I$python_path"
17648                 fi
17649                 PYTHON_CPPFLAGS=$python_path
17650         fi
17651         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
17652 $as_echo "$PYTHON_CPPFLAGS" >&6; }
17653
17654
17655         #
17656         # Check for Python library path
17657         #
17658         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
17659 $as_echo_n "checking for Python library path... " >&6; }
17660         if test -z "$PYTHON_LDFLAGS"; then
17661                 PYTHON_LDFLAGS=`$PYTHON -c "from $sysconfig_module import *; \
17662                         print('-L'+get_config_var('LIBDIR')+' -L'+get_config_var('LIBDEST')+' '+get_config_var('BLDLIBRARY'));"`
17663         fi
17664         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
17665 $as_echo "$PYTHON_LDFLAGS" >&6; }
17666
17667
17668         if test -z "$PYTHON_LIBDIR"; then
17669                 PYTHON_LIBDIR=`$PYTHON -c "from $sysconfig_module import *; \
17670                         print(get_config_var('LIBDIR'));"`
17671         fi
17672
17673         #
17674         # Check for site packages
17675         #
17676         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
17677 $as_echo_n "checking for Python site-packages path... " >&6; }
17678         if test -z "$PYTHON_SITE_PKG"; then
17679                 if test "$sysconfig_module" = "sysconfig"; then
17680                         PYTHON_SITE_PKG=`$PYTHON -c 'import sysconfig; \
17681                                 print(sysconfig.get_path("platlib"));'`
17682                 else
17683                         PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
17684                                 print(distutils.sysconfig.get_python_lib(1,0));"`
17685                 fi
17686         fi
17687         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
17688 $as_echo "$PYTHON_SITE_PKG" >&6; }
17689
17690
17691         #
17692         # final check to see if everything compiles alright
17693         #
17694         { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
17695 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
17696         ac_ext=c
17697 ac_cpp='$CPP $CPPFLAGS'
17698 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17699 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17700 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17701
17702         # save current global flags
17703         ac_save_LIBS="$LIBS"
17704         ac_save_CPPFLAGS="$CPPFLAGS"
17705
17706         LIBS="$LIBS $PYTHON_LDFLAGS"
17707         CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17708         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17709 /* end confdefs.h.  */
17710
17711                 #include <Python.h>
17712
17713 int
17714 main ()
17715 {
17716
17717                 Py_Initialize();
17718
17719   ;
17720   return 0;
17721 }
17722 _ACEOF
17723 if ac_fn_c_try_link "$LINENO"; then :
17724   pythonexists=yes
17725 else
17726   pythonexists=no
17727 fi
17728 rm -f core conftest.err conftest.$ac_objext \
17729     conftest$ac_exeext conftest.$ac_ext
17730
17731         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
17732 $as_echo "$pythonexists" >&6; }
17733
17734         if test ! "$pythonexists" = "yes"; then
17735            as_fn_error $? "
17736   Could not link test program to Python. Maybe the main Python library has been
17737   installed in some non-standard library path. If so, pass it to configure,
17738   via the LDFLAGS environment variable.
17739   Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
17740   ============================================================================
17741    ERROR!
17742    You probably have to install the development version of the Python package
17743    for your distribution.  The exact name of this package varies among them.
17744   ============================================================================
17745            " "$LINENO" 5
17746           PYTHON_VERSION=""
17747         fi
17748         ac_ext=c
17749 ac_cpp='$CPP $CPPFLAGS'
17750 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17751 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17752 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17753
17754         # turn back to default flags
17755         CPPFLAGS="$ac_save_CPPFLAGS"
17756         LIBS="$ac_save_LIBS"
17757
17758         #
17759         # all done!
17760         #
17761
17762    if test ! -z "$PYTHON_VERSION"; then
17763         badversion="no"
17764         if test "$PYTHON_VERSION_MAJOR" -lt 2; then
17765                 badversion="yes"
17766         fi
17767         if test "$PYTHON_VERSION_MAJOR" -eq 2 -a "$PYTHON_VERSION_MINOR" -lt 4; then
17768                 badversion="yes"
17769         fi
17770         if test "$badversion" = "yes"; then
17771                 as_fn_error $? "Python version >= 2.4.0 is required" "$LINENO" 5
17772         fi
17773
17774       PY_MAJOR_VERSION="`$PYTHON -c \"import sys; print(sys.version_info[0])\"`"
17775
17776       # Have Python
17777
17778 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
17779
17780       if test x_$ub_with_pythonmod != x_no; then
17781         if test -n "$LIBS"; then
17782           LIBS="$PYTHON_LDFLAGS $LIBS"
17783         else
17784           LIBS="$PYTHON_LDFLAGS"
17785         fi
17786       fi
17787       PYTHON_LIBS="$PYTHON_LDFLAGS"
17788
17789       if test -n "$CPPFLAGS"; then
17790         CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17791       else
17792         CPPFLAGS="$PYTHON_CPPFLAGS"
17793       fi
17794       if test "$PYTHON_LIBDIR" != "/usr/lib" -a "$PYTHON_LIBDIR" != "" -a "$PYTHON_LIBDIR" != "/usr/lib64"; then
17795
17796         if test "x$enable_rpath" = xyes; then
17797                 if echo "$PYTHON_LIBDIR" | grep "^/" >/dev/null; then
17798                         RUNTIME_PATH="$RUNTIME_PATH -R$PYTHON_LIBDIR"
17799                 fi
17800         fi
17801
17802       fi
17803       ub_have_python=yes
17804       if test -n "$PKG_CONFIG" && \
17805     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"python\${PY_MAJOR_VERSION}\"\""; } >&5
17806   ($PKG_CONFIG --exists --print-errors ""python${PY_MAJOR_VERSION}"") 2>&5
17807   ac_status=$?
17808   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17809   test $ac_status = 0; }; then
17810   PC_PY_DEPENDENCY="python${PY_MAJOR_VERSION}"
17811 else
17812   PC_PY_DEPENDENCY="python"
17813 fi
17814
17815
17816       # Check for SWIG
17817       ub_have_swig=no
17818       # Check whether --enable-swig-version-check was given.
17819 if test "${enable_swig_version_check+set}" = set; then :
17820   enableval=$enable_swig_version_check;
17821 fi
17822
17823       if test "$enable_swig_version_check" = "yes"; then
17824
17825         # Extract the first word of "swig", so it can be a program name with args.
17826 set dummy swig; ac_word=$2
17827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17828 $as_echo_n "checking for $ac_word... " >&6; }
17829 if ${ac_cv_path_SWIG+:} false; then :
17830   $as_echo_n "(cached) " >&6
17831 else
17832   case $SWIG in
17833   [\\/]* | ?:[\\/]*)
17834   ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17835   ;;
17836   *)
17837   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17838 for as_dir in $PATH
17839 do
17840   IFS=$as_save_IFS
17841   test -z "$as_dir" && as_dir=.
17842     for ac_exec_ext in '' $ac_executable_extensions; do
17843   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17844     ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17845     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17846     break 2
17847   fi
17848 done
17849   done
17850 IFS=$as_save_IFS
17851
17852   ;;
17853 esac
17854 fi
17855 SWIG=$ac_cv_path_SWIG
17856 if test -n "$SWIG"; then
17857   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17858 $as_echo "$SWIG" >&6; }
17859 else
17860   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17861 $as_echo "no" >&6; }
17862 fi
17863
17864
17865         if test -z "$SWIG" ; then
17866                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17867 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17868                 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17869         elif test -n "2.0.1" ; then
17870                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17871 $as_echo_n "checking for SWIG version... " >&6; }
17872                 swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`
17873                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17874 $as_echo "$swig_version" >&6; }
17875                 if test -n "$swig_version" ; then
17876                         # Calculate the required version number components
17877                         required=2.0.1
17878                         required_major=`echo $required | sed 's/[^0-9].*//'`
17879                         if test -z "$required_major" ; then
17880                                 required_major=0
17881                         fi
17882                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17883                         required_minor=`echo $required | sed 's/[^0-9].*//'`
17884                         if test -z "$required_minor" ; then
17885                                 required_minor=0
17886                         fi
17887                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17888                         required_patch=`echo $required | sed 's/[^0-9].*//'`
17889                         if test -z "$required_patch" ; then
17890                                 required_patch=0
17891                         fi
17892                         # Calculate the available version number components
17893                         available=$swig_version
17894                         available_major=`echo $available | sed 's/[^0-9].*//'`
17895                         if test -z "$available_major" ; then
17896                                 available_major=0
17897                         fi
17898                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17899                         available_minor=`echo $available | sed 's/[^0-9].*//'`
17900                         if test -z "$available_minor" ; then
17901                                 available_minor=0
17902                         fi
17903                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17904                         available_patch=`echo $available | sed 's/[^0-9].*//'`
17905                         if test -z "$available_patch" ; then
17906                                 available_patch=0
17907                         fi
17908                         badversion=0
17909                         if test $available_major -lt $required_major ; then
17910                                 badversion=1
17911                         fi
17912                         if test $available_major -eq $required_major \
17913                                 -a $available_minor -lt $required_minor ; then
17914                                 badversion=1
17915                         fi
17916                         if test $available_major -eq $required_major \
17917                                 -a $available_minor -eq $required_minor \
17918                                 -a $available_patch -lt $required_patch ; then
17919                                 badversion=1
17920                         fi
17921                         if test $badversion -eq 1 ; then
17922                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= 2.0.1 is required.  You have $swig_version.  You should look at http://www.swig.org" >&5
17923 $as_echo "$as_me: WARNING: SWIG version >= 2.0.1 is required.  You have $swig_version.  You should look at http://www.swig.org" >&2;}
17924                                 SWIG='echo "Error: SWIG version >= 2.0.1 is required.  You have '"$swig_version"'.  You should look at http://www.swig.org" ; false'
17925                         else
17926                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
17927 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
17928                                 SWIG_LIB=`$SWIG -swiglib`
17929                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
17930 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
17931                         fi
17932                 else
17933                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
17934 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
17935                         SWIG='echo "Error: Cannot determine SWIG version.  You should look at http://www.swig.org" ; false'
17936                 fi
17937         fi
17938
17939
17940       else
17941
17942         # Extract the first word of "swig", so it can be a program name with args.
17943 set dummy swig; ac_word=$2
17944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17945 $as_echo_n "checking for $ac_word... " >&6; }
17946 if ${ac_cv_path_SWIG+:} false; then :
17947   $as_echo_n "(cached) " >&6
17948 else
17949   case $SWIG in
17950   [\\/]* | ?:[\\/]*)
17951   ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17952   ;;
17953   *)
17954   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17955 for as_dir in $PATH
17956 do
17957   IFS=$as_save_IFS
17958   test -z "$as_dir" && as_dir=.
17959     for ac_exec_ext in '' $ac_executable_extensions; do
17960   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17961     ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17962     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17963     break 2
17964   fi
17965 done
17966   done
17967 IFS=$as_save_IFS
17968
17969   ;;
17970 esac
17971 fi
17972 SWIG=$ac_cv_path_SWIG
17973 if test -n "$SWIG"; then
17974   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17975 $as_echo "$SWIG" >&6; }
17976 else
17977   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17978 $as_echo "no" >&6; }
17979 fi
17980
17981
17982         if test -z "$SWIG" ; then
17983                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17984 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17985                 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17986         elif test -n "" ; then
17987                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17988 $as_echo_n "checking for SWIG version... " >&6; }
17989                 swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`
17990                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17991 $as_echo "$swig_version" >&6; }
17992                 if test -n "$swig_version" ; then
17993                         # Calculate the required version number components
17994                         required=
17995                         required_major=`echo $required | sed 's/[^0-9].*//'`
17996                         if test -z "$required_major" ; then
17997                                 required_major=0
17998                         fi
17999                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
18000                         required_minor=`echo $required | sed 's/[^0-9].*//'`
18001                         if test -z "$required_minor" ; then
18002                                 required_minor=0
18003                         fi
18004                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
18005                         required_patch=`echo $required | sed 's/[^0-9].*//'`
18006                         if test -z "$required_patch" ; then
18007                                 required_patch=0
18008                         fi
18009                         # Calculate the available version number components
18010                         available=$swig_version
18011                         available_major=`echo $available | sed 's/[^0-9].*//'`
18012                         if test -z "$available_major" ; then
18013                                 available_major=0
18014                         fi
18015                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
18016                         available_minor=`echo $available | sed 's/[^0-9].*//'`
18017                         if test -z "$available_minor" ; then
18018                                 available_minor=0
18019                         fi
18020                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
18021                         available_patch=`echo $available | sed 's/[^0-9].*//'`
18022                         if test -z "$available_patch" ; then
18023                                 available_patch=0
18024                         fi
18025                         badversion=0
18026                         if test $available_major -lt $required_major ; then
18027                                 badversion=1
18028                         fi
18029                         if test $available_major -eq $required_major \
18030                                 -a $available_minor -lt $required_minor ; then
18031                                 badversion=1
18032                         fi
18033                         if test $available_major -eq $required_major \
18034                                 -a $available_minor -eq $required_minor \
18035                                 -a $available_patch -lt $required_patch ; then
18036                                 badversion=1
18037                         fi
18038                         if test $badversion -eq 1 ; then
18039                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >=  is required.  You have $swig_version.  You should look at http://www.swig.org" >&5
18040 $as_echo "$as_me: WARNING: SWIG version >=  is required.  You have $swig_version.  You should look at http://www.swig.org" >&2;}
18041                                 SWIG='echo "Error: SWIG version >=  is required.  You have '"$swig_version"'.  You should look at http://www.swig.org" ; false'
18042                         else
18043                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
18044 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
18045                                 SWIG_LIB=`$SWIG -swiglib`
18046                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
18047 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
18048                         fi
18049                 else
18050                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
18051 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
18052                         SWIG='echo "Error: Cannot determine SWIG version.  You should look at http://www.swig.org" ; false'
18053                 fi
18054         fi
18055
18056
18057       fi
18058       { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG" >&5
18059 $as_echo_n "checking SWIG... " >&6; }
18060       if test ! -x "$SWIG"; then
18061          as_fn_error $? "failed to find swig tool, install it, or do not build Python module and PyUnbound" "$LINENO" 5
18062       else
18063
18064 $as_echo "#define HAVE_SWIG 1" >>confdefs.h
18065
18066          swig="$SWIG"
18067
18068          { $as_echo "$as_me:${as_lineno-$LINENO}: result: present" >&5
18069 $as_echo "present" >&6; }
18070
18071          # If have Python & SWIG
18072          # Declare PythonMod
18073          if test x_$ub_with_pythonmod != x_no; then
18074
18075 $as_echo "#define WITH_PYTHONMODULE 1" >>confdefs.h
18076
18077             WITH_PYTHONMODULE=yes
18078
18079             PYTHONMOD_OBJ="pythonmod.lo pythonmod_utils.lo"
18080
18081             PYTHONMOD_HEADER='$(srcdir)/pythonmod/pythonmod.h'
18082
18083             PYTHONMOD_INSTALL=pythonmod-install
18084
18085             PYTHONMOD_UNINSTALL=pythonmod-uninstall
18086
18087          fi
18088
18089          # Declare PyUnbound
18090          if test x_$ub_with_pyunbound != x_no; then
18091
18092 $as_echo "#define WITH_PYUNBOUND 1" >>confdefs.h
18093
18094             WITH_PYUNBOUND=yes
18095
18096             PYUNBOUND_OBJ="libunbound_wrap.lo"
18097
18098             PYUNBOUND_TARGET="_unbound.la"
18099
18100             PYUNBOUND_INSTALL=pyunbound-install
18101
18102             PYUNBOUND_UNINSTALL=pyunbound-uninstall
18103
18104          fi
18105       fi
18106    else
18107       { $as_echo "$as_me:${as_lineno-$LINENO}: result: *** Python libraries not found, won't build PythonMod or PyUnbound ***" >&5
18108 $as_echo "*** Python libraries not found, won't build PythonMod or PyUnbound ***" >&6; }
18109       ub_with_pyunbound=no
18110       ub_with_pythonmod=no
18111    fi
18112 fi
18113
18114 if test "`uname`" = "NetBSD"; then
18115         NETBSD_LINTFLAGS='"-D__RENAME(x)=" -D_NETINET_IN_H_'
18116
18117 fi
18118
18119 if test "`uname`" = "Linux"; then
18120         # splint cannot parse modern c99 header files
18121         GCC_DOCKER_LINTFLAGS='-syntax'
18122
18123 fi
18124 CONFIG_DATE=`date +%Y%m%d`
18125
18126
18127 # Checks for libraries.
18128
18129 # libnss
18130 USE_NSS="no"
18131
18132 # Check whether --with-nss was given.
18133 if test "${with_nss+set}" = set; then :
18134   withval=$with_nss;
18135         USE_NSS="yes"
18136
18137 $as_echo "#define HAVE_NSS 1" >>confdefs.h
18138
18139         if test "$withval" != "" -a "$withval" != "yes"; then
18140                 CPPFLAGS="$CPPFLAGS -I$withval/include/nss3"
18141                 LDFLAGS="$LDFLAGS -L$withval/lib"
18142
18143         if test "x$enable_rpath" = xyes; then
18144                 if echo "$withval/lib" | grep "^/" >/dev/null; then
18145                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
18146                 fi
18147         fi
18148
18149                 CPPFLAGS="-I$withval/include/nspr4 $CPPFLAGS"
18150         else
18151                 CPPFLAGS="$CPPFLAGS -I/usr/include/nss3"
18152                 CPPFLAGS="-I/usr/include/nspr4 $CPPFLAGS"
18153         fi
18154         LIBS="$LIBS -lnss3 -lnspr4"
18155         SSLLIB=""
18156         PC_CRYPTO_DEPENDENCY="nss nspr"
18157
18158
18159
18160 fi
18161
18162
18163 # libnettle
18164 USE_NETTLE="no"
18165
18166 # Check whether --with-nettle was given.
18167 if test "${with_nettle+set}" = set; then :
18168   withval=$with_nettle;
18169         USE_NETTLE="yes"
18170
18171 $as_echo "#define HAVE_NETTLE 1" >>confdefs.h
18172
18173         for ac_header in nettle/dsa-compat.h
18174 do :
18175   ac_fn_c_check_header_compile "$LINENO" "nettle/dsa-compat.h" "ac_cv_header_nettle_dsa_compat_h" "$ac_includes_default
18176 "
18177 if test "x$ac_cv_header_nettle_dsa_compat_h" = xyes; then :
18178   cat >>confdefs.h <<_ACEOF
18179 #define HAVE_NETTLE_DSA_COMPAT_H 1
18180 _ACEOF
18181
18182 fi
18183
18184 done
18185
18186         if test "$withval" != "" -a "$withval" != "yes"; then
18187                 CPPFLAGS="$CPPFLAGS -I$withval/include/nettle"
18188                 LDFLAGS="$LDFLAGS -L$withval/lib"
18189
18190         if test "x$enable_rpath" = xyes; then
18191                 if echo "$withval/lib" | grep "^/" >/dev/null; then
18192                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
18193                 fi
18194         fi
18195
18196         else
18197                 CPPFLAGS="$CPPFLAGS -I/usr/include/nettle"
18198         fi
18199         LIBS="$LIBS -lhogweed -lnettle -lgmp"
18200         SSLLIB=""
18201         PC_CRYPTO_DEPENDENCY="hogweed nettle"
18202
18203
18204
18205 fi
18206
18207
18208 # openssl
18209 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18210
18211
18212 # Check whether --with-ssl was given.
18213 if test "${with_ssl+set}" = set; then :
18214   withval=$with_ssl;
18215
18216 else
18217
18218             withval="yes"
18219
18220 fi
18221
18222     if test x_$withval = x_no; then
18223         as_fn_error $? "Need SSL library to do digital signature cryptography" "$LINENO" 5
18224     fi
18225
18226     withval=$withval
18227     if test x_$withval != x_no; then
18228         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL" >&5
18229 $as_echo_n "checking for SSL... " >&6; }
18230         if test -n "$withval"; then
18231                                                                                 if test ! -f "$withval/include/openssl/ssl.h" -a -f "$withval/openssl/ssl.h"; then
18232                         ssldir="$withval"
18233                         found_ssl="yes"
18234                         withval=""
18235                         ssldir_include="$ssldir"
18236                                                 ssldir_lib=`echo $ssldir | sed -e 's/include/lib/'`
18237                         if test -f "$ssldir_lib/libssl.a" -o -f "$ssldir_lib/libssl.so"; then
18238                                 : # found here
18239                         else
18240                                 ssldir_lib=`echo $ssldir | sed -e 's/include/lib64/'`
18241                                 if test -f "$ssldir_lib/libssl.a" -o -f "$ssldir_lib/libssl.so"; then
18242                                         : # found here
18243                                 else
18244                                         as_fn_error $? "Could not find openssl lib file, $ssldir_lib/libssl.so,a, pass like \"/usr/local\" or \"/usr/include/openssl11\"" "$LINENO" 5
18245                                 fi
18246                         fi
18247                 fi
18248         fi
18249         if test x_$withval = x_ -o x_$withval = x_yes; then
18250             withval="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw /usr"
18251         fi
18252         for dir in $withval; do
18253             ssldir="$dir"
18254             if test -f "$dir/include/openssl/ssl.h"; then
18255                 found_ssl="yes"
18256                 ssldir_include="$ssldir/include"
18257                 if test ! -d "$ssldir/lib" -a -d "$ssldir/lib64"; then
18258                         ssldir_lib="$ssldir/lib64"
18259                 else
18260                         ssldir_lib="$ssldir/lib"
18261                 fi
18262                 break;
18263             fi
18264         done
18265         if test x_$found_ssl != x_yes; then
18266             as_fn_error $? "Cannot find the SSL libraries in $withval" "$LINENO" 5
18267         else
18268             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $ssldir" >&5
18269 $as_echo "found in $ssldir" >&6; }
18270
18271 cat >>confdefs.h <<_ACEOF
18272 #define HAVE_SSL /**/
18273 _ACEOF
18274
18275             HAVE_SSL=yes
18276                         if test "$ssldir" != "/usr"; then
18277                     CPPFLAGS="$CPPFLAGS -I$ssldir_include"
18278                     LIBSSL_CPPFLAGS="$LIBSSL_CPPFLAGS -I$ssldir_include"
18279                     LDFLAGS="$LDFLAGS -L$ssldir_lib"
18280                     LIBSSL_LDFLAGS="$LIBSSL_LDFLAGS -L$ssldir_lib"
18281
18282         if test "x$enable_rpath" = xyes; then
18283                 if echo "$ssldir_lib" | grep "^/" >/dev/null; then
18284                         RUNTIME_PATH="$RUNTIME_PATH -R$ssldir_lib"
18285                 fi
18286         fi
18287
18288             fi
18289
18290             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EVP_sha256 in -lcrypto" >&5
18291 $as_echo_n "checking for EVP_sha256 in -lcrypto... " >&6; }
18292             LIBS="$LIBS -lcrypto"
18293             LIBSSL_LIBS="$LIBSSL_LIBS -lcrypto"
18294             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18295 /* end confdefs.h.  */
18296
18297 int
18298 main ()
18299 {
18300
18301                 int EVP_sha256(void);
18302                 (void)EVP_sha256();
18303
18304   ;
18305   return 0;
18306 }
18307 _ACEOF
18308 if ac_fn_c_try_link "$LINENO"; then :
18309
18310                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18311 $as_echo "yes" >&6; }
18312
18313 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18314
18315
18316 else
18317
18318                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18319 $as_echo "no" >&6; }
18320                 # check if -lwsock32 or -lgdi32 are needed.
18321                 BAKLIBS="$LIBS"
18322                 BAKSSLLIBS="$LIBSSL_LIBS"
18323                 LIBS="$LIBS -lgdi32 -lws2_32"
18324                 LIBSSL_LIBS="$LIBSSL_LIBS -lgdi32 -lws2_32"
18325                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -lgdi32" >&5
18326 $as_echo_n "checking if -lcrypto needs -lgdi32... " >&6; }
18327                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18328 /* end confdefs.h.  */
18329
18330 int
18331 main ()
18332 {
18333
18334                     int EVP_sha256(void);
18335                     (void)EVP_sha256();
18336
18337   ;
18338   return 0;
18339 }
18340 _ACEOF
18341 if ac_fn_c_try_link "$LINENO"; then :
18342
18343
18344 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18345
18346                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18347 $as_echo "yes" >&6; }
18348
18349 else
18350
18351                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18352 $as_echo "no" >&6; }
18353                     LIBS="$BAKLIBS"
18354                     LIBSSL_LIBS="$BAKSSLLIBS"
18355                     LIBS="$LIBS -ldl"
18356                     LIBSSL_LIBS="$LIBSSL_LIBS -ldl"
18357                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl" >&5
18358 $as_echo_n "checking if -lcrypto needs -ldl... " >&6; }
18359                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18360 /* end confdefs.h.  */
18361
18362 int
18363 main ()
18364 {
18365
18366                         int EVP_sha256(void);
18367                         (void)EVP_sha256();
18368
18369   ;
18370   return 0;
18371 }
18372 _ACEOF
18373 if ac_fn_c_try_link "$LINENO"; then :
18374
18375
18376 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18377
18378                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18379 $as_echo "yes" >&6; }
18380
18381 else
18382
18383                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18384 $as_echo "no" >&6; }
18385                         LIBS="$BAKLIBS"
18386                         LIBSSL_LIBS="$BAKSSLLIBS"
18387                         LIBS="$LIBS -ldl -pthread"
18388                         LIBSSL_LIBS="$LIBSSL_LIBS -ldl -pthread"
18389                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl -pthread" >&5
18390 $as_echo_n "checking if -lcrypto needs -ldl -pthread... " >&6; }
18391                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18392 /* end confdefs.h.  */
18393
18394 int
18395 main ()
18396 {
18397
18398                             int EVP_sha256(void);
18399                             (void)EVP_sha256();
18400
18401   ;
18402   return 0;
18403 }
18404 _ACEOF
18405 if ac_fn_c_try_link "$LINENO"; then :
18406
18407
18408 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18409
18410                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18411 $as_echo "yes" >&6; }
18412
18413 else
18414
18415                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18416 $as_echo "no" >&6; }
18417                             as_fn_error $? "OpenSSL found in $ssldir, but version 0.9.7 or higher is required" "$LINENO" 5
18418
18419 fi
18420 rm -f core conftest.err conftest.$ac_objext \
18421     conftest$ac_exeext conftest.$ac_ext
18422
18423 fi
18424 rm -f core conftest.err conftest.$ac_objext \
18425     conftest$ac_exeext conftest.$ac_ext
18426
18427 fi
18428 rm -f core conftest.err conftest.$ac_objext \
18429     conftest$ac_exeext conftest.$ac_ext
18430
18431 fi
18432 rm -f core conftest.err conftest.$ac_objext \
18433     conftest$ac_exeext conftest.$ac_ext
18434         fi
18435
18436
18437     fi
18438 for ac_header in openssl/ssl.h
18439 do :
18440   ac_fn_c_check_header_compile "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default
18441 "
18442 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
18443   cat >>confdefs.h <<_ACEOF
18444 #define HAVE_OPENSSL_SSL_H 1
18445 _ACEOF
18446
18447 fi
18448
18449 done
18450
18451 for ac_header in openssl/err.h
18452 do :
18453   ac_fn_c_check_header_compile "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default
18454 "
18455 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
18456   cat >>confdefs.h <<_ACEOF
18457 #define HAVE_OPENSSL_ERR_H 1
18458 _ACEOF
18459
18460 fi
18461
18462 done
18463
18464 for ac_header in openssl/rand.h
18465 do :
18466   ac_fn_c_check_header_compile "$LINENO" "openssl/rand.h" "ac_cv_header_openssl_rand_h" "$ac_includes_default
18467 "
18468 if test "x$ac_cv_header_openssl_rand_h" = xyes; then :
18469   cat >>confdefs.h <<_ACEOF
18470 #define HAVE_OPENSSL_RAND_H 1
18471 _ACEOF
18472
18473 fi
18474
18475 done
18476
18477
18478
18479
18480 # check if libssl needs libdl
18481 BAKLIBS="$LIBS"
18482 LIBS="-lssl $LIBS"
18483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs libdl" >&5
18484 $as_echo_n "checking if libssl needs libdl... " >&6; }
18485 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18486 /* end confdefs.h.  */
18487
18488 /* Override any GCC internal prototype to avoid an error.
18489    Use char because int might match the return type of a GCC
18490    builtin and then its argument prototype would still apply.  */
18491 #ifdef __cplusplus
18492 extern "C"
18493 #endif
18494 char SSL_CTX_new ();
18495 int
18496 main ()
18497 {
18498 return SSL_CTX_new ();
18499   ;
18500   return 0;
18501 }
18502 _ACEOF
18503 if ac_fn_c_try_link "$LINENO"; then :
18504
18505         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18506 $as_echo "no" >&6; }
18507         LIBS="$BAKLIBS"
18508
18509 else
18510
18511         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18512 $as_echo "yes" >&6; }
18513         LIBS="$BAKLIBS"
18514         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
18515 $as_echo_n "checking for library containing dlopen... " >&6; }
18516 if ${ac_cv_search_dlopen+:} false; then :
18517   $as_echo_n "(cached) " >&6
18518 else
18519   ac_func_search_save_LIBS=$LIBS
18520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18521 /* end confdefs.h.  */
18522
18523 /* Override any GCC internal prototype to avoid an error.
18524    Use char because int might match the return type of a GCC
18525    builtin and then its argument prototype would still apply.  */
18526 #ifdef __cplusplus
18527 extern "C"
18528 #endif
18529 char dlopen ();
18530 int
18531 main ()
18532 {
18533 return dlopen ();
18534   ;
18535   return 0;
18536 }
18537 _ACEOF
18538 for ac_lib in '' dl; do
18539   if test -z "$ac_lib"; then
18540     ac_res="none required"
18541   else
18542     ac_res=-l$ac_lib
18543     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18544   fi
18545   if ac_fn_c_try_link "$LINENO"; then :
18546   ac_cv_search_dlopen=$ac_res
18547 fi
18548 rm -f core conftest.err conftest.$ac_objext \
18549     conftest$ac_exeext
18550   if ${ac_cv_search_dlopen+:} false; then :
18551   break
18552 fi
18553 done
18554 if ${ac_cv_search_dlopen+:} false; then :
18555
18556 else
18557   ac_cv_search_dlopen=no
18558 fi
18559 rm conftest.$ac_ext
18560 LIBS=$ac_func_search_save_LIBS
18561 fi
18562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
18563 $as_echo "$ac_cv_search_dlopen" >&6; }
18564 ac_res=$ac_cv_search_dlopen
18565 if test "$ac_res" != no; then :
18566   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18567
18568 fi
18569
18570
18571 fi
18572 rm -f core conftest.err conftest.$ac_objext \
18573     conftest$ac_exeext conftest.$ac_ext
18574 SSLLIB="-lssl"
18575
18576 PC_CRYPTO_DEPENDENCY=""
18577
18578
18579 # check if -lcrypt32 is needed because CAPIENG needs that. (on windows)
18580 BAKLIBS="$LIBS"
18581 LIBS="-lssl $LIBS"
18582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs -lcrypt32" >&5
18583 $as_echo_n "checking if libssl needs -lcrypt32... " >&6; }
18584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18585 /* end confdefs.h.  */
18586
18587 int
18588 main ()
18589 {
18590
18591         int EVP_sha256(void);
18592         (void)EVP_sha256();
18593
18594   ;
18595   return 0;
18596 }
18597 _ACEOF
18598 if ac_fn_c_try_link "$LINENO"; then :
18599
18600         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18601 $as_echo "no" >&6; }
18602         LIBS="$BAKLIBS"
18603
18604 else
18605
18606         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18607 $as_echo "yes" >&6; }
18608         LIBS="$BAKLIBS"
18609         LIBS="$LIBS -lcrypt32"
18610
18611 fi
18612 rm -f core conftest.err conftest.$ac_objext \
18613     conftest$ac_exeext conftest.$ac_ext
18614
18615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LibreSSL" >&5
18616 $as_echo_n "checking for LibreSSL... " >&6; }
18617 if grep VERSION_TEXT $ssldir_include/openssl/opensslv.h | grep "LibreSSL" >/dev/null; then
18618         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18619 $as_echo "yes" >&6; }
18620
18621 $as_echo "#define HAVE_LIBRESSL 1" >>confdefs.h
18622
18623         # libressl provides these compat functions, but they may also be
18624         # declared by the OS in libc.  See if they have been declared.
18625         ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
18626 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
18627   ac_have_decl=1
18628 else
18629   ac_have_decl=0
18630 fi
18631
18632 cat >>confdefs.h <<_ACEOF
18633 #define HAVE_DECL_STRLCPY $ac_have_decl
18634 _ACEOF
18635 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
18636 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
18637   ac_have_decl=1
18638 else
18639   ac_have_decl=0
18640 fi
18641
18642 cat >>confdefs.h <<_ACEOF
18643 #define HAVE_DECL_STRLCAT $ac_have_decl
18644 _ACEOF
18645 ac_fn_c_check_decl "$LINENO" "arc4random" "ac_cv_have_decl_arc4random" "$ac_includes_default"
18646 if test "x$ac_cv_have_decl_arc4random" = xyes; then :
18647   ac_have_decl=1
18648 else
18649   ac_have_decl=0
18650 fi
18651
18652 cat >>confdefs.h <<_ACEOF
18653 #define HAVE_DECL_ARC4RANDOM $ac_have_decl
18654 _ACEOF
18655 ac_fn_c_check_decl "$LINENO" "arc4random_uniform" "ac_cv_have_decl_arc4random_uniform" "$ac_includes_default"
18656 if test "x$ac_cv_have_decl_arc4random_uniform" = xyes; then :
18657   ac_have_decl=1
18658 else
18659   ac_have_decl=0
18660 fi
18661
18662 cat >>confdefs.h <<_ACEOF
18663 #define HAVE_DECL_ARC4RANDOM_UNIFORM $ac_have_decl
18664 _ACEOF
18665
18666 else
18667         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18668 $as_echo "no" >&6; }
18669 fi
18670 for ac_header in openssl/conf.h openssl/engine.h openssl/bn.h openssl/dh.h openssl/dsa.h openssl/rsa.h openssl/core_names.h openssl/param_build.h
18671 do :
18672   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18673 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
18674 "
18675 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18676   cat >>confdefs.h <<_ACEOF
18677 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18678 _ACEOF
18679
18680 fi
18681
18682 done
18683
18684 for ac_func in OPENSSL_config EVP_sha1 EVP_sha256 EVP_sha512 FIPS_mode EVP_default_properties_is_fips_enabled EVP_MD_CTX_new OpenSSL_add_all_digests OPENSSL_init_crypto EVP_cleanup ENGINE_cleanup ERR_load_crypto_strings CRYPTO_cleanup_all_ex_data ERR_free_strings RAND_cleanup DSA_SIG_set0 EVP_dss1 EVP_DigestVerify EVP_aes_256_cbc EVP_EncryptInit_ex HMAC_Init_ex CRYPTO_THREADID_set_callback EVP_MAC_CTX_set_params OSSL_PARAM_BLD_new BIO_set_callback_ex
18685 do :
18686   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18687 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18688 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18689   cat >>confdefs.h <<_ACEOF
18690 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18691 _ACEOF
18692
18693 fi
18694 done
18695
18696
18697 # these check_funcs need -lssl
18698 BAKLIBS="$LIBS"
18699 LIBS="-lssl $LIBS"
18700 for ac_func in OPENSSL_init_ssl SSL_CTX_set_security_level SSL_set1_host SSL_get0_peername X509_VERIFY_PARAM_set1_host SSL_CTX_set_ciphersuites SSL_CTX_set_tlsext_ticket_key_evp_cb SSL_CTX_set_alpn_select_cb SSL_get0_alpn_selected SSL_CTX_set_alpn_protos SSL_get1_peer_certificate
18701 do :
18702   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18703 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18704 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18705   cat >>confdefs.h <<_ACEOF
18706 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18707 _ACEOF
18708
18709 fi
18710 done
18711
18712 LIBS="$BAKLIBS"
18713
18714 ac_fn_c_check_decl "$LINENO" "SSL_COMP_get_compression_methods" "ac_cv_have_decl_SSL_COMP_get_compression_methods" "
18715 $ac_includes_default
18716 #ifdef HAVE_OPENSSL_ERR_H
18717 #include <openssl/err.h>
18718 #endif
18719
18720 #ifdef HAVE_OPENSSL_RAND_H
18721 #include <openssl/rand.h>
18722 #endif
18723
18724 #ifdef HAVE_OPENSSL_CONF_H
18725 #include <openssl/conf.h>
18726 #endif
18727
18728 #ifdef HAVE_OPENSSL_ENGINE_H
18729 #include <openssl/engine.h>
18730 #endif
18731 #include <openssl/ssl.h>
18732 #include <openssl/evp.h>
18733
18734 "
18735 if test "x$ac_cv_have_decl_SSL_COMP_get_compression_methods" = xyes; then :
18736   ac_have_decl=1
18737 else
18738   ac_have_decl=0
18739 fi
18740
18741 cat >>confdefs.h <<_ACEOF
18742 #define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS $ac_have_decl
18743 _ACEOF
18744 ac_fn_c_check_decl "$LINENO" "sk_SSL_COMP_pop_free" "ac_cv_have_decl_sk_SSL_COMP_pop_free" "
18745 $ac_includes_default
18746 #ifdef HAVE_OPENSSL_ERR_H
18747 #include <openssl/err.h>
18748 #endif
18749
18750 #ifdef HAVE_OPENSSL_RAND_H
18751 #include <openssl/rand.h>
18752 #endif
18753
18754 #ifdef HAVE_OPENSSL_CONF_H
18755 #include <openssl/conf.h>
18756 #endif
18757
18758 #ifdef HAVE_OPENSSL_ENGINE_H
18759 #include <openssl/engine.h>
18760 #endif
18761 #include <openssl/ssl.h>
18762 #include <openssl/evp.h>
18763
18764 "
18765 if test "x$ac_cv_have_decl_sk_SSL_COMP_pop_free" = xyes; then :
18766   ac_have_decl=1
18767 else
18768   ac_have_decl=0
18769 fi
18770
18771 cat >>confdefs.h <<_ACEOF
18772 #define HAVE_DECL_SK_SSL_COMP_POP_FREE $ac_have_decl
18773 _ACEOF
18774 ac_fn_c_check_decl "$LINENO" "SSL_CTX_set_ecdh_auto" "ac_cv_have_decl_SSL_CTX_set_ecdh_auto" "
18775 $ac_includes_default
18776 #ifdef HAVE_OPENSSL_ERR_H
18777 #include <openssl/err.h>
18778 #endif
18779
18780 #ifdef HAVE_OPENSSL_RAND_H
18781 #include <openssl/rand.h>
18782 #endif
18783
18784 #ifdef HAVE_OPENSSL_CONF_H
18785 #include <openssl/conf.h>
18786 #endif
18787
18788 #ifdef HAVE_OPENSSL_ENGINE_H
18789 #include <openssl/engine.h>
18790 #endif
18791 #include <openssl/ssl.h>
18792 #include <openssl/evp.h>
18793
18794 "
18795 if test "x$ac_cv_have_decl_SSL_CTX_set_ecdh_auto" = xyes; then :
18796   ac_have_decl=1
18797 else
18798   ac_have_decl=0
18799 fi
18800
18801 cat >>confdefs.h <<_ACEOF
18802 #define HAVE_DECL_SSL_CTX_SET_ECDH_AUTO $ac_have_decl
18803 _ACEOF
18804
18805
18806 if test "$ac_cv_func_HMAC_Init_ex" = "yes"; then
18807 # check function return type.
18808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the return type of HMAC_Init_ex" >&5
18809 $as_echo_n "checking the return type of HMAC_Init_ex... " >&6; }
18810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18811 /* end confdefs.h.  */
18812
18813 #ifdef HAVE_OPENSSL_ERR_H
18814 #include <openssl/err.h>
18815 #endif
18816
18817 #ifdef HAVE_OPENSSL_RAND_H
18818 #include <openssl/rand.h>
18819 #endif
18820
18821 #ifdef HAVE_OPENSSL_CONF_H
18822 #include <openssl/conf.h>
18823 #endif
18824
18825 #ifdef HAVE_OPENSSL_ENGINE_H
18826 #include <openssl/engine.h>
18827 #endif
18828 #include <openssl/ssl.h>
18829 #include <openssl/evp.h>
18830
18831 int
18832 main ()
18833 {
18834
18835         HMAC_CTX* hmac_ctx = NULL;
18836         void* hmac_key = NULL;
18837         const EVP_MD* digest = NULL;
18838         int x = HMAC_Init_ex(hmac_ctx, hmac_key, 32, digest, NULL);
18839         (void)x;
18840
18841   ;
18842   return 0;
18843 }
18844 _ACEOF
18845 if ac_fn_c_try_compile "$LINENO"; then :
18846
18847         { $as_echo "$as_me:${as_lineno-$LINENO}: result: int" >&5
18848 $as_echo "int" >&6; }
18849
18850 else
18851
18852         { $as_echo "$as_me:${as_lineno-$LINENO}: result: void" >&5
18853 $as_echo "void" >&6; }
18854
18855 $as_echo "#define HMAC_INIT_EX_RETURNS_VOID 1" >>confdefs.h
18856
18857
18858 fi
18859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18860 fi
18861
18862 fi
18863
18864
18865 # libbsd
18866
18867 # Check whether --with-libbsd was given.
18868 if test "${with_libbsd+set}" = set; then :
18869   withval=$with_libbsd;
18870         for ac_header in bsd/string.h bsd/stdlib.h
18871 do :
18872   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18873 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
18874 "
18875 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18876   cat >>confdefs.h <<_ACEOF
18877 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18878 _ACEOF
18879
18880 fi
18881
18882 done
18883
18884         if test "x$ac_cv_header_bsd_string_h" = xyes -a "x$ac_cv_header_bsd_stdlib_h" = xyes; then
18885                 for func in strlcpy strlcat arc4random arc4random_uniform reallocarray; do
18886                         as_ac_Search=`$as_echo "ac_cv_search_$func" | $as_tr_sh`
18887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing $func" >&5
18888 $as_echo_n "checking for library containing $func... " >&6; }
18889 if eval \${$as_ac_Search+:} false; then :
18890   $as_echo_n "(cached) " >&6
18891 else
18892   ac_func_search_save_LIBS=$LIBS
18893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18894 /* end confdefs.h.  */
18895
18896 /* Override any GCC internal prototype to avoid an error.
18897    Use char because int might match the return type of a GCC
18898    builtin and then its argument prototype would still apply.  */
18899 #ifdef __cplusplus
18900 extern "C"
18901 #endif
18902 char $func ();
18903 int
18904 main ()
18905 {
18906 return $func ();
18907   ;
18908   return 0;
18909 }
18910 _ACEOF
18911 for ac_lib in '' bsd; do
18912   if test -z "$ac_lib"; then
18913     ac_res="none required"
18914   else
18915     ac_res=-l$ac_lib
18916     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18917   fi
18918   if ac_fn_c_try_link "$LINENO"; then :
18919   eval "$as_ac_Search=\$ac_res"
18920 fi
18921 rm -f core conftest.err conftest.$ac_objext \
18922     conftest$ac_exeext
18923   if eval \${$as_ac_Search+:} false; then :
18924   break
18925 fi
18926 done
18927 if eval \${$as_ac_Search+:} false; then :
18928
18929 else
18930   eval "$as_ac_Search=no"
18931 fi
18932 rm conftest.$ac_ext
18933 LIBS=$ac_func_search_save_LIBS
18934 fi
18935 eval ac_res=\$$as_ac_Search
18936                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18937 $as_echo "$ac_res" >&6; }
18938 eval ac_res=\$$as_ac_Search
18939 if test "$ac_res" != no; then :
18940   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18941
18942
18943 $as_echo "#define HAVE_LIBBSD 1" >>confdefs.h
18944
18945                                 PC_LIBBSD_DEPENDENCY=libbsd
18946
18947
18948 fi
18949
18950                 done
18951         fi
18952
18953 fi
18954
18955
18956 # Check whether --enable-sha1 was given.
18957 if test "${enable_sha1+set}" = set; then :
18958   enableval=$enable_sha1;
18959 fi
18960
18961 case "$enable_sha1" in
18962         no)
18963         ;;
18964         yes|*)
18965
18966 $as_echo "#define USE_SHA1 1" >>confdefs.h
18967
18968         ;;
18969 esac
18970
18971
18972 # Check whether --enable-sha2 was given.
18973 if test "${enable_sha2+set}" = set; then :
18974   enableval=$enable_sha2;
18975 fi
18976
18977 case "$enable_sha2" in
18978         no)
18979         ;;
18980         yes|*)
18981
18982 $as_echo "#define USE_SHA2 1" >>confdefs.h
18983
18984         ;;
18985 esac
18986
18987 # Check whether --enable-subnet was given.
18988 if test "${enable_subnet+set}" = set; then :
18989   enableval=$enable_subnet;
18990 fi
18991
18992 case "$enable_subnet" in
18993         yes)
18994
18995 $as_echo "#define CLIENT_SUBNET 1" >>confdefs.h
18996
18997         SUBNET_OBJ="edns-subnet.lo subnetmod.lo addrtree.lo subnet-whitelist.lo"
18998
18999         SUBNET_HEADER='$(srcdir)/edns-subnet/subnetmod.h $(srcdir)/edns-subnet/edns-subnet.h $(srcdir)/edns-subnet/subnet-whitelist.h $(srcdir)/edns-subnet/addrtree.h'
19000
19001         ;;
19002         no|*)
19003         ;;
19004 esac
19005
19006 # check whether gost also works
19007
19008 # Check whether --enable-gost was given.
19009 if test "${enable_gost+set}" = set; then :
19010   enableval=$enable_gost;
19011 fi
19012
19013 use_gost="no"
19014 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19015 case "$enable_gost" in
19016         no)
19017         ;;
19018         *)
19019         ac_fn_c_check_func "$LINENO" "EVP_PKEY_set_type_str" "ac_cv_func_EVP_PKEY_set_type_str"
19020 if test "x$ac_cv_func_EVP_PKEY_set_type_str" = xyes; then :
19021   :
19022 else
19023   as_fn_error $? "OpenSSL 1.0.0 is needed for GOST support" "$LINENO" 5
19024 fi
19025
19026         ac_fn_c_check_func "$LINENO" "EC_KEY_new" "ac_cv_func_EC_KEY_new"
19027 if test "x$ac_cv_func_EC_KEY_new" = xyes; then :
19028
19029 else
19030   as_fn_error $? "OpenSSL does not support ECC, needed for GOST support" "$LINENO" 5
19031 fi
19032
19033
19034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GOST works" >&5
19035 $as_echo_n "checking if GOST works... " >&6; }
19036 if test c${cross_compiling} = cno; then
19037 BAKCFLAGS="$CFLAGS"
19038 if test -n "$ssldir"; then
19039         CFLAGS="$CFLAGS -Wl,-rpath,$ssldir_lib"
19040 fi
19041 if test "$cross_compiling" = yes; then :
19042   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19043 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19044 as_fn_error $? "cannot run test program while cross compiling
19045 See \`config.log' for more details" "$LINENO" 5; }
19046 else
19047   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19048 /* end confdefs.h.  */
19049
19050 #include <string.h>
19051 #include <openssl/ssl.h>
19052 #include <openssl/evp.h>
19053 #include <openssl/engine.h>
19054 #include <openssl/conf.h>
19055 /* routine to load gost (from sldns) */
19056 int load_gost_id(void)
19057 {
19058         static int gost_id = 0;
19059         const EVP_PKEY_ASN1_METHOD* meth;
19060         ENGINE* e;
19061
19062         if(gost_id) return gost_id;
19063
19064         /* see if configuration loaded gost implementation from other engine*/
19065         meth = EVP_PKEY_asn1_find_str(NULL, "gost2001", -1);
19066         if(meth) {
19067                 EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
19068                 return gost_id;
19069         }
19070
19071         /* see if engine can be loaded already */
19072         e = ENGINE_by_id("gost");
19073         if(!e) {
19074                 /* load it ourself, in case statically linked */
19075                 ENGINE_load_builtin_engines();
19076                 ENGINE_load_dynamic();
19077                 e = ENGINE_by_id("gost");
19078         }
19079         if(!e) {
19080                 /* no gost engine in openssl */
19081                 return 0;
19082         }
19083         if(!ENGINE_set_default(e, ENGINE_METHOD_ALL)) {
19084                 ENGINE_finish(e);
19085                 ENGINE_free(e);
19086                 return 0;
19087         }
19088
19089         meth = EVP_PKEY_asn1_find_str(&e, "gost2001", -1);
19090         if(!meth) {
19091                 /* algo not found */
19092                 ENGINE_finish(e);
19093                 ENGINE_free(e);
19094                 return 0;
19095         }
19096         EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
19097         return gost_id;
19098 }
19099 int main(void) {
19100         EVP_MD_CTX* ctx;
19101         const EVP_MD* md;
19102         unsigned char digest[64]; /* its a 256-bit digest, so uses 32 bytes */
19103         const char* str = "Hello world";
19104         const unsigned char check[] = {
19105                 0x40 , 0xed , 0xf8 , 0x56 , 0x5a , 0xc5 , 0x36 , 0xe1 ,
19106                 0x33 , 0x7c , 0x7e , 0x87 , 0x62 , 0x1c , 0x42 , 0xe0 ,
19107                 0x17 , 0x1b , 0x5e , 0xce , 0xa8 , 0x46 , 0x65 , 0x4d ,
19108                 0x8d , 0x3e , 0x22 , 0x9b , 0xe1 , 0x30 , 0x19 , 0x9d
19109         };
19110         OPENSSL_config(NULL);
19111         (void)load_gost_id();
19112         md = EVP_get_digestbyname("md_gost94");
19113         if(!md) return 1;
19114         memset(digest, 0, sizeof(digest));
19115         ctx = EVP_MD_CTX_create();
19116         if(!ctx) return 2;
19117         if(!EVP_DigestInit_ex(ctx, md, NULL)) return 3;
19118         if(!EVP_DigestUpdate(ctx, str, 10)) return 4;
19119         if(!EVP_DigestFinal_ex(ctx, digest, NULL)) return 5;
19120         /* uncomment to see the hash calculated.
19121                 {int i;
19122                 for(i=0; i<32; i++)
19123                         printf(" %2.2x", (int)digest[i]);
19124                 printf("\n");}
19125         */
19126         if(memcmp(digest, check, sizeof(check)) != 0)
19127                 return 6;
19128         return 0;
19129 }
19130
19131 _ACEOF
19132 if ac_fn_c_try_run "$LINENO"; then :
19133   eval "ac_cv_c_gost_works=yes"
19134 else
19135   eval "ac_cv_c_gost_works=no"
19136 fi
19137 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19138   conftest.$ac_objext conftest.beam conftest.$ac_ext
19139 fi
19140
19141 CFLAGS="$BAKCFLAGS"
19142 else
19143 eval "ac_cv_c_gost_works=maybe"
19144 fi
19145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_gost_works" >&5
19146 $as_echo "$ac_cv_c_gost_works" >&6; }
19147
19148         if test "$ac_cv_c_gost_works" != no; then
19149                 use_gost="yes"
19150
19151 $as_echo "#define USE_GOST 1" >>confdefs.h
19152
19153         fi
19154         ;;
19155 esac
19156 fi
19157 # Check whether --enable-ecdsa was given.
19158 if test "${enable_ecdsa+set}" = set; then :
19159   enableval=$enable_ecdsa;
19160 fi
19161
19162 use_ecdsa="no"
19163 case "$enable_ecdsa" in
19164     no)
19165       ;;
19166     *)
19167       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19168               ac_fn_c_check_func "$LINENO" "ECDSA_sign" "ac_cv_func_ECDSA_sign"
19169 if test "x$ac_cv_func_ECDSA_sign" = xyes; then :
19170
19171 else
19172   as_fn_error $? "OpenSSL does not support ECDSA: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19173 fi
19174
19175               ac_fn_c_check_func "$LINENO" "SHA384_Init" "ac_cv_func_SHA384_Init"
19176 if test "x$ac_cv_func_SHA384_Init" = xyes; then :
19177
19178 else
19179   as_fn_error $? "OpenSSL does not support SHA384: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19180 fi
19181
19182               ac_fn_c_check_decl "$LINENO" "NID_X9_62_prime256v1" "ac_cv_have_decl_NID_X9_62_prime256v1" "$ac_includes_default
19183 #include <openssl/evp.h>
19184
19185 "
19186 if test "x$ac_cv_have_decl_NID_X9_62_prime256v1" = xyes; then :
19187   ac_have_decl=1
19188 else
19189   ac_have_decl=0
19190 fi
19191
19192 cat >>confdefs.h <<_ACEOF
19193 #define HAVE_DECL_NID_X9_62_PRIME256V1 $ac_have_decl
19194 _ACEOF
19195 if test $ac_have_decl = 1; then :
19196
19197 else
19198   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19199 fi
19200 ac_fn_c_check_decl "$LINENO" "NID_secp384r1" "ac_cv_have_decl_NID_secp384r1" "$ac_includes_default
19201 #include <openssl/evp.h>
19202
19203 "
19204 if test "x$ac_cv_have_decl_NID_secp384r1" = xyes; then :
19205   ac_have_decl=1
19206 else
19207   ac_have_decl=0
19208 fi
19209
19210 cat >>confdefs.h <<_ACEOF
19211 #define HAVE_DECL_NID_SECP384R1 $ac_have_decl
19212 _ACEOF
19213 if test $ac_have_decl = 1; then :
19214
19215 else
19216   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19217 fi
19218
19219               # see if OPENSSL 1.0.0 or later (has EVP MD and Verify independency)
19220               { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openssl supports SHA2 and ECDSA with EVP" >&5
19221 $as_echo_n "checking if openssl supports SHA2 and ECDSA with EVP... " >&6; }
19222               if grep OPENSSL_VERSION_TEXT $ssldir_include/openssl/opensslv.h | grep "OpenSSL" >/dev/null; then
19223                 if grep OPENSSL_VERSION_NUMBER $ssldir_include/openssl/opensslv.h | grep 0x0 >/dev/null; then
19224                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19225 $as_echo "no" >&6; }
19226
19227 cat >>confdefs.h <<_ACEOF
19228 #define USE_ECDSA_EVP_WORKAROUND 1
19229 _ACEOF
19230
19231                 else
19232                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19233 $as_echo "yes" >&6; }
19234                 fi
19235               else
19236                 # not OpenSSL, thus likely LibreSSL, which supports it
19237                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19238 $as_echo "yes" >&6; }
19239               fi
19240       fi
19241       # we now know we have ECDSA and the required curves.
19242
19243 cat >>confdefs.h <<_ACEOF
19244 #define USE_ECDSA 1
19245 _ACEOF
19246
19247       use_ecdsa="yes"
19248       ;;
19249 esac
19250
19251 # Check whether --enable-dsa was given.
19252 if test "${enable_dsa+set}" = set; then :
19253   enableval=$enable_dsa;
19254 fi
19255
19256 use_dsa="no"
19257 case "$enable_dsa" in
19258     yes)
19259       # detect if DSA is supported, and turn it off if not.
19260       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19261       ac_fn_c_check_func "$LINENO" "DSA_SIG_new" "ac_cv_func_DSA_SIG_new"
19262 if test "x$ac_cv_func_DSA_SIG_new" = xyes; then :
19263
19264       as_ac_Type=`$as_echo "ac_cv_type_DSA_SIG*" | $as_tr_sh`
19265 ac_fn_c_check_type "$LINENO" "DSA_SIG*" "$as_ac_Type" "
19266 $ac_includes_default
19267 #ifdef HAVE_OPENSSL_ERR_H
19268 #include <openssl/err.h>
19269 #endif
19270
19271 #ifdef HAVE_OPENSSL_RAND_H
19272 #include <openssl/rand.h>
19273 #endif
19274
19275 #ifdef HAVE_OPENSSL_CONF_H
19276 #include <openssl/conf.h>
19277 #endif
19278
19279 #ifdef HAVE_OPENSSL_ENGINE_H
19280 #include <openssl/engine.h>
19281 #endif
19282
19283 "
19284 if eval test \"x\$"$as_ac_Type"\" = x"yes"; then :
19285
19286
19287 cat >>confdefs.h <<_ACEOF
19288 #define USE_DSA 1
19289 _ACEOF
19290
19291
19292 else
19293   if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
19294                fi
19295 fi
19296
19297
19298 else
19299   if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
19300                fi
19301 fi
19302
19303       else
19304
19305 cat >>confdefs.h <<_ACEOF
19306 #define USE_DSA 1
19307 _ACEOF
19308
19309       fi
19310       ;;
19311     *)
19312       # disable dsa by default, RFC 8624 section 3.1, validators MUST NOT
19313       # support DSA for DNSSEC Validation.
19314       ;;
19315 esac
19316
19317
19318 # Check whether --with-deprecate-rsa-1024 was given.
19319 if test "${with_deprecate_rsa_1024+set}" = set; then :
19320   withval=$with_deprecate_rsa_1024;
19321 fi
19322
19323 if test "$with_deprecate_rsa_1024" = "yes"; then
19324
19325 $as_echo "#define DEPRECATE_RSA_1024 1" >>confdefs.h
19326
19327 fi
19328
19329 # Check whether --enable-ed25519 was given.
19330 if test "${enable_ed25519+set}" = set; then :
19331   enableval=$enable_ed25519;
19332 fi
19333
19334 use_ed25519="no"
19335 case "$enable_ed25519" in
19336     no)
19337       ;;
19338     *)
19339       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19340               ac_fn_c_check_decl "$LINENO" "NID_ED25519" "ac_cv_have_decl_NID_ED25519" "$ac_includes_default
19341 #include <openssl/evp.h>
19342
19343 "
19344 if test "x$ac_cv_have_decl_NID_ED25519" = xyes; then :
19345   ac_have_decl=1
19346 else
19347   ac_have_decl=0
19348 fi
19349
19350 cat >>confdefs.h <<_ACEOF
19351 #define HAVE_DECL_NID_ED25519 $ac_have_decl
19352 _ACEOF
19353 if test $ac_have_decl = 1; then :
19354
19355                 use_ed25519="yes"
19356
19357 else
19358    if test "x$enable_ed25519" = "xyes"; then as_fn_error $? "OpenSSL does not support ED25519 and you used --enable-ed25519." "$LINENO" 5
19359                 fi
19360 fi
19361
19362       fi
19363       if test $USE_NETTLE = "yes"; then
19364                 for ac_header in nettle/eddsa.h
19365 do :
19366   ac_fn_c_check_header_compile "$LINENO" "nettle/eddsa.h" "ac_cv_header_nettle_eddsa_h" "$ac_includes_default
19367 "
19368 if test "x$ac_cv_header_nettle_eddsa_h" = xyes; then :
19369   cat >>confdefs.h <<_ACEOF
19370 #define HAVE_NETTLE_EDDSA_H 1
19371 _ACEOF
19372  use_ed25519="yes"
19373 fi
19374
19375 done
19376
19377       fi
19378       if test $use_ed25519 = "yes"; then
19379
19380 cat >>confdefs.h <<_ACEOF
19381 #define USE_ED25519 1
19382 _ACEOF
19383
19384       fi
19385       ;;
19386 esac
19387
19388 # Check whether --enable-ed448 was given.
19389 if test "${enable_ed448+set}" = set; then :
19390   enableval=$enable_ed448;
19391 fi
19392
19393 use_ed448="no"
19394 case "$enable_ed448" in
19395     no)
19396       ;;
19397     *)
19398       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19399               ac_fn_c_check_decl "$LINENO" "NID_ED448" "ac_cv_have_decl_NID_ED448" "$ac_includes_default
19400 #include <openssl/evp.h>
19401
19402 "
19403 if test "x$ac_cv_have_decl_NID_ED448" = xyes; then :
19404   ac_have_decl=1
19405 else
19406   ac_have_decl=0
19407 fi
19408
19409 cat >>confdefs.h <<_ACEOF
19410 #define HAVE_DECL_NID_ED448 $ac_have_decl
19411 _ACEOF
19412 if test $ac_have_decl = 1; then :
19413
19414                 use_ed448="yes"
19415
19416 else
19417    if test "x$enable_ed448" = "xyes"; then as_fn_error $? "OpenSSL does not support ED448 and you used --enable-ed448." "$LINENO" 5
19418                 fi
19419 fi
19420
19421       fi
19422       if test $use_ed448 = "yes"; then
19423
19424 cat >>confdefs.h <<_ACEOF
19425 #define USE_ED448 1
19426 _ACEOF
19427
19428       fi
19429       ;;
19430 esac
19431
19432 # Check whether --enable-event-api was given.
19433 if test "${enable_event_api+set}" = set; then :
19434   enableval=$enable_event_api;
19435 fi
19436
19437 case "$enable_event_api" in
19438     yes)
19439       UNBOUND_EVENT_INSTALL=unbound-event-install
19440
19441       UNBOUND_EVENT_UNINSTALL=unbound-event-uninstall
19442
19443       ;;
19444     *)
19445       ;;
19446 esac
19447
19448 # Check whether --enable-tfo-client was given.
19449 if test "${enable_tfo_client+set}" = set; then :
19450   enableval=$enable_tfo_client;
19451 fi
19452
19453 case "$enable_tfo_client" in
19454         yes)
19455                 case "$host_os" in
19456                         linux*) ac_fn_c_check_decl "$LINENO" "MSG_FASTOPEN" "ac_cv_have_decl_MSG_FASTOPEN" "$ac_includes_default
19457 #include <netinet/tcp.h>
19458
19459 "
19460 if test "x$ac_cv_have_decl_MSG_FASTOPEN" = xyes; then :
19461   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
19462 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
19463 else
19464   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
19465 fi
19466
19467
19468 cat >>confdefs.h <<_ACEOF
19469 #define USE_MSG_FASTOPEN 1
19470 _ACEOF
19471
19472                                 ;;
19473                         darwin*) ac_fn_c_check_decl "$LINENO" "CONNECT_RESUME_ON_READ_WRITE" "ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" "$ac_includes_default
19474 #include <sys/socket.h>
19475
19476 "
19477 if test "x$ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" = xyes; then :
19478   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
19479 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
19480 else
19481   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
19482 fi
19483
19484
19485 cat >>confdefs.h <<_ACEOF
19486 #define USE_OSX_MSG_FASTOPEN 1
19487 _ACEOF
19488
19489                                 ;;
19490                 esac
19491                 ;;
19492         no|*)
19493                 ;;
19494 esac
19495
19496 # Check whether --enable-tfo-server was given.
19497 if test "${enable_tfo_server+set}" = set; then :
19498   enableval=$enable_tfo_server;
19499 fi
19500
19501 case "$enable_tfo_server" in
19502         yes)
19503               ac_fn_c_check_decl "$LINENO" "TCP_FASTOPEN" "ac_cv_have_decl_TCP_FASTOPEN" "$ac_includes_default
19504 #include <netinet/tcp.h>
19505
19506 "
19507 if test "x$ac_cv_have_decl_TCP_FASTOPEN" = xyes; then :
19508   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&5
19509 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&2;}
19510 else
19511   as_fn_error $? "TCP Fast Open is not available for server mode: please rerun without --enable-tfo-server" "$LINENO" 5
19512 fi
19513
19514
19515 cat >>confdefs.h <<_ACEOF
19516 #define USE_TCP_FASTOPEN 1
19517 _ACEOF
19518
19519                 ;;
19520         no|*)
19521                 ;;
19522 esac
19523
19524 # check for libevent
19525
19526 # Check whether --with-libevent was given.
19527 if test "${with_libevent+set}" = set; then :
19528   withval=$with_libevent;
19529 else
19530    with_libevent="no"
19531 fi
19532
19533 if test "x_$with_libevent" != x_no; then
19534
19535 $as_echo "#define USE_LIBEVENT 1" >>confdefs.h
19536
19537         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libevent" >&5
19538 $as_echo_n "checking for libevent... " >&6; }
19539         if test "x_$with_libevent" = x_ -o "x_$with_libevent" = x_yes; then
19540             with_libevent="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19541         fi
19542         for dir in $with_libevent; do
19543             thedir="$dir"
19544             if test -f "$dir/include/event.h" -o -f "$dir/include/event2/event.h"; then
19545                 found_libevent="yes"
19546                                                                 if test "$thedir" != "/usr"; then
19547                                     CPPFLAGS="$CPPFLAGS -I$thedir/include"
19548                                 fi
19549                                 break;
19550                     fi
19551         done
19552         if test x_$found_libevent != x_yes; then
19553                 if test -f "$dir/event.h" -a \( -f "$dir/libevent.la" -o -f "$dir/libev.la" \) ; then
19554                         # libevent source directory
19555                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19556 $as_echo "found in $thedir" >&6; }
19557                         CPPFLAGS="$CPPFLAGS -I$thedir -I$thedir/include"
19558                         BAK_LDFLAGS_SET="1"
19559                         BAK_LDFLAGS="$LDFLAGS"
19560                         # remove evdns from linking
19561                         mkdir build >/dev/null 2>&1
19562                         mkdir build/libevent >/dev/null 2>&1
19563                         mkdir build/libevent/.libs >/dev/null 2>&1
19564                         ev_files_o=`ls $thedir/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19565                         ev_files_lo=`ls $thedir/*.lo | grep -v evdns\.lo | grep -v bufferevent_openssl\.lo`
19566                         ev_files_libso=`ls $thedir/.libs/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19567                         cp $ev_files_o build/libevent
19568                         cp $ev_files_lo build/libevent
19569                         cp $ev_files_libso build/libevent/.libs
19570                         LATE_LDFLAGS="build/libevent/*.lo -lm"
19571                         LDFLAGS="build/libevent/*.o $LDFLAGS -lm"
19572                 else
19573             as_fn_error $? "Cannot find the libevent library in $with_libevent
19574 You can restart ./configure --with-libevent=no to use a builtin alternative.
19575 Please note that this alternative is not as capable as libevent when using
19576 large outgoing port ranges.  " "$LINENO" 5
19577                 fi
19578         else
19579             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19580 $as_echo "found in $thedir" >&6; }
19581                     if test ! -f $thedir/lib/libevent.a -a ! -f $thedir/lib/libevent.so -a -d "$thedir/lib/event2"; then
19582                     LDFLAGS="$LDFLAGS -L$thedir/lib/event2"
19583
19584         if test "x$enable_rpath" = xyes; then
19585                 if echo "$thedir/lib/event2" | grep "^/" >/dev/null; then
19586                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib/event2"
19587                 fi
19588         fi
19589
19590             else
19591                                     if test "$thedir" != "/usr" -a "$thedir" != ""; then
19592                         LDFLAGS="$LDFLAGS -L$thedir/lib"
19593
19594         if test "x$enable_rpath" = xyes; then
19595                 if echo "$thedir/lib" | grep "^/" >/dev/null; then
19596                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib"
19597                 fi
19598         fi
19599
19600                     fi
19601             fi
19602         fi
19603         # check for library used by libevent after 1.3c
19604         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19605 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19606 if ${ac_cv_search_clock_gettime+:} false; then :
19607   $as_echo_n "(cached) " >&6
19608 else
19609   ac_func_search_save_LIBS=$LIBS
19610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19611 /* end confdefs.h.  */
19612
19613 /* Override any GCC internal prototype to avoid an error.
19614    Use char because int might match the return type of a GCC
19615    builtin and then its argument prototype would still apply.  */
19616 #ifdef __cplusplus
19617 extern "C"
19618 #endif
19619 char clock_gettime ();
19620 int
19621 main ()
19622 {
19623 return clock_gettime ();
19624   ;
19625   return 0;
19626 }
19627 _ACEOF
19628 for ac_lib in '' rt; do
19629   if test -z "$ac_lib"; then
19630     ac_res="none required"
19631   else
19632     ac_res=-l$ac_lib
19633     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19634   fi
19635   if ac_fn_c_try_link "$LINENO"; then :
19636   ac_cv_search_clock_gettime=$ac_res
19637 fi
19638 rm -f core conftest.err conftest.$ac_objext \
19639     conftest$ac_exeext
19640   if ${ac_cv_search_clock_gettime+:} false; then :
19641   break
19642 fi
19643 done
19644 if ${ac_cv_search_clock_gettime+:} false; then :
19645
19646 else
19647   ac_cv_search_clock_gettime=no
19648 fi
19649 rm conftest.$ac_ext
19650 LIBS=$ac_func_search_save_LIBS
19651 fi
19652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19653 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19654 ac_res=$ac_cv_search_clock_gettime
19655 if test "$ac_res" != no; then :
19656   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19657
19658 fi
19659
19660
19661         # is the event.h header libev or libevent?
19662         for ac_header in event.h
19663 do :
19664   ac_fn_c_check_header_compile "$LINENO" "event.h" "ac_cv_header_event_h" "$ac_includes_default
19665 "
19666 if test "x$ac_cv_header_event_h" = xyes; then :
19667   cat >>confdefs.h <<_ACEOF
19668 #define HAVE_EVENT_H 1
19669 _ACEOF
19670
19671 fi
19672
19673 done
19674
19675         ac_fn_c_check_decl "$LINENO" "EV_VERSION_MAJOR" "ac_cv_have_decl_EV_VERSION_MAJOR" "$ac_includes_default
19676 #include <event.h>
19677
19678 "
19679 if test "x$ac_cv_have_decl_EV_VERSION_MAJOR" = xyes; then :
19680
19681                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19682 $as_echo_n "checking for library containing event_set... " >&6; }
19683 if ${ac_cv_search_event_set+:} false; then :
19684   $as_echo_n "(cached) " >&6
19685 else
19686   ac_func_search_save_LIBS=$LIBS
19687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19688 /* end confdefs.h.  */
19689
19690 /* Override any GCC internal prototype to avoid an error.
19691    Use char because int might match the return type of a GCC
19692    builtin and then its argument prototype would still apply.  */
19693 #ifdef __cplusplus
19694 extern "C"
19695 #endif
19696 char event_set ();
19697 int
19698 main ()
19699 {
19700 return event_set ();
19701   ;
19702   return 0;
19703 }
19704 _ACEOF
19705 for ac_lib in '' ev; do
19706   if test -z "$ac_lib"; then
19707     ac_res="none required"
19708   else
19709     ac_res=-l$ac_lib
19710     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19711   fi
19712   if ac_fn_c_try_link "$LINENO"; then :
19713   ac_cv_search_event_set=$ac_res
19714 fi
19715 rm -f core conftest.err conftest.$ac_objext \
19716     conftest$ac_exeext
19717   if ${ac_cv_search_event_set+:} false; then :
19718   break
19719 fi
19720 done
19721 if ${ac_cv_search_event_set+:} false; then :
19722
19723 else
19724   ac_cv_search_event_set=no
19725 fi
19726 rm conftest.$ac_ext
19727 LIBS=$ac_func_search_save_LIBS
19728 fi
19729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19730 $as_echo "$ac_cv_search_event_set" >&6; }
19731 ac_res=$ac_cv_search_event_set
19732 if test "$ac_res" != no; then :
19733   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19734
19735 fi
19736
19737
19738 else
19739
19740                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19741 $as_echo_n "checking for library containing event_set... " >&6; }
19742 if ${ac_cv_search_event_set+:} false; then :
19743   $as_echo_n "(cached) " >&6
19744 else
19745   ac_func_search_save_LIBS=$LIBS
19746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19747 /* end confdefs.h.  */
19748
19749 /* Override any GCC internal prototype to avoid an error.
19750    Use char because int might match the return type of a GCC
19751    builtin and then its argument prototype would still apply.  */
19752 #ifdef __cplusplus
19753 extern "C"
19754 #endif
19755 char event_set ();
19756 int
19757 main ()
19758 {
19759 return event_set ();
19760   ;
19761   return 0;
19762 }
19763 _ACEOF
19764 for ac_lib in '' event; do
19765   if test -z "$ac_lib"; then
19766     ac_res="none required"
19767   else
19768     ac_res=-l$ac_lib
19769     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19770   fi
19771   if ac_fn_c_try_link "$LINENO"; then :
19772   ac_cv_search_event_set=$ac_res
19773 fi
19774 rm -f core conftest.err conftest.$ac_objext \
19775     conftest$ac_exeext
19776   if ${ac_cv_search_event_set+:} false; then :
19777   break
19778 fi
19779 done
19780 if ${ac_cv_search_event_set+:} false; then :
19781
19782 else
19783   ac_cv_search_event_set=no
19784 fi
19785 rm conftest.$ac_ext
19786 LIBS=$ac_func_search_save_LIBS
19787 fi
19788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19789 $as_echo "$ac_cv_search_event_set" >&6; }
19790 ac_res=$ac_cv_search_event_set
19791 if test "$ac_res" != no; then :
19792   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19793
19794 fi
19795
19796
19797 fi
19798
19799         for ac_func in event_base_free
19800 do :
19801   ac_fn_c_check_func "$LINENO" "event_base_free" "ac_cv_func_event_base_free"
19802 if test "x$ac_cv_func_event_base_free" = xyes; then :
19803   cat >>confdefs.h <<_ACEOF
19804 #define HAVE_EVENT_BASE_FREE 1
19805 _ACEOF
19806
19807 fi
19808 done
19809  # only in libevent 1.2 and later
19810         for ac_func in event_base_once
19811 do :
19812   ac_fn_c_check_func "$LINENO" "event_base_once" "ac_cv_func_event_base_once"
19813 if test "x$ac_cv_func_event_base_once" = xyes; then :
19814   cat >>confdefs.h <<_ACEOF
19815 #define HAVE_EVENT_BASE_ONCE 1
19816 _ACEOF
19817
19818 fi
19819 done
19820  # only in libevent 1.4.1 and later
19821         for ac_func in event_base_new
19822 do :
19823   ac_fn_c_check_func "$LINENO" "event_base_new" "ac_cv_func_event_base_new"
19824 if test "x$ac_cv_func_event_base_new" = xyes; then :
19825   cat >>confdefs.h <<_ACEOF
19826 #define HAVE_EVENT_BASE_NEW 1
19827 _ACEOF
19828
19829 fi
19830 done
19831  # only in libevent 1.4.1 and later
19832         for ac_func in event_base_get_method
19833 do :
19834   ac_fn_c_check_func "$LINENO" "event_base_get_method" "ac_cv_func_event_base_get_method"
19835 if test "x$ac_cv_func_event_base_get_method" = xyes; then :
19836   cat >>confdefs.h <<_ACEOF
19837 #define HAVE_EVENT_BASE_GET_METHOD 1
19838 _ACEOF
19839
19840 fi
19841 done
19842  # only in libevent 1.4.3 and later
19843         for ac_func in ev_loop
19844 do :
19845   ac_fn_c_check_func "$LINENO" "ev_loop" "ac_cv_func_ev_loop"
19846 if test "x$ac_cv_func_ev_loop" = xyes; then :
19847   cat >>confdefs.h <<_ACEOF
19848 #define HAVE_EV_LOOP 1
19849 _ACEOF
19850
19851 fi
19852 done
19853  # only in libev. (tested on 3.51)
19854         for ac_func in ev_default_loop
19855 do :
19856   ac_fn_c_check_func "$LINENO" "ev_default_loop" "ac_cv_func_ev_default_loop"
19857 if test "x$ac_cv_func_ev_default_loop" = xyes; then :
19858   cat >>confdefs.h <<_ACEOF
19859 #define HAVE_EV_DEFAULT_LOOP 1
19860 _ACEOF
19861
19862 fi
19863 done
19864  # only in libev. (tested on 4.00)
19865         for ac_func in event_assign
19866 do :
19867   ac_fn_c_check_func "$LINENO" "event_assign" "ac_cv_func_event_assign"
19868 if test "x$ac_cv_func_event_assign" = xyes; then :
19869   cat >>confdefs.h <<_ACEOF
19870 #define HAVE_EVENT_ASSIGN 1
19871 _ACEOF
19872
19873 fi
19874 done
19875  # in libevent, for thread-safety
19876         ac_fn_c_check_decl "$LINENO" "evsignal_assign" "ac_cv_have_decl_evsignal_assign" "$ac_includes_default
19877 #ifdef HAVE_EVENT_H
19878 #  include <event.h>
19879 #else
19880 #  include \"event2/event.h\"
19881 #endif
19882
19883 "
19884 if test "x$ac_cv_have_decl_evsignal_assign" = xyes; then :
19885   ac_have_decl=1
19886 else
19887   ac_have_decl=0
19888 fi
19889
19890 cat >>confdefs.h <<_ACEOF
19891 #define HAVE_DECL_EVSIGNAL_ASSIGN $ac_have_decl
19892 _ACEOF
19893
19894         PC_LIBEVENT_DEPENDENCY="libevent"
19895
19896         if test -n "$BAK_LDFLAGS_SET"; then
19897                 LDFLAGS="$BAK_LDFLAGS"
19898         fi
19899 else
19900
19901 $as_echo "#define USE_MINI_EVENT 1" >>confdefs.h
19902
19903 fi
19904
19905 # check for libexpat
19906
19907 # Check whether --with-libexpat was given.
19908 if test "${with_libexpat+set}" = set; then :
19909   withval=$with_libexpat;
19910 else
19911    withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19912 fi
19913
19914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
19915 $as_echo_n "checking for libexpat... " >&6; }
19916 found_libexpat="no"
19917 for dir in $withval ; do
19918             if test -f "$dir/include/expat.h"; then
19919                 found_libexpat="yes"
19920                                 if test "$dir" != "/usr"; then
19921                     CPPFLAGS="$CPPFLAGS -I$dir/include"
19922                     LDFLAGS="$LDFLAGS -L$dir/lib"
19923                 fi
19924                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19925 $as_echo "found in $dir" >&6; }
19926                 break;
19927             fi
19928 done
19929 if test x_$found_libexpat != x_yes; then
19930         as_fn_error $? "Could not find libexpat, expat.h" "$LINENO" 5
19931 fi
19932 for ac_header in expat.h
19933 do :
19934   ac_fn_c_check_header_compile "$LINENO" "expat.h" "ac_cv_header_expat_h" "$ac_includes_default
19935 "
19936 if test "x$ac_cv_header_expat_h" = xyes; then :
19937   cat >>confdefs.h <<_ACEOF
19938 #define HAVE_EXPAT_H 1
19939 _ACEOF
19940
19941 fi
19942
19943 done
19944
19945 ac_fn_c_check_decl "$LINENO" "XML_StopParser" "ac_cv_have_decl_XML_StopParser" "$ac_includes_default
19946 #include <expat.h>
19947
19948 "
19949 if test "x$ac_cv_have_decl_XML_StopParser" = xyes; then :
19950   ac_have_decl=1
19951 else
19952   ac_have_decl=0
19953 fi
19954
19955 cat >>confdefs.h <<_ACEOF
19956 #define HAVE_DECL_XML_STOPPARSER $ac_have_decl
19957 _ACEOF
19958
19959
19960 # hiredis (redis C client for cachedb)
19961
19962 # Check whether --with-libhiredis was given.
19963 if test "${with_libhiredis+set}" = set; then :
19964   withval=$with_libhiredis;
19965 else
19966    withval="no"
19967 fi
19968
19969 found_libhiredis="no"
19970 if test x_$withval = x_yes -o x_$withval != x_no; then
19971    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libhiredis" >&5
19972 $as_echo_n "checking for libhiredis... " >&6; }
19973    if test x_$withval = x_ -o x_$withval = x_yes; then
19974             withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19975    fi
19976    for dir in $withval ; do
19977             if test -f "$dir/include/hiredis/hiredis.h"; then
19978                 found_libhiredis="yes"
19979                                 if test "$dir" != "/usr"; then
19980                     CPPFLAGS="$CPPFLAGS -I$dir/include"
19981                     LDFLAGS="$LDFLAGS -L$dir/lib"
19982                 fi
19983                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19984 $as_echo "found in $dir" >&6; }
19985
19986 $as_echo "#define USE_REDIS 1" >>confdefs.h
19987
19988                 LIBS="$LIBS -lhiredis"
19989                 break;
19990             fi
19991     done
19992     if test x_$found_libhiredis != x_yes; then
19993         as_fn_error $? "Could not find libhiredis, hiredis.h" "$LINENO" 5
19994     fi
19995     for ac_header in hiredis/hiredis.h
19996 do :
19997   ac_fn_c_check_header_compile "$LINENO" "hiredis/hiredis.h" "ac_cv_header_hiredis_hiredis_h" "$ac_includes_default
19998 "
19999 if test "x$ac_cv_header_hiredis_hiredis_h" = xyes; then :
20000   cat >>confdefs.h <<_ACEOF
20001 #define HAVE_HIREDIS_HIREDIS_H 1
20002 _ACEOF
20003
20004 fi
20005
20006 done
20007
20008     ac_fn_c_check_decl "$LINENO" "redisConnect" "ac_cv_have_decl_redisConnect" "$ac_includes_default
20009     #include <hiredis/hiredis.h>
20010
20011 "
20012 if test "x$ac_cv_have_decl_redisConnect" = xyes; then :
20013   ac_have_decl=1
20014 else
20015   ac_have_decl=0
20016 fi
20017
20018 cat >>confdefs.h <<_ACEOF
20019 #define HAVE_DECL_REDISCONNECT $ac_have_decl
20020 _ACEOF
20021
20022 fi
20023
20024 # nghttp2
20025
20026 # Check whether --with-libnghttp2 was given.
20027 if test "${with_libnghttp2+set}" = set; then :
20028   withval=$with_libnghttp2;
20029 else
20030    withval="no"
20031 fi
20032
20033 found_libnghttp2="no"
20034 if test x_$withval = x_yes -o x_$withval != x_no; then
20035    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnghttp2" >&5
20036 $as_echo_n "checking for libnghttp2... " >&6; }
20037    if test x_$withval = x_ -o x_$withval = x_yes; then
20038             withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
20039    fi
20040    for dir in $withval ; do
20041             if test -f "$dir/include/nghttp2/nghttp2.h"; then
20042                 found_libnghttp2="yes"
20043                                 if test "$dir" != "/usr"; then
20044                     CPPFLAGS="$CPPFLAGS -I$dir/include"
20045                     LDFLAGS="$LDFLAGS -L$dir/lib"
20046                 fi
20047                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
20048 $as_echo "found in $dir" >&6; }
20049
20050 $as_echo "#define HAVE_NGHTTP2 1" >>confdefs.h
20051
20052                 LIBS="$LIBS -lnghttp2"
20053                 break;
20054             fi
20055     done
20056     if test x_$found_libnghttp2 != x_yes; then
20057         as_fn_error $? "Could not find libnghttp2, nghttp2.h" "$LINENO" 5
20058     fi
20059     for ac_header in nghttp2/nghttp2.h
20060 do :
20061   ac_fn_c_check_header_compile "$LINENO" "nghttp2/nghttp2.h" "ac_cv_header_nghttp2_nghttp2_h" "$ac_includes_default
20062 "
20063 if test "x$ac_cv_header_nghttp2_nghttp2_h" = xyes; then :
20064   cat >>confdefs.h <<_ACEOF
20065 #define HAVE_NGHTTP2_NGHTTP2_H 1
20066 _ACEOF
20067
20068 fi
20069
20070 done
20071
20072     ac_fn_c_check_decl "$LINENO" "nghttp2_session_server_new" "ac_cv_have_decl_nghttp2_session_server_new" "$ac_includes_default
20073     #include <nghttp2/nghttp2.h>
20074
20075 "
20076 if test "x$ac_cv_have_decl_nghttp2_session_server_new" = xyes; then :
20077   ac_have_decl=1
20078 else
20079   ac_have_decl=0
20080 fi
20081
20082 cat >>confdefs.h <<_ACEOF
20083 #define HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW $ac_have_decl
20084 _ACEOF
20085
20086 fi
20087
20088 # set static linking for uninstalled libraries if requested
20089
20090 staticexe=""
20091 # Check whether --enable-static-exe was given.
20092 if test "${enable_static_exe+set}" = set; then :
20093   enableval=$enable_static_exe;
20094 fi
20095
20096 if test x_$enable_static_exe = x_yes; then
20097         staticexe="-static"
20098         if test "$on_mingw" = yes; then
20099                 staticexe="-all-static"
20100                 # for static compile, include gdi32 and zlib here.
20101                 if echo $LIBS | grep 'lgdi32' >/dev/null; then
20102                         :
20103                 else
20104                         LIBS="$LIBS -lgdi32"
20105                 fi
20106                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
20107 $as_echo_n "checking for compress in -lz... " >&6; }
20108 if ${ac_cv_lib_z_compress+:} false; then :
20109   $as_echo_n "(cached) " >&6
20110 else
20111   ac_check_lib_save_LIBS=$LIBS
20112 LIBS="-lz  $LIBS"
20113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20114 /* end confdefs.h.  */
20115
20116 /* Override any GCC internal prototype to avoid an error.
20117    Use char because int might match the return type of a GCC
20118    builtin and then its argument prototype would still apply.  */
20119 #ifdef __cplusplus
20120 extern "C"
20121 #endif
20122 char compress ();
20123 int
20124 main ()
20125 {
20126 return compress ();
20127   ;
20128   return 0;
20129 }
20130 _ACEOF
20131 if ac_fn_c_try_link "$LINENO"; then :
20132   ac_cv_lib_z_compress=yes
20133 else
20134   ac_cv_lib_z_compress=no
20135 fi
20136 rm -f core conftest.err conftest.$ac_objext \
20137     conftest$ac_exeext conftest.$ac_ext
20138 LIBS=$ac_check_lib_save_LIBS
20139 fi
20140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
20141 $as_echo "$ac_cv_lib_z_compress" >&6; }
20142 if test "x$ac_cv_lib_z_compress" = xyes; then :
20143    LIBS="$LIBS -lz"
20144 fi
20145
20146                 LIBS="$LIBS -l:libssp.a"
20147         fi
20148 fi
20149
20150 # set full static linking if requested
20151 # Check whether --enable-fully-static was given.
20152 if test "${enable_fully_static+set}" = set; then :
20153   enableval=$enable_fully_static;
20154 fi
20155
20156 if test x_$enable_fully_static = x_yes; then
20157         staticexe="-all-static"
20158         if test "$on_mingw" = yes; then
20159                 # for static compile, include gdi32 and zlib here.
20160                 if echo $LIBS | grep 'lgdi32' >/dev/null; then
20161                         :
20162                 else
20163                         LIBS="$LIBS -lgdi32"
20164                 fi
20165                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
20166 $as_echo_n "checking for compress in -lz... " >&6; }
20167 if ${ac_cv_lib_z_compress+:} false; then :
20168   $as_echo_n "(cached) " >&6
20169 else
20170   ac_check_lib_save_LIBS=$LIBS
20171 LIBS="-lz  $LIBS"
20172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20173 /* end confdefs.h.  */
20174
20175 /* Override any GCC internal prototype to avoid an error.
20176    Use char because int might match the return type of a GCC
20177    builtin and then its argument prototype would still apply.  */
20178 #ifdef __cplusplus
20179 extern "C"
20180 #endif
20181 char compress ();
20182 int
20183 main ()
20184 {
20185 return compress ();
20186   ;
20187   return 0;
20188 }
20189 _ACEOF
20190 if ac_fn_c_try_link "$LINENO"; then :
20191   ac_cv_lib_z_compress=yes
20192 else
20193   ac_cv_lib_z_compress=no
20194 fi
20195 rm -f core conftest.err conftest.$ac_objext \
20196     conftest$ac_exeext conftest.$ac_ext
20197 LIBS=$ac_check_lib_save_LIBS
20198 fi
20199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
20200 $as_echo "$ac_cv_lib_z_compress" >&6; }
20201 if test "x$ac_cv_lib_z_compress" = xyes; then :
20202    LIBS="$LIBS -lz"
20203 fi
20204
20205                 LIBS="$LIBS -l:libssp.a"
20206         fi
20207 fi
20208
20209 # set lock checking if requested
20210 # Check whether --enable-lock_checks was given.
20211 if test "${enable_lock_checks+set}" = set; then :
20212   enableval=$enable_lock_checks;
20213 fi
20214
20215 if test x_$enable_lock_checks = x_yes; then
20216
20217 $as_echo "#define ENABLE_LOCK_CHECKS 1" >>confdefs.h
20218
20219         CHECKLOCK_OBJ="checklocks.lo"
20220
20221 fi
20222
20223
20224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
20225 $as_echo_n "checking for getaddrinfo... " >&6; }
20226 ac_cv_func_getaddrinfo=no
20227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20228 /* end confdefs.h.  */
20229
20230 #ifdef __cplusplus
20231 extern "C"
20232 {
20233 #endif
20234 char* getaddrinfo();
20235 char* (*f) () = getaddrinfo;
20236 #ifdef __cplusplus
20237 }
20238 #endif
20239 int main(void) {
20240         ;
20241         return 0;
20242 }
20243
20244 _ACEOF
20245 if ac_fn_c_try_link "$LINENO"; then :
20246   ac_cv_func_getaddrinfo="yes"
20247 if test "$ac_cv_header_windows_h" = "yes"; then
20248
20249 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
20250
20251         USE_WINSOCK="1"
20252         if echo $LIBS | grep 'lws2_32' >/dev/null; then
20253                 :
20254         else
20255                 LIBS="$LIBS -lws2_32"
20256         fi
20257 fi
20258
20259 else
20260   ORIGLIBS="$LIBS"
20261 LIBS="$LIBS -lws2_32"
20262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20263 /* end confdefs.h.  */
20264
20265 #ifdef HAVE_WS2TCPIP_H
20266 #include <ws2tcpip.h>
20267 #endif
20268
20269 int
20270 main ()
20271 {
20272
20273         (void)getaddrinfo(NULL, NULL, NULL, NULL);
20274
20275
20276   ;
20277   return 0;
20278 }
20279 _ACEOF
20280 if ac_fn_c_try_link "$LINENO"; then :
20281
20282 ac_cv_func_getaddrinfo="yes"
20283
20284 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
20285
20286 USE_WINSOCK="1"
20287
20288 else
20289
20290 ac_cv_func_getaddrinfo="no"
20291 LIBS="$ORIGLIBS"
20292
20293 fi
20294 rm -f core conftest.err conftest.$ac_objext \
20295     conftest$ac_exeext conftest.$ac_ext
20296
20297 fi
20298 rm -f core conftest.err conftest.$ac_objext \
20299     conftest$ac_exeext conftest.$ac_ext
20300
20301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getaddrinfo" >&5
20302 $as_echo "$ac_cv_func_getaddrinfo" >&6; }
20303 if test $ac_cv_func_getaddrinfo = yes; then
20304
20305 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
20306
20307 fi
20308
20309 if test "$USE_WINSOCK" = 1; then
20310
20311 $as_echo "#define UB_ON_WINDOWS 1" >>confdefs.h
20312
20313         for ac_header in iphlpapi.h
20314 do :
20315   ac_fn_c_check_header_compile "$LINENO" "iphlpapi.h" "ac_cv_header_iphlpapi_h" "$ac_includes_default
20316 #include <windows.h>
20317
20318 "
20319 if test "x$ac_cv_header_iphlpapi_h" = xyes; then :
20320   cat >>confdefs.h <<_ACEOF
20321 #define HAVE_IPHLPAPI_H 1
20322 _ACEOF
20323
20324 fi
20325
20326 done
20327
20328         if test -n "$ac_tool_prefix"; then
20329   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
20330 set dummy ${ac_tool_prefix}windres; ac_word=$2
20331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20332 $as_echo_n "checking for $ac_word... " >&6; }
20333 if ${ac_cv_prog_WINDRES+:} false; then :
20334   $as_echo_n "(cached) " >&6
20335 else
20336   if test -n "$WINDRES"; then
20337   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
20338 else
20339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20340 for as_dir in $PATH
20341 do
20342   IFS=$as_save_IFS
20343   test -z "$as_dir" && as_dir=.
20344     for ac_exec_ext in '' $ac_executable_extensions; do
20345   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20346     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
20347     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20348     break 2
20349   fi
20350 done
20351   done
20352 IFS=$as_save_IFS
20353
20354 fi
20355 fi
20356 WINDRES=$ac_cv_prog_WINDRES
20357 if test -n "$WINDRES"; then
20358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
20359 $as_echo "$WINDRES" >&6; }
20360 else
20361   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20362 $as_echo "no" >&6; }
20363 fi
20364
20365
20366 fi
20367 if test -z "$ac_cv_prog_WINDRES"; then
20368   ac_ct_WINDRES=$WINDRES
20369   # Extract the first word of "windres", so it can be a program name with args.
20370 set dummy windres; ac_word=$2
20371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20372 $as_echo_n "checking for $ac_word... " >&6; }
20373 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
20374   $as_echo_n "(cached) " >&6
20375 else
20376   if test -n "$ac_ct_WINDRES"; then
20377   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
20378 else
20379 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20380 for as_dir in $PATH
20381 do
20382   IFS=$as_save_IFS
20383   test -z "$as_dir" && as_dir=.
20384     for ac_exec_ext in '' $ac_executable_extensions; do
20385   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20386     ac_cv_prog_ac_ct_WINDRES="windres"
20387     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20388     break 2
20389   fi
20390 done
20391   done
20392 IFS=$as_save_IFS
20393
20394 fi
20395 fi
20396 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
20397 if test -n "$ac_ct_WINDRES"; then
20398   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
20399 $as_echo "$ac_ct_WINDRES" >&6; }
20400 else
20401   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20402 $as_echo "no" >&6; }
20403 fi
20404
20405   if test "x$ac_ct_WINDRES" = x; then
20406     WINDRES=""
20407   else
20408     case $cross_compiling:$ac_tool_warned in
20409 yes:)
20410 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
20411 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
20412 ac_tool_warned=yes ;;
20413 esac
20414     WINDRES=$ac_ct_WINDRES
20415   fi
20416 else
20417   WINDRES="$ac_cv_prog_WINDRES"
20418 fi
20419
20420         LIBS="$LIBS -liphlpapi -lcrypt32"
20421         WINAPPS="unbound-service-install.exe unbound-service-remove.exe anchor-update.exe"
20422
20423         WIN_DAEMON_SRC="winrc/win_svc.c winrc/w_inst.c"
20424
20425         WIN_DAEMON_OBJ="win_svc.lo w_inst.lo"
20426
20427         WIN_DAEMON_OBJ_LINK="rsrc_unbound.o"
20428
20429         WIN_HOST_OBJ_LINK="rsrc_unbound_host.o"
20430
20431         WIN_UBANCHOR_OBJ_LINK="rsrc_unbound_anchor.o log.lo locks.lo"
20432
20433         WIN_CONTROL_OBJ_LINK="rsrc_unbound_control.o"
20434
20435         WIN_CHECKCONF_OBJ_LINK="rsrc_unbound_checkconf.o"
20436
20437
20438 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
20439
20440 fi
20441 if test $ac_cv_func_getaddrinfo = no; then
20442         case " $LIBOBJS " in
20443   *" fake-rfc2553.$ac_objext "* ) ;;
20444   *) LIBOBJS="$LIBOBJS fake-rfc2553.$ac_objext"
20445  ;;
20446 esac
20447
20448 fi
20449 # check after getaddrinfo for its libraries
20450
20451 # check ioctlsocket
20452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctlsocket" >&5
20453 $as_echo_n "checking for ioctlsocket... " >&6; }
20454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20455 /* end confdefs.h.  */
20456
20457 #ifdef HAVE_WINSOCK2_H
20458 #include <winsock2.h>
20459 #endif
20460
20461 int
20462 main ()
20463 {
20464
20465         (void)ioctlsocket(0, 0, NULL);
20466
20467   ;
20468   return 0;
20469 }
20470 _ACEOF
20471 if ac_fn_c_try_link "$LINENO"; then :
20472
20473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20474 $as_echo "yes" >&6; }
20475
20476 $as_echo "#define HAVE_IOCTLSOCKET 1" >>confdefs.h
20477
20478
20479 else
20480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20481 $as_echo "no" >&6; }
20482 fi
20483 rm -f core conftest.err conftest.$ac_objext \
20484     conftest$ac_exeext conftest.$ac_ext
20485
20486
20487 # see if daemon(3) exists, and if it is deprecated.
20488 for ac_func in daemon
20489 do :
20490   ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
20491 if test "x$ac_cv_func_daemon" = xyes; then :
20492   cat >>confdefs.h <<_ACEOF
20493 #define HAVE_DAEMON 1
20494 _ACEOF
20495
20496 fi
20497 done
20498
20499 if test $ac_cv_func_daemon = yes; then
20500
20501
20502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if daemon is deprecated" >&5
20503 $as_echo_n "checking if daemon is deprecated... " >&6; }
20504 cache=`echo daemon | sed 'y%.=/+-%___p_%'`
20505 if eval \${cv_cc_deprecated_$cache+:} false; then :
20506   $as_echo_n "(cached) " >&6
20507 else
20508
20509 echo '
20510 #include <stdlib.h>
20511 #include <unistd.h>
20512 ' >conftest.c
20513 echo 'void f(void){ (void)daemon(0, 0); }' >>conftest.c
20514 if test -z "`$CC $CPPFLAGS $CFLAGS -c conftest.c 2>&1 | grep -e deprecated -e unavailable`"; then
20515 eval "cv_cc_deprecated_$cache=no"
20516 else
20517 eval "cv_cc_deprecated_$cache=yes"
20518 fi
20519 rm -f conftest conftest.o conftest.c
20520
20521 fi
20522
20523 if eval "test \"`echo '$cv_cc_deprecated_'$cache`\" = yes"; then
20524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20525 $as_echo "yes" >&6; }
20526
20527 cat >>confdefs.h <<_ACEOF
20528 #define DEPRECATED_DAEMON 1
20529 _ACEOF
20530
20531 :
20532
20533 else
20534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20535 $as_echo "no" >&6; }
20536 :
20537
20538 fi
20539
20540 fi
20541
20542 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_len" "ac_cv_member_struct_sockaddr_un_sun_len" "
20543 $ac_includes_default
20544 #ifdef HAVE_SYS_UN_H
20545 #include <sys/un.h>
20546 #endif
20547
20548 "
20549 if test "x$ac_cv_member_struct_sockaddr_un_sun_len" = xyes; then :
20550
20551 cat >>confdefs.h <<_ACEOF
20552 #define HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 1
20553 _ACEOF
20554
20555
20556 fi
20557
20558 ac_fn_c_check_member "$LINENO" "struct in_pktinfo" "ipi_spec_dst" "ac_cv_member_struct_in_pktinfo_ipi_spec_dst" "
20559 $ac_includes_default
20560 #if HAVE_SYS_PARAM_H
20561 #include <sys/param.h>
20562 #endif
20563
20564 #ifdef HAVE_SYS_SOCKET_H
20565 #include <sys/socket.h>
20566 #endif
20567
20568 #ifdef HAVE_SYS_UIO_H
20569 #include <sys/uio.h>
20570 #endif
20571
20572 #ifdef HAVE_NETINET_IN_H
20573 #include <netinet/in.h>
20574 #endif
20575
20576 #ifdef HAVE_NETINET_TCP_H
20577 #include <netinet/tcp.h>
20578 #endif
20579
20580 #ifdef HAVE_ARPA_INET_H
20581 #include <arpa/inet.h>
20582 #endif
20583
20584 #ifdef HAVE_WINSOCK2_H
20585 #include <winsock2.h>
20586 #endif
20587
20588 #ifdef HAVE_WS2TCPIP_H
20589 #include <ws2tcpip.h>
20590 #endif
20591
20592 "
20593 if test "x$ac_cv_member_struct_in_pktinfo_ipi_spec_dst" = xyes; then :
20594
20595 cat >>confdefs.h <<_ACEOF
20596 #define HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST 1
20597 _ACEOF
20598
20599
20600 fi
20601
20602
20603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htobe64" >&5
20604 $as_echo_n "checking for htobe64... " >&6; }
20605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20606 /* end confdefs.h.  */
20607
20608 #include <stdio.h>
20609 #ifdef HAVE_ENDIAN_H
20610 #  include <endian.h>
20611 #endif
20612 #ifdef HAVE_SYS_ENDIAN_H
20613 #  include <sys/endian.h>
20614 #endif
20615
20616 int
20617 main ()
20618 {
20619 unsigned long long x = htobe64(0); printf("%u", (unsigned)x);
20620   ;
20621   return 0;
20622 }
20623 _ACEOF
20624 if ac_fn_c_try_link "$LINENO"; then :
20625   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20626 $as_echo "yes" >&6; }
20627
20628 $as_echo "#define HAVE_HTOBE64 1" >>confdefs.h
20629
20630 else
20631   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20632 $as_echo "no" >&6; }
20633 fi
20634 rm -f core conftest.err conftest.$ac_objext \
20635     conftest$ac_exeext conftest.$ac_ext
20636
20637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for be64toh" >&5
20638 $as_echo_n "checking for be64toh... " >&6; }
20639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20640 /* end confdefs.h.  */
20641
20642 #include <stdio.h>
20643 #ifdef HAVE_ENDIAN_H
20644 #  include <endian.h>
20645 #endif
20646 #ifdef HAVE_SYS_ENDIAN_H
20647 #  include <sys/endian.h>
20648 #endif
20649
20650 int
20651 main ()
20652 {
20653 unsigned long long x = be64toh(0); printf("%u", (unsigned)x);
20654   ;
20655   return 0;
20656 }
20657 _ACEOF
20658 if ac_fn_c_try_link "$LINENO"; then :
20659   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20660 $as_echo "yes" >&6; }
20661
20662 $as_echo "#define HAVE_BE64TOH 1" >>confdefs.h
20663
20664 else
20665   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20666 $as_echo "no" >&6; }
20667 fi
20668 rm -f core conftest.err conftest.$ac_objext \
20669     conftest$ac_exeext conftest.$ac_ext
20670
20671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setusercontext" >&5
20672 $as_echo_n "checking for library containing setusercontext... " >&6; }
20673 if ${ac_cv_search_setusercontext+:} false; then :
20674   $as_echo_n "(cached) " >&6
20675 else
20676   ac_func_search_save_LIBS=$LIBS
20677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20678 /* end confdefs.h.  */
20679
20680 /* Override any GCC internal prototype to avoid an error.
20681    Use char because int might match the return type of a GCC
20682    builtin and then its argument prototype would still apply.  */
20683 #ifdef __cplusplus
20684 extern "C"
20685 #endif
20686 char setusercontext ();
20687 int
20688 main ()
20689 {
20690 return setusercontext ();
20691   ;
20692   return 0;
20693 }
20694 _ACEOF
20695 for ac_lib in '' util; do
20696   if test -z "$ac_lib"; then
20697     ac_res="none required"
20698   else
20699     ac_res=-l$ac_lib
20700     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20701   fi
20702   if ac_fn_c_try_link "$LINENO"; then :
20703   ac_cv_search_setusercontext=$ac_res
20704 fi
20705 rm -f core conftest.err conftest.$ac_objext \
20706     conftest$ac_exeext
20707   if ${ac_cv_search_setusercontext+:} false; then :
20708   break
20709 fi
20710 done
20711 if ${ac_cv_search_setusercontext+:} false; then :
20712
20713 else
20714   ac_cv_search_setusercontext=no
20715 fi
20716 rm conftest.$ac_ext
20717 LIBS=$ac_func_search_save_LIBS
20718 fi
20719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setusercontext" >&5
20720 $as_echo "$ac_cv_search_setusercontext" >&6; }
20721 ac_res=$ac_cv_search_setusercontext
20722 if test "$ac_res" != no; then :
20723   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20724
20725 fi
20726
20727 for ac_func in tzset sigprocmask fcntl getpwnam endpwent getrlimit setrlimit setsid chroot kill chown sleep usleep random srandom recvmsg sendmsg writev socketpair glob initgroups strftime localtime_r setusercontext _beginthreadex endservent endprotoent fsync shmget accept4 getifaddrs if_nametoindex poll gettid
20728 do :
20729   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20730 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20731 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
20732   cat >>confdefs.h <<_ACEOF
20733 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20734 _ACEOF
20735
20736 fi
20737 done
20738
20739 for ac_func in setresuid
20740 do :
20741   ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
20742 if test "x$ac_cv_func_setresuid" = xyes; then :
20743   cat >>confdefs.h <<_ACEOF
20744 #define HAVE_SETRESUID 1
20745 _ACEOF
20746
20747 else
20748   for ac_func in setreuid
20749 do :
20750   ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid"
20751 if test "x$ac_cv_func_setreuid" = xyes; then :
20752   cat >>confdefs.h <<_ACEOF
20753 #define HAVE_SETREUID 1
20754 _ACEOF
20755
20756 fi
20757 done
20758
20759 fi
20760 done
20761
20762 for ac_func in setresgid
20763 do :
20764   ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
20765 if test "x$ac_cv_func_setresgid" = xyes; then :
20766   cat >>confdefs.h <<_ACEOF
20767 #define HAVE_SETRESGID 1
20768 _ACEOF
20769
20770 else
20771   for ac_func in setregid
20772 do :
20773   ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid"
20774 if test "x$ac_cv_func_setregid" = xyes; then :
20775   cat >>confdefs.h <<_ACEOF
20776 #define HAVE_SETREGID 1
20777 _ACEOF
20778
20779 fi
20780 done
20781
20782 fi
20783 done
20784
20785
20786 # check if setreuid en setregid fail, on MacOSX10.4(darwin8).
20787 if echo $host_os | grep darwin8 > /dev/null; then
20788
20789 $as_echo "#define DARWIN_BROKEN_SETREUID 1" >>confdefs.h
20790
20791 fi
20792 ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "
20793 $ac_includes_default
20794 #ifdef HAVE_NETINET_IN_H
20795 #include <netinet/in.h>
20796 #endif
20797
20798 #ifdef HAVE_NETINET_TCP_H
20799 #include <netinet/tcp.h>
20800 #endif
20801
20802 #ifdef HAVE_ARPA_INET_H
20803 #include <arpa/inet.h>
20804 #endif
20805
20806 #ifdef HAVE_WINSOCK2_H
20807 #include <winsock2.h>
20808 #endif
20809
20810 #ifdef HAVE_WS2TCPIP_H
20811 #include <ws2tcpip.h>
20812 #endif
20813
20814 "
20815 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
20816   ac_have_decl=1
20817 else
20818   ac_have_decl=0
20819 fi
20820
20821 cat >>confdefs.h <<_ACEOF
20822 #define HAVE_DECL_INET_PTON $ac_have_decl
20823 _ACEOF
20824 ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "
20825 $ac_includes_default
20826 #ifdef HAVE_NETINET_IN_H
20827 #include <netinet/in.h>
20828 #endif
20829
20830 #ifdef HAVE_NETINET_TCP_H
20831 #include <netinet/tcp.h>
20832 #endif
20833
20834 #ifdef HAVE_ARPA_INET_H
20835 #include <arpa/inet.h>
20836 #endif
20837
20838 #ifdef HAVE_WINSOCK2_H
20839 #include <winsock2.h>
20840 #endif
20841
20842 #ifdef HAVE_WS2TCPIP_H
20843 #include <ws2tcpip.h>
20844 #endif
20845
20846 "
20847 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
20848   ac_have_decl=1
20849 else
20850   ac_have_decl=0
20851 fi
20852
20853 cat >>confdefs.h <<_ACEOF
20854 #define HAVE_DECL_INET_NTOP $ac_have_decl
20855 _ACEOF
20856
20857 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
20858 if test "x$ac_cv_func_inet_aton" = xyes; then :
20859   $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
20860
20861 else
20862   case " $LIBOBJS " in
20863   *" inet_aton.$ac_objext "* ) ;;
20864   *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
20865  ;;
20866 esac
20867
20868 fi
20869
20870
20871 ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
20872 if test "x$ac_cv_func_inet_pton" = xyes; then :
20873   $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h
20874
20875 else
20876   case " $LIBOBJS " in
20877   *" inet_pton.$ac_objext "* ) ;;
20878   *) LIBOBJS="$LIBOBJS inet_pton.$ac_objext"
20879  ;;
20880 esac
20881
20882 fi
20883
20884
20885 ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
20886 if test "x$ac_cv_func_inet_ntop" = xyes; then :
20887   $as_echo "#define HAVE_INET_NTOP 1" >>confdefs.h
20888
20889 else
20890   case " $LIBOBJS " in
20891   *" inet_ntop.$ac_objext "* ) ;;
20892   *) LIBOBJS="$LIBOBJS inet_ntop.$ac_objext"
20893  ;;
20894 esac
20895
20896 fi
20897
20898
20899 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
20900 if test "x$ac_cv_func_snprintf" = xyes; then :
20901   $as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
20902
20903 else
20904   case " $LIBOBJS " in
20905   *" snprintf.$ac_objext "* ) ;;
20906   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20907  ;;
20908 esac
20909
20910 fi
20911
20912
20913 # test if snprintf return the proper length
20914 if test "x$ac_cv_func_snprintf" = xyes; then
20915     if test c${cross_compiling} = cno; then
20916         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for correct snprintf return value" >&5
20917 $as_echo_n "checking for correct snprintf return value... " >&6; }
20918         if test "$cross_compiling" = yes; then :
20919   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20920 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20921 as_fn_error $? "cannot run test program while cross compiling
20922 See \`config.log' for more details" "$LINENO" 5; }
20923 else
20924   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20925 /* end confdefs.h.  */
20926 $ac_includes_default
20927
20928 int main(void) { return !(snprintf(NULL, 0, "test") == 4); }
20929
20930 _ACEOF
20931 if ac_fn_c_try_run "$LINENO"; then :
20932   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20933 $as_echo "yes" >&6; }
20934 else
20935
20936                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20937 $as_echo "no" >&6; }
20938
20939 $as_echo "#define SNPRINTF_RET_BROKEN /**/" >>confdefs.h
20940
20941                 case " $LIBOBJS " in
20942   *" snprintf.$ac_objext "* ) ;;
20943   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20944  ;;
20945 esac
20946
20947
20948 fi
20949 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20950   conftest.$ac_objext conftest.beam conftest.$ac_ext
20951 fi
20952
20953     fi
20954 fi
20955 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
20956 if test "x$ac_cv_func_strlcat" = xyes; then :
20957   $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
20958
20959 else
20960   case " $LIBOBJS " in
20961   *" strlcat.$ac_objext "* ) ;;
20962   *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
20963  ;;
20964 esac
20965
20966 fi
20967
20968
20969 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
20970 if test "x$ac_cv_func_strlcpy" = xyes; then :
20971   $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
20972
20973 else
20974   case " $LIBOBJS " in
20975   *" strlcpy.$ac_objext "* ) ;;
20976   *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
20977  ;;
20978 esac
20979
20980 fi
20981
20982
20983 ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
20984 if test "x$ac_cv_func_memmove" = xyes; then :
20985   $as_echo "#define HAVE_MEMMOVE 1" >>confdefs.h
20986
20987 else
20988   case " $LIBOBJS " in
20989   *" memmove.$ac_objext "* ) ;;
20990   *) LIBOBJS="$LIBOBJS memmove.$ac_objext"
20991  ;;
20992 esac
20993
20994 fi
20995
20996
20997 ac_fn_c_check_func "$LINENO" "gmtime_r" "ac_cv_func_gmtime_r"
20998 if test "x$ac_cv_func_gmtime_r" = xyes; then :
20999   $as_echo "#define HAVE_GMTIME_R 1" >>confdefs.h
21000
21001 else
21002   case " $LIBOBJS " in
21003   *" gmtime_r.$ac_objext "* ) ;;
21004   *) LIBOBJS="$LIBOBJS gmtime_r.$ac_objext"
21005  ;;
21006 esac
21007
21008 fi
21009
21010
21011 ac_fn_c_check_func "$LINENO" "isblank" "ac_cv_func_isblank"
21012 if test "x$ac_cv_func_isblank" = xyes; then :
21013   $as_echo "#define HAVE_ISBLANK 1" >>confdefs.h
21014
21015 else
21016   case " $LIBOBJS " in
21017   *" isblank.$ac_objext "* ) ;;
21018   *) LIBOBJS="$LIBOBJS isblank.$ac_objext"
21019  ;;
21020 esac
21021
21022 fi
21023
21024
21025 ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero"
21026 if test "x$ac_cv_func_explicit_bzero" = xyes; then :
21027   $as_echo "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h
21028
21029 else
21030   case " $LIBOBJS " in
21031   *" explicit_bzero.$ac_objext "* ) ;;
21032   *) LIBOBJS="$LIBOBJS explicit_bzero.$ac_objext"
21033  ;;
21034 esac
21035
21036 fi
21037
21038
21039 LIBOBJ_WITHOUT_CTIMEARC4="$LIBOBJS"
21040
21041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for reallocarray" >&5
21042 $as_echo_n "checking for reallocarray... " >&6; }
21043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21044 /* end confdefs.h.  */
21045 $ac_includes_default
21046
21047 #ifndef _OPENBSD_SOURCE
21048 #define _OPENBSD_SOURCE 1
21049 #endif
21050 #include <stdlib.h>
21051 int main(void) {
21052         void* p = reallocarray(NULL, 10, 100);
21053         free(p);
21054         return 0;
21055 }
21056
21057 _ACEOF
21058 if ac_fn_c_try_link "$LINENO"; then :
21059   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21060 $as_echo "yes" >&6; }
21061
21062 $as_echo "#define HAVE_REALLOCARRAY 1" >>confdefs.h
21063
21064
21065 else
21066
21067         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21068 $as_echo "no" >&6; }
21069         case " $LIBOBJS " in
21070   *" reallocarray.$ac_objext "* ) ;;
21071   *) LIBOBJS="$LIBOBJS reallocarray.$ac_objext"
21072  ;;
21073 esac
21074
21075
21076 fi
21077 rm -f core conftest.err conftest.$ac_objext \
21078     conftest$ac_exeext conftest.$ac_ext
21079 ac_fn_c_check_decl "$LINENO" "reallocarray" "ac_cv_have_decl_reallocarray" "$ac_includes_default"
21080 if test "x$ac_cv_have_decl_reallocarray" = xyes; then :
21081   ac_have_decl=1
21082 else
21083   ac_have_decl=0
21084 fi
21085
21086 cat >>confdefs.h <<_ACEOF
21087 #define HAVE_DECL_REALLOCARRAY $ac_have_decl
21088 _ACEOF
21089
21090 if test "$USE_NSS" = "no"; then
21091         ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
21092 if test "x$ac_cv_func_arc4random" = xyes; then :
21093   $as_echo "#define HAVE_ARC4RANDOM 1" >>confdefs.h
21094
21095 else
21096   case " $LIBOBJS " in
21097   *" arc4random.$ac_objext "* ) ;;
21098   *) LIBOBJS="$LIBOBJS arc4random.$ac_objext"
21099  ;;
21100 esac
21101
21102 fi
21103
21104
21105         ac_fn_c_check_func "$LINENO" "arc4random_uniform" "ac_cv_func_arc4random_uniform"
21106 if test "x$ac_cv_func_arc4random_uniform" = xyes; then :
21107   $as_echo "#define HAVE_ARC4RANDOM_UNIFORM 1" >>confdefs.h
21108
21109 else
21110   case " $LIBOBJS " in
21111   *" arc4random_uniform.$ac_objext "* ) ;;
21112   *) LIBOBJS="$LIBOBJS arc4random_uniform.$ac_objext"
21113  ;;
21114 esac
21115
21116 fi
21117
21118
21119         if test "$ac_cv_func_arc4random" = "no"; then
21120                 case " $LIBOBJS " in
21121   *" arc4_lock.$ac_objext "* ) ;;
21122   *) LIBOBJS="$LIBOBJS arc4_lock.$ac_objext"
21123  ;;
21124 esac
21125
21126                 for ac_func in getentropy
21127 do :
21128   ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
21129 if test "x$ac_cv_func_getentropy" = xyes; then :
21130   cat >>confdefs.h <<_ACEOF
21131 #define HAVE_GETENTROPY 1
21132 _ACEOF
21133
21134 else
21135
21136                     if test "$USE_WINSOCK" = 1; then
21137                         case " $LIBOBJS " in
21138   *" getentropy_win.$ac_objext "* ) ;;
21139   *) LIBOBJS="$LIBOBJS getentropy_win.$ac_objext"
21140  ;;
21141 esac
21142
21143                     else
21144                         case "$host" in
21145                         Darwin|*darwin*)
21146                                 case " $LIBOBJS " in
21147   *" getentropy_osx.$ac_objext "* ) ;;
21148   *) LIBOBJS="$LIBOBJS getentropy_osx.$ac_objext"
21149  ;;
21150 esac
21151
21152                         ;;
21153                         *solaris*|*sunos*|SunOS)
21154                                 case " $LIBOBJS " in
21155   *" getentropy_solaris.$ac_objext "* ) ;;
21156   *) LIBOBJS="$LIBOBJS getentropy_solaris.$ac_objext"
21157  ;;
21158 esac
21159
21160                                 for ac_header in sys/sha2.h
21161 do :
21162   ac_fn_c_check_header_compile "$LINENO" "sys/sha2.h" "ac_cv_header_sys_sha2_h" "$ac_includes_default
21163 "
21164 if test "x$ac_cv_header_sys_sha2_h" = xyes; then :
21165   cat >>confdefs.h <<_ACEOF
21166 #define HAVE_SYS_SHA2_H 1
21167 _ACEOF
21168
21169 else
21170
21171                                         for ac_func in SHA512_Update
21172 do :
21173   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
21174 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
21175   cat >>confdefs.h <<_ACEOF
21176 #define HAVE_SHA512_UPDATE 1
21177 _ACEOF
21178
21179 else
21180
21181                                                 case " $LIBOBJS " in
21182   *" sha512.$ac_objext "* ) ;;
21183   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
21184  ;;
21185 esac
21186
21187
21188 fi
21189 done
21190
21191
21192 fi
21193
21194 done
21195
21196                                 if test "$ac_cv_header_sys_sha2_h" = "yes"; then
21197                                         # this lib needed for sha2 on solaris
21198                                         LIBS="$LIBS -lmd"
21199                                 fi
21200                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
21201 $as_echo_n "checking for library containing clock_gettime... " >&6; }
21202 if ${ac_cv_search_clock_gettime+:} false; then :
21203   $as_echo_n "(cached) " >&6
21204 else
21205   ac_func_search_save_LIBS=$LIBS
21206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21207 /* end confdefs.h.  */
21208
21209 /* Override any GCC internal prototype to avoid an error.
21210    Use char because int might match the return type of a GCC
21211    builtin and then its argument prototype would still apply.  */
21212 #ifdef __cplusplus
21213 extern "C"
21214 #endif
21215 char clock_gettime ();
21216 int
21217 main ()
21218 {
21219 return clock_gettime ();
21220   ;
21221   return 0;
21222 }
21223 _ACEOF
21224 for ac_lib in '' rt; do
21225   if test -z "$ac_lib"; then
21226     ac_res="none required"
21227   else
21228     ac_res=-l$ac_lib
21229     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21230   fi
21231   if ac_fn_c_try_link "$LINENO"; then :
21232   ac_cv_search_clock_gettime=$ac_res
21233 fi
21234 rm -f core conftest.err conftest.$ac_objext \
21235     conftest$ac_exeext
21236   if ${ac_cv_search_clock_gettime+:} false; then :
21237   break
21238 fi
21239 done
21240 if ${ac_cv_search_clock_gettime+:} false; then :
21241
21242 else
21243   ac_cv_search_clock_gettime=no
21244 fi
21245 rm conftest.$ac_ext
21246 LIBS=$ac_func_search_save_LIBS
21247 fi
21248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
21249 $as_echo "$ac_cv_search_clock_gettime" >&6; }
21250 ac_res=$ac_cv_search_clock_gettime
21251 if test "$ac_res" != no; then :
21252   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21253
21254 fi
21255
21256                         ;;
21257                         *freebsd*|*FreeBSD)
21258                                 case " $LIBOBJS " in
21259   *" getentropy_freebsd.$ac_objext "* ) ;;
21260   *) LIBOBJS="$LIBOBJS getentropy_freebsd.$ac_objext"
21261  ;;
21262 esac
21263
21264                         ;;
21265                         *linux*|Linux|*)
21266                                 case " $LIBOBJS " in
21267   *" getentropy_linux.$ac_objext "* ) ;;
21268   *) LIBOBJS="$LIBOBJS getentropy_linux.$ac_objext"
21269  ;;
21270 esac
21271
21272                                 for ac_func in SHA512_Update
21273 do :
21274   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
21275 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
21276   cat >>confdefs.h <<_ACEOF
21277 #define HAVE_SHA512_UPDATE 1
21278 _ACEOF
21279
21280 else
21281
21282
21283 $as_echo "#define COMPAT_SHA512 1" >>confdefs.h
21284
21285                                         case " $LIBOBJS " in
21286   *" sha512.$ac_objext "* ) ;;
21287   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
21288  ;;
21289 esac
21290
21291
21292 fi
21293 done
21294
21295                                 for ac_header in sys/sysctl.h
21296 do :
21297   ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default
21298 "
21299 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
21300   cat >>confdefs.h <<_ACEOF
21301 #define HAVE_SYS_SYSCTL_H 1
21302 _ACEOF
21303
21304 fi
21305
21306 done
21307
21308                                 for ac_func in getauxval
21309 do :
21310   ac_fn_c_check_func "$LINENO" "getauxval" "ac_cv_func_getauxval"
21311 if test "x$ac_cv_func_getauxval" = xyes; then :
21312   cat >>confdefs.h <<_ACEOF
21313 #define HAVE_GETAUXVAL 1
21314 _ACEOF
21315
21316 fi
21317 done
21318
21319                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
21320 $as_echo_n "checking for library containing clock_gettime... " >&6; }
21321 if ${ac_cv_search_clock_gettime+:} false; then :
21322   $as_echo_n "(cached) " >&6
21323 else
21324   ac_func_search_save_LIBS=$LIBS
21325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21326 /* end confdefs.h.  */
21327
21328 /* Override any GCC internal prototype to avoid an error.
21329    Use char because int might match the return type of a GCC
21330    builtin and then its argument prototype would still apply.  */
21331 #ifdef __cplusplus
21332 extern "C"
21333 #endif
21334 char clock_gettime ();
21335 int
21336 main ()
21337 {
21338 return clock_gettime ();
21339   ;
21340   return 0;
21341 }
21342 _ACEOF
21343 for ac_lib in '' rt; do
21344   if test -z "$ac_lib"; then
21345     ac_res="none required"
21346   else
21347     ac_res=-l$ac_lib
21348     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21349   fi
21350   if ac_fn_c_try_link "$LINENO"; then :
21351   ac_cv_search_clock_gettime=$ac_res
21352 fi
21353 rm -f core conftest.err conftest.$ac_objext \
21354     conftest$ac_exeext
21355   if ${ac_cv_search_clock_gettime+:} false; then :
21356   break
21357 fi
21358 done
21359 if ${ac_cv_search_clock_gettime+:} false; then :
21360
21361 else
21362   ac_cv_search_clock_gettime=no
21363 fi
21364 rm conftest.$ac_ext
21365 LIBS=$ac_func_search_save_LIBS
21366 fi
21367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
21368 $as_echo "$ac_cv_search_clock_gettime" >&6; }
21369 ac_res=$ac_cv_search_clock_gettime
21370 if test "$ac_res" != no; then :
21371   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21372
21373 fi
21374
21375                         ;;
21376                         esac
21377                     fi
21378
21379 fi
21380 done
21381
21382         fi
21383 fi
21384 LIBOBJ_WITHOUT_CTIME="$LIBOBJS"
21385
21386 ac_fn_c_check_func "$LINENO" "ctime_r" "ac_cv_func_ctime_r"
21387 if test "x$ac_cv_func_ctime_r" = xyes; then :
21388   $as_echo "#define HAVE_CTIME_R 1" >>confdefs.h
21389
21390 else
21391   case " $LIBOBJS " in
21392   *" ctime_r.$ac_objext "* ) ;;
21393   *) LIBOBJS="$LIBOBJS ctime_r.$ac_objext"
21394  ;;
21395 esac
21396
21397 fi
21398
21399
21400 ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
21401 if test "x$ac_cv_func_strsep" = xyes; then :
21402   $as_echo "#define HAVE_STRSEP 1" >>confdefs.h
21403
21404 else
21405   case " $LIBOBJS " in
21406   *" strsep.$ac_objext "* ) ;;
21407   *) LIBOBJS="$LIBOBJS strsep.$ac_objext"
21408  ;;
21409 esac
21410
21411 fi
21412
21413
21414
21415 # Check whether --enable-allsymbols was given.
21416 if test "${enable_allsymbols+set}" = set; then :
21417   enableval=$enable_allsymbols;
21418 fi
21419
21420 case "$enable_allsymbols" in
21421         yes)
21422         COMMON_OBJ_ALL_SYMBOLS=""
21423         UBSYMS=""
21424         EXTRALINK="libunbound.la"
21425
21426 $as_echo "#define EXPORT_ALL_SYMBOLS 1" >>confdefs.h
21427
21428         ;;
21429         no|*)
21430         COMMON_OBJ_ALL_SYMBOLS='$(COMMON_OBJ)'
21431         UBSYMS='-export-symbols $(srcdir)/libunbound/ubsyms.def'
21432         EXTRALINK=""
21433         ;;
21434 esac
21435
21436
21437
21438 if test x_$enable_lock_checks = x_yes; then
21439         UBSYMS="-export-symbols clubsyms.def"
21440         cp ${srcdir}/libunbound/ubsyms.def clubsyms.def
21441         echo lock_protect >> clubsyms.def
21442         echo lock_unprotect >> clubsyms.def
21443         echo lock_get_mem >> clubsyms.def
21444         echo checklock_start >> clubsyms.def
21445         echo checklock_stop >> clubsyms.def
21446         echo checklock_lock >> clubsyms.def
21447         echo checklock_unlock >> clubsyms.def
21448         echo checklock_init >> clubsyms.def
21449         echo checklock_thrcreate >> clubsyms.def
21450         echo checklock_thrjoin >> clubsyms.def
21451 fi
21452
21453 # check for dnstap if requested
21454
21455   # Check whether --enable-dnstap was given.
21456 if test "${enable_dnstap+set}" = set; then :
21457   enableval=$enable_dnstap; opt_dnstap=$enableval
21458 else
21459   opt_dnstap=no
21460 fi
21461
21462
21463
21464 # Check whether --with-dnstap-socket-path was given.
21465 if test "${with_dnstap_socket_path+set}" = set; then :
21466   withval=$with_dnstap_socket_path; opt_dnstap_socket_path=$withval
21467 else
21468   opt_dnstap_socket_path="$UNBOUND_RUN_DIR/dnstap.sock"
21469 fi
21470
21471
21472   if test "x$opt_dnstap" != "xno"; then
21473     # Extract the first word of "protoc-c", so it can be a program name with args.
21474 set dummy protoc-c; ac_word=$2
21475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21476 $as_echo_n "checking for $ac_word... " >&6; }
21477 if ${ac_cv_path_PROTOC_C+:} false; then :
21478   $as_echo_n "(cached) " >&6
21479 else
21480   case $PROTOC_C in
21481   [\\/]* | ?:[\\/]*)
21482   ac_cv_path_PROTOC_C="$PROTOC_C" # Let the user override the test with a path.
21483   ;;
21484   *)
21485   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21486 for as_dir in $PATH
21487 do
21488   IFS=$as_save_IFS
21489   test -z "$as_dir" && as_dir=.
21490     for ac_exec_ext in '' $ac_executable_extensions; do
21491   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21492     ac_cv_path_PROTOC_C="$as_dir/$ac_word$ac_exec_ext"
21493     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21494     break 2
21495   fi
21496 done
21497   done
21498 IFS=$as_save_IFS
21499
21500   ;;
21501 esac
21502 fi
21503 PROTOC_C=$ac_cv_path_PROTOC_C
21504 if test -n "$PROTOC_C"; then
21505   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROTOC_C" >&5
21506 $as_echo "$PROTOC_C" >&6; }
21507 else
21508   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21509 $as_echo "no" >&6; }
21510 fi
21511
21512
21513     if test -z "$PROTOC_C"; then
21514       as_fn_error $? "The protoc-c program was not found. Please install protobuf-c!" "$LINENO" 5
21515     fi
21516
21517 # Check whether --with-protobuf-c was given.
21518 if test "${with_protobuf_c+set}" = set; then :
21519   withval=$with_protobuf_c;
21520           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
21521           if test -f $withval/include/google/protobuf-c/protobuf-c.h; then
21522             CFLAGS="$CFLAGS -I$withval/include/google"
21523           else
21524             CFLAGS="$CFLAGS -I$withval/include"
21525           fi
21526           LDFLAGS="$LDFLAGS -L$withval/lib"
21527
21528 else
21529
21530           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
21531           if test -f /usr/include/google/protobuf-c/protobuf-c.h; then
21532             CFLAGS="$CFLAGS -I/usr/include/google"
21533           else
21534             if test -f /usr/local/include/google/protobuf-c/protobuf-c.h; then
21535               CFLAGS="$CFLAGS -I/usr/local/include/google"
21536               LDFLAGS="$LDFLAGS -L/usr/local/lib"
21537             fi
21538           fi
21539
21540 fi
21541
21542     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing protobuf_c_message_pack" >&5
21543 $as_echo_n "checking for library containing protobuf_c_message_pack... " >&6; }
21544 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21545   $as_echo_n "(cached) " >&6
21546 else
21547   ac_func_search_save_LIBS=$LIBS
21548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21549 /* end confdefs.h.  */
21550
21551 /* Override any GCC internal prototype to avoid an error.
21552    Use char because int might match the return type of a GCC
21553    builtin and then its argument prototype would still apply.  */
21554 #ifdef __cplusplus
21555 extern "C"
21556 #endif
21557 char protobuf_c_message_pack ();
21558 int
21559 main ()
21560 {
21561 return protobuf_c_message_pack ();
21562   ;
21563   return 0;
21564 }
21565 _ACEOF
21566 for ac_lib in '' protobuf-c; do
21567   if test -z "$ac_lib"; then
21568     ac_res="none required"
21569   else
21570     ac_res=-l$ac_lib
21571     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21572   fi
21573   if ac_fn_c_try_link "$LINENO"; then :
21574   ac_cv_search_protobuf_c_message_pack=$ac_res
21575 fi
21576 rm -f core conftest.err conftest.$ac_objext \
21577     conftest$ac_exeext
21578   if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21579   break
21580 fi
21581 done
21582 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21583
21584 else
21585   ac_cv_search_protobuf_c_message_pack=no
21586 fi
21587 rm conftest.$ac_ext
21588 LIBS=$ac_func_search_save_LIBS
21589 fi
21590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_protobuf_c_message_pack" >&5
21591 $as_echo "$ac_cv_search_protobuf_c_message_pack" >&6; }
21592 ac_res=$ac_cv_search_protobuf_c_message_pack
21593 if test "$ac_res" != no; then :
21594   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21595
21596 else
21597   as_fn_error $? "The protobuf-c library was not found. Please install protobuf-c!" "$LINENO" 5
21598 fi
21599
21600
21601
21602 $as_echo "#define USE_DNSTAP 1" >>confdefs.h
21603
21604         ENABLE_DNSTAP=1
21605
21606
21607
21608         hdr_dnstap_socket_path="`echo $opt_dnstap_socket_path | sed -e 's/\\\\/\\\\\\\\/g'`"
21609
21610
21611 cat >>confdefs.h <<_ACEOF
21612 #define DNSTAP_SOCKET_PATH "$hdr_dnstap_socket_path"
21613 _ACEOF
21614
21615         DNSTAP_SOCKET_PATH="$hdr_dnstap_socket_path"
21616
21617         DNSTAP_SOCKET_TESTBIN='unbound-dnstap-socket$(EXEEXT)'
21618
21619         DNSTAP_SRC="dnstap/dnstap.c dnstap/dnstap.pb-c.c dnstap/dnstap_fstrm.c dnstap/dtstream.c"
21620
21621         DNSTAP_OBJ="dnstap.lo dnstap.pb-c.lo dnstap_fstrm.lo dtstream.lo"
21622
21623
21624   else
21625
21626         ENABLE_DNSTAP=0
21627
21628
21629
21630   fi
21631
21632
21633 # check for dnscrypt if requested
21634
21635   # Check whether --enable-dnscrypt was given.
21636 if test "${enable_dnscrypt+set}" = set; then :
21637   enableval=$enable_dnscrypt; opt_dnscrypt=$enableval
21638 else
21639   opt_dnscrypt=no
21640 fi
21641
21642
21643   if test "x$opt_dnscrypt" != "xno"; then
21644
21645 # Check whether --with-libsodium was given.
21646 if test "${with_libsodium+set}" = set; then :
21647   withval=$with_libsodium;
21648         CFLAGS="$CFLAGS -I$withval/include"
21649         LDFLAGS="$LDFLAGS -L$withval/lib"
21650
21651 fi
21652
21653     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_init" >&5
21654 $as_echo_n "checking for library containing sodium_init... " >&6; }
21655 if ${ac_cv_search_sodium_init+:} false; then :
21656   $as_echo_n "(cached) " >&6
21657 else
21658   ac_func_search_save_LIBS=$LIBS
21659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21660 /* end confdefs.h.  */
21661
21662 /* Override any GCC internal prototype to avoid an error.
21663    Use char because int might match the return type of a GCC
21664    builtin and then its argument prototype would still apply.  */
21665 #ifdef __cplusplus
21666 extern "C"
21667 #endif
21668 char sodium_init ();
21669 int
21670 main ()
21671 {
21672 return sodium_init ();
21673   ;
21674   return 0;
21675 }
21676 _ACEOF
21677 for ac_lib in '' sodium; do
21678   if test -z "$ac_lib"; then
21679     ac_res="none required"
21680   else
21681     ac_res=-l$ac_lib
21682     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21683   fi
21684   if ac_fn_c_try_link "$LINENO"; then :
21685   ac_cv_search_sodium_init=$ac_res
21686 fi
21687 rm -f core conftest.err conftest.$ac_objext \
21688     conftest$ac_exeext
21689   if ${ac_cv_search_sodium_init+:} false; then :
21690   break
21691 fi
21692 done
21693 if ${ac_cv_search_sodium_init+:} false; then :
21694
21695 else
21696   ac_cv_search_sodium_init=no
21697 fi
21698 rm conftest.$ac_ext
21699 LIBS=$ac_func_search_save_LIBS
21700 fi
21701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_init" >&5
21702 $as_echo "$ac_cv_search_sodium_init" >&6; }
21703 ac_res=$ac_cv_search_sodium_init
21704 if test "$ac_res" != no; then :
21705   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21706
21707 else
21708   as_fn_error $? "The sodium library was not found. Please install sodium!" "$LINENO" 5
21709 fi
21710
21711     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21712 $as_echo_n "checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm... " >&6; }
21713 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21714   $as_echo_n "(cached) " >&6
21715 else
21716   ac_func_search_save_LIBS=$LIBS
21717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21718 /* end confdefs.h.  */
21719
21720 /* Override any GCC internal prototype to avoid an error.
21721    Use char because int might match the return type of a GCC
21722    builtin and then its argument prototype would still apply.  */
21723 #ifdef __cplusplus
21724 extern "C"
21725 #endif
21726 char crypto_box_curve25519xchacha20poly1305_beforenm ();
21727 int
21728 main ()
21729 {
21730 return crypto_box_curve25519xchacha20poly1305_beforenm ();
21731   ;
21732   return 0;
21733 }
21734 _ACEOF
21735 for ac_lib in '' sodium; do
21736   if test -z "$ac_lib"; then
21737     ac_res="none required"
21738   else
21739     ac_res=-l$ac_lib
21740     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21741   fi
21742   if ac_fn_c_try_link "$LINENO"; then :
21743   ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=$ac_res
21744 fi
21745 rm -f core conftest.err conftest.$ac_objext \
21746     conftest$ac_exeext
21747   if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21748   break
21749 fi
21750 done
21751 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21752
21753 else
21754   ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=no
21755 fi
21756 rm conftest.$ac_ext
21757 LIBS=$ac_func_search_save_LIBS
21758 fi
21759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21760 $as_echo "$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&6; }
21761 ac_res=$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm
21762 if test "$ac_res" != no; then :
21763   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21764
21765             ENABLE_DNSCRYPT_XCHACHA20=1
21766
21767
21768 $as_echo "#define USE_DNSCRYPT_XCHACHA20 1" >>confdefs.h
21769
21770
21771 else
21772
21773             ENABLE_DNSCRYPT_XCHACHA20=0
21774
21775
21776 fi
21777
21778     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_set_misuse_handler" >&5
21779 $as_echo_n "checking for library containing sodium_set_misuse_handler... " >&6; }
21780 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21781   $as_echo_n "(cached) " >&6
21782 else
21783   ac_func_search_save_LIBS=$LIBS
21784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21785 /* end confdefs.h.  */
21786
21787 /* Override any GCC internal prototype to avoid an error.
21788    Use char because int might match the return type of a GCC
21789    builtin and then its argument prototype would still apply.  */
21790 #ifdef __cplusplus
21791 extern "C"
21792 #endif
21793 char sodium_set_misuse_handler ();
21794 int
21795 main ()
21796 {
21797 return sodium_set_misuse_handler ();
21798   ;
21799   return 0;
21800 }
21801 _ACEOF
21802 for ac_lib in '' sodium; do
21803   if test -z "$ac_lib"; then
21804     ac_res="none required"
21805   else
21806     ac_res=-l$ac_lib
21807     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21808   fi
21809   if ac_fn_c_try_link "$LINENO"; then :
21810   ac_cv_search_sodium_set_misuse_handler=$ac_res
21811 fi
21812 rm -f core conftest.err conftest.$ac_objext \
21813     conftest$ac_exeext
21814   if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21815   break
21816 fi
21817 done
21818 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21819
21820 else
21821   ac_cv_search_sodium_set_misuse_handler=no
21822 fi
21823 rm conftest.$ac_ext
21824 LIBS=$ac_func_search_save_LIBS
21825 fi
21826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_set_misuse_handler" >&5
21827 $as_echo "$ac_cv_search_sodium_set_misuse_handler" >&6; }
21828 ac_res=$ac_cv_search_sodium_set_misuse_handler
21829 if test "$ac_res" != no; then :
21830   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21831
21832
21833 $as_echo "#define SODIUM_MISUSE_HANDLER 1" >>confdefs.h
21834
21835
21836 fi
21837
21838
21839
21840 $as_echo "#define USE_DNSCRYPT 1" >>confdefs.h
21841
21842         ENABLE_DNSCRYPT=1
21843
21844
21845         DNSCRYPT_SRC="dnscrypt/dnscrypt.c"
21846
21847         DNSCRYPT_OBJ="dnscrypt.lo"
21848
21849
21850   else
21851     ENABLE_DNSCRYPT_XCHACHA20=0
21852
21853
21854         ENABLE_DNSCRYPT=0
21855
21856
21857
21858   fi
21859
21860
21861 # check for cachedb if requested
21862 # Check whether --enable-cachedb was given.
21863 if test "${enable_cachedb+set}" = set; then :
21864   enableval=$enable_cachedb;
21865 fi
21866
21867 # turn on cachedb when hiredis support is enabled.
21868 if test "$found_libhiredis" = "yes"; then enable_cachedb="yes"; fi
21869 case "$enable_cachedb" in
21870     yes)
21871
21872 $as_echo "#define USE_CACHEDB 1" >>confdefs.h
21873
21874         CACHEDB_SRC="cachedb/cachedb.c cachedb/redis.c"
21875
21876         CACHEDB_OBJ="cachedb.lo redis.lo"
21877
21878         ;;
21879     no|*)
21880         # nothing
21881         ;;
21882 esac
21883
21884 # check for ipsecmod if requested
21885 # Check whether --enable-ipsecmod was given.
21886 if test "${enable_ipsecmod+set}" = set; then :
21887   enableval=$enable_ipsecmod;
21888 fi
21889
21890 case "$enable_ipsecmod" in
21891         yes)
21892
21893 $as_echo "#define USE_IPSECMOD 1" >>confdefs.h
21894
21895                 IPSECMOD_OBJ="ipsecmod.lo ipsecmod-whitelist.lo"
21896
21897                 IPSECMOD_HEADER='$(srcdir)/ipsecmod/ipsecmod.h $(srcdir)/ipsecmod/ipsecmod-whitelist.h'
21898
21899                 ;;
21900         no|*)
21901                 # nothing
21902                 ;;
21903 esac
21904
21905 # check for ipset if requested
21906 # Check whether --enable-ipset was given.
21907 if test "${enable_ipset+set}" = set; then :
21908   enableval=$enable_ipset;
21909 fi
21910
21911 case "$enable_ipset" in
21912     yes)
21913
21914 $as_echo "#define USE_IPSET 1" >>confdefs.h
21915
21916                 IPSET_SRC="ipset/ipset.c"
21917
21918                 IPSET_OBJ="ipset.lo"
21919
21920
21921                 # mnl
21922
21923 # Check whether --with-libmnl was given.
21924 if test "${with_libmnl+set}" = set; then :
21925   withval=$with_libmnl;
21926 else
21927    withval="yes"
21928 fi
21929
21930                 found_libmnl="no"
21931                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmnl" >&5
21932 $as_echo_n "checking for libmnl... " >&6; }
21933                 if test x_$withval = x_ -o x_$withval = x_yes; then
21934                         withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
21935                 fi
21936                 for dir in $withval ; do
21937                         if test -f "$dir/include/libmnl/libmnl.h" -o -f "$dir/include/libmnl/libmnl/libmnl.h"; then
21938                                 found_libmnl="yes"
21939                                                                 extralibmnl=""
21940                                 if test -f "$dir/include/libmnl/libmnl/libmnl.h"; then
21941                                         extralibmnl="/libmnl"
21942                                 fi
21943                                 if test "$dir" != "/usr" -o -n "$extralibmnl"; then
21944                                         CPPFLAGS="$CPPFLAGS -I$dir/include$extralibmnl"
21945                                 fi
21946                                 if test "$dir" != "/usr"; then
21947                                         LDFLAGS="$LDFLAGS -L$dir/lib"
21948                                 fi
21949                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
21950 $as_echo "found in $dir" >&6; }
21951                                 LIBS="$LIBS -lmnl"
21952                                 break;
21953                         fi
21954                 done
21955                 if test x_$found_libmnl != x_yes; then
21956                         as_fn_error $? "Could not find libmnl, libmnl.h" "$LINENO" 5
21957                 fi
21958                 ;;
21959     no|*)
21960         # nothing
21961                 ;;
21962 esac
21963 # Check whether --enable-explicit-port-randomisation was given.
21964 if test "${enable_explicit_port_randomisation+set}" = set; then :
21965   enableval=$enable_explicit_port_randomisation;
21966 fi
21967
21968 case "$enable_explicit_port_randomisation" in
21969         no)
21970
21971 $as_echo "#define DISABLE_EXPLICIT_PORT_RANDOMISATION 1" >>confdefs.h
21972
21973                 ;;
21974         yes|*)
21975                 ;;
21976 esac
21977
21978 if echo "$host" | $GREP -i -e linux >/dev/null; then
21979         # Check whether --enable-linux-ip-local-port-range was given.
21980 if test "${enable_linux_ip_local_port_range+set}" = set; then :
21981   enableval=$enable_linux_ip_local_port_range;
21982 fi
21983
21984         case "$enable_linux_ip_local_port_range" in
21985                 yes)
21986
21987 $as_echo "#define USE_LINUX_IP_LOCAL_PORT_RANGE 1" >>confdefs.h
21988
21989                         ;;
21990                 no|*)
21991                         ;;
21992         esac
21993 fi
21994
21995
21996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ${MAKE:-make} supports $< with implicit rule in scope" >&5
21997 $as_echo_n "checking if ${MAKE:-make} supports $< with implicit rule in scope... " >&6; }
21998 # on openBSD, the implicit rule make $< work.
21999 # on Solaris, it does not work ($? is changed sources, $^ lists dependencies).
22000 # gmake works.
22001 cat >conftest.make <<EOF
22002 all:    conftest.lo
22003
22004 conftest.lo foo.lo bla.lo:
22005         if test -f "\$<"; then touch \$@; fi
22006
22007 .SUFFIXES: .lo
22008 .c.lo:
22009         if test -f "\$<"; then touch \$@; fi
22010
22011 conftest.lo:        conftest.dir/conftest.c
22012 EOF
22013 mkdir conftest.dir
22014 touch conftest.dir/conftest.c
22015 rm -f conftest.lo conftest.c
22016 ${MAKE:-make} -f conftest.make >/dev/null
22017 rm -f conftest.make conftest.c conftest.dir/conftest.c
22018 rm -rf conftest.dir
22019 if test ! -f conftest.lo; then
22020         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22021 $as_echo "no" >&6; }
22022         SOURCEDETERMINE='echo "$^" | awk "-F " "{print \$$1;}" > .source'
22023         SOURCEFILE='`cat .source`'
22024 else
22025         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22026 $as_echo "yes" >&6; }
22027         SOURCEDETERMINE=':'
22028         SOURCEFILE='$<'
22029 fi
22030 rm -f conftest.lo
22031
22032
22033
22034 # see if we want to build the library or everything
22035 ALLTARGET="alltargets"
22036 INSTALLTARGET="install-all"
22037
22038 # Check whether --with-libunbound-only was given.
22039 if test "${with_libunbound_only+set}" = set; then :
22040   withval=$with_libunbound_only;
22041         if test "$withval" = "yes"; then
22042                 ALLTARGET="lib"
22043                 INSTALLTARGET="install-lib"
22044         fi
22045
22046 fi
22047
22048 if test $ALLTARGET = "alltargets"; then
22049         if test $USE_NSS = "yes"; then
22050                 as_fn_error $? "--with-nss can only be used in combination with --with-libunbound-only." "$LINENO" 5
22051         fi
22052         if test $USE_NETTLE = "yes"; then
22053                 as_fn_error $? "--with-nettle can only be used in combination with --with-libunbound-only." "$LINENO" 5
22054         fi
22055 fi
22056
22057
22058
22059
22060
22061   { $as_echo "$as_me:${as_lineno-$LINENO}: Stripping extension flags..." >&5
22062 $as_echo "$as_me: Stripping extension flags..." >&6;}
22063
22064   if echo $CFLAGS | grep " -D_GNU_SOURCE" >/dev/null 2>&1; then
22065     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_GNU_SOURCE//g'`"
22066
22067 $as_echo "#define OMITTED__D_GNU_SOURCE 1" >>confdefs.h
22068
22069   fi
22070
22071
22072   if echo $CFLAGS | grep " -D_BSD_SOURCE" >/dev/null 2>&1; then
22073     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_BSD_SOURCE//g'`"
22074
22075 $as_echo "#define OMITTED__D_BSD_SOURCE 1" >>confdefs.h
22076
22077   fi
22078
22079
22080   if echo $CFLAGS | grep " -D_DEFAULT_SOURCE" >/dev/null 2>&1; then
22081     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_DEFAULT_SOURCE//g'`"
22082
22083 $as_echo "#define OMITTED__D_DEFAULT_SOURCE 1" >>confdefs.h
22084
22085   fi
22086
22087
22088   if echo $CFLAGS | grep " -D__EXTENSIONS__" >/dev/null 2>&1; then
22089     CFLAGS="`echo $CFLAGS | sed -e 's/ -D__EXTENSIONS__//g'`"
22090
22091 $as_echo "#define OMITTED__D__EXTENSIONS__ 1" >>confdefs.h
22092
22093   fi
22094
22095
22096   if echo $CFLAGS | grep " -D_POSIX_C_SOURCE=200112" >/dev/null 2>&1; then
22097     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_POSIX_C_SOURCE=200112//g'`"
22098
22099 $as_echo "#define OMITTED__D_POSIX_C_SOURCE_200112 1" >>confdefs.h
22100
22101   fi
22102
22103
22104   if echo $CFLAGS | grep " -D_XOPEN_SOURCE=600" >/dev/null 2>&1; then
22105     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE=600//g'`"
22106
22107 $as_echo "#define OMITTED__D_XOPEN_SOURCE_600 1" >>confdefs.h
22108
22109   fi
22110
22111
22112   if echo $CFLAGS | grep " -D_XOPEN_SOURCE_EXTENDED=1" >/dev/null 2>&1; then
22113     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE_EXTENDED=1//g'`"
22114
22115 $as_echo "#define OMITTED__D_XOPEN_SOURCE_EXTENDED_1 1" >>confdefs.h
22116
22117   fi
22118
22119
22120   if echo $CFLAGS | grep " -D_ALL_SOURCE" >/dev/null 2>&1; then
22121     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_ALL_SOURCE//g'`"
22122
22123 $as_echo "#define OMITTED__D_ALL_SOURCE 1" >>confdefs.h
22124
22125   fi
22126
22127
22128   if echo $CFLAGS | grep " -D_LARGEFILE_SOURCE=1" >/dev/null 2>&1; then
22129     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_LARGEFILE_SOURCE=1//g'`"
22130
22131 $as_echo "#define OMITTED__D_LARGEFILE_SOURCE_1 1" >>confdefs.h
22132
22133   fi
22134
22135
22136 if test -n "$LATE_LDFLAGS"; then
22137   LDFLAGS="$LATE_LDFLAGS $LDFLAGS"
22138 fi
22139 # remove start spaces
22140 LDFLAGS=`echo "$LDFLAGS"|sed -e 's/^ *//'`
22141 LIBS=`echo "$LIBS"|sed -e 's/^ *//'`
22142
22143
22144 cat >>confdefs.h <<_ACEOF
22145 #define MAXSYSLOGMSGLEN 10240
22146 _ACEOF
22147
22148
22149
22150
22151 version=1.18.0
22152
22153 date=`date +'%b %e, %Y'`
22154
22155
22156 ac_config_files="$ac_config_files Makefile doc/example.conf doc/libunbound.3 doc/unbound.8 doc/unbound-anchor.8 doc/unbound-checkconf.8 doc/unbound.conf.5 doc/unbound-control.8 doc/unbound-host.1 smallapp/unbound-control-setup.sh dnstap/dnstap_config.h dnscrypt/dnscrypt_config.h contrib/libunbound.pc contrib/unbound.socket contrib/unbound.service contrib/unbound_portable.service"
22157
22158 ac_config_headers="$ac_config_headers config.h"
22159
22160 cat >confcache <<\_ACEOF
22161 # This file is a shell script that caches the results of configure
22162 # tests run on this system so they can be shared between configure
22163 # scripts and configure runs, see configure's option --config-cache.
22164 # It is not useful on other systems.  If it contains results you don't
22165 # want to keep, you may remove or edit it.
22166 #
22167 # config.status only pays attention to the cache file if you give it
22168 # the --recheck option to rerun configure.
22169 #
22170 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22171 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22172 # following values.
22173
22174 _ACEOF
22175
22176 # The following way of writing the cache mishandles newlines in values,
22177 # but we know of no workaround that is simple, portable, and efficient.
22178 # So, we kill variables containing newlines.
22179 # Ultrix sh set writes to stderr and can't be redirected directly,
22180 # and sets the high bit in the cache file unless we assign to the vars.
22181 (
22182   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
22183     eval ac_val=\$$ac_var
22184     case $ac_val in #(
22185     *${as_nl}*)
22186       case $ac_var in #(
22187       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
22188 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
22189       esac
22190       case $ac_var in #(
22191       _ | IFS | as_nl) ;; #(
22192       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
22193       *) { eval $ac_var=; unset $ac_var;} ;;
22194       esac ;;
22195     esac
22196   done
22197
22198   (set) 2>&1 |
22199     case $as_nl`(ac_space=' '; set) 2>&1` in #(
22200     *${as_nl}ac_space=\ *)
22201       # `set' does not quote correctly, so add quotes: double-quote
22202       # substitution turns \\\\ into \\, and sed turns \\ into \.
22203       sed -n \
22204         "s/'/'\\\\''/g;
22205           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22206       ;; #(
22207     *)
22208       # `set' quotes correctly as required by POSIX, so do not add quotes.
22209       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
22210       ;;
22211     esac |
22212     sort
22213 ) |
22214   sed '
22215      /^ac_cv_env_/b end
22216      t clear
22217      :clear
22218      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22219      t end
22220      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22221      :end' >>confcache
22222 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
22223   if test -w "$cache_file"; then
22224     if test "x$cache_file" != "x/dev/null"; then
22225       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
22226 $as_echo "$as_me: updating cache $cache_file" >&6;}
22227       if test ! -f "$cache_file" || test -h "$cache_file"; then
22228         cat confcache >"$cache_file"
22229       else
22230         case $cache_file in #(
22231         */* | ?:*)
22232           mv -f confcache "$cache_file"$$ &&
22233           mv -f "$cache_file"$$ "$cache_file" ;; #(
22234         *)
22235           mv -f confcache "$cache_file" ;;
22236         esac
22237       fi
22238     fi
22239   else
22240     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
22241 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
22242   fi
22243 fi
22244 rm -f confcache
22245
22246 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22247 # Let make expand exec_prefix.
22248 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22249
22250 DEFS=-DHAVE_CONFIG_H
22251
22252 ac_libobjs=
22253 ac_ltlibobjs=
22254 U=
22255 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22256   # 1. Remove the extension, and $U if already installed.
22257   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
22258   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
22259   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
22260   #    will be set to the directory where LIBOBJS objects are built.
22261   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
22262   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
22263 done
22264 LIBOBJS=$ac_libobjs
22265
22266 LTLIBOBJS=$ac_ltlibobjs
22267
22268
22269 if test -z "${USE_SYSTEMD_TRUE}" && test -z "${USE_SYSTEMD_FALSE}"; then
22270   as_fn_error $? "conditional \"USE_SYSTEMD\" was never defined.
22271 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22272 fi
22273
22274 : "${CONFIG_STATUS=./config.status}"
22275 ac_write_fail=0
22276 ac_clean_files_save=$ac_clean_files
22277 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22278 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
22279 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
22280 as_write_fail=0
22281 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
22282 #! $SHELL
22283 # Generated by $as_me.
22284 # Run this file to recreate the current configuration.
22285 # Compiler output produced by configure, useful for debugging
22286 # configure, is in config.log if it exists.
22287
22288 debug=false
22289 ac_cs_recheck=false
22290 ac_cs_silent=false
22291
22292 SHELL=\${CONFIG_SHELL-$SHELL}
22293 export SHELL
22294 _ASEOF
22295 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
22296 ## -------------------- ##
22297 ## M4sh Initialization. ##
22298 ## -------------------- ##
22299
22300 # Be more Bourne compatible
22301 DUALCASE=1; export DUALCASE # for MKS sh
22302 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22303   emulate sh
22304   NULLCMD=:
22305   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
22306   # is contrary to our usage.  Disable this feature.
22307   alias -g '${1+"$@"}'='"$@"'
22308   setopt NO_GLOB_SUBST
22309 else
22310   case `(set -o) 2>/dev/null` in #(
22311   *posix*) :
22312     set -o posix ;; #(
22313   *) :
22314      ;;
22315 esac
22316 fi
22317
22318
22319 as_nl='
22320 '
22321 export as_nl
22322 # Printing a long string crashes Solaris 7 /usr/bin/printf.
22323 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
22324 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
22325 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
22326 # Prefer a ksh shell builtin over an external printf program on Solaris,
22327 # but without wasting forks for bash or zsh.
22328 if test -z "$BASH_VERSION$ZSH_VERSION" \
22329     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
22330   as_echo='print -r --'
22331   as_echo_n='print -rn --'
22332 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
22333   as_echo='printf %s\n'
22334   as_echo_n='printf %s'
22335 else
22336   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
22337     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
22338     as_echo_n='/usr/ucb/echo -n'
22339   else
22340     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
22341     as_echo_n_body='eval
22342       arg=$1;
22343       case $arg in #(
22344       *"$as_nl"*)
22345         expr "X$arg" : "X\\(.*\\)$as_nl";
22346         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
22347       esac;
22348       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
22349     '
22350     export as_echo_n_body
22351     as_echo_n='sh -c $as_echo_n_body as_echo'
22352   fi
22353   export as_echo_body
22354   as_echo='sh -c $as_echo_body as_echo'
22355 fi
22356
22357 # The user is always right.
22358 if test "${PATH_SEPARATOR+set}" != set; then
22359   PATH_SEPARATOR=:
22360   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
22361     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
22362       PATH_SEPARATOR=';'
22363   }
22364 fi
22365
22366
22367 # IFS
22368 # We need space, tab and new line, in precisely that order.  Quoting is
22369 # there to prevent editors from complaining about space-tab.
22370 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
22371 # splitting by setting IFS to empty value.)
22372 IFS=" ""        $as_nl"
22373
22374 # Find who we are.  Look in the path if we contain no directory separator.
22375 as_myself=
22376 case $0 in #((
22377   *[\\/]* ) as_myself=$0 ;;
22378   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22379 for as_dir in $PATH
22380 do
22381   IFS=$as_save_IFS
22382   test -z "$as_dir" && as_dir=.
22383     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22384   done
22385 IFS=$as_save_IFS
22386
22387      ;;
22388 esac
22389 # We did not find ourselves, most probably we were run as `sh COMMAND'
22390 # in which case we are not to be found in the path.
22391 if test "x$as_myself" = x; then
22392   as_myself=$0
22393 fi
22394 if test ! -f "$as_myself"; then
22395   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
22396   exit 1
22397 fi
22398
22399 # Unset variables that we do not need and which cause bugs (e.g. in
22400 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
22401 # suppresses any "Segmentation fault" message there.  '((' could
22402 # trigger a bug in pdksh 5.2.14.
22403 for as_var in BASH_ENV ENV MAIL MAILPATH
22404 do eval test x\${$as_var+set} = xset \
22405   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
22406 done
22407 PS1='$ '
22408 PS2='> '
22409 PS4='+ '
22410
22411 # NLS nuisances.
22412 LC_ALL=C
22413 export LC_ALL
22414 LANGUAGE=C
22415 export LANGUAGE
22416
22417 # CDPATH.
22418 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22419
22420
22421 # as_fn_error STATUS ERROR [LINENO LOG_FD]
22422 # ----------------------------------------
22423 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
22424 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22425 # script with STATUS, using 1 if that was 0.
22426 as_fn_error ()
22427 {
22428   as_status=$1; test $as_status -eq 0 && as_status=1
22429   if test "$4"; then
22430     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
22431     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
22432   fi
22433   $as_echo "$as_me: error: $2" >&2
22434   as_fn_exit $as_status
22435 } # as_fn_error
22436
22437
22438 # as_fn_set_status STATUS
22439 # -----------------------
22440 # Set $? to STATUS, without forking.
22441 as_fn_set_status ()
22442 {
22443   return $1
22444 } # as_fn_set_status
22445
22446 # as_fn_exit STATUS
22447 # -----------------
22448 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
22449 as_fn_exit ()
22450 {
22451   set +e
22452   as_fn_set_status $1
22453   exit $1
22454 } # as_fn_exit
22455
22456 # as_fn_unset VAR
22457 # ---------------
22458 # Portably unset VAR.
22459 as_fn_unset ()
22460 {
22461   { eval $1=; unset $1;}
22462 }
22463 as_unset=as_fn_unset
22464 # as_fn_append VAR VALUE
22465 # ----------------------
22466 # Append the text in VALUE to the end of the definition contained in VAR. Take
22467 # advantage of any shell optimizations that allow amortized linear growth over
22468 # repeated appends, instead of the typical quadratic growth present in naive
22469 # implementations.
22470 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
22471   eval 'as_fn_append ()
22472   {
22473     eval $1+=\$2
22474   }'
22475 else
22476   as_fn_append ()
22477   {
22478     eval $1=\$$1\$2
22479   }
22480 fi # as_fn_append
22481
22482 # as_fn_arith ARG...
22483 # ------------------
22484 # Perform arithmetic evaluation on the ARGs, and store the result in the
22485 # global $as_val. Take advantage of shells that can avoid forks. The arguments
22486 # must be portable across $(()) and expr.
22487 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
22488   eval 'as_fn_arith ()
22489   {
22490     as_val=$(( $* ))
22491   }'
22492 else
22493   as_fn_arith ()
22494   {
22495     as_val=`expr "$@" || test $? -eq 1`
22496   }
22497 fi # as_fn_arith
22498
22499
22500 if expr a : '\(a\)' >/dev/null 2>&1 &&
22501    test "X`expr 00001 : '.*\(...\)'`" = X001; then
22502   as_expr=expr
22503 else
22504   as_expr=false
22505 fi
22506
22507 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
22508   as_basename=basename
22509 else
22510   as_basename=false
22511 fi
22512
22513 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
22514   as_dirname=dirname
22515 else
22516   as_dirname=false
22517 fi
22518
22519 as_me=`$as_basename -- "$0" ||
22520 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22521          X"$0" : 'X\(//\)$' \| \
22522          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
22523 $as_echo X/"$0" |
22524     sed '/^.*\/\([^/][^/]*\)\/*$/{
22525             s//\1/
22526             q
22527           }
22528           /^X\/\(\/\/\)$/{
22529             s//\1/
22530             q
22531           }
22532           /^X\/\(\/\).*/{
22533             s//\1/
22534             q
22535           }
22536           s/.*/./; q'`
22537
22538 # Avoid depending upon Character Ranges.
22539 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22540 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22541 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22542 as_cr_digits='0123456789'
22543 as_cr_alnum=$as_cr_Letters$as_cr_digits
22544
22545 ECHO_C= ECHO_N= ECHO_T=
22546 case `echo -n x` in #(((((
22547 -n*)
22548   case `echo 'xy\c'` in
22549   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
22550   xy)  ECHO_C='\c';;
22551   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
22552        ECHO_T=' ';;
22553   esac;;
22554 *)
22555   ECHO_N='-n';;
22556 esac
22557
22558 rm -f conf$$ conf$$.exe conf$$.file
22559 if test -d conf$$.dir; then
22560   rm -f conf$$.dir/conf$$.file
22561 else
22562   rm -f conf$$.dir
22563   mkdir conf$$.dir 2>/dev/null
22564 fi
22565 if (echo >conf$$.file) 2>/dev/null; then
22566   if ln -s conf$$.file conf$$ 2>/dev/null; then
22567     as_ln_s='ln -s'
22568     # ... but there are two gotchas:
22569     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
22570     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22571     # In both cases, we have to default to `cp -pR'.
22572     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22573       as_ln_s='cp -pR'
22574   elif ln conf$$.file conf$$ 2>/dev/null; then
22575     as_ln_s=ln
22576   else
22577     as_ln_s='cp -pR'
22578   fi
22579 else
22580   as_ln_s='cp -pR'
22581 fi
22582 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
22583 rmdir conf$$.dir 2>/dev/null
22584
22585
22586 # as_fn_mkdir_p
22587 # -------------
22588 # Create "$as_dir" as a directory, including parents if necessary.
22589 as_fn_mkdir_p ()
22590 {
22591
22592   case $as_dir in #(
22593   -*) as_dir=./$as_dir;;
22594   esac
22595   test -d "$as_dir" || eval $as_mkdir_p || {
22596     as_dirs=
22597     while :; do
22598       case $as_dir in #(
22599       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
22600       *) as_qdir=$as_dir;;
22601       esac
22602       as_dirs="'$as_qdir' $as_dirs"
22603       as_dir=`$as_dirname -- "$as_dir" ||
22604 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22605          X"$as_dir" : 'X\(//\)[^/]' \| \
22606          X"$as_dir" : 'X\(//\)$' \| \
22607          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
22608 $as_echo X"$as_dir" |
22609     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22610             s//\1/
22611             q
22612           }
22613           /^X\(\/\/\)[^/].*/{
22614             s//\1/
22615             q
22616           }
22617           /^X\(\/\/\)$/{
22618             s//\1/
22619             q
22620           }
22621           /^X\(\/\).*/{
22622             s//\1/
22623             q
22624           }
22625           s/.*/./; q'`
22626       test -d "$as_dir" && break
22627     done
22628     test -z "$as_dirs" || eval "mkdir $as_dirs"
22629   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
22630
22631
22632 } # as_fn_mkdir_p
22633 if mkdir -p . 2>/dev/null; then
22634   as_mkdir_p='mkdir -p "$as_dir"'
22635 else
22636   test -d ./-p && rmdir ./-p
22637   as_mkdir_p=false
22638 fi
22639
22640
22641 # as_fn_executable_p FILE
22642 # -----------------------
22643 # Test if FILE is an executable regular file.
22644 as_fn_executable_p ()
22645 {
22646   test -f "$1" && test -x "$1"
22647 } # as_fn_executable_p
22648 as_test_x='test -x'
22649 as_executable_p=as_fn_executable_p
22650
22651 # Sed expression to map a string onto a valid CPP name.
22652 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
22653
22654 # Sed expression to map a string onto a valid variable name.
22655 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
22656
22657
22658 exec 6>&1
22659 ## ----------------------------------- ##
22660 ## Main body of $CONFIG_STATUS script. ##
22661 ## ----------------------------------- ##
22662 _ASEOF
22663 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
22664
22665 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22666 # Save the log message, to keep $0 and so on meaningful, and to
22667 # report actual input values of CONFIG_FILES etc. instead of their
22668 # values after options handling.
22669 ac_log="
22670 This file was extended by unbound $as_me 1.18.0, which was
22671 generated by GNU Autoconf 2.69.  Invocation command line was
22672
22673   CONFIG_FILES    = $CONFIG_FILES
22674   CONFIG_HEADERS  = $CONFIG_HEADERS
22675   CONFIG_LINKS    = $CONFIG_LINKS
22676   CONFIG_COMMANDS = $CONFIG_COMMANDS
22677   $ $0 $@
22678
22679 on `(hostname || uname -n) 2>/dev/null | sed 1q`
22680 "
22681
22682 _ACEOF
22683
22684 case $ac_config_files in *"
22685 "*) set x $ac_config_files; shift; ac_config_files=$*;;
22686 esac
22687
22688 case $ac_config_headers in *"
22689 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
22690 esac
22691
22692
22693 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22694 # Files that config.status was made for.
22695 config_files="$ac_config_files"
22696 config_headers="$ac_config_headers"
22697 config_commands="$ac_config_commands"
22698
22699 _ACEOF
22700
22701 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22702 ac_cs_usage="\
22703 \`$as_me' instantiates files and other configuration actions
22704 from templates according to the current configuration.  Unless the files
22705 and actions are specified as TAGs, all are instantiated by default.
22706
22707 Usage: $0 [OPTION]... [TAG]...
22708
22709   -h, --help       print this help, then exit
22710   -V, --version    print version number and configuration settings, then exit
22711       --config     print configuration, then exit
22712   -q, --quiet, --silent
22713                    do not print progress messages
22714   -d, --debug      don't remove temporary files
22715       --recheck    update $as_me by reconfiguring in the same conditions
22716       --file=FILE[:TEMPLATE]
22717                    instantiate the configuration file FILE
22718       --header=FILE[:TEMPLATE]
22719                    instantiate the configuration header FILE
22720
22721 Configuration files:
22722 $config_files
22723
22724 Configuration headers:
22725 $config_headers
22726
22727 Configuration commands:
22728 $config_commands
22729
22730 Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>."
22731
22732 _ACEOF
22733 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22734 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
22735 ac_cs_version="\\
22736 unbound config.status 1.18.0
22737 configured by $0, generated by GNU Autoconf 2.69,
22738   with options \\"\$ac_cs_config\\"
22739
22740 Copyright (C) 2012 Free Software Foundation, Inc.
22741 This config.status script is free software; the Free Software Foundation
22742 gives unlimited permission to copy, distribute and modify it."
22743
22744 ac_pwd='$ac_pwd'
22745 srcdir='$srcdir'
22746 AWK='$AWK'
22747 test -n "\$AWK" || AWK=awk
22748 _ACEOF
22749
22750 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22751 # The default lists apply if the user does not specify any file.
22752 ac_need_defaults=:
22753 while test $# != 0
22754 do
22755   case $1 in
22756   --*=?*)
22757     ac_option=`expr "X$1" : 'X\([^=]*\)='`
22758     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
22759     ac_shift=:
22760     ;;
22761   --*=)
22762     ac_option=`expr "X$1" : 'X\([^=]*\)='`
22763     ac_optarg=
22764     ac_shift=:
22765     ;;
22766   *)
22767     ac_option=$1
22768     ac_optarg=$2
22769     ac_shift=shift
22770     ;;
22771   esac
22772
22773   case $ac_option in
22774   # Handling of the options.
22775   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22776     ac_cs_recheck=: ;;
22777   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
22778     $as_echo "$ac_cs_version"; exit ;;
22779   --config | --confi | --conf | --con | --co | --c )
22780     $as_echo "$ac_cs_config"; exit ;;
22781   --debug | --debu | --deb | --de | --d | -d )
22782     debug=: ;;
22783   --file | --fil | --fi | --f )
22784     $ac_shift
22785     case $ac_optarg in
22786     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22787     '') as_fn_error $? "missing file argument" ;;
22788     esac
22789     as_fn_append CONFIG_FILES " '$ac_optarg'"
22790     ac_need_defaults=false;;
22791   --header | --heade | --head | --hea )
22792     $ac_shift
22793     case $ac_optarg in
22794     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22795     esac
22796     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
22797     ac_need_defaults=false;;
22798   --he | --h)
22799     # Conflict between --help and --header
22800     as_fn_error $? "ambiguous option: \`$1'
22801 Try \`$0 --help' for more information.";;
22802   --help | --hel | -h )
22803     $as_echo "$ac_cs_usage"; exit ;;
22804   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22805   | -silent | --silent | --silen | --sile | --sil | --si | --s)
22806     ac_cs_silent=: ;;
22807
22808   # This is an error.
22809   -*) as_fn_error $? "unrecognized option: \`$1'
22810 Try \`$0 --help' for more information." ;;
22811
22812   *) as_fn_append ac_config_targets " $1"
22813      ac_need_defaults=false ;;
22814
22815   esac
22816   shift
22817 done
22818
22819 ac_configure_extra_args=
22820
22821 if $ac_cs_silent; then
22822   exec 6>/dev/null
22823   ac_configure_extra_args="$ac_configure_extra_args --silent"
22824 fi
22825
22826 _ACEOF
22827 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22828 if \$ac_cs_recheck; then
22829   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22830   shift
22831   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
22832   CONFIG_SHELL='$SHELL'
22833   export CONFIG_SHELL
22834   exec "\$@"
22835 fi
22836
22837 _ACEOF
22838 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22839 exec 5>>config.log
22840 {
22841   echo
22842   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22843 ## Running $as_me. ##
22844 _ASBOX
22845   $as_echo "$ac_log"
22846 } >&5
22847
22848 _ACEOF
22849 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22850 #
22851 # INIT-COMMANDS
22852 #
22853
22854
22855 # The HP-UX ksh and POSIX shell print the target directory to stdout
22856 # if CDPATH is set.
22857 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22858
22859 sed_quote_subst='$sed_quote_subst'
22860 double_quote_subst='$double_quote_subst'
22861 delay_variable_subst='$delay_variable_subst'
22862 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
22863 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
22864 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
22865 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
22866 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
22867 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
22868 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
22869 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
22870 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
22871 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
22872 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
22873 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
22874 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
22875 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
22876 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
22877 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
22878 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
22879 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
22880 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
22881 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
22882 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
22883 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
22884 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
22885 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
22886 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
22887 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
22888 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
22889 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
22890 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
22891 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
22892 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
22893 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
22894 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
22895 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
22896 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
22897 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
22898 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
22899 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
22900 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
22901 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
22902 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
22903 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
22904 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
22905 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
22906 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
22907 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
22908 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22909 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22910 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
22911 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
22912 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
22913 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
22914 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
22915 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
22916 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
22917 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
22918 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
22919 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
22920 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
22921 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
22922 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
22923 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
22924 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
22925 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
22926 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
22927 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
22928 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
22929 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
22930 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
22931 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
22932 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
22933 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
22934 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
22935 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
22936 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
22937 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
22938 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
22939 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
22940 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
22941 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22942 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
22943 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
22944 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
22945 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
22946 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
22947 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
22948 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22949 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
22950 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22951 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
22952 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22953 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
22954 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
22955 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
22956 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
22957 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
22958 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
22959 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
22960 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
22961 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
22962 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
22963 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
22964 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
22965 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
22966 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
22967 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
22968 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
22969 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
22970 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
22971 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
22972 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
22973 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
22974 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
22975 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
22976 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
22977 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
22978 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
22979 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
22980 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
22981 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
22982 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
22983 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22984 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22985 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
22986 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
22987 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
22988 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
22989 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
22990 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
22991 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
22992 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
22993 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
22994 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
22995 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
22996 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
22997
22998 LTCC='$LTCC'
22999 LTCFLAGS='$LTCFLAGS'
23000 compiler='$compiler_DEFAULT'
23001
23002 # A function that is used when there is no print builtin or printf.
23003 func_fallback_echo ()
23004 {
23005   eval 'cat <<_LTECHO_EOF
23006 \$1
23007 _LTECHO_EOF'
23008 }
23009
23010 # Quote evaled strings.
23011 for var in SHELL \
23012 ECHO \
23013 PATH_SEPARATOR \
23014 SED \
23015 GREP \
23016 EGREP \
23017 FGREP \
23018 LD \
23019 NM \
23020 LN_S \
23021 lt_SP2NL \
23022 lt_NL2SP \
23023 reload_flag \
23024 OBJDUMP \
23025 deplibs_check_method \
23026 file_magic_cmd \
23027 file_magic_glob \
23028 want_nocaseglob \
23029 DLLTOOL \
23030 sharedlib_from_linklib_cmd \
23031 AR \
23032 AR_FLAGS \
23033 archiver_list_spec \
23034 STRIP \
23035 RANLIB \
23036 CC \
23037 CFLAGS \
23038 compiler \
23039 lt_cv_sys_global_symbol_pipe \
23040 lt_cv_sys_global_symbol_to_cdecl \
23041 lt_cv_sys_global_symbol_to_import \
23042 lt_cv_sys_global_symbol_to_c_name_address \
23043 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
23044 lt_cv_nm_interface \
23045 nm_file_list_spec \
23046 lt_cv_truncate_bin \
23047 lt_prog_compiler_no_builtin_flag \
23048 lt_prog_compiler_pic \
23049 lt_prog_compiler_wl \
23050 lt_prog_compiler_static \
23051 lt_cv_prog_compiler_c_o \
23052 need_locks \
23053 MANIFEST_TOOL \
23054 DSYMUTIL \
23055 NMEDIT \
23056 LIPO \
23057 OTOOL \
23058 OTOOL64 \
23059 shrext_cmds \
23060 export_dynamic_flag_spec \
23061 whole_archive_flag_spec \
23062 compiler_needs_object \
23063 with_gnu_ld \
23064 allow_undefined_flag \
23065 no_undefined_flag \
23066 hardcode_libdir_flag_spec \
23067 hardcode_libdir_separator \
23068 exclude_expsyms \
23069 include_expsyms \
23070 file_list_spec \
23071 variables_saved_for_relink \
23072 libname_spec \
23073 library_names_spec \
23074 soname_spec \
23075 install_override_mode \
23076 finish_eval \
23077 old_striplib \
23078 striplib; do
23079     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
23080     *[\\\\\\\`\\"\\\$]*)
23081       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
23082       ;;
23083     *)
23084       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
23085       ;;
23086     esac
23087 done
23088
23089 # Double-quote double-evaled strings.
23090 for var in reload_cmds \
23091 old_postinstall_cmds \
23092 old_postuninstall_cmds \
23093 old_archive_cmds \
23094 extract_expsyms_cmds \
23095 old_archive_from_new_cmds \
23096 old_archive_from_expsyms_cmds \
23097 archive_cmds \
23098 archive_expsym_cmds \
23099 module_cmds \
23100 module_expsym_cmds \
23101 export_symbols_cmds \
23102 prelink_cmds \
23103 postlink_cmds \
23104 postinstall_cmds \
23105 postuninstall_cmds \
23106 finish_cmds \
23107 sys_lib_search_path_spec \
23108 configure_time_dlsearch_path \
23109 configure_time_lt_sys_library_path; do
23110     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
23111     *[\\\\\\\`\\"\\\$]*)
23112       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
23113       ;;
23114     *)
23115       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
23116       ;;
23117     esac
23118 done
23119
23120 ac_aux_dir='$ac_aux_dir'
23121
23122 # See if we are running on zsh, and set the options that allow our
23123 # commands through without removal of \ escapes INIT.
23124 if test -n "\${ZSH_VERSION+set}"; then
23125    setopt NO_GLOB_SUBST
23126 fi
23127
23128
23129     PACKAGE='$PACKAGE'
23130     VERSION='$VERSION'
23131     RM='$RM'
23132     ofile='$ofile'
23133
23134
23135
23136
23137 _ACEOF
23138
23139 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23140
23141 # Handling of arguments.
23142 for ac_config_target in $ac_config_targets
23143 do
23144   case $ac_config_target in
23145     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
23146     "disable-rpath") CONFIG_COMMANDS="$CONFIG_COMMANDS disable-rpath" ;;
23147     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23148     "doc/example.conf") CONFIG_FILES="$CONFIG_FILES doc/example.conf" ;;
23149     "doc/libunbound.3") CONFIG_FILES="$CONFIG_FILES doc/libunbound.3" ;;
23150     "doc/unbound.8") CONFIG_FILES="$CONFIG_FILES doc/unbound.8" ;;
23151     "doc/unbound-anchor.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-anchor.8" ;;
23152     "doc/unbound-checkconf.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-checkconf.8" ;;
23153     "doc/unbound.conf.5") CONFIG_FILES="$CONFIG_FILES doc/unbound.conf.5" ;;
23154     "doc/unbound-control.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-control.8" ;;
23155     "doc/unbound-host.1") CONFIG_FILES="$CONFIG_FILES doc/unbound-host.1" ;;
23156     "smallapp/unbound-control-setup.sh") CONFIG_FILES="$CONFIG_FILES smallapp/unbound-control-setup.sh" ;;
23157     "dnstap/dnstap_config.h") CONFIG_FILES="$CONFIG_FILES dnstap/dnstap_config.h" ;;
23158     "dnscrypt/dnscrypt_config.h") CONFIG_FILES="$CONFIG_FILES dnscrypt/dnscrypt_config.h" ;;
23159     "contrib/libunbound.pc") CONFIG_FILES="$CONFIG_FILES contrib/libunbound.pc" ;;
23160     "contrib/unbound.socket") CONFIG_FILES="$CONFIG_FILES contrib/unbound.socket" ;;
23161     "contrib/unbound.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound.service" ;;
23162     "contrib/unbound_portable.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound_portable.service" ;;
23163     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
23164
23165   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
23166   esac
23167 done
23168
23169
23170 # If the user did not use the arguments to specify the items to instantiate,
23171 # then the envvar interface is used.  Set only those that are not.
23172 # We use the long form for the default assignment because of an extremely
23173 # bizarre bug on SunOS 4.1.3.
23174 if $ac_need_defaults; then
23175   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23176   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23177   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23178 fi
23179
23180 # Have a temporary directory for convenience.  Make it in the build tree
23181 # simply because there is no reason against having it here, and in addition,
23182 # creating and moving files from /tmp can sometimes cause problems.
23183 # Hook for its removal unless debugging.
23184 # Note that there is a small window in which the directory will not be cleaned:
23185 # after its creation but before its name has been assigned to `$tmp'.
23186 $debug ||
23187 {
23188   tmp= ac_tmp=
23189   trap 'exit_status=$?
23190   : "${ac_tmp:=$tmp}"
23191   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
23192 ' 0
23193   trap 'as_fn_exit 1' 1 2 13 15
23194 }
23195 # Create a (secure) tmp directory for tmp files.
23196
23197 {
23198   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
23199   test -d "$tmp"
23200 }  ||
23201 {
23202   tmp=./conf$$-$RANDOM
23203   (umask 077 && mkdir "$tmp")
23204 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
23205 ac_tmp=$tmp
23206
23207 # Set up the scripts for CONFIG_FILES section.
23208 # No need to generate them if there are no CONFIG_FILES.
23209 # This happens for instance with `./config.status config.h'.
23210 if test -n "$CONFIG_FILES"; then
23211
23212
23213 ac_cr=`echo X | tr X '\015'`
23214 # On cygwin, bash can eat \r inside `` if the user requested igncr.
23215 # But we know of no other shell where ac_cr would be empty at this
23216 # point, so we can use a bashism as a fallback.
23217 if test "x$ac_cr" = x; then
23218   eval ac_cr=\$\'\\r\'
23219 fi
23220 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
23221 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
23222   ac_cs_awk_cr='\\r'
23223 else
23224   ac_cs_awk_cr=$ac_cr
23225 fi
23226
23227 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
23228 _ACEOF
23229
23230
23231 {
23232   echo "cat >conf$$subs.awk <<_ACEOF" &&
23233   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
23234   echo "_ACEOF"
23235 } >conf$$subs.sh ||
23236   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23237 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
23238 ac_delim='%!_!# '
23239 for ac_last_try in false false false false false :; do
23240   . ./conf$$subs.sh ||
23241     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23242
23243   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
23244   if test $ac_delim_n = $ac_delim_num; then
23245     break
23246   elif $ac_last_try; then
23247     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23248   else
23249     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23250   fi
23251 done
23252 rm -f conf$$subs.sh
23253
23254 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23255 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
23256 _ACEOF
23257 sed -n '
23258 h
23259 s/^/S["/; s/!.*/"]=/
23260 p
23261 g
23262 s/^[^!]*!//
23263 :repl
23264 t repl
23265 s/'"$ac_delim"'$//
23266 t delim
23267 :nl
23268 h
23269 s/\(.\{148\}\)..*/\1/
23270 t more1
23271 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
23272 p
23273 n
23274 b repl
23275 :more1
23276 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23277 p
23278 g
23279 s/.\{148\}//
23280 t nl
23281 :delim
23282 h
23283 s/\(.\{148\}\)..*/\1/
23284 t more2
23285 s/["\\]/\\&/g; s/^/"/; s/$/"/
23286 p
23287 b
23288 :more2
23289 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23290 p
23291 g
23292 s/.\{148\}//
23293 t delim
23294 ' <conf$$subs.awk | sed '
23295 /^[^""]/{
23296   N
23297   s/\n//
23298 }
23299 ' >>$CONFIG_STATUS || ac_write_fail=1
23300 rm -f conf$$subs.awk
23301 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23302 _ACAWK
23303 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
23304   for (key in S) S_is_set[key] = 1
23305   FS = "\a"
23306
23307 }
23308 {
23309   line = $ 0
23310   nfields = split(line, field, "@")
23311   substed = 0
23312   len = length(field[1])
23313   for (i = 2; i < nfields; i++) {
23314     key = field[i]
23315     keylen = length(key)
23316     if (S_is_set[key]) {
23317       value = S[key]
23318       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
23319       len += length(value) + length(field[++i])
23320       substed = 1
23321     } else
23322       len += 1 + keylen
23323   }
23324
23325   print line
23326 }
23327
23328 _ACAWK
23329 _ACEOF
23330 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23331 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
23332   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
23333 else
23334   cat
23335 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
23336   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
23337 _ACEOF
23338
23339 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
23340 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
23341 # trailing colons and then remove the whole line if VPATH becomes empty
23342 # (actually we leave an empty line to preserve line numbers).
23343 if test "x$srcdir" = x.; then
23344   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
23345 h
23346 s///
23347 s/^/:/
23348 s/[      ]*$/:/
23349 s/:\$(srcdir):/:/g
23350 s/:\${srcdir}:/:/g
23351 s/:@srcdir@:/:/g
23352 s/^:*//
23353 s/:*$//
23354 x
23355 s/\(=[   ]*\).*/\1/
23356 G
23357 s/\n//
23358 s/^[^=]*=[       ]*$//
23359 }'
23360 fi
23361
23362 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23363 fi # test -n "$CONFIG_FILES"
23364
23365 # Set up the scripts for CONFIG_HEADERS section.
23366 # No need to generate them if there are no CONFIG_HEADERS.
23367 # This happens for instance with `./config.status Makefile'.
23368 if test -n "$CONFIG_HEADERS"; then
23369 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
23370 BEGIN {
23371 _ACEOF
23372
23373 # Transform confdefs.h into an awk script `defines.awk', embedded as
23374 # here-document in config.status, that substitutes the proper values into
23375 # config.h.in to produce config.h.
23376
23377 # Create a delimiter string that does not exist in confdefs.h, to ease
23378 # handling of long lines.
23379 ac_delim='%!_!# '
23380 for ac_last_try in false false :; do
23381   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
23382   if test -z "$ac_tt"; then
23383     break
23384   elif $ac_last_try; then
23385     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
23386   else
23387     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23388   fi
23389 done
23390
23391 # For the awk script, D is an array of macro values keyed by name,
23392 # likewise P contains macro parameters if any.  Preserve backslash
23393 # newline sequences.
23394
23395 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
23396 sed -n '
23397 s/.\{148\}/&'"$ac_delim"'/g
23398 t rset
23399 :rset
23400 s/^[     ]*#[    ]*define[       ][      ]*/ /
23401 t def
23402 d
23403 :def
23404 s/\\$//
23405 t bsnl
23406 s/["\\]/\\&/g
23407 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
23408 D["\1"]=" \3"/p
23409 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
23410 d
23411 :bsnl
23412 s/["\\]/\\&/g
23413 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
23414 D["\1"]=" \3\\\\\\n"\\/p
23415 t cont
23416 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
23417 t cont
23418 d
23419 :cont
23420 n
23421 s/.\{148\}/&'"$ac_delim"'/g
23422 t clear
23423 :clear
23424 s/\\$//
23425 t bsnlc
23426 s/["\\]/\\&/g; s/^/"/; s/$/"/p
23427 d
23428 :bsnlc
23429 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
23430 b cont
23431 ' <confdefs.h | sed '
23432 s/'"$ac_delim"'/"\\\
23433 "/g' >>$CONFIG_STATUS || ac_write_fail=1
23434
23435 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23436   for (key in D) D_is_set[key] = 1
23437   FS = "\a"
23438 }
23439 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
23440   line = \$ 0
23441   split(line, arg, " ")
23442   if (arg[1] == "#") {
23443     defundef = arg[2]
23444     mac1 = arg[3]
23445   } else {
23446     defundef = substr(arg[1], 2)
23447     mac1 = arg[2]
23448   }
23449   split(mac1, mac2, "(") #)
23450   macro = mac2[1]
23451   prefix = substr(line, 1, index(line, defundef) - 1)
23452   if (D_is_set[macro]) {
23453     # Preserve the white space surrounding the "#".
23454     print prefix "define", macro P[macro] D[macro]
23455     next
23456   } else {
23457     # Replace #undef with comments.  This is necessary, for example,
23458     # in the case of _POSIX_SOURCE, which is predefined and required
23459     # on some systems where configure will not decide to define it.
23460     if (defundef == "undef") {
23461       print "/*", prefix defundef, macro, "*/"
23462       next
23463     }
23464   }
23465 }
23466 { print }
23467 _ACAWK
23468 _ACEOF
23469 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23470   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
23471 fi # test -n "$CONFIG_HEADERS"
23472
23473
23474 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
23475 shift
23476 for ac_tag
23477 do
23478   case $ac_tag in
23479   :[FHLC]) ac_mode=$ac_tag; continue;;
23480   esac
23481   case $ac_mode$ac_tag in
23482   :[FHL]*:*);;
23483   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
23484   :[FH]-) ac_tag=-:-;;
23485   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
23486   esac
23487   ac_save_IFS=$IFS
23488   IFS=:
23489   set x $ac_tag
23490   IFS=$ac_save_IFS
23491   shift
23492   ac_file=$1
23493   shift
23494
23495   case $ac_mode in
23496   :L) ac_source=$1;;
23497   :[FH])
23498     ac_file_inputs=
23499     for ac_f
23500     do
23501       case $ac_f in
23502       -) ac_f="$ac_tmp/stdin";;
23503       *) # Look for the file first in the build tree, then in the source tree
23504          # (if the path is not absolute).  The absolute path cannot be DOS-style,
23505          # because $ac_f cannot contain `:'.
23506          test -f "$ac_f" ||
23507            case $ac_f in
23508            [\\/$]*) false;;
23509            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
23510            esac ||
23511            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
23512       esac
23513       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
23514       as_fn_append ac_file_inputs " '$ac_f'"
23515     done
23516
23517     # Let's still pretend it is `configure' which instantiates (i.e., don't
23518     # use $as_me), people would be surprised to read:
23519     #    /* config.h.  Generated by config.status.  */
23520     configure_input='Generated from '`
23521           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
23522         `' by configure.'
23523     if test x"$ac_file" != x-; then
23524       configure_input="$ac_file.  $configure_input"
23525       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
23526 $as_echo "$as_me: creating $ac_file" >&6;}
23527     fi
23528     # Neutralize special characters interpreted by sed in replacement strings.
23529     case $configure_input in #(
23530     *\&* | *\|* | *\\* )
23531        ac_sed_conf_input=`$as_echo "$configure_input" |
23532        sed 's/[\\\\&|]/\\\\&/g'`;; #(
23533     *) ac_sed_conf_input=$configure_input;;
23534     esac
23535
23536     case $ac_tag in
23537     *:-:* | *:-) cat >"$ac_tmp/stdin" \
23538       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
23539     esac
23540     ;;
23541   esac
23542
23543   ac_dir=`$as_dirname -- "$ac_file" ||
23544 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23545          X"$ac_file" : 'X\(//\)[^/]' \| \
23546          X"$ac_file" : 'X\(//\)$' \| \
23547          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
23548 $as_echo X"$ac_file" |
23549     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23550             s//\1/
23551             q
23552           }
23553           /^X\(\/\/\)[^/].*/{
23554             s//\1/
23555             q
23556           }
23557           /^X\(\/\/\)$/{
23558             s//\1/
23559             q
23560           }
23561           /^X\(\/\).*/{
23562             s//\1/
23563             q
23564           }
23565           s/.*/./; q'`
23566   as_dir="$ac_dir"; as_fn_mkdir_p
23567   ac_builddir=.
23568
23569 case "$ac_dir" in
23570 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
23571 *)
23572   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
23573   # A ".." for each directory in $ac_dir_suffix.
23574   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
23575   case $ac_top_builddir_sub in
23576   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
23577   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
23578   esac ;;
23579 esac
23580 ac_abs_top_builddir=$ac_pwd
23581 ac_abs_builddir=$ac_pwd$ac_dir_suffix
23582 # for backward compatibility:
23583 ac_top_builddir=$ac_top_build_prefix
23584
23585 case $srcdir in
23586   .)  # We are building in place.
23587     ac_srcdir=.
23588     ac_top_srcdir=$ac_top_builddir_sub
23589     ac_abs_top_srcdir=$ac_pwd ;;
23590   [\\/]* | ?:[\\/]* )  # Absolute name.
23591     ac_srcdir=$srcdir$ac_dir_suffix;
23592     ac_top_srcdir=$srcdir
23593     ac_abs_top_srcdir=$srcdir ;;
23594   *) # Relative name.
23595     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
23596     ac_top_srcdir=$ac_top_build_prefix$srcdir
23597     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
23598 esac
23599 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
23600
23601
23602   case $ac_mode in
23603   :F)
23604   #
23605   # CONFIG_FILE
23606   #
23607
23608 _ACEOF
23609
23610 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23611 # If the template does not know about datarootdir, expand it.
23612 # FIXME: This hack should be removed a few years after 2.60.
23613 ac_datarootdir_hack=; ac_datarootdir_seen=
23614 ac_sed_dataroot='
23615 /datarootdir/ {
23616   p
23617   q
23618 }
23619 /@datadir@/p
23620 /@docdir@/p
23621 /@infodir@/p
23622 /@localedir@/p
23623 /@mandir@/p'
23624 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
23625 *datarootdir*) ac_datarootdir_seen=yes;;
23626 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
23627   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
23628 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
23629 _ACEOF
23630 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23631   ac_datarootdir_hack='
23632   s&@datadir@&$datadir&g
23633   s&@docdir@&$docdir&g
23634   s&@infodir@&$infodir&g
23635   s&@localedir@&$localedir&g
23636   s&@mandir@&$mandir&g
23637   s&\\\${datarootdir}&$datarootdir&g' ;;
23638 esac
23639 _ACEOF
23640
23641 # Neutralize VPATH when `$srcdir' = `.'.
23642 # Shell code in configure.ac might set extrasub.
23643 # FIXME: do we really want to maintain this feature?
23644 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23645 ac_sed_extra="$ac_vpsub
23646 $extrasub
23647 _ACEOF
23648 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23649 :t
23650 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23651 s|@configure_input@|$ac_sed_conf_input|;t t
23652 s&@top_builddir@&$ac_top_builddir_sub&;t t
23653 s&@top_build_prefix@&$ac_top_build_prefix&;t t
23654 s&@srcdir@&$ac_srcdir&;t t
23655 s&@abs_srcdir@&$ac_abs_srcdir&;t t
23656 s&@top_srcdir@&$ac_top_srcdir&;t t
23657 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
23658 s&@builddir@&$ac_builddir&;t t
23659 s&@abs_builddir@&$ac_abs_builddir&;t t
23660 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
23661 $ac_datarootdir_hack
23662 "
23663 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
23664   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23665
23666 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
23667   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
23668   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
23669       "$ac_tmp/out"`; test -z "$ac_out"; } &&
23670   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23671 which seems to be undefined.  Please make sure it is defined" >&5
23672 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23673 which seems to be undefined.  Please make sure it is defined" >&2;}
23674
23675   rm -f "$ac_tmp/stdin"
23676   case $ac_file in
23677   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
23678   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
23679   esac \
23680   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23681  ;;
23682   :H)
23683   #
23684   # CONFIG_HEADER
23685   #
23686   if test x"$ac_file" != x-; then
23687     {
23688       $as_echo "/* $configure_input  */" \
23689       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
23690     } >"$ac_tmp/config.h" \
23691       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23692     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
23693       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
23694 $as_echo "$as_me: $ac_file is unchanged" >&6;}
23695     else
23696       rm -f "$ac_file"
23697       mv "$ac_tmp/config.h" "$ac_file" \
23698         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23699     fi
23700   else
23701     $as_echo "/* $configure_input  */" \
23702       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
23703       || as_fn_error $? "could not create -" "$LINENO" 5
23704   fi
23705  ;;
23706
23707   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
23708 $as_echo "$as_me: executing $ac_file commands" >&6;}
23709  ;;
23710   esac
23711
23712
23713   case $ac_file$ac_mode in
23714     "libtool":C)
23715
23716     # See if we are running on zsh, and set the options that allow our
23717     # commands through without removal of \ escapes.
23718     if test -n "${ZSH_VERSION+set}"; then
23719       setopt NO_GLOB_SUBST
23720     fi
23721
23722     cfgfile=${ofile}T
23723     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
23724     $RM "$cfgfile"
23725
23726     cat <<_LT_EOF >> "$cfgfile"
23727 #! $SHELL
23728 # Generated automatically by $as_me ($PACKAGE) $VERSION
23729 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
23730 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
23731
23732 # Provide generalized library-building support services.
23733 # Written by Gordon Matzigkeit, 1996
23734
23735 # Copyright (C) 2014 Free Software Foundation, Inc.
23736 # This is free software; see the source for copying conditions.  There is NO
23737 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
23738
23739 # GNU Libtool is free software; you can redistribute it and/or modify
23740 # it under the terms of the GNU General Public License as published by
23741 # the Free Software Foundation; either version 2 of of the License, or
23742 # (at your option) any later version.
23743 #
23744 # As a special exception to the GNU General Public License, if you
23745 # distribute this file as part of a program or library that is built
23746 # using GNU Libtool, you may include this file under the  same
23747 # distribution terms that you use for the rest of that program.
23748 #
23749 # GNU Libtool is distributed in the hope that it will be useful, but
23750 # WITHOUT ANY WARRANTY; without even the implied warranty of
23751 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23752 # GNU General Public License for more details.
23753 #
23754 # You should have received a copy of the GNU General Public License
23755 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
23756
23757
23758 # The names of the tagged configurations supported by this script.
23759 available_tags=''
23760
23761 # Configured defaults for sys_lib_dlsearch_path munging.
23762 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
23763
23764 # ### BEGIN LIBTOOL CONFIG
23765
23766 # Which release of libtool.m4 was used?
23767 macro_version=$macro_version
23768 macro_revision=$macro_revision
23769
23770 # Whether or not to build shared libraries.
23771 build_libtool_libs=$enable_shared
23772
23773 # Whether or not to build static libraries.
23774 build_old_libs=$enable_static
23775
23776 # What type of objects to build.
23777 pic_mode=$pic_mode
23778
23779 # Whether or not to optimize for fast installation.
23780 fast_install=$enable_fast_install
23781
23782 # Shared archive member basename,for filename based shared library versioning on AIX.
23783 shared_archive_member_spec=$shared_archive_member_spec
23784
23785 # Shell to use when invoking shell scripts.
23786 SHELL=$lt_SHELL
23787
23788 # An echo program that protects backslashes.
23789 ECHO=$lt_ECHO
23790
23791 # The PATH separator for the build system.
23792 PATH_SEPARATOR=$lt_PATH_SEPARATOR
23793
23794 # The host system.
23795 host_alias=$host_alias
23796 host=$host
23797 host_os=$host_os
23798
23799 # The build system.
23800 build_alias=$build_alias
23801 build=$build
23802 build_os=$build_os
23803
23804 # A sed program that does not truncate output.
23805 SED=$lt_SED
23806
23807 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
23808 Xsed="\$SED -e 1s/^X//"
23809
23810 # A grep program that handles long lines.
23811 GREP=$lt_GREP
23812
23813 # An ERE matcher.
23814 EGREP=$lt_EGREP
23815
23816 # A literal string matcher.
23817 FGREP=$lt_FGREP
23818
23819 # A BSD- or MS-compatible name lister.
23820 NM=$lt_NM
23821
23822 # Whether we need soft or hard links.
23823 LN_S=$lt_LN_S
23824
23825 # What is the maximum length of a command?
23826 max_cmd_len=$max_cmd_len
23827
23828 # Object file suffix (normally "o").
23829 objext=$ac_objext
23830
23831 # Executable file suffix (normally "").
23832 exeext=$exeext
23833
23834 # whether the shell understands "unset".
23835 lt_unset=$lt_unset
23836
23837 # turn spaces into newlines.
23838 SP2NL=$lt_lt_SP2NL
23839
23840 # turn newlines into spaces.
23841 NL2SP=$lt_lt_NL2SP
23842
23843 # convert \$build file names to \$host format.
23844 to_host_file_cmd=$lt_cv_to_host_file_cmd
23845
23846 # convert \$build files to toolchain format.
23847 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
23848
23849 # An object symbol dumper.
23850 OBJDUMP=$lt_OBJDUMP
23851
23852 # Method to check whether dependent libraries are shared objects.
23853 deplibs_check_method=$lt_deplibs_check_method
23854
23855 # Command to use when deplibs_check_method = "file_magic".
23856 file_magic_cmd=$lt_file_magic_cmd
23857
23858 # How to find potential files when deplibs_check_method = "file_magic".
23859 file_magic_glob=$lt_file_magic_glob
23860
23861 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
23862 want_nocaseglob=$lt_want_nocaseglob
23863
23864 # DLL creation program.
23865 DLLTOOL=$lt_DLLTOOL
23866
23867 # Command to associate shared and link libraries.
23868 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
23869
23870 # The archiver.
23871 AR=$lt_AR
23872
23873 # Flags to create an archive.
23874 AR_FLAGS=$lt_AR_FLAGS
23875
23876 # How to feed a file listing to the archiver.
23877 archiver_list_spec=$lt_archiver_list_spec
23878
23879 # A symbol stripping program.
23880 STRIP=$lt_STRIP
23881
23882 # Commands used to install an old-style archive.
23883 RANLIB=$lt_RANLIB
23884 old_postinstall_cmds=$lt_old_postinstall_cmds
23885 old_postuninstall_cmds=$lt_old_postuninstall_cmds
23886
23887 # Whether to use a lock for old archive extraction.
23888 lock_old_archive_extraction=$lock_old_archive_extraction
23889
23890 # A C compiler.
23891 LTCC=$lt_CC
23892
23893 # LTCC compiler flags.
23894 LTCFLAGS=$lt_CFLAGS
23895
23896 # Take the output of nm and produce a listing of raw symbols and C names.
23897 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
23898
23899 # Transform the output of nm in a proper C declaration.
23900 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
23901
23902 # Transform the output of nm into a list of symbols to manually relocate.
23903 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
23904
23905 # Transform the output of nm in a C name address pair.
23906 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
23907
23908 # Transform the output of nm in a C name address pair when lib prefix is needed.
23909 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
23910
23911 # The name lister interface.
23912 nm_interface=$lt_lt_cv_nm_interface
23913
23914 # Specify filename containing input files for \$NM.
23915 nm_file_list_spec=$lt_nm_file_list_spec
23916
23917 # The root where to search for dependent libraries,and where our libraries should be installed.
23918 lt_sysroot=$lt_sysroot
23919
23920 # Command to truncate a binary pipe.
23921 lt_truncate_bin=$lt_lt_cv_truncate_bin
23922
23923 # The name of the directory that contains temporary libtool files.
23924 objdir=$objdir
23925
23926 # Used to examine libraries when file_magic_cmd begins with "file".
23927 MAGIC_CMD=$MAGIC_CMD
23928
23929 # Must we lock files when doing compilation?
23930 need_locks=$lt_need_locks
23931
23932 # Manifest tool.
23933 MANIFEST_TOOL=$lt_MANIFEST_TOOL
23934
23935 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
23936 DSYMUTIL=$lt_DSYMUTIL
23937
23938 # Tool to change global to local symbols on Mac OS X.
23939 NMEDIT=$lt_NMEDIT
23940
23941 # Tool to manipulate fat objects and archives on Mac OS X.
23942 LIPO=$lt_LIPO
23943
23944 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
23945 OTOOL=$lt_OTOOL
23946
23947 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
23948 OTOOL64=$lt_OTOOL64
23949
23950 # Old archive suffix (normally "a").
23951 libext=$libext
23952
23953 # Shared library suffix (normally ".so").
23954 shrext_cmds=$lt_shrext_cmds
23955
23956 # The commands to extract the exported symbol list from a shared archive.
23957 extract_expsyms_cmds=$lt_extract_expsyms_cmds
23958
23959 # Variables whose values should be saved in libtool wrapper scripts and
23960 # restored at link time.
23961 variables_saved_for_relink=$lt_variables_saved_for_relink
23962
23963 # Do we need the "lib" prefix for modules?
23964 need_lib_prefix=$need_lib_prefix
23965
23966 # Do we need a version for libraries?
23967 need_version=$need_version
23968
23969 # Library versioning type.
23970 version_type=$version_type
23971
23972 # Shared library runtime path variable.
23973 runpath_var=$runpath_var
23974
23975 # Shared library path variable.
23976 shlibpath_var=$shlibpath_var
23977
23978 # Is shlibpath searched before the hard-coded library search path?
23979 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
23980
23981 # Format of library name prefix.
23982 libname_spec=$lt_libname_spec
23983
23984 # List of archive names.  First name is the real one, the rest are links.
23985 # The last name is the one that the linker finds with -lNAME
23986 library_names_spec=$lt_library_names_spec
23987
23988 # The coded name of the library, if different from the real name.
23989 soname_spec=$lt_soname_spec
23990
23991 # Permission mode override for installation of shared libraries.
23992 install_override_mode=$lt_install_override_mode
23993
23994 # Command to use after installation of a shared archive.
23995 postinstall_cmds=$lt_postinstall_cmds
23996
23997 # Command to use after uninstallation of a shared archive.
23998 postuninstall_cmds=$lt_postuninstall_cmds
23999
24000 # Commands used to finish a libtool library installation in a directory.
24001 finish_cmds=$lt_finish_cmds
24002
24003 # As "finish_cmds", except a single script fragment to be evaled but
24004 # not shown.
24005 finish_eval=$lt_finish_eval
24006
24007 # Whether we should hardcode library paths into libraries.
24008 hardcode_into_libs=$hardcode_into_libs
24009
24010 # Compile-time system search path for libraries.
24011 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
24012
24013 # Detected run-time system search path for libraries.
24014 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
24015
24016 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
24017 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
24018
24019 # Whether dlopen is supported.
24020 dlopen_support=$enable_dlopen
24021
24022 # Whether dlopen of programs is supported.
24023 dlopen_self=$enable_dlopen_self
24024
24025 # Whether dlopen of statically linked programs is supported.
24026 dlopen_self_static=$enable_dlopen_self_static
24027
24028 # Commands to strip libraries.
24029 old_striplib=$lt_old_striplib
24030 striplib=$lt_striplib
24031
24032
24033 # The linker used to build libraries.
24034 LD=$lt_LD
24035
24036 # How to create reloadable object files.
24037 reload_flag=$lt_reload_flag
24038 reload_cmds=$lt_reload_cmds
24039
24040 # Commands used to build an old-style archive.
24041 old_archive_cmds=$lt_old_archive_cmds
24042
24043 # A language specific compiler.
24044 CC=$lt_compiler
24045
24046 # Is the compiler the GNU compiler?
24047 with_gcc=$GCC
24048
24049 # Compiler flag to turn off builtin functions.
24050 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
24051
24052 # Additional compiler flags for building library objects.
24053 pic_flag=$lt_lt_prog_compiler_pic
24054
24055 # How to pass a linker flag through the compiler.
24056 wl=$lt_lt_prog_compiler_wl
24057
24058 # Compiler flag to prevent dynamic linking.
24059 link_static_flag=$lt_lt_prog_compiler_static
24060
24061 # Does compiler simultaneously support -c and -o options?
24062 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
24063
24064 # Whether or not to add -lc for building shared libraries.
24065 build_libtool_need_lc=$archive_cmds_need_lc
24066
24067 # Whether or not to disallow shared libs when runtime libs are static.
24068 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
24069
24070 # Compiler flag to allow reflexive dlopens.
24071 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
24072
24073 # Compiler flag to generate shared objects directly from archives.
24074 whole_archive_flag_spec=$lt_whole_archive_flag_spec
24075
24076 # Whether the compiler copes with passing no objects directly.
24077 compiler_needs_object=$lt_compiler_needs_object
24078
24079 # Create an old-style archive from a shared archive.
24080 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
24081
24082 # Create a temporary old-style archive to link instead of a shared archive.
24083 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
24084
24085 # Commands used to build a shared archive.
24086 archive_cmds=$lt_archive_cmds
24087 archive_expsym_cmds=$lt_archive_expsym_cmds
24088
24089 # Commands used to build a loadable module if different from building
24090 # a shared archive.
24091 module_cmds=$lt_module_cmds
24092 module_expsym_cmds=$lt_module_expsym_cmds
24093
24094 # Whether we are building with GNU ld or not.
24095 with_gnu_ld=$lt_with_gnu_ld
24096
24097 # Flag that allows shared libraries with undefined symbols to be built.
24098 allow_undefined_flag=$lt_allow_undefined_flag
24099
24100 # Flag that enforces no undefined symbols.
24101 no_undefined_flag=$lt_no_undefined_flag
24102
24103 # Flag to hardcode \$libdir into a binary during linking.
24104 # This must work even if \$libdir does not exist
24105 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
24106
24107 # Whether we need a single "-rpath" flag with a separated argument.
24108 hardcode_libdir_separator=$lt_hardcode_libdir_separator
24109
24110 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
24111 # DIR into the resulting binary.
24112 hardcode_direct=$hardcode_direct
24113
24114 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
24115 # DIR into the resulting binary and the resulting library dependency is
24116 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
24117 # library is relocated.
24118 hardcode_direct_absolute=$hardcode_direct_absolute
24119
24120 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
24121 # into the resulting binary.
24122 hardcode_minus_L=$hardcode_minus_L
24123
24124 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
24125 # into the resulting binary.
24126 hardcode_shlibpath_var=$hardcode_shlibpath_var
24127
24128 # Set to "yes" if building a shared library automatically hardcodes DIR
24129 # into the library and all subsequent libraries and executables linked
24130 # against it.
24131 hardcode_automatic=$hardcode_automatic
24132
24133 # Set to yes if linker adds runtime paths of dependent libraries
24134 # to runtime path list.
24135 inherit_rpath=$inherit_rpath
24136
24137 # Whether libtool must link a program against all its dependency libraries.
24138 link_all_deplibs=$link_all_deplibs
24139
24140 # Set to "yes" if exported symbols are required.
24141 always_export_symbols=$always_export_symbols
24142
24143 # The commands to list exported symbols.
24144 export_symbols_cmds=$lt_export_symbols_cmds
24145
24146 # Symbols that should not be listed in the preloaded symbols.
24147 exclude_expsyms=$lt_exclude_expsyms
24148
24149 # Symbols that must always be exported.
24150 include_expsyms=$lt_include_expsyms
24151
24152 # Commands necessary for linking programs (against libraries) with templates.
24153 prelink_cmds=$lt_prelink_cmds
24154
24155 # Commands necessary for finishing linking programs.
24156 postlink_cmds=$lt_postlink_cmds
24157
24158 # Specify filename containing input files.
24159 file_list_spec=$lt_file_list_spec
24160
24161 # How to hardcode a shared library path into an executable.
24162 hardcode_action=$hardcode_action
24163
24164 # ### END LIBTOOL CONFIG
24165
24166 _LT_EOF
24167
24168     cat <<'_LT_EOF' >> "$cfgfile"
24169
24170 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
24171
24172 # func_munge_path_list VARIABLE PATH
24173 # -----------------------------------
24174 # VARIABLE is name of variable containing _space_ separated list of
24175 # directories to be munged by the contents of PATH, which is string
24176 # having a format:
24177 # "DIR[:DIR]:"
24178 #       string "DIR[ DIR]" will be prepended to VARIABLE
24179 # ":DIR[:DIR]"
24180 #       string "DIR[ DIR]" will be appended to VARIABLE
24181 # "DIRP[:DIRP]::[DIRA:]DIRA"
24182 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
24183 #       "DIRA[ DIRA]" will be appended to VARIABLE
24184 # "DIR[:DIR]"
24185 #       VARIABLE will be replaced by "DIR[ DIR]"
24186 func_munge_path_list ()
24187 {
24188     case x$2 in
24189     x)
24190         ;;
24191     *:)
24192         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
24193         ;;
24194     x:*)
24195         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
24196         ;;
24197     *::*)
24198         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
24199         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
24200         ;;
24201     *)
24202         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
24203         ;;
24204     esac
24205 }
24206
24207
24208 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
24209 func_cc_basename ()
24210 {
24211     for cc_temp in $*""; do
24212       case $cc_temp in
24213         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
24214         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
24215         \-*) ;;
24216         *) break;;
24217       esac
24218     done
24219     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
24220 }
24221
24222
24223 # ### END FUNCTIONS SHARED WITH CONFIGURE
24224
24225 _LT_EOF
24226
24227   case $host_os in
24228   aix3*)
24229     cat <<\_LT_EOF >> "$cfgfile"
24230 # AIX sometimes has problems with the GCC collect2 program.  For some
24231 # reason, if we set the COLLECT_NAMES environment variable, the problems
24232 # vanish in a puff of smoke.
24233 if test set != "${COLLECT_NAMES+set}"; then
24234   COLLECT_NAMES=
24235   export COLLECT_NAMES
24236 fi
24237 _LT_EOF
24238     ;;
24239   esac
24240
24241
24242 ltmain=$ac_aux_dir/ltmain.sh
24243
24244
24245   # We use sed instead of cat because bash on DJGPP gets confused if
24246   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
24247   # text mode, it properly converts lines to CR/LF.  This bash problem
24248   # is reportedly fixed, but why not run on old versions too?
24249   sed '$q' "$ltmain" >> "$cfgfile" \
24250      || (rm -f "$cfgfile"; exit 1)
24251
24252    mv -f "$cfgfile" "$ofile" ||
24253     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
24254   chmod +x "$ofile"
24255
24256  ;;
24257     "disable-rpath":C)
24258         sed < libtool > libtool-2 \
24259         's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_RPATH_SED__ "/'
24260         mv libtool-2 libtool
24261         chmod 755 libtool
24262         libtool="./libtool"
24263          ;;
24264
24265   esac
24266 done # for ac_tag
24267
24268
24269 as_fn_exit 0
24270 _ACEOF
24271 ac_clean_files=$ac_clean_files_save
24272
24273 test $ac_write_fail = 0 ||
24274   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
24275
24276
24277 # configure is writing to config.log, and then calls config.status.
24278 # config.status does its own redirection, appending to config.log.
24279 # Unfortunately, on DOS this fails, as config.log is still kept open
24280 # by configure, so config.status won't be able to write to it; its
24281 # output is simply discarded.  So we exec the FD to /dev/null,
24282 # effectively closing config.log, so it can be properly (re)opened and
24283 # appended to by config.status.  When coming back to configure, we
24284 # need to make the FD available again.
24285 if test "$no_create" != yes; then
24286   ac_cs_success=:
24287   ac_config_status_args=
24288   test "$silent" = yes &&
24289     ac_config_status_args="$ac_config_status_args --quiet"
24290   exec 5>/dev/null
24291   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24292   exec 5>>config.log
24293   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24294   # would make configure fail if this is the last instruction.
24295   $ac_cs_success || as_fn_exit 1
24296 fi
24297 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24298   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24299 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
24300 fi
24301