]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/unbound/configure
MFV: cherry-pick "PR/358: Fix width for -f - (jpalus)"
[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.16.2.
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.16.2'
595 PACKAGE_STRING='unbound 1.16.2'
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.16.2 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.16.2:";;
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.16.2
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.16.2, 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=16
2848
2849 UNBOUND_VERSION_MICRO=2
2850
2851
2852 LIBUNBOUND_CURRENT=9
2853 LIBUNBOUND_REVISION=18
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
2940 #   Current  -- the number of the binary API that we're implementing
2941 #   Revision -- which iteration of the implementation of the binary
2942 #               API are we supplying?
2943 #   Age      -- How many previous binary API versions do we also
2944 #               support?
2945 #
2946 # If we release a new version that does not change the binary API,
2947 # increment Revision.
2948 #
2949 # If we release a new version that changes the binary API, but does
2950 # not break programs compiled against the old binary API, increment
2951 # Current and Age.  Set Revision to 0, since this is the first
2952 # implementation of the new API.
2953 #
2954 # Otherwise, we're changing the binary API and breaking backward
2955 # compatibility with old binaries.  Increment Current.  Set Age to 0,
2956 # since we're backward compatible with no previous APIs.  Set Revision
2957 # to 0 too.
2958
2959
2960
2961
2962
2963 cmdln="`echo $@ | sed -e 's/\\\\/\\\\\\\\/g' | sed -e 's/"/\\\\"/'g`"
2964
2965 cat >>confdefs.h <<_ACEOF
2966 #define CONFCMDLINE "$cmdln"
2967 _ACEOF
2968
2969
2970 CFLAGS="$CFLAGS"
2971 ac_ext=c
2972 ac_cpp='$CPP $CPPFLAGS'
2973 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2974 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2975 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2976 if test -n "$ac_tool_prefix"; then
2977   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2978 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2980 $as_echo_n "checking for $ac_word... " >&6; }
2981 if ${ac_cv_prog_CC+:} false; then :
2982   $as_echo_n "(cached) " >&6
2983 else
2984   if test -n "$CC"; then
2985   ac_cv_prog_CC="$CC" # Let the user override the test.
2986 else
2987 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2988 for as_dir in $PATH
2989 do
2990   IFS=$as_save_IFS
2991   test -z "$as_dir" && as_dir=.
2992     for ac_exec_ext in '' $ac_executable_extensions; do
2993   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2994     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2995     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2996     break 2
2997   fi
2998 done
2999   done
3000 IFS=$as_save_IFS
3001
3002 fi
3003 fi
3004 CC=$ac_cv_prog_CC
3005 if test -n "$CC"; then
3006   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3007 $as_echo "$CC" >&6; }
3008 else
3009   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3010 $as_echo "no" >&6; }
3011 fi
3012
3013
3014 fi
3015 if test -z "$ac_cv_prog_CC"; then
3016   ac_ct_CC=$CC
3017   # Extract the first word of "gcc", so it can be a program name with args.
3018 set dummy gcc; ac_word=$2
3019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3020 $as_echo_n "checking for $ac_word... " >&6; }
3021 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3022   $as_echo_n "(cached) " >&6
3023 else
3024   if test -n "$ac_ct_CC"; then
3025   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3026 else
3027 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3028 for as_dir in $PATH
3029 do
3030   IFS=$as_save_IFS
3031   test -z "$as_dir" && as_dir=.
3032     for ac_exec_ext in '' $ac_executable_extensions; do
3033   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3034     ac_cv_prog_ac_ct_CC="gcc"
3035     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3036     break 2
3037   fi
3038 done
3039   done
3040 IFS=$as_save_IFS
3041
3042 fi
3043 fi
3044 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3045 if test -n "$ac_ct_CC"; then
3046   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3047 $as_echo "$ac_ct_CC" >&6; }
3048 else
3049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3050 $as_echo "no" >&6; }
3051 fi
3052
3053   if test "x$ac_ct_CC" = x; then
3054     CC=""
3055   else
3056     case $cross_compiling:$ac_tool_warned in
3057 yes:)
3058 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3059 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3060 ac_tool_warned=yes ;;
3061 esac
3062     CC=$ac_ct_CC
3063   fi
3064 else
3065   CC="$ac_cv_prog_CC"
3066 fi
3067
3068 if test -z "$CC"; then
3069           if test -n "$ac_tool_prefix"; then
3070     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3071 set dummy ${ac_tool_prefix}cc; ac_word=$2
3072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3073 $as_echo_n "checking for $ac_word... " >&6; }
3074 if ${ac_cv_prog_CC+:} false; then :
3075   $as_echo_n "(cached) " >&6
3076 else
3077   if test -n "$CC"; then
3078   ac_cv_prog_CC="$CC" # Let the user override the test.
3079 else
3080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3081 for as_dir in $PATH
3082 do
3083   IFS=$as_save_IFS
3084   test -z "$as_dir" && as_dir=.
3085     for ac_exec_ext in '' $ac_executable_extensions; do
3086   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3087     ac_cv_prog_CC="${ac_tool_prefix}cc"
3088     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3089     break 2
3090   fi
3091 done
3092   done
3093 IFS=$as_save_IFS
3094
3095 fi
3096 fi
3097 CC=$ac_cv_prog_CC
3098 if test -n "$CC"; then
3099   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3100 $as_echo "$CC" >&6; }
3101 else
3102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3103 $as_echo "no" >&6; }
3104 fi
3105
3106
3107   fi
3108 fi
3109 if test -z "$CC"; then
3110   # Extract the first word of "cc", so it can be a program name with args.
3111 set dummy cc; ac_word=$2
3112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3113 $as_echo_n "checking for $ac_word... " >&6; }
3114 if ${ac_cv_prog_CC+:} false; then :
3115   $as_echo_n "(cached) " >&6
3116 else
3117   if test -n "$CC"; then
3118   ac_cv_prog_CC="$CC" # Let the user override the test.
3119 else
3120   ac_prog_rejected=no
3121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3122 for as_dir in $PATH
3123 do
3124   IFS=$as_save_IFS
3125   test -z "$as_dir" && as_dir=.
3126     for ac_exec_ext in '' $ac_executable_extensions; do
3127   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3128     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3129        ac_prog_rejected=yes
3130        continue
3131      fi
3132     ac_cv_prog_CC="cc"
3133     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3134     break 2
3135   fi
3136 done
3137   done
3138 IFS=$as_save_IFS
3139
3140 if test $ac_prog_rejected = yes; then
3141   # We found a bogon in the path, so make sure we never use it.
3142   set dummy $ac_cv_prog_CC
3143   shift
3144   if test $# != 0; then
3145     # We chose a different compiler from the bogus one.
3146     # However, it has the same basename, so the bogon will be chosen
3147     # first if we set CC to just the basename; use the full file name.
3148     shift
3149     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3150   fi
3151 fi
3152 fi
3153 fi
3154 CC=$ac_cv_prog_CC
3155 if test -n "$CC"; then
3156   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3157 $as_echo "$CC" >&6; }
3158 else
3159   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3160 $as_echo "no" >&6; }
3161 fi
3162
3163
3164 fi
3165 if test -z "$CC"; then
3166   if test -n "$ac_tool_prefix"; then
3167   for ac_prog in cl.exe
3168   do
3169     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3170 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3172 $as_echo_n "checking for $ac_word... " >&6; }
3173 if ${ac_cv_prog_CC+:} false; then :
3174   $as_echo_n "(cached) " >&6
3175 else
3176   if test -n "$CC"; then
3177   ac_cv_prog_CC="$CC" # Let the user override the test.
3178 else
3179 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3180 for as_dir in $PATH
3181 do
3182   IFS=$as_save_IFS
3183   test -z "$as_dir" && as_dir=.
3184     for ac_exec_ext in '' $ac_executable_extensions; do
3185   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3186     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3187     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3188     break 2
3189   fi
3190 done
3191   done
3192 IFS=$as_save_IFS
3193
3194 fi
3195 fi
3196 CC=$ac_cv_prog_CC
3197 if test -n "$CC"; then
3198   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3199 $as_echo "$CC" >&6; }
3200 else
3201   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3202 $as_echo "no" >&6; }
3203 fi
3204
3205
3206     test -n "$CC" && break
3207   done
3208 fi
3209 if test -z "$CC"; then
3210   ac_ct_CC=$CC
3211   for ac_prog in cl.exe
3212 do
3213   # Extract the first word of "$ac_prog", so it can be a program name with args.
3214 set dummy $ac_prog; ac_word=$2
3215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3216 $as_echo_n "checking for $ac_word... " >&6; }
3217 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3218   $as_echo_n "(cached) " >&6
3219 else
3220   if test -n "$ac_ct_CC"; then
3221   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3222 else
3223 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3224 for as_dir in $PATH
3225 do
3226   IFS=$as_save_IFS
3227   test -z "$as_dir" && as_dir=.
3228     for ac_exec_ext in '' $ac_executable_extensions; do
3229   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3230     ac_cv_prog_ac_ct_CC="$ac_prog"
3231     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3232     break 2
3233   fi
3234 done
3235   done
3236 IFS=$as_save_IFS
3237
3238 fi
3239 fi
3240 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3241 if test -n "$ac_ct_CC"; then
3242   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3243 $as_echo "$ac_ct_CC" >&6; }
3244 else
3245   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3246 $as_echo "no" >&6; }
3247 fi
3248
3249
3250   test -n "$ac_ct_CC" && break
3251 done
3252
3253   if test "x$ac_ct_CC" = x; then
3254     CC=""
3255   else
3256     case $cross_compiling:$ac_tool_warned in
3257 yes:)
3258 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3259 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3260 ac_tool_warned=yes ;;
3261 esac
3262     CC=$ac_ct_CC
3263   fi
3264 fi
3265
3266 fi
3267
3268
3269 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3270 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3271 as_fn_error $? "no acceptable C compiler found in \$PATH
3272 See \`config.log' for more details" "$LINENO" 5; }
3273
3274 # Provide some information about the compiler.
3275 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3276 set X $ac_compile
3277 ac_compiler=$2
3278 for ac_option in --version -v -V -qversion; do
3279   { { ac_try="$ac_compiler $ac_option >&5"
3280 case "(($ac_try" in
3281   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3282   *) ac_try_echo=$ac_try;;
3283 esac
3284 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3285 $as_echo "$ac_try_echo"; } >&5
3286   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3287   ac_status=$?
3288   if test -s conftest.err; then
3289     sed '10a\
3290 ... rest of stderr output deleted ...
3291          10q' conftest.err >conftest.er1
3292     cat conftest.er1 >&5
3293   fi
3294   rm -f conftest.er1 conftest.err
3295   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3296   test $ac_status = 0; }
3297 done
3298
3299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3300 /* end confdefs.h.  */
3301
3302 int
3303 main ()
3304 {
3305
3306   ;
3307   return 0;
3308 }
3309 _ACEOF
3310 ac_clean_files_save=$ac_clean_files
3311 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3312 # Try to create an executable without -o first, disregard a.out.
3313 # It will help us diagnose broken compilers, and finding out an intuition
3314 # of exeext.
3315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3316 $as_echo_n "checking whether the C compiler works... " >&6; }
3317 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3318
3319 # The possible output files:
3320 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3321
3322 ac_rmfiles=
3323 for ac_file in $ac_files
3324 do
3325   case $ac_file in
3326     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3327     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3328   esac
3329 done
3330 rm -f $ac_rmfiles
3331
3332 if { { ac_try="$ac_link_default"
3333 case "(($ac_try" in
3334   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3335   *) ac_try_echo=$ac_try;;
3336 esac
3337 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3338 $as_echo "$ac_try_echo"; } >&5
3339   (eval "$ac_link_default") 2>&5
3340   ac_status=$?
3341   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3342   test $ac_status = 0; }; then :
3343   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3344 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3345 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3346 # so that the user can short-circuit this test for compilers unknown to
3347 # Autoconf.
3348 for ac_file in $ac_files ''
3349 do
3350   test -f "$ac_file" || continue
3351   case $ac_file in
3352     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3353         ;;
3354     [ab].out )
3355         # We found the default executable, but exeext='' is most
3356         # certainly right.
3357         break;;
3358     *.* )
3359         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3360         then :; else
3361            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3362         fi
3363         # We set ac_cv_exeext here because the later test for it is not
3364         # safe: cross compilers may not add the suffix if given an `-o'
3365         # argument, so we may need to know it at that point already.
3366         # Even if this section looks crufty: it has the advantage of
3367         # actually working.
3368         break;;
3369     * )
3370         break;;
3371   esac
3372 done
3373 test "$ac_cv_exeext" = no && ac_cv_exeext=
3374
3375 else
3376   ac_file=''
3377 fi
3378 if test -z "$ac_file"; then :
3379   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3380 $as_echo "no" >&6; }
3381 $as_echo "$as_me: failed program was:" >&5
3382 sed 's/^/| /' conftest.$ac_ext >&5
3383
3384 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3385 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3386 as_fn_error 77 "C compiler cannot create executables
3387 See \`config.log' for more details" "$LINENO" 5; }
3388 else
3389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3390 $as_echo "yes" >&6; }
3391 fi
3392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3393 $as_echo_n "checking for C compiler default output file name... " >&6; }
3394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3395 $as_echo "$ac_file" >&6; }
3396 ac_exeext=$ac_cv_exeext
3397
3398 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3399 ac_clean_files=$ac_clean_files_save
3400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3401 $as_echo_n "checking for suffix of executables... " >&6; }
3402 if { { ac_try="$ac_link"
3403 case "(($ac_try" in
3404   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3405   *) ac_try_echo=$ac_try;;
3406 esac
3407 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3408 $as_echo "$ac_try_echo"; } >&5
3409   (eval "$ac_link") 2>&5
3410   ac_status=$?
3411   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3412   test $ac_status = 0; }; then :
3413   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3414 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3415 # work properly (i.e., refer to `conftest.exe'), while it won't with
3416 # `rm'.
3417 for ac_file in conftest.exe conftest conftest.*; do
3418   test -f "$ac_file" || continue
3419   case $ac_file in
3420     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3421     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3422           break;;
3423     * ) break;;
3424   esac
3425 done
3426 else
3427   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3428 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3429 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3430 See \`config.log' for more details" "$LINENO" 5; }
3431 fi
3432 rm -f conftest conftest$ac_cv_exeext
3433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3434 $as_echo "$ac_cv_exeext" >&6; }
3435
3436 rm -f conftest.$ac_ext
3437 EXEEXT=$ac_cv_exeext
3438 ac_exeext=$EXEEXT
3439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3440 /* end confdefs.h.  */
3441 #include <stdio.h>
3442 int
3443 main ()
3444 {
3445 FILE *f = fopen ("conftest.out", "w");
3446  return ferror (f) || fclose (f) != 0;
3447
3448   ;
3449   return 0;
3450 }
3451 _ACEOF
3452 ac_clean_files="$ac_clean_files conftest.out"
3453 # Check that the compiler produces executables we can run.  If not, either
3454 # the compiler is broken, or we cross compile.
3455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3456 $as_echo_n "checking whether we are cross compiling... " >&6; }
3457 if test "$cross_compiling" != yes; then
3458   { { ac_try="$ac_link"
3459 case "(($ac_try" in
3460   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3461   *) ac_try_echo=$ac_try;;
3462 esac
3463 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3464 $as_echo "$ac_try_echo"; } >&5
3465   (eval "$ac_link") 2>&5
3466   ac_status=$?
3467   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3468   test $ac_status = 0; }
3469   if { ac_try='./conftest$ac_cv_exeext'
3470   { { case "(($ac_try" in
3471   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3472   *) ac_try_echo=$ac_try;;
3473 esac
3474 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3475 $as_echo "$ac_try_echo"; } >&5
3476   (eval "$ac_try") 2>&5
3477   ac_status=$?
3478   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3479   test $ac_status = 0; }; }; then
3480     cross_compiling=no
3481   else
3482     if test "$cross_compiling" = maybe; then
3483         cross_compiling=yes
3484     else
3485         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3486 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3487 as_fn_error $? "cannot run C compiled programs.
3488 If you meant to cross compile, use \`--host'.
3489 See \`config.log' for more details" "$LINENO" 5; }
3490     fi
3491   fi
3492 fi
3493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3494 $as_echo "$cross_compiling" >&6; }
3495
3496 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3497 ac_clean_files=$ac_clean_files_save
3498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3499 $as_echo_n "checking for suffix of object files... " >&6; }
3500 if ${ac_cv_objext+:} false; then :
3501   $as_echo_n "(cached) " >&6
3502 else
3503   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3504 /* end confdefs.h.  */
3505
3506 int
3507 main ()
3508 {
3509
3510   ;
3511   return 0;
3512 }
3513 _ACEOF
3514 rm -f conftest.o conftest.obj
3515 if { { ac_try="$ac_compile"
3516 case "(($ac_try" in
3517   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3518   *) ac_try_echo=$ac_try;;
3519 esac
3520 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3521 $as_echo "$ac_try_echo"; } >&5
3522   (eval "$ac_compile") 2>&5
3523   ac_status=$?
3524   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3525   test $ac_status = 0; }; then :
3526   for ac_file in conftest.o conftest.obj conftest.*; do
3527   test -f "$ac_file" || continue;
3528   case $ac_file in
3529     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3530     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3531        break;;
3532   esac
3533 done
3534 else
3535   $as_echo "$as_me: failed program was:" >&5
3536 sed 's/^/| /' conftest.$ac_ext >&5
3537
3538 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3539 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3540 as_fn_error $? "cannot compute suffix of object files: cannot compile
3541 See \`config.log' for more details" "$LINENO" 5; }
3542 fi
3543 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3544 fi
3545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3546 $as_echo "$ac_cv_objext" >&6; }
3547 OBJEXT=$ac_cv_objext
3548 ac_objext=$OBJEXT
3549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3550 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3551 if ${ac_cv_c_compiler_gnu+:} false; then :
3552   $as_echo_n "(cached) " >&6
3553 else
3554   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3555 /* end confdefs.h.  */
3556
3557 int
3558 main ()
3559 {
3560 #ifndef __GNUC__
3561        choke me
3562 #endif
3563
3564   ;
3565   return 0;
3566 }
3567 _ACEOF
3568 if ac_fn_c_try_compile "$LINENO"; then :
3569   ac_compiler_gnu=yes
3570 else
3571   ac_compiler_gnu=no
3572 fi
3573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3574 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3575
3576 fi
3577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3578 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3579 if test $ac_compiler_gnu = yes; then
3580   GCC=yes
3581 else
3582   GCC=
3583 fi
3584 ac_test_CFLAGS=${CFLAGS+set}
3585 ac_save_CFLAGS=$CFLAGS
3586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3587 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3588 if ${ac_cv_prog_cc_g+:} false; then :
3589   $as_echo_n "(cached) " >&6
3590 else
3591   ac_save_c_werror_flag=$ac_c_werror_flag
3592    ac_c_werror_flag=yes
3593    ac_cv_prog_cc_g=no
3594    CFLAGS="-g"
3595    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3596 /* end confdefs.h.  */
3597
3598 int
3599 main ()
3600 {
3601
3602   ;
3603   return 0;
3604 }
3605 _ACEOF
3606 if ac_fn_c_try_compile "$LINENO"; then :
3607   ac_cv_prog_cc_g=yes
3608 else
3609   CFLAGS=""
3610       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3611 /* end confdefs.h.  */
3612
3613 int
3614 main ()
3615 {
3616
3617   ;
3618   return 0;
3619 }
3620 _ACEOF
3621 if ac_fn_c_try_compile "$LINENO"; then :
3622
3623 else
3624   ac_c_werror_flag=$ac_save_c_werror_flag
3625          CFLAGS="-g"
3626          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3627 /* end confdefs.h.  */
3628
3629 int
3630 main ()
3631 {
3632
3633   ;
3634   return 0;
3635 }
3636 _ACEOF
3637 if ac_fn_c_try_compile "$LINENO"; then :
3638   ac_cv_prog_cc_g=yes
3639 fi
3640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3641 fi
3642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3643 fi
3644 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3645    ac_c_werror_flag=$ac_save_c_werror_flag
3646 fi
3647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3648 $as_echo "$ac_cv_prog_cc_g" >&6; }
3649 if test "$ac_test_CFLAGS" = set; then
3650   CFLAGS=$ac_save_CFLAGS
3651 elif test $ac_cv_prog_cc_g = yes; then
3652   if test "$GCC" = yes; then
3653     CFLAGS="-g -O2"
3654   else
3655     CFLAGS="-g"
3656   fi
3657 else
3658   if test "$GCC" = yes; then
3659     CFLAGS="-O2"
3660   else
3661     CFLAGS=
3662   fi
3663 fi
3664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3665 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3666 if ${ac_cv_prog_cc_c89+:} false; then :
3667   $as_echo_n "(cached) " >&6
3668 else
3669   ac_cv_prog_cc_c89=no
3670 ac_save_CC=$CC
3671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3672 /* end confdefs.h.  */
3673 #include <stdarg.h>
3674 #include <stdio.h>
3675 struct stat;
3676 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3677 struct buf { int x; };
3678 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3679 static char *e (p, i)
3680      char **p;
3681      int i;
3682 {
3683   return p[i];
3684 }
3685 static char *f (char * (*g) (char **, int), char **p, ...)
3686 {
3687   char *s;
3688   va_list v;
3689   va_start (v,p);
3690   s = g (p, va_arg (v,int));
3691   va_end (v);
3692   return s;
3693 }
3694
3695 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3696    function prototypes and stuff, but not '\xHH' hex character constants.
3697    These don't provoke an error unfortunately, instead are silently treated
3698    as 'x'.  The following induces an error, until -std is added to get
3699    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3700    array size at least.  It's necessary to write '\x00'==0 to get something
3701    that's true only with -std.  */
3702 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3703
3704 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3705    inside strings and character constants.  */
3706 #define FOO(x) 'x'
3707 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3708
3709 int test (int i, double x);
3710 struct s1 {int (*f) (int a);};
3711 struct s2 {int (*f) (double a);};
3712 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3713 int argc;
3714 char **argv;
3715 int
3716 main ()
3717 {
3718 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3719   ;
3720   return 0;
3721 }
3722 _ACEOF
3723 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3724         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3725 do
3726   CC="$ac_save_CC $ac_arg"
3727   if ac_fn_c_try_compile "$LINENO"; then :
3728   ac_cv_prog_cc_c89=$ac_arg
3729 fi
3730 rm -f core conftest.err conftest.$ac_objext
3731   test "x$ac_cv_prog_cc_c89" != "xno" && break
3732 done
3733 rm -f conftest.$ac_ext
3734 CC=$ac_save_CC
3735
3736 fi
3737 # AC_CACHE_VAL
3738 case "x$ac_cv_prog_cc_c89" in
3739   x)
3740     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3741 $as_echo "none needed" >&6; } ;;
3742   xno)
3743     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3744 $as_echo "unsupported" >&6; } ;;
3745   *)
3746     CC="$CC $ac_cv_prog_cc_c89"
3747     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3748 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3749 esac
3750 if test "x$ac_cv_prog_cc_c89" != xno; then :
3751
3752 fi
3753
3754 ac_ext=c
3755 ac_cpp='$CPP $CPPFLAGS'
3756 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3757 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3758 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3759
3760
3761 ac_ext=c
3762 ac_cpp='$CPP $CPPFLAGS'
3763 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3764 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3765 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3767 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3768 # On Suns, sometimes $CPP names a directory.
3769 if test -n "$CPP" && test -d "$CPP"; then
3770   CPP=
3771 fi
3772 if test -z "$CPP"; then
3773   if ${ac_cv_prog_CPP+:} false; then :
3774   $as_echo_n "(cached) " >&6
3775 else
3776       # Double quotes because CPP needs to be expanded
3777     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3778     do
3779       ac_preproc_ok=false
3780 for ac_c_preproc_warn_flag in '' yes
3781 do
3782   # Use a header file that comes with gcc, so configuring glibc
3783   # with a fresh cross-compiler works.
3784   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3785   # <limits.h> exists even on freestanding compilers.
3786   # On the NeXT, cc -E runs the code through the compiler's parser,
3787   # not just through cpp. "Syntax error" is here to catch this case.
3788   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3789 /* end confdefs.h.  */
3790 #ifdef __STDC__
3791 # include <limits.h>
3792 #else
3793 # include <assert.h>
3794 #endif
3795                      Syntax error
3796 _ACEOF
3797 if ac_fn_c_try_cpp "$LINENO"; then :
3798
3799 else
3800   # Broken: fails on valid input.
3801 continue
3802 fi
3803 rm -f conftest.err conftest.i conftest.$ac_ext
3804
3805   # OK, works on sane cases.  Now check whether nonexistent headers
3806   # can be detected and how.
3807   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3808 /* end confdefs.h.  */
3809 #include <ac_nonexistent.h>
3810 _ACEOF
3811 if ac_fn_c_try_cpp "$LINENO"; then :
3812   # Broken: success on invalid input.
3813 continue
3814 else
3815   # Passes both tests.
3816 ac_preproc_ok=:
3817 break
3818 fi
3819 rm -f conftest.err conftest.i conftest.$ac_ext
3820
3821 done
3822 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3823 rm -f conftest.i conftest.err conftest.$ac_ext
3824 if $ac_preproc_ok; then :
3825   break
3826 fi
3827
3828     done
3829     ac_cv_prog_CPP=$CPP
3830
3831 fi
3832   CPP=$ac_cv_prog_CPP
3833 else
3834   ac_cv_prog_CPP=$CPP
3835 fi
3836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3837 $as_echo "$CPP" >&6; }
3838 ac_preproc_ok=false
3839 for ac_c_preproc_warn_flag in '' yes
3840 do
3841   # Use a header file that comes with gcc, so configuring glibc
3842   # with a fresh cross-compiler works.
3843   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3844   # <limits.h> exists even on freestanding compilers.
3845   # On the NeXT, cc -E runs the code through the compiler's parser,
3846   # not just through cpp. "Syntax error" is here to catch this case.
3847   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3848 /* end confdefs.h.  */
3849 #ifdef __STDC__
3850 # include <limits.h>
3851 #else
3852 # include <assert.h>
3853 #endif
3854                      Syntax error
3855 _ACEOF
3856 if ac_fn_c_try_cpp "$LINENO"; then :
3857
3858 else
3859   # Broken: fails on valid input.
3860 continue
3861 fi
3862 rm -f conftest.err conftest.i conftest.$ac_ext
3863
3864   # OK, works on sane cases.  Now check whether nonexistent headers
3865   # can be detected and how.
3866   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3867 /* end confdefs.h.  */
3868 #include <ac_nonexistent.h>
3869 _ACEOF
3870 if ac_fn_c_try_cpp "$LINENO"; then :
3871   # Broken: success on invalid input.
3872 continue
3873 else
3874   # Passes both tests.
3875 ac_preproc_ok=:
3876 break
3877 fi
3878 rm -f conftest.err conftest.i conftest.$ac_ext
3879
3880 done
3881 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3882 rm -f conftest.i conftest.err conftest.$ac_ext
3883 if $ac_preproc_ok; then :
3884
3885 else
3886   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3887 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3888 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3889 See \`config.log' for more details" "$LINENO" 5; }
3890 fi
3891
3892 ac_ext=c
3893 ac_cpp='$CPP $CPPFLAGS'
3894 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3895 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3896 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3897
3898
3899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3900 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3901 if ${ac_cv_path_GREP+:} false; then :
3902   $as_echo_n "(cached) " >&6
3903 else
3904   if test -z "$GREP"; then
3905   ac_path_GREP_found=false
3906   # Loop through the user's path and test for each of PROGNAME-LIST
3907   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3908 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3909 do
3910   IFS=$as_save_IFS
3911   test -z "$as_dir" && as_dir=.
3912     for ac_prog in grep ggrep; do
3913     for ac_exec_ext in '' $ac_executable_extensions; do
3914       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3915       as_fn_executable_p "$ac_path_GREP" || continue
3916 # Check for GNU ac_path_GREP and select it if it is found.
3917   # Check for GNU $ac_path_GREP
3918 case `"$ac_path_GREP" --version 2>&1` in
3919 *GNU*)
3920   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3921 *)
3922   ac_count=0
3923   $as_echo_n 0123456789 >"conftest.in"
3924   while :
3925   do
3926     cat "conftest.in" "conftest.in" >"conftest.tmp"
3927     mv "conftest.tmp" "conftest.in"
3928     cp "conftest.in" "conftest.nl"
3929     $as_echo 'GREP' >> "conftest.nl"
3930     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3931     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3932     as_fn_arith $ac_count + 1 && ac_count=$as_val
3933     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3934       # Best one so far, save it but keep looking for a better one
3935       ac_cv_path_GREP="$ac_path_GREP"
3936       ac_path_GREP_max=$ac_count
3937     fi
3938     # 10*(2^10) chars as input seems more than enough
3939     test $ac_count -gt 10 && break
3940   done
3941   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3942 esac
3943
3944       $ac_path_GREP_found && break 3
3945     done
3946   done
3947   done
3948 IFS=$as_save_IFS
3949   if test -z "$ac_cv_path_GREP"; then
3950     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3951   fi
3952 else
3953   ac_cv_path_GREP=$GREP
3954 fi
3955
3956 fi
3957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3958 $as_echo "$ac_cv_path_GREP" >&6; }
3959  GREP="$ac_cv_path_GREP"
3960
3961
3962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3963 $as_echo_n "checking for egrep... " >&6; }
3964 if ${ac_cv_path_EGREP+:} false; then :
3965   $as_echo_n "(cached) " >&6
3966 else
3967   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3968    then ac_cv_path_EGREP="$GREP -E"
3969    else
3970      if test -z "$EGREP"; then
3971   ac_path_EGREP_found=false
3972   # Loop through the user's path and test for each of PROGNAME-LIST
3973   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3974 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3975 do
3976   IFS=$as_save_IFS
3977   test -z "$as_dir" && as_dir=.
3978     for ac_prog in egrep; do
3979     for ac_exec_ext in '' $ac_executable_extensions; do
3980       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3981       as_fn_executable_p "$ac_path_EGREP" || continue
3982 # Check for GNU ac_path_EGREP and select it if it is found.
3983   # Check for GNU $ac_path_EGREP
3984 case `"$ac_path_EGREP" --version 2>&1` in
3985 *GNU*)
3986   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3987 *)
3988   ac_count=0
3989   $as_echo_n 0123456789 >"conftest.in"
3990   while :
3991   do
3992     cat "conftest.in" "conftest.in" >"conftest.tmp"
3993     mv "conftest.tmp" "conftest.in"
3994     cp "conftest.in" "conftest.nl"
3995     $as_echo 'EGREP' >> "conftest.nl"
3996     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3997     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3998     as_fn_arith $ac_count + 1 && ac_count=$as_val
3999     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4000       # Best one so far, save it but keep looking for a better one
4001       ac_cv_path_EGREP="$ac_path_EGREP"
4002       ac_path_EGREP_max=$ac_count
4003     fi
4004     # 10*(2^10) chars as input seems more than enough
4005     test $ac_count -gt 10 && break
4006   done
4007   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4008 esac
4009
4010       $ac_path_EGREP_found && break 3
4011     done
4012   done
4013   done
4014 IFS=$as_save_IFS
4015   if test -z "$ac_cv_path_EGREP"; then
4016     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4017   fi
4018 else
4019   ac_cv_path_EGREP=$EGREP
4020 fi
4021
4022    fi
4023 fi
4024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4025 $as_echo "$ac_cv_path_EGREP" >&6; }
4026  EGREP="$ac_cv_path_EGREP"
4027
4028
4029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4030 $as_echo_n "checking for ANSI C header files... " >&6; }
4031 if ${ac_cv_header_stdc+:} false; then :
4032   $as_echo_n "(cached) " >&6
4033 else
4034   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4035 /* end confdefs.h.  */
4036 #include <stdlib.h>
4037 #include <stdarg.h>
4038 #include <string.h>
4039 #include <float.h>
4040
4041 int
4042 main ()
4043 {
4044
4045   ;
4046   return 0;
4047 }
4048 _ACEOF
4049 if ac_fn_c_try_compile "$LINENO"; then :
4050   ac_cv_header_stdc=yes
4051 else
4052   ac_cv_header_stdc=no
4053 fi
4054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4055
4056 if test $ac_cv_header_stdc = yes; then
4057   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4058   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4059 /* end confdefs.h.  */
4060 #include <string.h>
4061
4062 _ACEOF
4063 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4064   $EGREP "memchr" >/dev/null 2>&1; then :
4065
4066 else
4067   ac_cv_header_stdc=no
4068 fi
4069 rm -f conftest*
4070
4071 fi
4072
4073 if test $ac_cv_header_stdc = yes; then
4074   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4075   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4076 /* end confdefs.h.  */
4077 #include <stdlib.h>
4078
4079 _ACEOF
4080 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4081   $EGREP "free" >/dev/null 2>&1; then :
4082
4083 else
4084   ac_cv_header_stdc=no
4085 fi
4086 rm -f conftest*
4087
4088 fi
4089
4090 if test $ac_cv_header_stdc = yes; then
4091   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4092   if test "$cross_compiling" = yes; then :
4093   :
4094 else
4095   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4096 /* end confdefs.h.  */
4097 #include <ctype.h>
4098 #include <stdlib.h>
4099 #if ((' ' & 0x0FF) == 0x020)
4100 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4101 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4102 #else
4103 # define ISLOWER(c) \
4104                    (('a' <= (c) && (c) <= 'i') \
4105                      || ('j' <= (c) && (c) <= 'r') \
4106                      || ('s' <= (c) && (c) <= 'z'))
4107 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4108 #endif
4109
4110 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4111 int
4112 main ()
4113 {
4114   int i;
4115   for (i = 0; i < 256; i++)
4116     if (XOR (islower (i), ISLOWER (i))
4117         || toupper (i) != TOUPPER (i))
4118       return 2;
4119   return 0;
4120 }
4121 _ACEOF
4122 if ac_fn_c_try_run "$LINENO"; then :
4123
4124 else
4125   ac_cv_header_stdc=no
4126 fi
4127 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4128   conftest.$ac_objext conftest.beam conftest.$ac_ext
4129 fi
4130
4131 fi
4132 fi
4133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4134 $as_echo "$ac_cv_header_stdc" >&6; }
4135 if test $ac_cv_header_stdc = yes; then
4136
4137 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4138
4139 fi
4140
4141 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4142 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4143                   inttypes.h stdint.h unistd.h
4144 do :
4145   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4146 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4147 "
4148 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4149   cat >>confdefs.h <<_ACEOF
4150 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4151 _ACEOF
4152
4153 fi
4154
4155 done
4156
4157
4158
4159   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4160 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4161   MINIX=yes
4162 else
4163   MINIX=
4164 fi
4165
4166
4167   if test "$MINIX" = yes; then
4168
4169 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4170
4171
4172 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4173
4174
4175 $as_echo "#define _MINIX 1" >>confdefs.h
4176
4177   fi
4178
4179
4180   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4181 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4182 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4183   $as_echo_n "(cached) " >&6
4184 else
4185   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4186 /* end confdefs.h.  */
4187
4188 #         define __EXTENSIONS__ 1
4189           $ac_includes_default
4190 int
4191 main ()
4192 {
4193
4194   ;
4195   return 0;
4196 }
4197 _ACEOF
4198 if ac_fn_c_try_compile "$LINENO"; then :
4199   ac_cv_safe_to_define___extensions__=yes
4200 else
4201   ac_cv_safe_to_define___extensions__=no
4202 fi
4203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4204 fi
4205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4206 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4207   test $ac_cv_safe_to_define___extensions__ = yes &&
4208     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4209
4210   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4211
4212   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4213
4214   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4215
4216   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4217
4218
4219 if test "$ac_cv_header_minix_config_h" = "yes"; then
4220
4221 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4222
4223 fi
4224
4225 case "$prefix" in
4226         NONE)
4227                 prefix="/usr/local"
4228         ;;
4229 esac
4230 case "$exec_prefix" in
4231         NONE)
4232                 exec_prefix="$prefix"
4233         ;;
4234 esac
4235
4236 # are we on MinGW?
4237 if uname -s 2>&1 | grep MINGW >/dev/null; then on_mingw="yes"
4238 else
4239         if echo $host | grep mingw >/dev/null; then on_mingw="yes"
4240         else on_mingw="no"; fi
4241 fi
4242
4243 #
4244 # Determine configuration file
4245 # the eval is to evaluate shell expansion twice
4246 UNBOUND_SBIN_DIR=`eval echo "${sbindir}"`
4247
4248 UNBOUND_SYSCONF_DIR=`eval echo "${sysconfdir}"`
4249
4250 UNBOUND_LOCALSTATE_DIR=`eval echo "${localstatedir}"`
4251
4252 if test $on_mingw = "no"; then
4253   ub_conf_file=`eval echo "${sysconfdir}/unbound/unbound.conf"`
4254 else
4255   ub_conf_file="C:\\Program Files\\Unbound\\service.conf"
4256 fi
4257
4258 # Check whether --with-conf_file was given.
4259 if test "${with_conf_file+set}" = set; then :
4260   withval=$with_conf_file; ub_conf_file="$withval"
4261 fi
4262
4263
4264 hdr_config="`echo $ub_conf_file | sed -e 's/\\\\/\\\\\\\\/g'`"
4265
4266
4267 cat >>confdefs.h <<_ACEOF
4268 #define CONFIGFILE "$hdr_config"
4269 _ACEOF
4270
4271 ub_conf_dir=`$as_dirname -- "$ub_conf_file" ||
4272 $as_expr X"$ub_conf_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4273          X"$ub_conf_file" : 'X\(//\)[^/]' \| \
4274          X"$ub_conf_file" : 'X\(//\)$' \| \
4275          X"$ub_conf_file" : 'X\(/\)' \| . 2>/dev/null ||
4276 $as_echo X"$ub_conf_file" |
4277     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
4278             s//\1/
4279             q
4280           }
4281           /^X\(\/\/\)[^/].*/{
4282             s//\1/
4283             q
4284           }
4285           /^X\(\/\/\)$/{
4286             s//\1/
4287             q
4288           }
4289           /^X\(\/\).*/{
4290             s//\1/
4291             q
4292           }
4293           s/.*/./; q'`
4294
4295
4296 # Determine run, chroot directory and pidfile locations
4297
4298 # Check whether --with-run-dir was given.
4299 if test "${with_run_dir+set}" = set; then :
4300   withval=$with_run_dir; UNBOUND_RUN_DIR="$withval"
4301 else
4302   if test $on_mingw = no; then
4303     UNBOUND_RUN_DIR=`dirname "$ub_conf_file"`
4304 else
4305     UNBOUND_RUN_DIR=""
4306 fi
4307
4308 fi
4309
4310
4311 hdr_run="`echo $UNBOUND_RUN_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4312
4313
4314 cat >>confdefs.h <<_ACEOF
4315 #define RUN_DIR "$hdr_run"
4316 _ACEOF
4317
4318
4319
4320 # Check whether --with-chroot-dir was given.
4321 if test "${with_chroot_dir+set}" = set; then :
4322   withval=$with_chroot_dir; UNBOUND_CHROOT_DIR="$withval"
4323 else
4324   if test $on_mingw = no; then
4325     UNBOUND_CHROOT_DIR="$UNBOUND_RUN_DIR"
4326 else
4327     UNBOUND_CHROOT_DIR=""
4328 fi
4329
4330 fi
4331
4332
4333 hdr_chroot="`echo $UNBOUND_CHROOT_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4334
4335
4336 cat >>confdefs.h <<_ACEOF
4337 #define CHROOT_DIR "$hdr_chroot"
4338 _ACEOF
4339
4340
4341
4342 # Check whether --with-share-dir was given.
4343 if test "${with_share_dir+set}" = set; then :
4344   withval=$with_share_dir; UNBOUND_SHARE_DIR="$withval"
4345 else
4346   UNBOUND_SHARE_DIR="$UNBOUND_RUN_DIR"
4347 fi
4348
4349
4350
4351 cat >>confdefs.h <<_ACEOF
4352 #define SHARE_DIR "$UNBOUND_SHARE_DIR"
4353 _ACEOF
4354
4355
4356
4357 # Check whether --with-pidfile was given.
4358 if test "${with_pidfile+set}" = set; then :
4359   withval=$with_pidfile; UNBOUND_PIDFILE="$withval"
4360 else
4361   if test $on_mingw = no; then
4362     UNBOUND_PIDFILE="$UNBOUND_RUN_DIR/unbound.pid"
4363 else
4364     UNBOUND_PIDFILE=""
4365 fi
4366
4367 fi
4368
4369
4370 hdr_pid="`echo $UNBOUND_PIDFILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4371
4372
4373 cat >>confdefs.h <<_ACEOF
4374 #define PIDFILE "$hdr_pid"
4375 _ACEOF
4376
4377
4378
4379 # Check whether --with-rootkey-file was given.
4380 if test "${with_rootkey_file+set}" = set; then :
4381   withval=$with_rootkey_file; UNBOUND_ROOTKEY_FILE="$withval"
4382 else
4383   if test $on_mingw = no; then
4384     UNBOUND_ROOTKEY_FILE="$UNBOUND_RUN_DIR/root.key"
4385 else
4386     UNBOUND_ROOTKEY_FILE="C:\\Program Files\\Unbound\\root.key"
4387 fi
4388
4389 fi
4390
4391
4392 hdr_rkey="`echo $UNBOUND_ROOTKEY_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4393
4394
4395 cat >>confdefs.h <<_ACEOF
4396 #define ROOT_ANCHOR_FILE "$hdr_rkey"
4397 _ACEOF
4398
4399
4400
4401 # Check whether --with-rootcert-file was given.
4402 if test "${with_rootcert_file+set}" = set; then :
4403   withval=$with_rootcert_file; UNBOUND_ROOTCERT_FILE="$withval"
4404 else
4405   if test $on_mingw = no; then
4406     UNBOUND_ROOTCERT_FILE="$UNBOUND_RUN_DIR/icannbundle.pem"
4407 else
4408     UNBOUND_ROOTCERT_FILE="C:\\Program Files\\Unbound\\icannbundle.pem"
4409 fi
4410
4411 fi
4412
4413
4414 hdr_rpem="`echo $UNBOUND_ROOTCERT_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4415
4416
4417 cat >>confdefs.h <<_ACEOF
4418 #define ROOT_CERT_FILE "$hdr_rpem"
4419 _ACEOF
4420
4421
4422
4423 # Check whether --with-username was given.
4424 if test "${with_username+set}" = set; then :
4425   withval=$with_username; UNBOUND_USERNAME="$withval"
4426 else
4427   UNBOUND_USERNAME="unbound"
4428 fi
4429
4430
4431
4432 cat >>confdefs.h <<_ACEOF
4433 #define UB_USERNAME "$UNBOUND_USERNAME"
4434 _ACEOF
4435
4436
4437
4438 $as_echo "#define WINVER 0x0502" >>confdefs.h
4439
4440 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/' `
4441
4442
4443 cat >>confdefs.h <<_ACEOF
4444 #define RSRC_PACKAGE_VERSION $wnvs
4445 _ACEOF
4446
4447
4448 # Checks for typedefs, structures, and compiler characteristics.
4449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
4450 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
4451 if ${ac_cv_c_const+:} false; then :
4452   $as_echo_n "(cached) " >&6
4453 else
4454   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4455 /* end confdefs.h.  */
4456
4457 int
4458 main ()
4459 {
4460
4461 #ifndef __cplusplus
4462   /* Ultrix mips cc rejects this sort of thing.  */
4463   typedef int charset[2];
4464   const charset cs = { 0, 0 };
4465   /* SunOS 4.1.1 cc rejects this.  */
4466   char const *const *pcpcc;
4467   char **ppc;
4468   /* NEC SVR4.0.2 mips cc rejects this.  */
4469   struct point {int x, y;};
4470   static struct point const zero = {0,0};
4471   /* AIX XL C 1.02.0.0 rejects this.
4472      It does not let you subtract one const X* pointer from another in
4473      an arm of an if-expression whose if-part is not a constant
4474      expression */
4475   const char *g = "string";
4476   pcpcc = &g + (g ? g-g : 0);
4477   /* HPUX 7.0 cc rejects these. */
4478   ++pcpcc;
4479   ppc = (char**) pcpcc;
4480   pcpcc = (char const *const *) ppc;
4481   { /* SCO 3.2v4 cc rejects this sort of thing.  */
4482     char tx;
4483     char *t = &tx;
4484     char const *s = 0 ? (char *) 0 : (char const *) 0;
4485
4486     *t++ = 0;
4487     if (s) return 0;
4488   }
4489   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
4490     int x[] = {25, 17};
4491     const int *foo = &x[0];
4492     ++foo;
4493   }
4494   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4495     typedef const int *iptr;
4496     iptr p = 0;
4497     ++p;
4498   }
4499   { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
4500        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4501     struct s { int j; const int *ap[3]; } bx;
4502     struct s *b = &bx; b->j = 5;
4503   }
4504   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4505     const int foo = 10;
4506     if (!foo) return 0;
4507   }
4508   return !cs[0] && !zero.x;
4509 #endif
4510
4511   ;
4512   return 0;
4513 }
4514 _ACEOF
4515 if ac_fn_c_try_compile "$LINENO"; then :
4516   ac_cv_c_const=yes
4517 else
4518   ac_cv_c_const=no
4519 fi
4520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4521 fi
4522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
4523 $as_echo "$ac_cv_c_const" >&6; }
4524 if test $ac_cv_c_const = no; then
4525
4526 $as_echo "#define const /**/" >>confdefs.h
4527
4528 fi
4529
4530 ac_ext=c
4531 ac_cpp='$CPP $CPPFLAGS'
4532 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4533 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4534 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4535
4536 # allow user to override the -g -O2 flags.
4537 default_cflags=no
4538 if test "x$CFLAGS" = "x" ; then
4539
4540
4541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -g" >&5
4542 $as_echo_n "checking whether $CC supports -g... " >&6; }
4543 cache=`echo g | sed 'y%.=/+-%___p_%'`
4544 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4545   $as_echo_n "(cached) " >&6
4546 else
4547
4548 echo 'void f(void){}' >conftest.c
4549 if test -z "`$CC $CPPFLAGS $CFLAGS -g -c conftest.c 2>&1`"; then
4550 eval "cv_prog_cc_flag_$cache=yes"
4551 else
4552 eval "cv_prog_cc_flag_$cache=no"
4553 fi
4554 rm -f conftest conftest.o conftest.c
4555
4556 fi
4557
4558 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4560 $as_echo "yes" >&6; }
4561 :
4562 CFLAGS="$CFLAGS -g"
4563 else
4564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4565 $as_echo "no" >&6; }
4566 :
4567
4568 fi
4569
4570
4571
4572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -O2" >&5
4573 $as_echo_n "checking whether $CC supports -O2... " >&6; }
4574 cache=`echo O2 | sed 'y%.=/+-%___p_%'`
4575 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4576   $as_echo_n "(cached) " >&6
4577 else
4578
4579 echo 'void f(void){}' >conftest.c
4580 if test -z "`$CC $CPPFLAGS $CFLAGS -O2 -c conftest.c 2>&1`"; then
4581 eval "cv_prog_cc_flag_$cache=yes"
4582 else
4583 eval "cv_prog_cc_flag_$cache=no"
4584 fi
4585 rm -f conftest conftest.o conftest.c
4586
4587 fi
4588
4589 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4591 $as_echo "yes" >&6; }
4592 :
4593 CFLAGS="$CFLAGS -O2"
4594 else
4595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4596 $as_echo "no" >&6; }
4597 :
4598
4599 fi
4600
4601 default_cflags=yes
4602 fi
4603 ac_ext=c
4604 ac_cpp='$CPP $CPPFLAGS'
4605 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4606 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4607 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4608 if test -n "$ac_tool_prefix"; then
4609   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4610 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4612 $as_echo_n "checking for $ac_word... " >&6; }
4613 if ${ac_cv_prog_CC+:} false; then :
4614   $as_echo_n "(cached) " >&6
4615 else
4616   if test -n "$CC"; then
4617   ac_cv_prog_CC="$CC" # Let the user override the test.
4618 else
4619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4620 for as_dir in $PATH
4621 do
4622   IFS=$as_save_IFS
4623   test -z "$as_dir" && as_dir=.
4624     for ac_exec_ext in '' $ac_executable_extensions; do
4625   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4626     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4627     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4628     break 2
4629   fi
4630 done
4631   done
4632 IFS=$as_save_IFS
4633
4634 fi
4635 fi
4636 CC=$ac_cv_prog_CC
4637 if test -n "$CC"; then
4638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4639 $as_echo "$CC" >&6; }
4640 else
4641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4642 $as_echo "no" >&6; }
4643 fi
4644
4645
4646 fi
4647 if test -z "$ac_cv_prog_CC"; then
4648   ac_ct_CC=$CC
4649   # Extract the first word of "gcc", so it can be a program name with args.
4650 set dummy gcc; ac_word=$2
4651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4652 $as_echo_n "checking for $ac_word... " >&6; }
4653 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4654   $as_echo_n "(cached) " >&6
4655 else
4656   if test -n "$ac_ct_CC"; then
4657   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4658 else
4659 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4660 for as_dir in $PATH
4661 do
4662   IFS=$as_save_IFS
4663   test -z "$as_dir" && as_dir=.
4664     for ac_exec_ext in '' $ac_executable_extensions; do
4665   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4666     ac_cv_prog_ac_ct_CC="gcc"
4667     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4668     break 2
4669   fi
4670 done
4671   done
4672 IFS=$as_save_IFS
4673
4674 fi
4675 fi
4676 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4677 if test -n "$ac_ct_CC"; then
4678   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4679 $as_echo "$ac_ct_CC" >&6; }
4680 else
4681   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4682 $as_echo "no" >&6; }
4683 fi
4684
4685   if test "x$ac_ct_CC" = x; then
4686     CC=""
4687   else
4688     case $cross_compiling:$ac_tool_warned in
4689 yes:)
4690 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4691 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4692 ac_tool_warned=yes ;;
4693 esac
4694     CC=$ac_ct_CC
4695   fi
4696 else
4697   CC="$ac_cv_prog_CC"
4698 fi
4699
4700 if test -z "$CC"; then
4701           if test -n "$ac_tool_prefix"; then
4702     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4703 set dummy ${ac_tool_prefix}cc; ac_word=$2
4704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4705 $as_echo_n "checking for $ac_word... " >&6; }
4706 if ${ac_cv_prog_CC+:} false; then :
4707   $as_echo_n "(cached) " >&6
4708 else
4709   if test -n "$CC"; then
4710   ac_cv_prog_CC="$CC" # Let the user override the test.
4711 else
4712 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4713 for as_dir in $PATH
4714 do
4715   IFS=$as_save_IFS
4716   test -z "$as_dir" && as_dir=.
4717     for ac_exec_ext in '' $ac_executable_extensions; do
4718   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4719     ac_cv_prog_CC="${ac_tool_prefix}cc"
4720     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4721     break 2
4722   fi
4723 done
4724   done
4725 IFS=$as_save_IFS
4726
4727 fi
4728 fi
4729 CC=$ac_cv_prog_CC
4730 if test -n "$CC"; then
4731   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4732 $as_echo "$CC" >&6; }
4733 else
4734   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4735 $as_echo "no" >&6; }
4736 fi
4737
4738
4739   fi
4740 fi
4741 if test -z "$CC"; then
4742   # Extract the first word of "cc", so it can be a program name with args.
4743 set dummy cc; ac_word=$2
4744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4745 $as_echo_n "checking for $ac_word... " >&6; }
4746 if ${ac_cv_prog_CC+:} false; then :
4747   $as_echo_n "(cached) " >&6
4748 else
4749   if test -n "$CC"; then
4750   ac_cv_prog_CC="$CC" # Let the user override the test.
4751 else
4752   ac_prog_rejected=no
4753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4754 for as_dir in $PATH
4755 do
4756   IFS=$as_save_IFS
4757   test -z "$as_dir" && as_dir=.
4758     for ac_exec_ext in '' $ac_executable_extensions; do
4759   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4760     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4761        ac_prog_rejected=yes
4762        continue
4763      fi
4764     ac_cv_prog_CC="cc"
4765     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4766     break 2
4767   fi
4768 done
4769   done
4770 IFS=$as_save_IFS
4771
4772 if test $ac_prog_rejected = yes; then
4773   # We found a bogon in the path, so make sure we never use it.
4774   set dummy $ac_cv_prog_CC
4775   shift
4776   if test $# != 0; then
4777     # We chose a different compiler from the bogus one.
4778     # However, it has the same basename, so the bogon will be chosen
4779     # first if we set CC to just the basename; use the full file name.
4780     shift
4781     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4782   fi
4783 fi
4784 fi
4785 fi
4786 CC=$ac_cv_prog_CC
4787 if test -n "$CC"; then
4788   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4789 $as_echo "$CC" >&6; }
4790 else
4791   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4792 $as_echo "no" >&6; }
4793 fi
4794
4795
4796 fi
4797 if test -z "$CC"; then
4798   if test -n "$ac_tool_prefix"; then
4799   for ac_prog in cl.exe
4800   do
4801     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4802 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4804 $as_echo_n "checking for $ac_word... " >&6; }
4805 if ${ac_cv_prog_CC+:} false; then :
4806   $as_echo_n "(cached) " >&6
4807 else
4808   if test -n "$CC"; then
4809   ac_cv_prog_CC="$CC" # Let the user override the test.
4810 else
4811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4812 for as_dir in $PATH
4813 do
4814   IFS=$as_save_IFS
4815   test -z "$as_dir" && as_dir=.
4816     for ac_exec_ext in '' $ac_executable_extensions; do
4817   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4818     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4819     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4820     break 2
4821   fi
4822 done
4823   done
4824 IFS=$as_save_IFS
4825
4826 fi
4827 fi
4828 CC=$ac_cv_prog_CC
4829 if test -n "$CC"; then
4830   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4831 $as_echo "$CC" >&6; }
4832 else
4833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4834 $as_echo "no" >&6; }
4835 fi
4836
4837
4838     test -n "$CC" && break
4839   done
4840 fi
4841 if test -z "$CC"; then
4842   ac_ct_CC=$CC
4843   for ac_prog in cl.exe
4844 do
4845   # Extract the first word of "$ac_prog", so it can be a program name with args.
4846 set dummy $ac_prog; ac_word=$2
4847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4848 $as_echo_n "checking for $ac_word... " >&6; }
4849 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4850   $as_echo_n "(cached) " >&6
4851 else
4852   if test -n "$ac_ct_CC"; then
4853   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4854 else
4855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4856 for as_dir in $PATH
4857 do
4858   IFS=$as_save_IFS
4859   test -z "$as_dir" && as_dir=.
4860     for ac_exec_ext in '' $ac_executable_extensions; do
4861   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4862     ac_cv_prog_ac_ct_CC="$ac_prog"
4863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4864     break 2
4865   fi
4866 done
4867   done
4868 IFS=$as_save_IFS
4869
4870 fi
4871 fi
4872 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4873 if test -n "$ac_ct_CC"; then
4874   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4875 $as_echo "$ac_ct_CC" >&6; }
4876 else
4877   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4878 $as_echo "no" >&6; }
4879 fi
4880
4881
4882   test -n "$ac_ct_CC" && break
4883 done
4884
4885   if test "x$ac_ct_CC" = x; then
4886     CC=""
4887   else
4888     case $cross_compiling:$ac_tool_warned in
4889 yes:)
4890 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4891 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4892 ac_tool_warned=yes ;;
4893 esac
4894     CC=$ac_ct_CC
4895   fi
4896 fi
4897
4898 fi
4899
4900
4901 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4902 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4903 as_fn_error $? "no acceptable C compiler found in \$PATH
4904 See \`config.log' for more details" "$LINENO" 5; }
4905
4906 # Provide some information about the compiler.
4907 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4908 set X $ac_compile
4909 ac_compiler=$2
4910 for ac_option in --version -v -V -qversion; do
4911   { { ac_try="$ac_compiler $ac_option >&5"
4912 case "(($ac_try" in
4913   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4914   *) ac_try_echo=$ac_try;;
4915 esac
4916 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4917 $as_echo "$ac_try_echo"; } >&5
4918   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4919   ac_status=$?
4920   if test -s conftest.err; then
4921     sed '10a\
4922 ... rest of stderr output deleted ...
4923          10q' conftest.err >conftest.er1
4924     cat conftest.er1 >&5
4925   fi
4926   rm -f conftest.er1 conftest.err
4927   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4928   test $ac_status = 0; }
4929 done
4930
4931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4932 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4933 if ${ac_cv_c_compiler_gnu+:} false; then :
4934   $as_echo_n "(cached) " >&6
4935 else
4936   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4937 /* end confdefs.h.  */
4938
4939 int
4940 main ()
4941 {
4942 #ifndef __GNUC__
4943        choke me
4944 #endif
4945
4946   ;
4947   return 0;
4948 }
4949 _ACEOF
4950 if ac_fn_c_try_compile "$LINENO"; then :
4951   ac_compiler_gnu=yes
4952 else
4953   ac_compiler_gnu=no
4954 fi
4955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4956 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4957
4958 fi
4959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4960 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4961 if test $ac_compiler_gnu = yes; then
4962   GCC=yes
4963 else
4964   GCC=
4965 fi
4966 ac_test_CFLAGS=${CFLAGS+set}
4967 ac_save_CFLAGS=$CFLAGS
4968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4969 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4970 if ${ac_cv_prog_cc_g+:} false; then :
4971   $as_echo_n "(cached) " >&6
4972 else
4973   ac_save_c_werror_flag=$ac_c_werror_flag
4974    ac_c_werror_flag=yes
4975    ac_cv_prog_cc_g=no
4976    CFLAGS="-g"
4977    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4978 /* end confdefs.h.  */
4979
4980 int
4981 main ()
4982 {
4983
4984   ;
4985   return 0;
4986 }
4987 _ACEOF
4988 if ac_fn_c_try_compile "$LINENO"; then :
4989   ac_cv_prog_cc_g=yes
4990 else
4991   CFLAGS=""
4992       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4993 /* end confdefs.h.  */
4994
4995 int
4996 main ()
4997 {
4998
4999   ;
5000   return 0;
5001 }
5002 _ACEOF
5003 if ac_fn_c_try_compile "$LINENO"; then :
5004
5005 else
5006   ac_c_werror_flag=$ac_save_c_werror_flag
5007          CFLAGS="-g"
5008          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5009 /* end confdefs.h.  */
5010
5011 int
5012 main ()
5013 {
5014
5015   ;
5016   return 0;
5017 }
5018 _ACEOF
5019 if ac_fn_c_try_compile "$LINENO"; then :
5020   ac_cv_prog_cc_g=yes
5021 fi
5022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5023 fi
5024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5025 fi
5026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5027    ac_c_werror_flag=$ac_save_c_werror_flag
5028 fi
5029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5030 $as_echo "$ac_cv_prog_cc_g" >&6; }
5031 if test "$ac_test_CFLAGS" = set; then
5032   CFLAGS=$ac_save_CFLAGS
5033 elif test $ac_cv_prog_cc_g = yes; then
5034   if test "$GCC" = yes; then
5035     CFLAGS="-g -O2"
5036   else
5037     CFLAGS="-g"
5038   fi
5039 else
5040   if test "$GCC" = yes; then
5041     CFLAGS="-O2"
5042   else
5043     CFLAGS=
5044   fi
5045 fi
5046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5047 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5048 if ${ac_cv_prog_cc_c89+:} false; then :
5049   $as_echo_n "(cached) " >&6
5050 else
5051   ac_cv_prog_cc_c89=no
5052 ac_save_CC=$CC
5053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5054 /* end confdefs.h.  */
5055 #include <stdarg.h>
5056 #include <stdio.h>
5057 struct stat;
5058 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5059 struct buf { int x; };
5060 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5061 static char *e (p, i)
5062      char **p;
5063      int i;
5064 {
5065   return p[i];
5066 }
5067 static char *f (char * (*g) (char **, int), char **p, ...)
5068 {
5069   char *s;
5070   va_list v;
5071   va_start (v,p);
5072   s = g (p, va_arg (v,int));
5073   va_end (v);
5074   return s;
5075 }
5076
5077 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5078    function prototypes and stuff, but not '\xHH' hex character constants.
5079    These don't provoke an error unfortunately, instead are silently treated
5080    as 'x'.  The following induces an error, until -std is added to get
5081    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5082    array size at least.  It's necessary to write '\x00'==0 to get something
5083    that's true only with -std.  */
5084 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5085
5086 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5087    inside strings and character constants.  */
5088 #define FOO(x) 'x'
5089 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5090
5091 int test (int i, double x);
5092 struct s1 {int (*f) (int a);};
5093 struct s2 {int (*f) (double a);};
5094 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5095 int argc;
5096 char **argv;
5097 int
5098 main ()
5099 {
5100 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5101   ;
5102   return 0;
5103 }
5104 _ACEOF
5105 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5106         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5107 do
5108   CC="$ac_save_CC $ac_arg"
5109   if ac_fn_c_try_compile "$LINENO"; then :
5110   ac_cv_prog_cc_c89=$ac_arg
5111 fi
5112 rm -f core conftest.err conftest.$ac_objext
5113   test "x$ac_cv_prog_cc_c89" != "xno" && break
5114 done
5115 rm -f conftest.$ac_ext
5116 CC=$ac_save_CC
5117
5118 fi
5119 # AC_CACHE_VAL
5120 case "x$ac_cv_prog_cc_c89" in
5121   x)
5122     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5123 $as_echo "none needed" >&6; } ;;
5124   xno)
5125     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5126 $as_echo "unsupported" >&6; } ;;
5127   *)
5128     CC="$CC $ac_cv_prog_cc_c89"
5129     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5130 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5131 esac
5132 if test "x$ac_cv_prog_cc_c89" != xno; then :
5133
5134 fi
5135
5136 ac_ext=c
5137 ac_cpp='$CPP $CPPFLAGS'
5138 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5139 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5140 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5141
5142
5143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $CC dependency flag" >&5
5144 $as_echo_n "checking $CC dependency flag... " >&6; }
5145 echo 'void f(){}' >conftest.c
5146 if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5147         DEPFLAG="-MM"
5148 else
5149   if test "`$CC -xM1 conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5150         DEPFLAG="-xM1"
5151   else
5152         DEPFLAG="-MM"  # dunno do something
5153   fi
5154 fi
5155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEPFLAG" >&5
5156 $as_echo "$DEPFLAG" >&6; }
5157 rm -f conftest.c
5158
5159
5160
5161
5162
5163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Werror" >&5
5164 $as_echo_n "checking whether $CC supports -Werror... " >&6; }
5165 cache=`echo Werror | sed 'y%.=/+-%___p_%'`
5166 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5167   $as_echo_n "(cached) " >&6
5168 else
5169
5170 echo 'void f(void){}' >conftest.c
5171 if test -z "`$CC $CPPFLAGS $CFLAGS -Werror -c conftest.c 2>&1`"; then
5172 eval "cv_prog_cc_flag_$cache=yes"
5173 else
5174 eval "cv_prog_cc_flag_$cache=no"
5175 fi
5176 rm -f conftest conftest.o conftest.c
5177
5178 fi
5179
5180 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5182 $as_echo "yes" >&6; }
5183 :
5184 ERRFLAG="-Werror"
5185 else
5186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5187 $as_echo "no" >&6; }
5188 :
5189 ERRFLAG="-errwarn"
5190 fi
5191
5192
5193
5194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5195 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5196 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5197 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5198   $as_echo_n "(cached) " >&6
5199 else
5200
5201 echo 'void f(void){}' >conftest.c
5202 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5203 eval "cv_prog_cc_flag_$cache=yes"
5204 else
5205 eval "cv_prog_cc_flag_$cache=no"
5206 fi
5207 rm -f conftest conftest.o conftest.c
5208
5209 fi
5210
5211 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5213 $as_echo "yes" >&6; }
5214 :
5215 ERRFLAG="$ERRFLAG -Wall"
5216 else
5217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5218 $as_echo "no" >&6; }
5219 :
5220 ERRFLAG="$ERRFLAG -errfmt"
5221 fi
5222
5223
5224
5225
5226
5227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -std=c99" >&5
5228 $as_echo_n "checking whether $CC supports -std=c99... " >&6; }
5229 cache=`echo std=c99 | sed 'y%.=/+-%___p_%'`
5230 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5231   $as_echo_n "(cached) " >&6
5232 else
5233
5234 echo 'void f(void){}' >conftest.c
5235 if test -z "`$CC $CPPFLAGS $CFLAGS -std=c99 -c conftest.c 2>&1`"; then
5236 eval "cv_prog_cc_flag_$cache=yes"
5237 else
5238 eval "cv_prog_cc_flag_$cache=no"
5239 fi
5240 rm -f conftest conftest.o conftest.c
5241
5242 fi
5243
5244 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5246 $as_echo "yes" >&6; }
5247 :
5248 C99FLAG="-std=c99"
5249 else
5250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5251 $as_echo "no" >&6; }
5252 :
5253
5254 fi
5255
5256
5257
5258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -xc99" >&5
5259 $as_echo_n "checking whether $CC supports -xc99... " >&6; }
5260 cache=`echo xc99 | sed 'y%.=/+-%___p_%'`
5261 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5262   $as_echo_n "(cached) " >&6
5263 else
5264
5265 echo 'void f(void){}' >conftest.c
5266 if test -z "`$CC $CPPFLAGS $CFLAGS -xc99 -c conftest.c 2>&1`"; then
5267 eval "cv_prog_cc_flag_$cache=yes"
5268 else
5269 eval "cv_prog_cc_flag_$cache=no"
5270 fi
5271 rm -f conftest conftest.o conftest.c
5272
5273 fi
5274
5275 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5277 $as_echo "yes" >&6; }
5278 :
5279 C99FLAG="-xc99"
5280 else
5281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5282 $as_echo "no" >&6; }
5283 :
5284
5285 fi
5286
5287
5288 for ac_header in getopt.h time.h
5289 do :
5290   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5291 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5292 "
5293 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5294   cat >>confdefs.h <<_ACEOF
5295 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5296 _ACEOF
5297
5298 fi
5299
5300 done
5301
5302
5303
5304
5305
5306 { $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
5307 $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; }
5308 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`
5309 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5310   $as_echo_n "(cached) " >&6
5311 else
5312
5313 echo '
5314 #include "confdefs.h"
5315 #include <stdlib.h>
5316 #include <ctype.h>
5317 #include <sys/time.h>
5318 #ifdef HAVE_TIME_H
5319 #include <time.h>
5320 #endif
5321 #include <unistd.h>
5322 #include <netdb.h>
5323 #ifdef HAVE_GETOPT_H
5324 #include <getopt.h>
5325 #endif
5326
5327 int test() {
5328         int a;
5329         char **opts = NULL;
5330         struct timeval tv;
5331         char *t;
5332         time_t time = 0;
5333         char *buf = NULL;
5334         const char* str = NULL;
5335         struct msghdr msg;
5336         msg.msg_control = 0;
5337         t = ctime_r(&time, buf);
5338         tv.tv_usec = 10;
5339         srandom(32);
5340         a = getopt(2, opts, "a");
5341         a = isascii(32);
5342         str = gai_strerror(0);
5343         if(str && t && tv.tv_usec && msg.msg_control)
5344                 a = 0;
5345         return a;
5346 }
5347 ' > conftest.c
5348 echo 'void f(){}' >>conftest.c
5349 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5350 eval "cv_prog_cc_flag_needed_$cache=no"
5351 else
5352
5353 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
5354 eval "cv_prog_cc_flag_needed_$cache=yes"
5355 else
5356 eval "cv_prog_cc_flag_needed_$cache=fail"
5357 #echo 'Test with flag fails too!'
5358 #cat conftest.c
5359 #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"
5360 #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`
5361 #exit 1
5362 fi
5363
5364 fi
5365 rm -f conftest conftest.c conftest.o
5366
5367 fi
5368
5369 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5371 $as_echo "yes" >&6; }
5372 :
5373 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"
5374 else
5375 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5377 $as_echo "no" >&6; }
5378 #echo 'Test with flag is no!'
5379 #cat conftest.c
5380 #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"
5381 #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`
5382 #exit 1
5383 :
5384
5385 else
5386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5387 $as_echo "failed" >&6; }
5388 :
5389
5390 fi
5391 fi
5392
5393
5394
5395
5396
5397 { $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
5398 $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; }
5399 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`
5400 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5401   $as_echo_n "(cached) " >&6
5402 else
5403
5404 echo '
5405 #include "confdefs.h"
5406 #include <stdlib.h>
5407 #include <ctype.h>
5408 #include <sys/time.h>
5409 #ifdef HAVE_TIME_H
5410 #include <time.h>
5411 #endif
5412 #include <unistd.h>
5413 #include <netdb.h>
5414 #ifdef HAVE_GETOPT_H
5415 #include <getopt.h>
5416 #endif
5417
5418 int test() {
5419         int a;
5420         char **opts = NULL;
5421         struct timeval tv;
5422         char *t;
5423         time_t time = 0;
5424         char *buf = NULL;
5425         const char* str = NULL;
5426         struct msghdr msg;
5427         msg.msg_control = 0;
5428         t = ctime_r(&time, buf);
5429         tv.tv_usec = 10;
5430         srandom(32);
5431         a = getopt(2, opts, "a");
5432         a = isascii(32);
5433         str = gai_strerror(0);
5434         if(str && t && tv.tv_usec && msg.msg_control)
5435                 a = 0;
5436         return a;
5437 }
5438 ' > conftest.c
5439 echo 'void f(){}' >>conftest.c
5440 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5441 eval "cv_prog_cc_flag_needed_$cache=no"
5442 else
5443
5444 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
5445 eval "cv_prog_cc_flag_needed_$cache=yes"
5446 else
5447 eval "cv_prog_cc_flag_needed_$cache=fail"
5448 #echo 'Test with flag fails too!'
5449 #cat conftest.c
5450 #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"
5451 #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`
5452 #exit 1
5453 fi
5454
5455 fi
5456 rm -f conftest conftest.c conftest.o
5457
5458 fi
5459
5460 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5462 $as_echo "yes" >&6; }
5463 :
5464 CFLAGS="$CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE"
5465 else
5466 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5468 $as_echo "no" >&6; }
5469 #echo 'Test with flag is no!'
5470 #cat conftest.c
5471 #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"
5472 #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`
5473 #exit 1
5474 :
5475
5476 else
5477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5478 $as_echo "failed" >&6; }
5479 :
5480
5481 fi
5482 fi
5483
5484
5485
5486
5487
5488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG as a flag for $CC" >&5
5489 $as_echo_n "checking whether we need $C99FLAG as a flag for $CC... " >&6; }
5490 cache=`$as_echo "$C99FLAG" | $as_tr_sh`
5491 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5492   $as_echo_n "(cached) " >&6
5493 else
5494
5495 echo '
5496 #include <stdbool.h>
5497 #include <ctype.h>
5498 int test() {
5499         int a = 0;
5500         return a;
5501 }
5502 ' > conftest.c
5503 echo 'void f(){}' >>conftest.c
5504 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5505 eval "cv_prog_cc_flag_needed_$cache=no"
5506 else
5507
5508 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`"; then
5509 eval "cv_prog_cc_flag_needed_$cache=yes"
5510 else
5511 eval "cv_prog_cc_flag_needed_$cache=fail"
5512 #echo 'Test with flag fails too!'
5513 #cat conftest.c
5514 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5515 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5516 #exit 1
5517 fi
5518
5519 fi
5520 rm -f conftest conftest.c conftest.o
5521
5522 fi
5523
5524 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5526 $as_echo "yes" >&6; }
5527 :
5528 CFLAGS="$CFLAGS $C99FLAG"
5529 else
5530 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5532 $as_echo "no" >&6; }
5533 #echo 'Test with flag is no!'
5534 #cat conftest.c
5535 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5536 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5537 #exit 1
5538 :
5539
5540 else
5541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5542 $as_echo "failed" >&6; }
5543 :
5544
5545 fi
5546 fi
5547
5548
5549
5550
5551
5552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC" >&5
5553 $as_echo_n "checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC... " >&6; }
5554 cache=_D_BSD_SOURCE__D_DEFAULT_SOURCE
5555 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5556   $as_echo_n "(cached) " >&6
5557 else
5558
5559 echo '
5560 #include <ctype.h>
5561
5562 int test() {
5563         int a;
5564         a = isascii(32);
5565         return a;
5566 }
5567 ' > conftest.c
5568 echo 'void f(){}' >>conftest.c
5569 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5570 eval "cv_prog_cc_flag_needed_$cache=no"
5571 else
5572
5573 if test -z "`$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5574 eval "cv_prog_cc_flag_needed_$cache=yes"
5575 else
5576 eval "cv_prog_cc_flag_needed_$cache=fail"
5577 #echo 'Test with flag fails too!'
5578 #cat conftest.c
5579 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5580 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5581 #exit 1
5582 fi
5583
5584 fi
5585 rm -f conftest conftest.c conftest.o
5586
5587 fi
5588
5589 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5591 $as_echo "yes" >&6; }
5592 :
5593 CFLAGS="$CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE"
5594 else
5595 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5597 $as_echo "no" >&6; }
5598 #echo 'Test with flag is no!'
5599 #cat conftest.c
5600 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5601 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5602 #exit 1
5603 :
5604
5605 else
5606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5607 $as_echo "failed" >&6; }
5608 :
5609
5610 fi
5611 fi
5612
5613
5614
5615
5616
5617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE as a flag for $CC" >&5
5618 $as_echo_n "checking whether we need -D_GNU_SOURCE as a flag for $CC... " >&6; }
5619 cache=_D_GNU_SOURCE
5620 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5621   $as_echo_n "(cached) " >&6
5622 else
5623
5624 echo '
5625 #include <netinet/in.h>
5626
5627 int test() {
5628         struct in6_pktinfo inf;
5629         int a = (int)sizeof(inf);
5630         return a;
5631 }
5632 ' > conftest.c
5633 echo 'void f(){}' >>conftest.c
5634 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5635 eval "cv_prog_cc_flag_needed_$cache=no"
5636 else
5637
5638 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5639 eval "cv_prog_cc_flag_needed_$cache=yes"
5640 else
5641 eval "cv_prog_cc_flag_needed_$cache=fail"
5642 #echo 'Test with flag fails too!'
5643 #cat conftest.c
5644 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5645 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5646 #exit 1
5647 fi
5648
5649 fi
5650 rm -f conftest conftest.c conftest.o
5651
5652 fi
5653
5654 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5656 $as_echo "yes" >&6; }
5657 :
5658 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5659 else
5660 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5662 $as_echo "no" >&6; }
5663 #echo 'Test with flag is no!'
5664 #cat conftest.c
5665 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5666 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5667 #exit 1
5668 :
5669
5670 else
5671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5672 $as_echo "failed" >&6; }
5673 :
5674
5675 fi
5676 fi
5677
5678
5679 # check again for GNU_SOURCE for setresgid. May fail if setresgid
5680 # is not available at all. -D_FRSRESGID is to make this check unique.
5681 # otherwise we would get the previous cached result.
5682
5683
5684
5685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC" >&5
5686 $as_echo_n "checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC... " >&6; }
5687 cache=_D_GNU_SOURCE__D_FRSRESGID
5688 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5689   $as_echo_n "(cached) " >&6
5690 else
5691
5692 echo '
5693 #include <unistd.h>
5694
5695 int test() {
5696         int a = setresgid(0,0,0);
5697         a = setresuid(0,0,0);
5698         return a;
5699 }
5700 ' > conftest.c
5701 echo 'void f(){}' >>conftest.c
5702 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5703 eval "cv_prog_cc_flag_needed_$cache=no"
5704 else
5705
5706 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`"; then
5707 eval "cv_prog_cc_flag_needed_$cache=yes"
5708 else
5709 eval "cv_prog_cc_flag_needed_$cache=fail"
5710 #echo 'Test with flag fails too!'
5711 #cat conftest.c
5712 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5713 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5714 #exit 1
5715 fi
5716
5717 fi
5718 rm -f conftest conftest.c conftest.o
5719
5720 fi
5721
5722 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5724 $as_echo "yes" >&6; }
5725 :
5726 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5727 else
5728 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5730 $as_echo "no" >&6; }
5731 #echo 'Test with flag is no!'
5732 #cat conftest.c
5733 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5734 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5735 #exit 1
5736 :
5737
5738 else
5739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5740 $as_echo "failed" >&6; }
5741 :
5742
5743 fi
5744 fi
5745
5746
5747
5748
5749
5750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC" >&5
5751 $as_echo_n "checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC... " >&6; }
5752 cache=_D_POSIX_C_SOURCE_200112
5753 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5754   $as_echo_n "(cached) " >&6
5755 else
5756
5757 echo '
5758 #include "confdefs.h"
5759 #ifdef HAVE_TIME_H
5760 #include <time.h>
5761 #endif
5762 #include <netdb.h>
5763
5764 int test() {
5765         int a = 0;
5766         char *t;
5767         time_t time = 0;
5768         char *buf = NULL;
5769         const char* str = NULL;
5770         t = ctime_r(&time, buf);
5771         str = gai_strerror(0);
5772         if(t && str)
5773                 a = 0;
5774         return a;
5775 }
5776 ' > conftest.c
5777 echo 'void f(){}' >>conftest.c
5778 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5779 eval "cv_prog_cc_flag_needed_$cache=no"
5780 else
5781
5782 if test -z "`$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`"; then
5783 eval "cv_prog_cc_flag_needed_$cache=yes"
5784 else
5785 eval "cv_prog_cc_flag_needed_$cache=fail"
5786 #echo 'Test with flag fails too!'
5787 #cat conftest.c
5788 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5789 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5790 #exit 1
5791 fi
5792
5793 fi
5794 rm -f conftest conftest.c conftest.o
5795
5796 fi
5797
5798 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5800 $as_echo "yes" >&6; }
5801 :
5802 CFLAGS="$CFLAGS -D_POSIX_C_SOURCE=200112"
5803 else
5804 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5806 $as_echo "no" >&6; }
5807 #echo 'Test with flag is no!'
5808 #cat conftest.c
5809 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5810 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5811 #exit 1
5812 :
5813
5814 else
5815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5816 $as_echo "failed" >&6; }
5817 :
5818
5819 fi
5820 fi
5821
5822
5823
5824
5825
5826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D__EXTENSIONS__ as a flag for $CC" >&5
5827 $as_echo_n "checking whether we need -D__EXTENSIONS__ as a flag for $CC... " >&6; }
5828 cache=_D__EXTENSIONS__
5829 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5830   $as_echo_n "(cached) " >&6
5831 else
5832
5833 echo '
5834 #include "confdefs.h"
5835 #include <stdlib.h>
5836 #include <ctype.h>
5837 #include <sys/time.h>
5838 #ifdef HAVE_TIME_H
5839 #include <time.h>
5840 #endif
5841 #include <unistd.h>
5842 #ifdef HAVE_GETOPT_H
5843 #include <getopt.h>
5844 #endif
5845
5846 int test() {
5847         int a;
5848         char **opts = NULL;
5849         struct timeval tv;
5850         tv.tv_usec = 10;
5851         srandom(32);
5852         a = getopt(2, opts, "a");
5853         a = isascii(32);
5854         if(tv.tv_usec)
5855                 a = 0;
5856         return a;
5857 }
5858 ' > conftest.c
5859 echo 'void f(){}' >>conftest.c
5860 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5861 eval "cv_prog_cc_flag_needed_$cache=no"
5862 else
5863
5864 if test -z "`$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`"; then
5865 eval "cv_prog_cc_flag_needed_$cache=yes"
5866 else
5867 eval "cv_prog_cc_flag_needed_$cache=fail"
5868 #echo 'Test with flag fails too!'
5869 #cat conftest.c
5870 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5871 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5872 #exit 1
5873 fi
5874
5875 fi
5876 rm -f conftest conftest.c conftest.o
5877
5878 fi
5879
5880 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5882 $as_echo "yes" >&6; }
5883 :
5884 CFLAGS="$CFLAGS -D__EXTENSIONS__"
5885 else
5886 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5888 $as_echo "no" >&6; }
5889 #echo 'Test with flag is no!'
5890 #cat conftest.c
5891 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5892 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5893 #exit 1
5894 :
5895
5896 else
5897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5898 $as_echo "failed" >&6; }
5899 :
5900
5901 fi
5902 fi
5903
5904
5905
5906
5907 # debug mode flags warnings
5908 # Check whether --enable-checking was given.
5909 if test "${enable_checking+set}" = set; then :
5910   enableval=$enable_checking;
5911 fi
5912
5913 # Check whether --enable-debug was given.
5914 if test "${enable_debug+set}" = set; then :
5915   enableval=$enable_debug;
5916 fi
5917
5918 if test "$enable_debug" = "yes"; then debug_enabled="$enable_debug";
5919 else debug_enabled="$enable_checking"; fi
5920
5921 case "$debug_enabled" in
5922         yes)
5923
5924
5925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -W" >&5
5926 $as_echo_n "checking whether $CC supports -W... " >&6; }
5927 cache=`echo W | sed 'y%.=/+-%___p_%'`
5928 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5929   $as_echo_n "(cached) " >&6
5930 else
5931
5932 echo 'void f(void){}' >conftest.c
5933 if test -z "`$CC $CPPFLAGS $CFLAGS -W -c conftest.c 2>&1`"; then
5934 eval "cv_prog_cc_flag_$cache=yes"
5935 else
5936 eval "cv_prog_cc_flag_$cache=no"
5937 fi
5938 rm -f conftest conftest.o conftest.c
5939
5940 fi
5941
5942 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5944 $as_echo "yes" >&6; }
5945 :
5946 CFLAGS="$CFLAGS -W"
5947 else
5948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5949 $as_echo "no" >&6; }
5950 :
5951
5952 fi
5953
5954
5955
5956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5957 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5958 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5959 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5960   $as_echo_n "(cached) " >&6
5961 else
5962
5963 echo 'void f(void){}' >conftest.c
5964 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5965 eval "cv_prog_cc_flag_$cache=yes"
5966 else
5967 eval "cv_prog_cc_flag_$cache=no"
5968 fi
5969 rm -f conftest conftest.o conftest.c
5970
5971 fi
5972
5973 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5975 $as_echo "yes" >&6; }
5976 :
5977 CFLAGS="$CFLAGS -Wall"
5978 else
5979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5980 $as_echo "no" >&6; }
5981 :
5982
5983 fi
5984
5985
5986
5987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wextra" >&5
5988 $as_echo_n "checking whether $CC supports -Wextra... " >&6; }
5989 cache=`echo Wextra | sed 'y%.=/+-%___p_%'`
5990 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5991   $as_echo_n "(cached) " >&6
5992 else
5993
5994 echo 'void f(void){}' >conftest.c
5995 if test -z "`$CC $CPPFLAGS $CFLAGS -Wextra -c conftest.c 2>&1`"; then
5996 eval "cv_prog_cc_flag_$cache=yes"
5997 else
5998 eval "cv_prog_cc_flag_$cache=no"
5999 fi
6000 rm -f conftest conftest.o conftest.c
6001
6002 fi
6003
6004 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
6005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6006 $as_echo "yes" >&6; }
6007 :
6008 CFLAGS="$CFLAGS -Wextra"
6009 else
6010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6011 $as_echo "no" >&6; }
6012 :
6013
6014 fi
6015
6016
6017
6018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wdeclaration-after-statement" >&5
6019 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
6020 cache=`echo Wdeclaration-after-statement | sed 'y%.=/+-%___p_%'`
6021 if eval \${cv_prog_cc_flag_$cache+:} false; then :
6022   $as_echo_n "(cached) " >&6
6023 else
6024
6025 echo 'void f(void){}' >conftest.c
6026 if test -z "`$CC $CPPFLAGS $CFLAGS -Wdeclaration-after-statement -c conftest.c 2>&1`"; then
6027 eval "cv_prog_cc_flag_$cache=yes"
6028 else
6029 eval "cv_prog_cc_flag_$cache=no"
6030 fi
6031 rm -f conftest conftest.o conftest.c
6032
6033 fi
6034
6035 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
6036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6037 $as_echo "yes" >&6; }
6038 :
6039 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
6040 else
6041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6042 $as_echo "no" >&6; }
6043 :
6044
6045 fi
6046
6047
6048 $as_echo "#define UNBOUND_DEBUG /**/" >>confdefs.h
6049
6050                 ;;
6051         no|*)
6052                 # nothing to do.
6053                 ;;
6054 esac
6055 if test "$default_cflags" = "yes"; then
6056         # only when CFLAGS was "" at the start, if the users wants to
6057         # override we shouldn't add default cflags, because they wouldn't
6058         # be able to turn off these options and set the CFLAGS wanted.
6059
6060     # Check whether --enable-flto was given.
6061 if test "${enable_flto+set}" = set; then :
6062   enableval=$enable_flto;
6063 fi
6064
6065     if test "x$enable_flto" != "xno"; then :
6066
6067         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -flto" >&5
6068 $as_echo_n "checking if $CC supports -flto... " >&6; }
6069         BAKCFLAGS="$CFLAGS"
6070         CFLAGS="$CFLAGS -flto"
6071         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6072 /* end confdefs.h.  */
6073
6074 int
6075 main ()
6076 {
6077
6078   ;
6079   return 0;
6080 }
6081 _ACEOF
6082 if ac_fn_c_try_link "$LINENO"; then :
6083
6084             if $CC $CFLAGS -o conftest conftest.c 2>&1 | $GREP -e "warning: no debug symbols in executable" -e "warning: object" >/dev/null; then
6085                 CFLAGS="$BAKCFLAGS"
6086                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6087 $as_echo "no" >&6; }
6088             else
6089                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6090 $as_echo "yes" >&6; }
6091             fi
6092             rm -f conftest conftest.c conftest.o
6093
6094 else
6095   CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6096 $as_echo "no" >&6; }
6097 fi
6098 rm -f core conftest.err conftest.$ac_objext \
6099     conftest$ac_exeext conftest.$ac_ext
6100
6101 fi
6102
6103
6104     # Check whether --enable-pie was given.
6105 if test "${enable_pie+set}" = set; then :
6106   enableval=$enable_pie;
6107 fi
6108
6109     if test "x$enable_pie" = "xyes"; then :
6110
6111         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports PIE" >&5
6112 $as_echo_n "checking if $CC supports PIE... " >&6; }
6113         BAKLDFLAGS="$LDFLAGS"
6114         BAKCFLAGS="$CFLAGS"
6115         LDFLAGS="$LDFLAGS -pie"
6116         CFLAGS="$CFLAGS -fPIE"
6117         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6118 /* end confdefs.h.  */
6119
6120 int
6121 main ()
6122 {
6123
6124   ;
6125   return 0;
6126 }
6127 _ACEOF
6128 if ac_fn_c_try_link "$LINENO"; then :
6129
6130             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6131                 LDFLAGS="$BAKLDFLAGS"
6132                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6133 $as_echo "no" >&6; }
6134             else
6135                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6136 $as_echo "yes" >&6; }
6137             fi
6138             rm -f conftest conftest.c conftest.o
6139
6140 else
6141   LDFLAGS="$BAKLDFLAGS" ; CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6142 $as_echo "no" >&6; }
6143 fi
6144 rm -f core conftest.err conftest.$ac_objext \
6145     conftest$ac_exeext conftest.$ac_ext
6146
6147 fi
6148
6149
6150     # Check whether --enable-relro_now was given.
6151 if test "${enable_relro_now+set}" = set; then :
6152   enableval=$enable_relro_now;
6153 fi
6154
6155     if test "x$enable_relro_now" = "xyes"; then :
6156
6157         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wl,-z,relro,-z,now" >&5
6158 $as_echo_n "checking if $CC supports -Wl,-z,relro,-z,now... " >&6; }
6159         BAKLDFLAGS="$LDFLAGS"
6160         LDFLAGS="$LDFLAGS -Wl,-z,relro,-z,now"
6161         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6162 /* end confdefs.h.  */
6163
6164 int
6165 main ()
6166 {
6167
6168   ;
6169   return 0;
6170 }
6171 _ACEOF
6172 if ac_fn_c_try_link "$LINENO"; then :
6173
6174             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6175                 LDFLAGS="$BAKLDFLAGS"
6176                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6177 $as_echo "no" >&6; }
6178             else
6179                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6180 $as_echo "yes" >&6; }
6181             fi
6182             rm -f conftest conftest.c conftest.o
6183
6184 else
6185   LDFLAGS="$BAKLDFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6186 $as_echo "no" >&6; }
6187 fi
6188 rm -f core conftest.err conftest.$ac_objext \
6189     conftest$ac_exeext conftest.$ac_ext
6190
6191 fi
6192
6193 fi
6194
6195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
6196 $as_echo_n "checking for inline... " >&6; }
6197 if ${ac_cv_c_inline+:} false; then :
6198   $as_echo_n "(cached) " >&6
6199 else
6200   ac_cv_c_inline=no
6201 for ac_kw in inline __inline__ __inline; do
6202   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6203 /* end confdefs.h.  */
6204 #ifndef __cplusplus
6205 typedef int foo_t;
6206 static $ac_kw foo_t static_foo () {return 0; }
6207 $ac_kw foo_t foo () {return 0; }
6208 #endif
6209
6210 _ACEOF
6211 if ac_fn_c_try_compile "$LINENO"; then :
6212   ac_cv_c_inline=$ac_kw
6213 fi
6214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6215   test "$ac_cv_c_inline" != no && break
6216 done
6217
6218 fi
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
6220 $as_echo "$ac_cv_c_inline" >&6; }
6221
6222 case $ac_cv_c_inline in
6223   inline | yes) ;;
6224   *)
6225     case $ac_cv_c_inline in
6226       no) ac_val=;;
6227       *) ac_val=$ac_cv_c_inline;;
6228     esac
6229     cat >>confdefs.h <<_ACEOF
6230 #ifndef __cplusplus
6231 #define inline $ac_val
6232 #endif
6233 _ACEOF
6234     ;;
6235 esac
6236
6237
6238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute" >&5
6239 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute... " >&6; }
6240 if ${ac_cv_c_format_attribute+:} false; then :
6241   $as_echo_n "(cached) " >&6
6242 else
6243   ac_cv_c_format_attribute=no
6244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6245 /* end confdefs.h.  */
6246 #include <stdio.h>
6247 void f (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6248 void (*pf) (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6249
6250 int
6251 main ()
6252 {
6253
6254    f ("%s", "str");
6255
6256   ;
6257   return 0;
6258 }
6259 _ACEOF
6260 if ac_fn_c_try_compile "$LINENO"; then :
6261   ac_cv_c_format_attribute="yes"
6262 else
6263   ac_cv_c_format_attribute="no"
6264 fi
6265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6266
6267 fi
6268
6269
6270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_format_attribute" >&5
6271 $as_echo "$ac_cv_c_format_attribute" >&6; }
6272 if test $ac_cv_c_format_attribute = yes; then
6273
6274 $as_echo "#define HAVE_ATTR_FORMAT 1" >>confdefs.h
6275
6276 fi
6277
6278
6279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute" >&5
6280 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute... " >&6; }
6281 if ${ac_cv_c_unused_attribute+:} false; then :
6282   $as_echo_n "(cached) " >&6
6283 else
6284   ac_cv_c_unused_attribute=no
6285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6286 /* end confdefs.h.  */
6287 #include <stdio.h>
6288 void f (char *u __attribute__((unused)));
6289
6290 int
6291 main ()
6292 {
6293
6294    f ("x");
6295
6296   ;
6297   return 0;
6298 }
6299 _ACEOF
6300 if ac_fn_c_try_compile "$LINENO"; then :
6301   ac_cv_c_unused_attribute="yes"
6302 else
6303   ac_cv_c_unused_attribute="no"
6304 fi
6305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6306
6307 fi
6308
6309
6310
6311
6312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_unused_attribute" >&5
6313 $as_echo "$ac_cv_c_unused_attribute" >&6; }
6314 if test $ac_cv_c_unused_attribute = yes; then
6315
6316 $as_echo "#define HAVE_ATTR_UNUSED 1" >>confdefs.h
6317
6318 fi
6319
6320
6321
6322
6323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute" >&5
6324 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute... " >&6; }
6325 if ${ac_cv_c_weak_attribute+:} false; then :
6326   $as_echo_n "(cached) " >&6
6327 else
6328   ac_cv_c_weak_attribute=no
6329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6330 /* end confdefs.h.  */
6331  #include <stdio.h>
6332 __attribute__((weak)) void f(int x) { printf("%d", x); }
6333
6334 int
6335 main ()
6336 {
6337
6338    f(1);
6339
6340   ;
6341   return 0;
6342 }
6343 _ACEOF
6344 if ac_fn_c_try_compile "$LINENO"; then :
6345   ac_cv_c_weak_attribute="yes"
6346 else
6347   ac_cv_c_weak_attribute="no"
6348 fi
6349 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6350
6351 fi
6352
6353
6354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_weak_attribute" >&5
6355 $as_echo "$ac_cv_c_weak_attribute" >&6; }
6356 if test $ac_cv_c_weak_attribute = yes; then
6357
6358 $as_echo "#define HAVE_ATTR_WEAK 1" >>confdefs.h
6359
6360
6361 $as_echo "#define ATTR_WEAK __attribute__((weak))" >>confdefs.h
6362
6363 fi
6364
6365
6366
6367
6368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute" >&5
6369 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute... " >&6; }
6370 if ${ac_cv_c_noreturn_attribute+:} false; then :
6371   $as_echo_n "(cached) " >&6
6372 else
6373   ac_cv_c_noreturn_attribute=no
6374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6375 /* end confdefs.h.  */
6376  #include <stdio.h>
6377 __attribute__((noreturn)) void f(int x) { printf("%d", x); }
6378
6379 int
6380 main ()
6381 {
6382
6383    f(1);
6384
6385   ;
6386   return 0;
6387 }
6388 _ACEOF
6389 if ac_fn_c_try_compile "$LINENO"; then :
6390   ac_cv_c_noreturn_attribute="yes"
6391 else
6392   ac_cv_c_noreturn_attribute="no"
6393 fi
6394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6395
6396 fi
6397
6398
6399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_noreturn_attribute" >&5
6400 $as_echo "$ac_cv_c_noreturn_attribute" >&6; }
6401 if test $ac_cv_c_noreturn_attribute = yes; then
6402
6403 $as_echo "#define HAVE_ATTR_NORETURN 1" >>confdefs.h
6404
6405
6406 $as_echo "#define ATTR_NORETURN __attribute__((__noreturn__))" >>confdefs.h
6407
6408 fi
6409
6410
6411 if test "$srcdir" != "."; then
6412         CPPFLAGS="$CPPFLAGS -I$srcdir"
6413 fi
6414
6415
6416
6417
6418
6419 for ac_prog in flex lex
6420 do
6421   # Extract the first word of "$ac_prog", so it can be a program name with args.
6422 set dummy $ac_prog; ac_word=$2
6423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6424 $as_echo_n "checking for $ac_word... " >&6; }
6425 if ${ac_cv_prog_LEX+:} false; then :
6426   $as_echo_n "(cached) " >&6
6427 else
6428   if test -n "$LEX"; then
6429   ac_cv_prog_LEX="$LEX" # Let the user override the test.
6430 else
6431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6432 for as_dir in $PATH
6433 do
6434   IFS=$as_save_IFS
6435   test -z "$as_dir" && as_dir=.
6436     for ac_exec_ext in '' $ac_executable_extensions; do
6437   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6438     ac_cv_prog_LEX="$ac_prog"
6439     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6440     break 2
6441   fi
6442 done
6443   done
6444 IFS=$as_save_IFS
6445
6446 fi
6447 fi
6448 LEX=$ac_cv_prog_LEX
6449 if test -n "$LEX"; then
6450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
6451 $as_echo "$LEX" >&6; }
6452 else
6453   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6454 $as_echo "no" >&6; }
6455 fi
6456
6457
6458   test -n "$LEX" && break
6459 done
6460 test -n "$LEX" || LEX=":"
6461
6462 if test "x$LEX" != "x:"; then
6463   cat >conftest.l <<_ACEOF
6464 %%
6465 a { ECHO; }
6466 b { REJECT; }
6467 c { yymore (); }
6468 d { yyless (1); }
6469 e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument.  */
6470     yyless ((input () != 0)); }
6471 f { unput (yytext[0]); }
6472 . { BEGIN INITIAL; }
6473 %%
6474 #ifdef YYTEXT_POINTER
6475 extern char *yytext;
6476 #endif
6477 int
6478 main (void)
6479 {
6480   return ! yylex () + ! yywrap ();
6481 }
6482 _ACEOF
6483 { { ac_try="$LEX conftest.l"
6484 case "(($ac_try" in
6485   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6486   *) ac_try_echo=$ac_try;;
6487 esac
6488 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6489 $as_echo "$ac_try_echo"; } >&5
6490   (eval "$LEX conftest.l") 2>&5
6491   ac_status=$?
6492   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6493   test $ac_status = 0; }
6494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
6495 $as_echo_n "checking lex output file root... " >&6; }
6496 if ${ac_cv_prog_lex_root+:} false; then :
6497   $as_echo_n "(cached) " >&6
6498 else
6499
6500 if test -f lex.yy.c; then
6501   ac_cv_prog_lex_root=lex.yy
6502 elif test -f lexyy.c; then
6503   ac_cv_prog_lex_root=lexyy
6504 else
6505   as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
6506 fi
6507 fi
6508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
6509 $as_echo "$ac_cv_prog_lex_root" >&6; }
6510 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
6511
6512 if test -z "${LEXLIB+set}"; then
6513   { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
6514 $as_echo_n "checking lex library... " >&6; }
6515 if ${ac_cv_lib_lex+:} false; then :
6516   $as_echo_n "(cached) " >&6
6517 else
6518
6519     ac_save_LIBS=$LIBS
6520     ac_cv_lib_lex='none needed'
6521     for ac_lib in '' -lfl -ll; do
6522       LIBS="$ac_lib $ac_save_LIBS"
6523       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6524 /* end confdefs.h.  */
6525 `cat $LEX_OUTPUT_ROOT.c`
6526 _ACEOF
6527 if ac_fn_c_try_link "$LINENO"; then :
6528   ac_cv_lib_lex=$ac_lib
6529 fi
6530 rm -f core conftest.err conftest.$ac_objext \
6531     conftest$ac_exeext conftest.$ac_ext
6532       test "$ac_cv_lib_lex" != 'none needed' && break
6533     done
6534     LIBS=$ac_save_LIBS
6535
6536 fi
6537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
6538 $as_echo "$ac_cv_lib_lex" >&6; }
6539   test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
6540 fi
6541
6542
6543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
6544 $as_echo_n "checking whether yytext is a pointer... " >&6; }
6545 if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
6546   $as_echo_n "(cached) " >&6
6547 else
6548   # POSIX says lex can declare yytext either as a pointer or an array; the
6549 # default is implementation-dependent.  Figure out which it is, since
6550 # not all implementations provide the %pointer and %array declarations.
6551 ac_cv_prog_lex_yytext_pointer=no
6552 ac_save_LIBS=$LIBS
6553 LIBS="$LEXLIB $ac_save_LIBS"
6554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6555 /* end confdefs.h.  */
6556
6557   #define YYTEXT_POINTER 1
6558 `cat $LEX_OUTPUT_ROOT.c`
6559 _ACEOF
6560 if ac_fn_c_try_link "$LINENO"; then :
6561   ac_cv_prog_lex_yytext_pointer=yes
6562 fi
6563 rm -f core conftest.err conftest.$ac_objext \
6564     conftest$ac_exeext conftest.$ac_ext
6565 LIBS=$ac_save_LIBS
6566
6567 fi
6568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
6569 $as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
6570 if test $ac_cv_prog_lex_yytext_pointer = yes; then
6571
6572 $as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
6573
6574 fi
6575 rm -f conftest.l $LEX_OUTPUT_ROOT.c
6576
6577 fi
6578 if test "$LEX" != "" -a "$LEX" != ":"; then
6579
6580         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yylex_destroy" >&5
6581 $as_echo_n "checking for yylex_destroy... " >&6; }
6582         if echo %% | $LEX -t 2>&1 | grep yylex_destroy >/dev/null 2>&1; then
6583
6584 $as_echo "#define LEX_HAS_YYLEX_DESTROY 1" >>confdefs.h
6585
6586                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6587 $as_echo "yes" >&6; }
6588         else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6589 $as_echo "no" >&6; };
6590                 LEX=":"
6591         fi
6592
6593 fi
6594 if test "$LEX" != "" -a "$LEX" != ":"; then
6595
6596         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lex %option" >&5
6597 $as_echo_n "checking for lex %option... " >&6; }
6598         if cat <<EOF | $LEX -t 2>&1 | grep yy_delete_buffer >/dev/null 2>&1; then
6599 %option nounput
6600 %%
6601 EOF
6602                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6603 $as_echo "yes" >&6; }
6604         else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6605 $as_echo "no" >&6; };
6606                 LEX=":"
6607         fi
6608
6609 fi
6610 for ac_prog in 'bison -y' byacc
6611 do
6612   # Extract the first word of "$ac_prog", so it can be a program name with args.
6613 set dummy $ac_prog; ac_word=$2
6614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6615 $as_echo_n "checking for $ac_word... " >&6; }
6616 if ${ac_cv_prog_YACC+:} false; then :
6617   $as_echo_n "(cached) " >&6
6618 else
6619   if test -n "$YACC"; then
6620   ac_cv_prog_YACC="$YACC" # Let the user override the test.
6621 else
6622 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6623 for as_dir in $PATH
6624 do
6625   IFS=$as_save_IFS
6626   test -z "$as_dir" && as_dir=.
6627     for ac_exec_ext in '' $ac_executable_extensions; do
6628   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6629     ac_cv_prog_YACC="$ac_prog"
6630     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6631     break 2
6632   fi
6633 done
6634   done
6635 IFS=$as_save_IFS
6636
6637 fi
6638 fi
6639 YACC=$ac_cv_prog_YACC
6640 if test -n "$YACC"; then
6641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6642 $as_echo "$YACC" >&6; }
6643 else
6644   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6645 $as_echo "no" >&6; }
6646 fi
6647
6648
6649   test -n "$YACC" && break
6650 done
6651 test -n "$YACC" || YACC="yacc"
6652
6653 # Extract the first word of "doxygen", so it can be a program name with args.
6654 set dummy doxygen; ac_word=$2
6655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6656 $as_echo_n "checking for $ac_word... " >&6; }
6657 if ${ac_cv_prog_doxygen+:} false; then :
6658   $as_echo_n "(cached) " >&6
6659 else
6660   if test -n "$doxygen"; then
6661   ac_cv_prog_doxygen="$doxygen" # Let the user override the test.
6662 else
6663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6664 for as_dir in $PATH
6665 do
6666   IFS=$as_save_IFS
6667   test -z "$as_dir" && as_dir=.
6668     for ac_exec_ext in '' $ac_executable_extensions; do
6669   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6670     ac_cv_prog_doxygen="doxygen"
6671     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6672     break 2
6673   fi
6674 done
6675   done
6676 IFS=$as_save_IFS
6677
6678 fi
6679 fi
6680 doxygen=$ac_cv_prog_doxygen
6681 if test -n "$doxygen"; then
6682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $doxygen" >&5
6683 $as_echo "$doxygen" >&6; }
6684 else
6685   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6686 $as_echo "no" >&6; }
6687 fi
6688
6689
6690 if test -n "$ac_tool_prefix"; then
6691   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6692 set dummy ${ac_tool_prefix}strip; ac_word=$2
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6694 $as_echo_n "checking for $ac_word... " >&6; }
6695 if ${ac_cv_prog_STRIP+:} false; then :
6696   $as_echo_n "(cached) " >&6
6697 else
6698   if test -n "$STRIP"; then
6699   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6700 else
6701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6702 for as_dir in $PATH
6703 do
6704   IFS=$as_save_IFS
6705   test -z "$as_dir" && as_dir=.
6706     for ac_exec_ext in '' $ac_executable_extensions; do
6707   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6708     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6709     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6710     break 2
6711   fi
6712 done
6713   done
6714 IFS=$as_save_IFS
6715
6716 fi
6717 fi
6718 STRIP=$ac_cv_prog_STRIP
6719 if test -n "$STRIP"; then
6720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6721 $as_echo "$STRIP" >&6; }
6722 else
6723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6724 $as_echo "no" >&6; }
6725 fi
6726
6727
6728 fi
6729 if test -z "$ac_cv_prog_STRIP"; then
6730   ac_ct_STRIP=$STRIP
6731   # Extract the first word of "strip", so it can be a program name with args.
6732 set dummy strip; ac_word=$2
6733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6734 $as_echo_n "checking for $ac_word... " >&6; }
6735 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6736   $as_echo_n "(cached) " >&6
6737 else
6738   if test -n "$ac_ct_STRIP"; then
6739   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6740 else
6741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6742 for as_dir in $PATH
6743 do
6744   IFS=$as_save_IFS
6745   test -z "$as_dir" && as_dir=.
6746     for ac_exec_ext in '' $ac_executable_extensions; do
6747   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6748     ac_cv_prog_ac_ct_STRIP="strip"
6749     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6750     break 2
6751   fi
6752 done
6753   done
6754 IFS=$as_save_IFS
6755
6756 fi
6757 fi
6758 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6759 if test -n "$ac_ct_STRIP"; then
6760   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6761 $as_echo "$ac_ct_STRIP" >&6; }
6762 else
6763   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6764 $as_echo "no" >&6; }
6765 fi
6766
6767   if test "x$ac_ct_STRIP" = x; then
6768     STRIP=""
6769   else
6770     case $cross_compiling:$ac_tool_warned in
6771 yes:)
6772 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6773 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6774 ac_tool_warned=yes ;;
6775 esac
6776     STRIP=$ac_ct_STRIP
6777   fi
6778 else
6779   STRIP="$ac_cv_prog_STRIP"
6780 fi
6781
6782 ac_aux_dir=
6783 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
6784   if test -f "$ac_dir/install-sh"; then
6785     ac_aux_dir=$ac_dir
6786     ac_install_sh="$ac_aux_dir/install-sh -c"
6787     break
6788   elif test -f "$ac_dir/install.sh"; then
6789     ac_aux_dir=$ac_dir
6790     ac_install_sh="$ac_aux_dir/install.sh -c"
6791     break
6792   elif test -f "$ac_dir/shtool"; then
6793     ac_aux_dir=$ac_dir
6794     ac_install_sh="$ac_aux_dir/shtool install -c"
6795     break
6796   fi
6797 done
6798 if test -z "$ac_aux_dir"; then
6799   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
6800 fi
6801
6802 # These three variables are undocumented and unsupported,
6803 # and are intended to be withdrawn in a future Autoconf release.
6804 # They can cause serious problems if a builder's source tree is in a directory
6805 # whose full name contains unusual characters.
6806 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
6807 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
6808 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
6809
6810
6811 # Make sure we can run config.sub.
6812 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
6813   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
6814
6815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
6816 $as_echo_n "checking build system type... " >&6; }
6817 if ${ac_cv_build+:} false; then :
6818   $as_echo_n "(cached) " >&6
6819 else
6820   ac_build_alias=$build_alias
6821 test "x$ac_build_alias" = x &&
6822   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
6823 test "x$ac_build_alias" = x &&
6824   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
6825 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
6826   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
6827
6828 fi
6829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
6830 $as_echo "$ac_cv_build" >&6; }
6831 case $ac_cv_build in
6832 *-*-*) ;;
6833 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
6834 esac
6835 build=$ac_cv_build
6836 ac_save_IFS=$IFS; IFS='-'
6837 set x $ac_cv_build
6838 shift
6839 build_cpu=$1
6840 build_vendor=$2
6841 shift; shift
6842 # Remember, the first character of IFS is used to create $*,
6843 # except with old shells:
6844 build_os=$*
6845 IFS=$ac_save_IFS
6846 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
6847
6848
6849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
6850 $as_echo_n "checking host system type... " >&6; }
6851 if ${ac_cv_host+:} false; then :
6852   $as_echo_n "(cached) " >&6
6853 else
6854   if test "x$host_alias" = x; then
6855   ac_cv_host=$ac_cv_build
6856 else
6857   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
6858     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
6859 fi
6860
6861 fi
6862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
6863 $as_echo "$ac_cv_host" >&6; }
6864 case $ac_cv_host in
6865 *-*-*) ;;
6866 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
6867 esac
6868 host=$ac_cv_host
6869 ac_save_IFS=$IFS; IFS='-'
6870 set x $ac_cv_host
6871 shift
6872 host_cpu=$1
6873 host_vendor=$2
6874 shift; shift
6875 # Remember, the first character of IFS is used to create $*,
6876 # except with old shells:
6877 host_os=$*
6878 IFS=$ac_save_IFS
6879 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
6880
6881
6882
6883 # skip these tests, we do not need them.
6884
6885
6886
6887
6888
6889
6890
6891
6892 # always use ./libtool unless override from commandline (libtool=mylibtool)
6893 if test -z "$libtool"; then
6894         libtool="./libtool"
6895 fi
6896
6897 # avoid libtool max commandline length test on systems that fork slowly.
6898
6899 if echo "$host_os" | grep "sunos4" >/dev/null; then
6900         lt_cv_sys_max_cmd_len=32750;
6901 fi
6902 if test -n "$ac_tool_prefix"; then
6903   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6904 set dummy ${ac_tool_prefix}ar; ac_word=$2
6905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6906 $as_echo_n "checking for $ac_word... " >&6; }
6907 if ${ac_cv_path_AR+:} false; then :
6908   $as_echo_n "(cached) " >&6
6909 else
6910   case $AR in
6911   [\\/]* | ?:[\\/]*)
6912   ac_cv_path_AR="$AR" # Let the user override the test with a path.
6913   ;;
6914   *)
6915   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6916 for as_dir in $PATH
6917 do
6918   IFS=$as_save_IFS
6919   test -z "$as_dir" && as_dir=.
6920     for ac_exec_ext in '' $ac_executable_extensions; do
6921   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6922     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
6923     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6924     break 2
6925   fi
6926 done
6927   done
6928 IFS=$as_save_IFS
6929
6930   ;;
6931 esac
6932 fi
6933 AR=$ac_cv_path_AR
6934 if test -n "$AR"; then
6935   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6936 $as_echo "$AR" >&6; }
6937 else
6938   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6939 $as_echo "no" >&6; }
6940 fi
6941
6942
6943 fi
6944 if test -z "$ac_cv_path_AR"; then
6945   ac_pt_AR=$AR
6946   # Extract the first word of "ar", so it can be a program name with args.
6947 set dummy ar; ac_word=$2
6948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6949 $as_echo_n "checking for $ac_word... " >&6; }
6950 if ${ac_cv_path_ac_pt_AR+:} false; then :
6951   $as_echo_n "(cached) " >&6
6952 else
6953   case $ac_pt_AR in
6954   [\\/]* | ?:[\\/]*)
6955   ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
6956   ;;
6957   *)
6958   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6959 for as_dir in $PATH
6960 do
6961   IFS=$as_save_IFS
6962   test -z "$as_dir" && as_dir=.
6963     for ac_exec_ext in '' $ac_executable_extensions; do
6964   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6965     ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
6966     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6967     break 2
6968   fi
6969 done
6970   done
6971 IFS=$as_save_IFS
6972
6973   ;;
6974 esac
6975 fi
6976 ac_pt_AR=$ac_cv_path_ac_pt_AR
6977 if test -n "$ac_pt_AR"; then
6978   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
6979 $as_echo "$ac_pt_AR" >&6; }
6980 else
6981   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6982 $as_echo "no" >&6; }
6983 fi
6984
6985   if test "x$ac_pt_AR" = x; then
6986     AR="false"
6987   else
6988     case $cross_compiling:$ac_tool_warned in
6989 yes:)
6990 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6991 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6992 ac_tool_warned=yes ;;
6993 esac
6994     AR=$ac_pt_AR
6995   fi
6996 else
6997   AR="$ac_cv_path_AR"
6998 fi
6999
7000 if test $AR = false; then
7001         as_fn_error $? "Cannot find 'ar', please extend PATH to include it" "$LINENO" 5
7002 fi
7003
7004 case `pwd` in
7005   *\ * | *\     *)
7006     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
7007 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
7008 esac
7009
7010
7011
7012 macro_version='2.4.6'
7013 macro_revision='2.4.6'
7014
7015
7016
7017
7018
7019
7020
7021
7022
7023
7024
7025
7026
7027 ltmain=$ac_aux_dir/ltmain.sh
7028
7029 # Backslashify metacharacters that are still active within
7030 # double-quoted strings.
7031 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7032
7033 # Same as above, but do not quote variable references.
7034 double_quote_subst='s/\(["`\\]\)/\\\1/g'
7035
7036 # Sed substitution to delay expansion of an escaped shell variable in a
7037 # double_quote_subst'ed string.
7038 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7039
7040 # Sed substitution to delay expansion of an escaped single quote.
7041 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7042
7043 # Sed substitution to avoid accidental globbing in evaled expressions
7044 no_glob_subst='s/\*/\\\*/g'
7045
7046 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7047 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7048 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7049
7050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7051 $as_echo_n "checking how to print strings... " >&6; }
7052 # Test print first, because it will be a builtin if present.
7053 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7054    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7055   ECHO='print -r --'
7056 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7057   ECHO='printf %s\n'
7058 else
7059   # Use this function as a fallback that always works.
7060   func_fallback_echo ()
7061   {
7062     eval 'cat <<_LTECHO_EOF
7063 $1
7064 _LTECHO_EOF'
7065   }
7066   ECHO='func_fallback_echo'
7067 fi
7068
7069 # func_echo_all arg...
7070 # Invoke $ECHO with all args, space-separated.
7071 func_echo_all ()
7072 {
7073     $ECHO ""
7074 }
7075
7076 case $ECHO in
7077   printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7078 $as_echo "printf" >&6; } ;;
7079   print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7080 $as_echo "print -r" >&6; } ;;
7081   *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7082 $as_echo "cat" >&6; } ;;
7083 esac
7084
7085
7086
7087
7088
7089
7090
7091
7092
7093
7094
7095
7096
7097
7098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7099 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7100 if ${ac_cv_path_SED+:} false; then :
7101   $as_echo_n "(cached) " >&6
7102 else
7103             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7104      for ac_i in 1 2 3 4 5 6 7; do
7105        ac_script="$ac_script$as_nl$ac_script"
7106      done
7107      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7108      { ac_script=; unset ac_script;}
7109      if test -z "$SED"; then
7110   ac_path_SED_found=false
7111   # Loop through the user's path and test for each of PROGNAME-LIST
7112   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7113 for as_dir in $PATH
7114 do
7115   IFS=$as_save_IFS
7116   test -z "$as_dir" && as_dir=.
7117     for ac_prog in sed gsed; do
7118     for ac_exec_ext in '' $ac_executable_extensions; do
7119       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7120       as_fn_executable_p "$ac_path_SED" || continue
7121 # Check for GNU ac_path_SED and select it if it is found.
7122   # Check for GNU $ac_path_SED
7123 case `"$ac_path_SED" --version 2>&1` in
7124 *GNU*)
7125   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7126 *)
7127   ac_count=0
7128   $as_echo_n 0123456789 >"conftest.in"
7129   while :
7130   do
7131     cat "conftest.in" "conftest.in" >"conftest.tmp"
7132     mv "conftest.tmp" "conftest.in"
7133     cp "conftest.in" "conftest.nl"
7134     $as_echo '' >> "conftest.nl"
7135     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7136     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7137     as_fn_arith $ac_count + 1 && ac_count=$as_val
7138     if test $ac_count -gt ${ac_path_SED_max-0}; then
7139       # Best one so far, save it but keep looking for a better one
7140       ac_cv_path_SED="$ac_path_SED"
7141       ac_path_SED_max=$ac_count
7142     fi
7143     # 10*(2^10) chars as input seems more than enough
7144     test $ac_count -gt 10 && break
7145   done
7146   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7147 esac
7148
7149       $ac_path_SED_found && break 3
7150     done
7151   done
7152   done
7153 IFS=$as_save_IFS
7154   if test -z "$ac_cv_path_SED"; then
7155     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7156   fi
7157 else
7158   ac_cv_path_SED=$SED
7159 fi
7160
7161 fi
7162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7163 $as_echo "$ac_cv_path_SED" >&6; }
7164  SED="$ac_cv_path_SED"
7165   rm -f conftest.sed
7166
7167 test -z "$SED" && SED=sed
7168 Xsed="$SED -e 1s/^X//"
7169
7170
7171
7172
7173
7174
7175
7176
7177
7178
7179
7180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7181 $as_echo_n "checking for fgrep... " >&6; }
7182 if ${ac_cv_path_FGREP+:} false; then :
7183   $as_echo_n "(cached) " >&6
7184 else
7185   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7186    then ac_cv_path_FGREP="$GREP -F"
7187    else
7188      if test -z "$FGREP"; then
7189   ac_path_FGREP_found=false
7190   # Loop through the user's path and test for each of PROGNAME-LIST
7191   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7192 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7193 do
7194   IFS=$as_save_IFS
7195   test -z "$as_dir" && as_dir=.
7196     for ac_prog in fgrep; do
7197     for ac_exec_ext in '' $ac_executable_extensions; do
7198       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7199       as_fn_executable_p "$ac_path_FGREP" || continue
7200 # Check for GNU ac_path_FGREP and select it if it is found.
7201   # Check for GNU $ac_path_FGREP
7202 case `"$ac_path_FGREP" --version 2>&1` in
7203 *GNU*)
7204   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7205 *)
7206   ac_count=0
7207   $as_echo_n 0123456789 >"conftest.in"
7208   while :
7209   do
7210     cat "conftest.in" "conftest.in" >"conftest.tmp"
7211     mv "conftest.tmp" "conftest.in"
7212     cp "conftest.in" "conftest.nl"
7213     $as_echo 'FGREP' >> "conftest.nl"
7214     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7215     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7216     as_fn_arith $ac_count + 1 && ac_count=$as_val
7217     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7218       # Best one so far, save it but keep looking for a better one
7219       ac_cv_path_FGREP="$ac_path_FGREP"
7220       ac_path_FGREP_max=$ac_count
7221     fi
7222     # 10*(2^10) chars as input seems more than enough
7223     test $ac_count -gt 10 && break
7224   done
7225   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7226 esac
7227
7228       $ac_path_FGREP_found && break 3
7229     done
7230   done
7231   done
7232 IFS=$as_save_IFS
7233   if test -z "$ac_cv_path_FGREP"; then
7234     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7235   fi
7236 else
7237   ac_cv_path_FGREP=$FGREP
7238 fi
7239
7240    fi
7241 fi
7242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7243 $as_echo "$ac_cv_path_FGREP" >&6; }
7244  FGREP="$ac_cv_path_FGREP"
7245
7246
7247 test -z "$GREP" && GREP=grep
7248
7249
7250
7251
7252
7253
7254
7255
7256
7257
7258
7259
7260
7261
7262
7263
7264
7265
7266
7267 # Check whether --with-gnu-ld was given.
7268 if test "${with_gnu_ld+set}" = set; then :
7269   withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7270 else
7271   with_gnu_ld=no
7272 fi
7273
7274 ac_prog=ld
7275 if test yes = "$GCC"; then
7276   # Check if gcc -print-prog-name=ld gives a path.
7277   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7278 $as_echo_n "checking for ld used by $CC... " >&6; }
7279   case $host in
7280   *-*-mingw*)
7281     # gcc leaves a trailing carriage return, which upsets mingw
7282     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7283   *)
7284     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7285   esac
7286   case $ac_prog in
7287     # Accept absolute paths.
7288     [\\/]* | ?:[\\/]*)
7289       re_direlt='/[^/][^/]*/\.\./'
7290       # Canonicalize the pathname of ld
7291       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7292       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7293         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7294       done
7295       test -z "$LD" && LD=$ac_prog
7296       ;;
7297   "")
7298     # If it fails, then pretend we aren't using GCC.
7299     ac_prog=ld
7300     ;;
7301   *)
7302     # If it is relative, then search for the first ld in PATH.
7303     with_gnu_ld=unknown
7304     ;;
7305   esac
7306 elif test yes = "$with_gnu_ld"; then
7307   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7308 $as_echo_n "checking for GNU ld... " >&6; }
7309 else
7310   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7311 $as_echo_n "checking for non-GNU ld... " >&6; }
7312 fi
7313 if ${lt_cv_path_LD+:} false; then :
7314   $as_echo_n "(cached) " >&6
7315 else
7316   if test -z "$LD"; then
7317   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7318   for ac_dir in $PATH; do
7319     IFS=$lt_save_ifs
7320     test -z "$ac_dir" && ac_dir=.
7321     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7322       lt_cv_path_LD=$ac_dir/$ac_prog
7323       # Check to see if the program is GNU ld.  I'd rather use --version,
7324       # but apparently some variants of GNU ld only accept -v.
7325       # Break only if it was the GNU/non-GNU ld that we prefer.
7326       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7327       *GNU* | *'with BFD'*)
7328         test no != "$with_gnu_ld" && break
7329         ;;
7330       *)
7331         test yes != "$with_gnu_ld" && break
7332         ;;
7333       esac
7334     fi
7335   done
7336   IFS=$lt_save_ifs
7337 else
7338   lt_cv_path_LD=$LD # Let the user override the test with a path.
7339 fi
7340 fi
7341
7342 LD=$lt_cv_path_LD
7343 if test -n "$LD"; then
7344   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7345 $as_echo "$LD" >&6; }
7346 else
7347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7348 $as_echo "no" >&6; }
7349 fi
7350 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7352 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7353 if ${lt_cv_prog_gnu_ld+:} false; then :
7354   $as_echo_n "(cached) " >&6
7355 else
7356   # I'd rather use --version here, but apparently some GNU lds only accept -v.
7357 case `$LD -v 2>&1 </dev/null` in
7358 *GNU* | *'with BFD'*)
7359   lt_cv_prog_gnu_ld=yes
7360   ;;
7361 *)
7362   lt_cv_prog_gnu_ld=no
7363   ;;
7364 esac
7365 fi
7366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7367 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
7368 with_gnu_ld=$lt_cv_prog_gnu_ld
7369
7370
7371
7372
7373
7374
7375
7376
7377
7378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7379 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7380 if ${lt_cv_path_NM+:} false; then :
7381   $as_echo_n "(cached) " >&6
7382 else
7383   if test -n "$NM"; then
7384   # Let the user override the test.
7385   lt_cv_path_NM=$NM
7386 else
7387   lt_nm_to_check=${ac_tool_prefix}nm
7388   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7389     lt_nm_to_check="$lt_nm_to_check nm"
7390   fi
7391   for lt_tmp_nm in $lt_nm_to_check; do
7392     lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7393     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7394       IFS=$lt_save_ifs
7395       test -z "$ac_dir" && ac_dir=.
7396       tmp_nm=$ac_dir/$lt_tmp_nm
7397       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7398         # Check to see if the nm accepts a BSD-compat flag.
7399         # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7400         #   nm: unknown option "B" ignored
7401         # Tru64's nm complains that /dev/null is an invalid object file
7402         # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7403         case $build_os in
7404         mingw*) lt_bad_file=conftest.nm/nofile ;;
7405         *) lt_bad_file=/dev/null ;;
7406         esac
7407         case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7408         *$lt_bad_file* | *'Invalid file or object type'*)
7409           lt_cv_path_NM="$tmp_nm -B"
7410           break 2
7411           ;;
7412         *)
7413           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7414           */dev/null*)
7415             lt_cv_path_NM="$tmp_nm -p"
7416             break 2
7417             ;;
7418           *)
7419             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7420             continue # so that we can try to find one that supports BSD flags
7421             ;;
7422           esac
7423           ;;
7424         esac
7425       fi
7426     done
7427     IFS=$lt_save_ifs
7428   done
7429   : ${lt_cv_path_NM=no}
7430 fi
7431 fi
7432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7433 $as_echo "$lt_cv_path_NM" >&6; }
7434 if test no != "$lt_cv_path_NM"; then
7435   NM=$lt_cv_path_NM
7436 else
7437   # Didn't find any BSD compatible name lister, look for dumpbin.
7438   if test -n "$DUMPBIN"; then :
7439     # Let the user override the test.
7440   else
7441     if test -n "$ac_tool_prefix"; then
7442   for ac_prog in dumpbin "link -dump"
7443   do
7444     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7445 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7447 $as_echo_n "checking for $ac_word... " >&6; }
7448 if ${ac_cv_prog_DUMPBIN+:} false; then :
7449   $as_echo_n "(cached) " >&6
7450 else
7451   if test -n "$DUMPBIN"; then
7452   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7453 else
7454 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7455 for as_dir in $PATH
7456 do
7457   IFS=$as_save_IFS
7458   test -z "$as_dir" && as_dir=.
7459     for ac_exec_ext in '' $ac_executable_extensions; do
7460   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7461     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7462     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7463     break 2
7464   fi
7465 done
7466   done
7467 IFS=$as_save_IFS
7468
7469 fi
7470 fi
7471 DUMPBIN=$ac_cv_prog_DUMPBIN
7472 if test -n "$DUMPBIN"; then
7473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7474 $as_echo "$DUMPBIN" >&6; }
7475 else
7476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7477 $as_echo "no" >&6; }
7478 fi
7479
7480
7481     test -n "$DUMPBIN" && break
7482   done
7483 fi
7484 if test -z "$DUMPBIN"; then
7485   ac_ct_DUMPBIN=$DUMPBIN
7486   for ac_prog in dumpbin "link -dump"
7487 do
7488   # Extract the first word of "$ac_prog", so it can be a program name with args.
7489 set dummy $ac_prog; ac_word=$2
7490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7491 $as_echo_n "checking for $ac_word... " >&6; }
7492 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7493   $as_echo_n "(cached) " >&6
7494 else
7495   if test -n "$ac_ct_DUMPBIN"; then
7496   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7497 else
7498 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7499 for as_dir in $PATH
7500 do
7501   IFS=$as_save_IFS
7502   test -z "$as_dir" && as_dir=.
7503     for ac_exec_ext in '' $ac_executable_extensions; do
7504   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7505     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7506     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7507     break 2
7508   fi
7509 done
7510   done
7511 IFS=$as_save_IFS
7512
7513 fi
7514 fi
7515 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7516 if test -n "$ac_ct_DUMPBIN"; then
7517   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7518 $as_echo "$ac_ct_DUMPBIN" >&6; }
7519 else
7520   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7521 $as_echo "no" >&6; }
7522 fi
7523
7524
7525   test -n "$ac_ct_DUMPBIN" && break
7526 done
7527
7528   if test "x$ac_ct_DUMPBIN" = x; then
7529     DUMPBIN=":"
7530   else
7531     case $cross_compiling:$ac_tool_warned in
7532 yes:)
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7534 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7535 ac_tool_warned=yes ;;
7536 esac
7537     DUMPBIN=$ac_ct_DUMPBIN
7538   fi
7539 fi
7540
7541     case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7542     *COFF*)
7543       DUMPBIN="$DUMPBIN -symbols -headers"
7544       ;;
7545     *)
7546       DUMPBIN=:
7547       ;;
7548     esac
7549   fi
7550
7551   if test : != "$DUMPBIN"; then
7552     NM=$DUMPBIN
7553   fi
7554 fi
7555 test -z "$NM" && NM=nm
7556
7557
7558
7559
7560
7561
7562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7563 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
7564 if ${lt_cv_nm_interface+:} false; then :
7565   $as_echo_n "(cached) " >&6
7566 else
7567   lt_cv_nm_interface="BSD nm"
7568   echo "int some_variable = 0;" > conftest.$ac_ext
7569   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7570   (eval "$ac_compile" 2>conftest.err)
7571   cat conftest.err >&5
7572   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7573   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7574   cat conftest.err >&5
7575   (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7576   cat conftest.out >&5
7577   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7578     lt_cv_nm_interface="MS dumpbin"
7579   fi
7580   rm -f conftest*
7581 fi
7582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7583 $as_echo "$lt_cv_nm_interface" >&6; }
7584
7585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7586 $as_echo_n "checking whether ln -s works... " >&6; }
7587 LN_S=$as_ln_s
7588 if test "$LN_S" = "ln -s"; then
7589   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7590 $as_echo "yes" >&6; }
7591 else
7592   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7593 $as_echo "no, using $LN_S" >&6; }
7594 fi
7595
7596 # find the maximum length of command line arguments
7597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7598 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
7599 if ${lt_cv_sys_max_cmd_len+:} false; then :
7600   $as_echo_n "(cached) " >&6
7601 else
7602     i=0
7603   teststring=ABCD
7604
7605   case $build_os in
7606   msdosdjgpp*)
7607     # On DJGPP, this test can blow up pretty badly due to problems in libc
7608     # (any single argument exceeding 2000 bytes causes a buffer overrun
7609     # during glob expansion).  Even if it were fixed, the result of this
7610     # check would be larger than it should be.
7611     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
7612     ;;
7613
7614   gnu*)
7615     # Under GNU Hurd, this test is not required because there is
7616     # no limit to the length of command line arguments.
7617     # Libtool will interpret -1 as no limit whatsoever
7618     lt_cv_sys_max_cmd_len=-1;
7619     ;;
7620
7621   cygwin* | mingw* | cegcc*)
7622     # On Win9x/ME, this test blows up -- it succeeds, but takes
7623     # about 5 minutes as the teststring grows exponentially.
7624     # Worse, since 9x/ME are not pre-emptively multitasking,
7625     # you end up with a "frozen" computer, even though with patience
7626     # the test eventually succeeds (with a max line length of 256k).
7627     # Instead, let's just punt: use the minimum linelength reported by
7628     # all of the supported platforms: 8192 (on NT/2K/XP).
7629     lt_cv_sys_max_cmd_len=8192;
7630     ;;
7631
7632   mint*)
7633     # On MiNT this can take a long time and run out of memory.
7634     lt_cv_sys_max_cmd_len=8192;
7635     ;;
7636
7637   amigaos*)
7638     # On AmigaOS with pdksh, this test takes hours, literally.
7639     # So we just punt and use a minimum line length of 8192.
7640     lt_cv_sys_max_cmd_len=8192;
7641     ;;
7642
7643   bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7644     # This has been around since 386BSD, at least.  Likely further.
7645     if test -x /sbin/sysctl; then
7646       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7647     elif test -x /usr/sbin/sysctl; then
7648       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7649     else
7650       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
7651     fi
7652     # And add a safety zone
7653     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7654     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7655     ;;
7656
7657   interix*)
7658     # We know the value 262144 and hardcode it with a safety zone (like BSD)
7659     lt_cv_sys_max_cmd_len=196608
7660     ;;
7661
7662   os2*)
7663     # The test takes a long time on OS/2.
7664     lt_cv_sys_max_cmd_len=8192
7665     ;;
7666
7667   osf*)
7668     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7669     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7670     # nice to cause kernel panics so lets avoid the loop below.
7671     # First set a reasonable default.
7672     lt_cv_sys_max_cmd_len=16384
7673     #
7674     if test -x /sbin/sysconfig; then
7675       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7676         *1*) lt_cv_sys_max_cmd_len=-1 ;;
7677       esac
7678     fi
7679     ;;
7680   sco3.2v5*)
7681     lt_cv_sys_max_cmd_len=102400
7682     ;;
7683   sysv5* | sco5v6* | sysv4.2uw2*)
7684     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7685     if test -n "$kargmax"; then
7686       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
7687     else
7688       lt_cv_sys_max_cmd_len=32768
7689     fi
7690     ;;
7691   *)
7692     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7693     if test -n "$lt_cv_sys_max_cmd_len" && \
7694        test undefined != "$lt_cv_sys_max_cmd_len"; then
7695       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7696       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7697     else
7698       # Make teststring a little bigger before we do anything with it.
7699       # a 1K string should be a reasonable start.
7700       for i in 1 2 3 4 5 6 7 8; do
7701         teststring=$teststring$teststring
7702       done
7703       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7704       # If test is not a shell built-in, we'll probably end up computing a
7705       # maximum length that is only half of the actual maximum length, but
7706       # we can't tell.
7707       while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7708                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7709               test 17 != "$i" # 1/2 MB should be enough
7710       do
7711         i=`expr $i + 1`
7712         teststring=$teststring$teststring
7713       done
7714       # Only check the string length outside the loop.
7715       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7716       teststring=
7717       # Add a significant safety factor because C++ compilers can tack on
7718       # massive amounts of additional arguments before passing them to the
7719       # linker.  It appears as though 1/2 is a usable value.
7720       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7721     fi
7722     ;;
7723   esac
7724
7725 fi
7726
7727 if test -n "$lt_cv_sys_max_cmd_len"; then
7728   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7729 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7730 else
7731   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7732 $as_echo "none" >&6; }
7733 fi
7734 max_cmd_len=$lt_cv_sys_max_cmd_len
7735
7736
7737
7738
7739
7740
7741 : ${CP="cp -f"}
7742 : ${MV="mv -f"}
7743 : ${RM="rm -f"}
7744
7745 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7746   lt_unset=unset
7747 else
7748   lt_unset=false
7749 fi
7750
7751
7752
7753
7754
7755 # test EBCDIC or ASCII
7756 case `echo X|tr X '\101'` in
7757  A) # ASCII based system
7758     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7759   lt_SP2NL='tr \040 \012'
7760   lt_NL2SP='tr \015\012 \040\040'
7761   ;;
7762  *) # EBCDIC based system
7763   lt_SP2NL='tr \100 \n'
7764   lt_NL2SP='tr \r\n \100\100'
7765   ;;
7766 esac
7767
7768
7769
7770
7771
7772
7773
7774
7775
7776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7777 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7778 if ${lt_cv_to_host_file_cmd+:} false; then :
7779   $as_echo_n "(cached) " >&6
7780 else
7781   case $host in
7782   *-*-mingw* )
7783     case $build in
7784       *-*-mingw* ) # actually msys
7785         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7786         ;;
7787       *-*-cygwin* )
7788         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7789         ;;
7790       * ) # otherwise, assume *nix
7791         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7792         ;;
7793     esac
7794     ;;
7795   *-*-cygwin* )
7796     case $build in
7797       *-*-mingw* ) # actually msys
7798         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7799         ;;
7800       *-*-cygwin* )
7801         lt_cv_to_host_file_cmd=func_convert_file_noop
7802         ;;
7803       * ) # otherwise, assume *nix
7804         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7805         ;;
7806     esac
7807     ;;
7808   * ) # unhandled hosts (and "normal" native builds)
7809     lt_cv_to_host_file_cmd=func_convert_file_noop
7810     ;;
7811 esac
7812
7813 fi
7814
7815 to_host_file_cmd=$lt_cv_to_host_file_cmd
7816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7817 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
7818
7819
7820
7821
7822
7823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7824 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7825 if ${lt_cv_to_tool_file_cmd+:} false; then :
7826   $as_echo_n "(cached) " >&6
7827 else
7828   #assume ordinary cross tools, or native build.
7829 lt_cv_to_tool_file_cmd=func_convert_file_noop
7830 case $host in
7831   *-*-mingw* )
7832     case $build in
7833       *-*-mingw* ) # actually msys
7834         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7835         ;;
7836     esac
7837     ;;
7838 esac
7839
7840 fi
7841
7842 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7844 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7845
7846
7847
7848
7849
7850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7851 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7852 if ${lt_cv_ld_reload_flag+:} false; then :
7853   $as_echo_n "(cached) " >&6
7854 else
7855   lt_cv_ld_reload_flag='-r'
7856 fi
7857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7858 $as_echo "$lt_cv_ld_reload_flag" >&6; }
7859 reload_flag=$lt_cv_ld_reload_flag
7860 case $reload_flag in
7861 "" | " "*) ;;
7862 *) reload_flag=" $reload_flag" ;;
7863 esac
7864 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7865 case $host_os in
7866   cygwin* | mingw* | pw32* | cegcc*)
7867     if test yes != "$GCC"; then
7868       reload_cmds=false
7869     fi
7870     ;;
7871   darwin*)
7872     if test yes = "$GCC"; then
7873       reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
7874     else
7875       reload_cmds='$LD$reload_flag -o $output$reload_objs'
7876     fi
7877     ;;
7878 esac
7879
7880
7881
7882
7883
7884
7885
7886
7887
7888 if test -n "$ac_tool_prefix"; then
7889   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7890 set dummy ${ac_tool_prefix}objdump; ac_word=$2
7891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7892 $as_echo_n "checking for $ac_word... " >&6; }
7893 if ${ac_cv_prog_OBJDUMP+:} false; then :
7894   $as_echo_n "(cached) " >&6
7895 else
7896   if test -n "$OBJDUMP"; then
7897   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7898 else
7899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7900 for as_dir in $PATH
7901 do
7902   IFS=$as_save_IFS
7903   test -z "$as_dir" && as_dir=.
7904     for ac_exec_ext in '' $ac_executable_extensions; do
7905   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7906     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7907     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7908     break 2
7909   fi
7910 done
7911   done
7912 IFS=$as_save_IFS
7913
7914 fi
7915 fi
7916 OBJDUMP=$ac_cv_prog_OBJDUMP
7917 if test -n "$OBJDUMP"; then
7918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7919 $as_echo "$OBJDUMP" >&6; }
7920 else
7921   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7922 $as_echo "no" >&6; }
7923 fi
7924
7925
7926 fi
7927 if test -z "$ac_cv_prog_OBJDUMP"; then
7928   ac_ct_OBJDUMP=$OBJDUMP
7929   # Extract the first word of "objdump", so it can be a program name with args.
7930 set dummy objdump; ac_word=$2
7931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7932 $as_echo_n "checking for $ac_word... " >&6; }
7933 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7934   $as_echo_n "(cached) " >&6
7935 else
7936   if test -n "$ac_ct_OBJDUMP"; then
7937   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7938 else
7939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7940 for as_dir in $PATH
7941 do
7942   IFS=$as_save_IFS
7943   test -z "$as_dir" && as_dir=.
7944     for ac_exec_ext in '' $ac_executable_extensions; do
7945   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7946     ac_cv_prog_ac_ct_OBJDUMP="objdump"
7947     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7948     break 2
7949   fi
7950 done
7951   done
7952 IFS=$as_save_IFS
7953
7954 fi
7955 fi
7956 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7957 if test -n "$ac_ct_OBJDUMP"; then
7958   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7959 $as_echo "$ac_ct_OBJDUMP" >&6; }
7960 else
7961   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7962 $as_echo "no" >&6; }
7963 fi
7964
7965   if test "x$ac_ct_OBJDUMP" = x; then
7966     OBJDUMP="false"
7967   else
7968     case $cross_compiling:$ac_tool_warned in
7969 yes:)
7970 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7971 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7972 ac_tool_warned=yes ;;
7973 esac
7974     OBJDUMP=$ac_ct_OBJDUMP
7975   fi
7976 else
7977   OBJDUMP="$ac_cv_prog_OBJDUMP"
7978 fi
7979
7980 test -z "$OBJDUMP" && OBJDUMP=objdump
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
7991 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
7992 if ${lt_cv_deplibs_check_method+:} false; then :
7993   $as_echo_n "(cached) " >&6
7994 else
7995   lt_cv_file_magic_cmd='$MAGIC_CMD'
7996 lt_cv_file_magic_test_file=
7997 lt_cv_deplibs_check_method='unknown'
7998 # Need to set the preceding variable on all platforms that support
7999 # interlibrary dependencies.
8000 # 'none' -- dependencies not supported.
8001 # 'unknown' -- same as none, but documents that we really don't know.
8002 # 'pass_all' -- all dependencies passed with no checks.
8003 # 'test_compile' -- check by making test program.
8004 # 'file_magic [[regex]]' -- check by looking for files in library path
8005 # that responds to the $file_magic_cmd with a given extended regex.
8006 # If you have 'file' or equivalent on your system and you're not sure
8007 # whether 'pass_all' will *always* work, you probably want this one.
8008
8009 case $host_os in
8010 aix[4-9]*)
8011   lt_cv_deplibs_check_method=pass_all
8012   ;;
8013
8014 beos*)
8015   lt_cv_deplibs_check_method=pass_all
8016   ;;
8017
8018 bsdi[45]*)
8019   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
8020   lt_cv_file_magic_cmd='/usr/bin/file -L'
8021   lt_cv_file_magic_test_file=/shlib/libc.so
8022   ;;
8023
8024 cygwin*)
8025   # func_win32_libid is a shell function defined in ltmain.sh
8026   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8027   lt_cv_file_magic_cmd='func_win32_libid'
8028   ;;
8029
8030 mingw* | pw32*)
8031   # Base MSYS/MinGW do not provide the 'file' command needed by
8032   # func_win32_libid shell function, so use a weaker test based on 'objdump',
8033   # unless we find 'file', for example because we are cross-compiling.
8034   if ( file / ) >/dev/null 2>&1; then
8035     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8036     lt_cv_file_magic_cmd='func_win32_libid'
8037   else
8038     # Keep this pattern in sync with the one in func_win32_libid.
8039     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
8040     lt_cv_file_magic_cmd='$OBJDUMP -f'
8041   fi
8042   ;;
8043
8044 cegcc*)
8045   # use the weaker test based on 'objdump'. See mingw*.
8046   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
8047   lt_cv_file_magic_cmd='$OBJDUMP -f'
8048   ;;
8049
8050 darwin* | rhapsody*)
8051   lt_cv_deplibs_check_method=pass_all
8052   ;;
8053
8054 freebsd* | dragonfly*)
8055   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8056     case $host_cpu in
8057     i*86 )
8058       # Not sure whether the presence of OpenBSD here was a mistake.
8059       # Let's accept both of them until this is cleared up.
8060       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8061       lt_cv_file_magic_cmd=/usr/bin/file
8062       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8063       ;;
8064     esac
8065   else
8066     lt_cv_deplibs_check_method=pass_all
8067   fi
8068   ;;
8069
8070 haiku*)
8071   lt_cv_deplibs_check_method=pass_all
8072   ;;
8073
8074 hpux10.20* | hpux11*)
8075   lt_cv_file_magic_cmd=/usr/bin/file
8076   case $host_cpu in
8077   ia64*)
8078     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8079     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8080     ;;
8081   hppa*64*)
8082     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]'
8083     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8084     ;;
8085   *)
8086     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8087     lt_cv_file_magic_test_file=/usr/lib/libc.sl
8088     ;;
8089   esac
8090   ;;
8091
8092 interix[3-9]*)
8093   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8094   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8095   ;;
8096
8097 irix5* | irix6* | nonstopux*)
8098   case $LD in
8099   *-32|*"-32 ") libmagic=32-bit;;
8100   *-n32|*"-n32 ") libmagic=N32;;
8101   *-64|*"-64 ") libmagic=64-bit;;
8102   *) libmagic=never-match;;
8103   esac
8104   lt_cv_deplibs_check_method=pass_all
8105   ;;
8106
8107 # This must be glibc/ELF.
8108 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8109   lt_cv_deplibs_check_method=pass_all
8110   ;;
8111
8112 netbsd*)
8113   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8114     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8115   else
8116     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8117   fi
8118   ;;
8119
8120 newos6*)
8121   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8122   lt_cv_file_magic_cmd=/usr/bin/file
8123   lt_cv_file_magic_test_file=/usr/lib/libnls.so
8124   ;;
8125
8126 *nto* | *qnx*)
8127   lt_cv_deplibs_check_method=pass_all
8128   ;;
8129
8130 openbsd* | bitrig*)
8131   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8132     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8133   else
8134     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8135   fi
8136   ;;
8137
8138 osf3* | osf4* | osf5*)
8139   lt_cv_deplibs_check_method=pass_all
8140   ;;
8141
8142 rdos*)
8143   lt_cv_deplibs_check_method=pass_all
8144   ;;
8145
8146 solaris*)
8147   lt_cv_deplibs_check_method=pass_all
8148   ;;
8149
8150 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8151   lt_cv_deplibs_check_method=pass_all
8152   ;;
8153
8154 sysv4 | sysv4.3*)
8155   case $host_vendor in
8156   motorola)
8157     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]'
8158     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8159     ;;
8160   ncr)
8161     lt_cv_deplibs_check_method=pass_all
8162     ;;
8163   sequent)
8164     lt_cv_file_magic_cmd='/bin/file'
8165     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8166     ;;
8167   sni)
8168     lt_cv_file_magic_cmd='/bin/file'
8169     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8170     lt_cv_file_magic_test_file=/lib/libc.so
8171     ;;
8172   siemens)
8173     lt_cv_deplibs_check_method=pass_all
8174     ;;
8175   pc)
8176     lt_cv_deplibs_check_method=pass_all
8177     ;;
8178   esac
8179   ;;
8180
8181 tpf*)
8182   lt_cv_deplibs_check_method=pass_all
8183   ;;
8184 os2*)
8185   lt_cv_deplibs_check_method=pass_all
8186   ;;
8187 esac
8188
8189 fi
8190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8191 $as_echo "$lt_cv_deplibs_check_method" >&6; }
8192
8193 file_magic_glob=
8194 want_nocaseglob=no
8195 if test "$build" = "$host"; then
8196   case $host_os in
8197   mingw* | pw32*)
8198     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8199       want_nocaseglob=yes
8200     else
8201       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8202     fi
8203     ;;
8204   esac
8205 fi
8206
8207 file_magic_cmd=$lt_cv_file_magic_cmd
8208 deplibs_check_method=$lt_cv_deplibs_check_method
8209 test -z "$deplibs_check_method" && deplibs_check_method=unknown
8210
8211
8212
8213
8214
8215
8216
8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232 if test -n "$ac_tool_prefix"; then
8233   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8234 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8236 $as_echo_n "checking for $ac_word... " >&6; }
8237 if ${ac_cv_prog_DLLTOOL+:} false; then :
8238   $as_echo_n "(cached) " >&6
8239 else
8240   if test -n "$DLLTOOL"; then
8241   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8242 else
8243 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8244 for as_dir in $PATH
8245 do
8246   IFS=$as_save_IFS
8247   test -z "$as_dir" && as_dir=.
8248     for ac_exec_ext in '' $ac_executable_extensions; do
8249   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8250     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8251     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8252     break 2
8253   fi
8254 done
8255   done
8256 IFS=$as_save_IFS
8257
8258 fi
8259 fi
8260 DLLTOOL=$ac_cv_prog_DLLTOOL
8261 if test -n "$DLLTOOL"; then
8262   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8263 $as_echo "$DLLTOOL" >&6; }
8264 else
8265   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8266 $as_echo "no" >&6; }
8267 fi
8268
8269
8270 fi
8271 if test -z "$ac_cv_prog_DLLTOOL"; then
8272   ac_ct_DLLTOOL=$DLLTOOL
8273   # Extract the first word of "dlltool", so it can be a program name with args.
8274 set dummy dlltool; ac_word=$2
8275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8276 $as_echo_n "checking for $ac_word... " >&6; }
8277 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8278   $as_echo_n "(cached) " >&6
8279 else
8280   if test -n "$ac_ct_DLLTOOL"; then
8281   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8282 else
8283 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8284 for as_dir in $PATH
8285 do
8286   IFS=$as_save_IFS
8287   test -z "$as_dir" && as_dir=.
8288     for ac_exec_ext in '' $ac_executable_extensions; do
8289   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8290     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8291     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8292     break 2
8293   fi
8294 done
8295   done
8296 IFS=$as_save_IFS
8297
8298 fi
8299 fi
8300 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8301 if test -n "$ac_ct_DLLTOOL"; then
8302   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8303 $as_echo "$ac_ct_DLLTOOL" >&6; }
8304 else
8305   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8306 $as_echo "no" >&6; }
8307 fi
8308
8309   if test "x$ac_ct_DLLTOOL" = x; then
8310     DLLTOOL="false"
8311   else
8312     case $cross_compiling:$ac_tool_warned in
8313 yes:)
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8315 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8316 ac_tool_warned=yes ;;
8317 esac
8318     DLLTOOL=$ac_ct_DLLTOOL
8319   fi
8320 else
8321   DLLTOOL="$ac_cv_prog_DLLTOOL"
8322 fi
8323
8324 test -z "$DLLTOOL" && DLLTOOL=dlltool
8325
8326
8327
8328
8329
8330
8331
8332
8333
8334
8335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8336 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8337 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8338   $as_echo_n "(cached) " >&6
8339 else
8340   lt_cv_sharedlib_from_linklib_cmd='unknown'
8341
8342 case $host_os in
8343 cygwin* | mingw* | pw32* | cegcc*)
8344   # two different shell functions defined in ltmain.sh;
8345   # decide which one to use based on capabilities of $DLLTOOL
8346   case `$DLLTOOL --help 2>&1` in
8347   *--identify-strict*)
8348     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8349     ;;
8350   *)
8351     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8352     ;;
8353   esac
8354   ;;
8355 *)
8356   # fallback: assume linklib IS sharedlib
8357   lt_cv_sharedlib_from_linklib_cmd=$ECHO
8358   ;;
8359 esac
8360
8361 fi
8362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8363 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8364 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8365 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8366
8367
8368
8369
8370
8371
8372
8373 if test -n "$ac_tool_prefix"; then
8374   for ac_prog in ar
8375   do
8376     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8377 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8379 $as_echo_n "checking for $ac_word... " >&6; }
8380 if ${ac_cv_prog_AR+:} false; then :
8381   $as_echo_n "(cached) " >&6
8382 else
8383   if test -n "$AR"; then
8384   ac_cv_prog_AR="$AR" # Let the user override the test.
8385 else
8386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8387 for as_dir in $PATH
8388 do
8389   IFS=$as_save_IFS
8390   test -z "$as_dir" && as_dir=.
8391     for ac_exec_ext in '' $ac_executable_extensions; do
8392   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8393     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8394     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8395     break 2
8396   fi
8397 done
8398   done
8399 IFS=$as_save_IFS
8400
8401 fi
8402 fi
8403 AR=$ac_cv_prog_AR
8404 if test -n "$AR"; then
8405   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8406 $as_echo "$AR" >&6; }
8407 else
8408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8409 $as_echo "no" >&6; }
8410 fi
8411
8412
8413     test -n "$AR" && break
8414   done
8415 fi
8416 if test -z "$AR"; then
8417   ac_ct_AR=$AR
8418   for ac_prog in ar
8419 do
8420   # Extract the first word of "$ac_prog", so it can be a program name with args.
8421 set dummy $ac_prog; ac_word=$2
8422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8423 $as_echo_n "checking for $ac_word... " >&6; }
8424 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8425   $as_echo_n "(cached) " >&6
8426 else
8427   if test -n "$ac_ct_AR"; then
8428   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8429 else
8430 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8431 for as_dir in $PATH
8432 do
8433   IFS=$as_save_IFS
8434   test -z "$as_dir" && as_dir=.
8435     for ac_exec_ext in '' $ac_executable_extensions; do
8436   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8437     ac_cv_prog_ac_ct_AR="$ac_prog"
8438     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8439     break 2
8440   fi
8441 done
8442   done
8443 IFS=$as_save_IFS
8444
8445 fi
8446 fi
8447 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8448 if test -n "$ac_ct_AR"; then
8449   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8450 $as_echo "$ac_ct_AR" >&6; }
8451 else
8452   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8453 $as_echo "no" >&6; }
8454 fi
8455
8456
8457   test -n "$ac_ct_AR" && break
8458 done
8459
8460   if test "x$ac_ct_AR" = x; then
8461     AR="false"
8462   else
8463     case $cross_compiling:$ac_tool_warned in
8464 yes:)
8465 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8466 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8467 ac_tool_warned=yes ;;
8468 esac
8469     AR=$ac_ct_AR
8470   fi
8471 fi
8472
8473 : ${AR=ar}
8474 : ${AR_FLAGS=cru}
8475
8476
8477
8478
8479
8480
8481
8482
8483
8484
8485
8486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8487 $as_echo_n "checking for archiver @FILE support... " >&6; }
8488 if ${lt_cv_ar_at_file+:} false; then :
8489   $as_echo_n "(cached) " >&6
8490 else
8491   lt_cv_ar_at_file=no
8492    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8493 /* end confdefs.h.  */
8494
8495 int
8496 main ()
8497 {
8498
8499   ;
8500   return 0;
8501 }
8502 _ACEOF
8503 if ac_fn_c_try_compile "$LINENO"; then :
8504   echo conftest.$ac_objext > conftest.lst
8505       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8506       { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8507   (eval $lt_ar_try) 2>&5
8508   ac_status=$?
8509   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8510   test $ac_status = 0; }
8511       if test 0 -eq "$ac_status"; then
8512         # Ensure the archiver fails upon bogus file names.
8513         rm -f conftest.$ac_objext libconftest.a
8514         { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8515   (eval $lt_ar_try) 2>&5
8516   ac_status=$?
8517   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8518   test $ac_status = 0; }
8519         if test 0 -ne "$ac_status"; then
8520           lt_cv_ar_at_file=@
8521         fi
8522       fi
8523       rm -f conftest.* libconftest.a
8524
8525 fi
8526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8527
8528 fi
8529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8530 $as_echo "$lt_cv_ar_at_file" >&6; }
8531
8532 if test no = "$lt_cv_ar_at_file"; then
8533   archiver_list_spec=
8534 else
8535   archiver_list_spec=$lt_cv_ar_at_file
8536 fi
8537
8538
8539
8540
8541
8542
8543
8544 if test -n "$ac_tool_prefix"; then
8545   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8546 set dummy ${ac_tool_prefix}strip; ac_word=$2
8547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8548 $as_echo_n "checking for $ac_word... " >&6; }
8549 if ${ac_cv_prog_STRIP+:} false; then :
8550   $as_echo_n "(cached) " >&6
8551 else
8552   if test -n "$STRIP"; then
8553   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8554 else
8555 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8556 for as_dir in $PATH
8557 do
8558   IFS=$as_save_IFS
8559   test -z "$as_dir" && as_dir=.
8560     for ac_exec_ext in '' $ac_executable_extensions; do
8561   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8562     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8563     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8564     break 2
8565   fi
8566 done
8567   done
8568 IFS=$as_save_IFS
8569
8570 fi
8571 fi
8572 STRIP=$ac_cv_prog_STRIP
8573 if test -n "$STRIP"; then
8574   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8575 $as_echo "$STRIP" >&6; }
8576 else
8577   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8578 $as_echo "no" >&6; }
8579 fi
8580
8581
8582 fi
8583 if test -z "$ac_cv_prog_STRIP"; then
8584   ac_ct_STRIP=$STRIP
8585   # Extract the first word of "strip", so it can be a program name with args.
8586 set dummy strip; ac_word=$2
8587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8588 $as_echo_n "checking for $ac_word... " >&6; }
8589 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8590   $as_echo_n "(cached) " >&6
8591 else
8592   if test -n "$ac_ct_STRIP"; then
8593   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8594 else
8595 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8596 for as_dir in $PATH
8597 do
8598   IFS=$as_save_IFS
8599   test -z "$as_dir" && as_dir=.
8600     for ac_exec_ext in '' $ac_executable_extensions; do
8601   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8602     ac_cv_prog_ac_ct_STRIP="strip"
8603     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8604     break 2
8605   fi
8606 done
8607   done
8608 IFS=$as_save_IFS
8609
8610 fi
8611 fi
8612 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8613 if test -n "$ac_ct_STRIP"; then
8614   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8615 $as_echo "$ac_ct_STRIP" >&6; }
8616 else
8617   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8618 $as_echo "no" >&6; }
8619 fi
8620
8621   if test "x$ac_ct_STRIP" = x; then
8622     STRIP=":"
8623   else
8624     case $cross_compiling:$ac_tool_warned in
8625 yes:)
8626 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8627 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8628 ac_tool_warned=yes ;;
8629 esac
8630     STRIP=$ac_ct_STRIP
8631   fi
8632 else
8633   STRIP="$ac_cv_prog_STRIP"
8634 fi
8635
8636 test -z "$STRIP" && STRIP=:
8637
8638
8639
8640
8641
8642
8643 if test -n "$ac_tool_prefix"; then
8644   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8645 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8647 $as_echo_n "checking for $ac_word... " >&6; }
8648 if ${ac_cv_prog_RANLIB+:} false; then :
8649   $as_echo_n "(cached) " >&6
8650 else
8651   if test -n "$RANLIB"; then
8652   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8653 else
8654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8655 for as_dir in $PATH
8656 do
8657   IFS=$as_save_IFS
8658   test -z "$as_dir" && as_dir=.
8659     for ac_exec_ext in '' $ac_executable_extensions; do
8660   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8661     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8662     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8663     break 2
8664   fi
8665 done
8666   done
8667 IFS=$as_save_IFS
8668
8669 fi
8670 fi
8671 RANLIB=$ac_cv_prog_RANLIB
8672 if test -n "$RANLIB"; then
8673   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8674 $as_echo "$RANLIB" >&6; }
8675 else
8676   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8677 $as_echo "no" >&6; }
8678 fi
8679
8680
8681 fi
8682 if test -z "$ac_cv_prog_RANLIB"; then
8683   ac_ct_RANLIB=$RANLIB
8684   # Extract the first word of "ranlib", so it can be a program name with args.
8685 set dummy ranlib; ac_word=$2
8686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8687 $as_echo_n "checking for $ac_word... " >&6; }
8688 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8689   $as_echo_n "(cached) " >&6
8690 else
8691   if test -n "$ac_ct_RANLIB"; then
8692   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8693 else
8694 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8695 for as_dir in $PATH
8696 do
8697   IFS=$as_save_IFS
8698   test -z "$as_dir" && as_dir=.
8699     for ac_exec_ext in '' $ac_executable_extensions; do
8700   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8701     ac_cv_prog_ac_ct_RANLIB="ranlib"
8702     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8703     break 2
8704   fi
8705 done
8706   done
8707 IFS=$as_save_IFS
8708
8709 fi
8710 fi
8711 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8712 if test -n "$ac_ct_RANLIB"; then
8713   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8714 $as_echo "$ac_ct_RANLIB" >&6; }
8715 else
8716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8717 $as_echo "no" >&6; }
8718 fi
8719
8720   if test "x$ac_ct_RANLIB" = x; then
8721     RANLIB=":"
8722   else
8723     case $cross_compiling:$ac_tool_warned in
8724 yes:)
8725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8726 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8727 ac_tool_warned=yes ;;
8728 esac
8729     RANLIB=$ac_ct_RANLIB
8730   fi
8731 else
8732   RANLIB="$ac_cv_prog_RANLIB"
8733 fi
8734
8735 test -z "$RANLIB" && RANLIB=:
8736
8737
8738
8739
8740
8741
8742 # Determine commands to create old-style static archives.
8743 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8744 old_postinstall_cmds='chmod 644 $oldlib'
8745 old_postuninstall_cmds=
8746
8747 if test -n "$RANLIB"; then
8748   case $host_os in
8749   bitrig* | openbsd*)
8750     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8751     ;;
8752   *)
8753     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8754     ;;
8755   esac
8756   old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8757 fi
8758
8759 case $host_os in
8760   darwin*)
8761     lock_old_archive_extraction=yes ;;
8762   *)
8763     lock_old_archive_extraction=no ;;
8764 esac
8765
8766
8767
8768
8769
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786 for ac_prog in gawk mawk nawk awk
8787 do
8788   # Extract the first word of "$ac_prog", so it can be a program name with args.
8789 set dummy $ac_prog; ac_word=$2
8790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8791 $as_echo_n "checking for $ac_word... " >&6; }
8792 if ${ac_cv_prog_AWK+:} false; then :
8793   $as_echo_n "(cached) " >&6
8794 else
8795   if test -n "$AWK"; then
8796   ac_cv_prog_AWK="$AWK" # Let the user override the test.
8797 else
8798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8799 for as_dir in $PATH
8800 do
8801   IFS=$as_save_IFS
8802   test -z "$as_dir" && as_dir=.
8803     for ac_exec_ext in '' $ac_executable_extensions; do
8804   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8805     ac_cv_prog_AWK="$ac_prog"
8806     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8807     break 2
8808   fi
8809 done
8810   done
8811 IFS=$as_save_IFS
8812
8813 fi
8814 fi
8815 AWK=$ac_cv_prog_AWK
8816 if test -n "$AWK"; then
8817   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
8818 $as_echo "$AWK" >&6; }
8819 else
8820   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8821 $as_echo "no" >&6; }
8822 fi
8823
8824
8825   test -n "$AWK" && break
8826 done
8827
8828
8829
8830
8831
8832
8833
8834
8835
8836
8837
8838
8839
8840
8841
8842
8843
8844
8845
8846 # If no C compiler was specified, use CC.
8847 LTCC=${LTCC-"$CC"}
8848
8849 # If no C compiler flags were specified, use CFLAGS.
8850 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8851
8852 # Allow CC to be a program name with arguments.
8853 compiler=$CC
8854
8855
8856 # Check for command to grab the raw symbol name followed by C symbol from nm.
8857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8858 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8859 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8860   $as_echo_n "(cached) " >&6
8861 else
8862
8863 # These are sane defaults that work on at least a few old systems.
8864 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
8865
8866 # Character class describing NM global symbol codes.
8867 symcode='[BCDEGRST]'
8868
8869 # Regexp to match symbols that can be accessed directly from C.
8870 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8871
8872 # Define system-specific variables.
8873 case $host_os in
8874 aix*)
8875   symcode='[BCDT]'
8876   ;;
8877 cygwin* | mingw* | pw32* | cegcc*)
8878   symcode='[ABCDGISTW]'
8879   ;;
8880 hpux*)
8881   if test ia64 = "$host_cpu"; then
8882     symcode='[ABCDEGRST]'
8883   fi
8884   ;;
8885 irix* | nonstopux*)
8886   symcode='[BCDEGRST]'
8887   ;;
8888 osf*)
8889   symcode='[BCDEGQRST]'
8890   ;;
8891 solaris*)
8892   symcode='[BDRT]'
8893   ;;
8894 sco3.2v5*)
8895   symcode='[DT]'
8896   ;;
8897 sysv4.2uw2*)
8898   symcode='[DT]'
8899   ;;
8900 sysv5* | sco5v6* | unixware* | OpenUNIX*)
8901   symcode='[ABDT]'
8902   ;;
8903 sysv4)
8904   symcode='[DFNSTU]'
8905   ;;
8906 esac
8907
8908 # If we're using GNU nm, then use its standard symbol codes.
8909 case `$NM -V 2>&1` in
8910 *GNU* | *'with BFD'*)
8911   symcode='[ABCDGIRSTW]' ;;
8912 esac
8913
8914 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8915   # Gets list of data symbols to import.
8916   lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
8917   # Adjust the below global symbol transforms to fixup imported variables.
8918   lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
8919   lt_c_name_hook=" -e 's/^I .* \(.*\)$/  {\"\1\", (void *) 0},/p'"
8920   lt_c_name_lib_hook="\
8921   -e 's/^I .* \(lib.*\)$/  {\"\1\", (void *) 0},/p'\
8922   -e 's/^I .* \(.*\)$/  {\"lib\1\", (void *) 0},/p'"
8923 else
8924   # Disable hooks by default.
8925   lt_cv_sys_global_symbol_to_import=
8926   lt_cdecl_hook=
8927   lt_c_name_hook=
8928   lt_c_name_lib_hook=
8929 fi
8930
8931 # Transform an extracted symbol line into a proper C declaration.
8932 # Some systems (esp. on ia64) link data and code symbols differently,
8933 # so use this general approach.
8934 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
8935 $lt_cdecl_hook\
8936 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
8937 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
8938
8939 # Transform an extracted symbol line into symbol name and symbol address
8940 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
8941 $lt_c_name_hook\
8942 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8943 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/p'"
8944
8945 # Transform an extracted symbol line into symbol name with lib prefix and
8946 # symbol address.
8947 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
8948 $lt_c_name_lib_hook\
8949 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8950 " -e 's/^$symcode$symcode* .* \(lib.*\)$/  {\"\1\", (void *) \&\1},/p'"\
8951 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"lib\1\", (void *) \&\1},/p'"
8952
8953 # Handle CRLF in mingw tool chain
8954 opt_cr=
8955 case $build_os in
8956 mingw*)
8957   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8958   ;;
8959 esac
8960
8961 # Try without a prefix underscore, then with it.
8962 for ac_symprfx in "" "_"; do
8963
8964   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8965   symxfrm="\\1 $ac_symprfx\\2 \\2"
8966
8967   # Write the raw and C identifiers.
8968   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8969     # Fake it for dumpbin and say T for any non-static function,
8970     # D for any global variable and I for any imported variable.
8971     # Also find C++ and __fastcall symbols from MSVC++,
8972     # which start with @ or ?.
8973     lt_cv_sys_global_symbol_pipe="$AWK '"\
8974 "     {last_section=section; section=\$ 3};"\
8975 "     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8976 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8977 "     /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
8978 "     /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
8979 "     /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
8980 "     \$ 0!~/External *\|/{next};"\
8981 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8982 "     {if(hide[section]) next};"\
8983 "     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
8984 "     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
8985 "     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
8986 "     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
8987 "     ' prfx=^$ac_symprfx"
8988   else
8989     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
8990   fi
8991   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
8992
8993   # Check to see that the pipe works correctly.
8994   pipe_works=no
8995
8996   rm -f conftest*
8997   cat > conftest.$ac_ext <<_LT_EOF
8998 #ifdef __cplusplus
8999 extern "C" {
9000 #endif
9001 char nm_test_var;
9002 void nm_test_func(void);
9003 void nm_test_func(void){}
9004 #ifdef __cplusplus
9005 }
9006 #endif
9007 int main(){nm_test_var='a';nm_test_func();return(0);}
9008 _LT_EOF
9009
9010   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9011   (eval $ac_compile) 2>&5
9012   ac_status=$?
9013   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9014   test $ac_status = 0; }; then
9015     # Now try to grab the symbols.
9016     nlist=conftest.nm
9017     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
9018   (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
9019   ac_status=$?
9020   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9021   test $ac_status = 0; } && test -s "$nlist"; then
9022       # Try sorting and uniquifying the output.
9023       if sort "$nlist" | uniq > "$nlist"T; then
9024         mv -f "$nlist"T "$nlist"
9025       else
9026         rm -f "$nlist"T
9027       fi
9028
9029       # Make sure that we snagged all the symbols we need.
9030       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
9031         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9032           cat <<_LT_EOF > conftest.$ac_ext
9033 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
9034 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
9035 /* DATA imports from DLLs on WIN32 can't be const, because runtime
9036    relocations are performed -- see ld's documentation on pseudo-relocs.  */
9037 # define LT_DLSYM_CONST
9038 #elif defined __osf__
9039 /* This system does not cope well with relocations in const data.  */
9040 # define LT_DLSYM_CONST
9041 #else
9042 # define LT_DLSYM_CONST const
9043 #endif
9044
9045 #ifdef __cplusplus
9046 extern "C" {
9047 #endif
9048
9049 _LT_EOF
9050           # Now generate the symbol file.
9051           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9052
9053           cat <<_LT_EOF >> conftest.$ac_ext
9054
9055 /* The mapping between symbol names and symbols.  */
9056 LT_DLSYM_CONST struct {
9057   const char *name;
9058   void       *address;
9059 }
9060 lt__PROGRAM__LTX_preloaded_symbols[] =
9061 {
9062   { "@PROGRAM@", (void *) 0 },
9063 _LT_EOF
9064           $SED "s/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9065           cat <<\_LT_EOF >> conftest.$ac_ext
9066   {0, (void *) 0}
9067 };
9068
9069 /* This works around a problem in FreeBSD linker */
9070 #ifdef FREEBSD_WORKAROUND
9071 static const void *lt_preloaded_setup() {
9072   return lt__PROGRAM__LTX_preloaded_symbols;
9073 }
9074 #endif
9075
9076 #ifdef __cplusplus
9077 }
9078 #endif
9079 _LT_EOF
9080           # Now try linking the two files.
9081           mv conftest.$ac_objext conftstm.$ac_objext
9082           lt_globsym_save_LIBS=$LIBS
9083           lt_globsym_save_CFLAGS=$CFLAGS
9084           LIBS=conftstm.$ac_objext
9085           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9086           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9087   (eval $ac_link) 2>&5
9088   ac_status=$?
9089   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9090   test $ac_status = 0; } && test -s conftest$ac_exeext; then
9091             pipe_works=yes
9092           fi
9093           LIBS=$lt_globsym_save_LIBS
9094           CFLAGS=$lt_globsym_save_CFLAGS
9095         else
9096           echo "cannot find nm_test_func in $nlist" >&5
9097         fi
9098       else
9099         echo "cannot find nm_test_var in $nlist" >&5
9100       fi
9101     else
9102       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9103     fi
9104   else
9105     echo "$progname: failed program was:" >&5
9106     cat conftest.$ac_ext >&5
9107   fi
9108   rm -rf conftest* conftst*
9109
9110   # Do not use the global_symbol_pipe unless it works.
9111   if test yes = "$pipe_works"; then
9112     break
9113   else
9114     lt_cv_sys_global_symbol_pipe=
9115   fi
9116 done
9117
9118 fi
9119
9120 if test -z "$lt_cv_sys_global_symbol_pipe"; then
9121   lt_cv_sys_global_symbol_to_cdecl=
9122 fi
9123 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9125 $as_echo "failed" >&6; }
9126 else
9127   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9128 $as_echo "ok" >&6; }
9129 fi
9130
9131 # Response file support.
9132 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9133   nm_file_list_spec='@'
9134 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9135   nm_file_list_spec='@'
9136 fi
9137
9138
9139
9140
9141
9142
9143
9144
9145
9146
9147
9148
9149
9150
9151
9152
9153
9154
9155
9156
9157
9158
9159
9160
9161
9162
9163
9164
9165
9166
9167
9168
9169
9170
9171
9172
9173
9174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9175 $as_echo_n "checking for sysroot... " >&6; }
9176
9177 # Check whether --with-sysroot was given.
9178 if test "${with_sysroot+set}" = set; then :
9179   withval=$with_sysroot;
9180 else
9181   with_sysroot=no
9182 fi
9183
9184
9185 lt_sysroot=
9186 case $with_sysroot in #(
9187  yes)
9188    if test yes = "$GCC"; then
9189      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9190    fi
9191    ;; #(
9192  /*)
9193    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9194    ;; #(
9195  no|'')
9196    ;; #(
9197  *)
9198    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9199 $as_echo "$with_sysroot" >&6; }
9200    as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9201    ;;
9202 esac
9203
9204  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9205 $as_echo "${lt_sysroot:-no}" >&6; }
9206
9207
9208
9209
9210
9211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9212 $as_echo_n "checking for a working dd... " >&6; }
9213 if ${ac_cv_path_lt_DD+:} false; then :
9214   $as_echo_n "(cached) " >&6
9215 else
9216   printf 0123456789abcdef0123456789abcdef >conftest.i
9217 cat conftest.i conftest.i >conftest2.i
9218 : ${lt_DD:=$DD}
9219 if test -z "$lt_DD"; then
9220   ac_path_lt_DD_found=false
9221   # Loop through the user's path and test for each of PROGNAME-LIST
9222   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9223 for as_dir in $PATH
9224 do
9225   IFS=$as_save_IFS
9226   test -z "$as_dir" && as_dir=.
9227     for ac_prog in dd; do
9228     for ac_exec_ext in '' $ac_executable_extensions; do
9229       ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9230       as_fn_executable_p "$ac_path_lt_DD" || continue
9231 if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9232   cmp -s conftest.i conftest.out \
9233   && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9234 fi
9235       $ac_path_lt_DD_found && break 3
9236     done
9237   done
9238   done
9239 IFS=$as_save_IFS
9240   if test -z "$ac_cv_path_lt_DD"; then
9241     :
9242   fi
9243 else
9244   ac_cv_path_lt_DD=$lt_DD
9245 fi
9246
9247 rm -f conftest.i conftest2.i conftest.out
9248 fi
9249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9250 $as_echo "$ac_cv_path_lt_DD" >&6; }
9251
9252
9253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9254 $as_echo_n "checking how to truncate binary pipes... " >&6; }
9255 if ${lt_cv_truncate_bin+:} false; then :
9256   $as_echo_n "(cached) " >&6
9257 else
9258   printf 0123456789abcdef0123456789abcdef >conftest.i
9259 cat conftest.i conftest.i >conftest2.i
9260 lt_cv_truncate_bin=
9261 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9262   cmp -s conftest.i conftest.out \
9263   && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9264 fi
9265 rm -f conftest.i conftest2.i conftest.out
9266 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9267 fi
9268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9269 $as_echo "$lt_cv_truncate_bin" >&6; }
9270
9271
9272
9273
9274
9275
9276
9277 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
9278 func_cc_basename ()
9279 {
9280     for cc_temp in $*""; do
9281       case $cc_temp in
9282         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9283         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9284         \-*) ;;
9285         *) break;;
9286       esac
9287     done
9288     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9289 }
9290
9291 # Check whether --enable-libtool-lock was given.
9292 if test "${enable_libtool_lock+set}" = set; then :
9293   enableval=$enable_libtool_lock;
9294 fi
9295
9296 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9297
9298 # Some flags need to be propagated to the compiler or linker for good
9299 # libtool support.
9300 case $host in
9301 ia64-*-hpux*)
9302   # Find out what ABI is being produced by ac_compile, and set mode
9303   # options accordingly.
9304   echo 'int i;' > conftest.$ac_ext
9305   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9306   (eval $ac_compile) 2>&5
9307   ac_status=$?
9308   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9309   test $ac_status = 0; }; then
9310     case `/usr/bin/file conftest.$ac_objext` in
9311       *ELF-32*)
9312         HPUX_IA64_MODE=32
9313         ;;
9314       *ELF-64*)
9315         HPUX_IA64_MODE=64
9316         ;;
9317     esac
9318   fi
9319   rm -rf conftest*
9320   ;;
9321 *-*-irix6*)
9322   # Find out what ABI is being produced by ac_compile, and set linker
9323   # options accordingly.
9324   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9325   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9326   (eval $ac_compile) 2>&5
9327   ac_status=$?
9328   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9329   test $ac_status = 0; }; then
9330     if test yes = "$lt_cv_prog_gnu_ld"; then
9331       case `/usr/bin/file conftest.$ac_objext` in
9332         *32-bit*)
9333           LD="${LD-ld} -melf32bsmip"
9334           ;;
9335         *N32*)
9336           LD="${LD-ld} -melf32bmipn32"
9337           ;;
9338         *64-bit*)
9339           LD="${LD-ld} -melf64bmip"
9340         ;;
9341       esac
9342     else
9343       case `/usr/bin/file conftest.$ac_objext` in
9344         *32-bit*)
9345           LD="${LD-ld} -32"
9346           ;;
9347         *N32*)
9348           LD="${LD-ld} -n32"
9349           ;;
9350         *64-bit*)
9351           LD="${LD-ld} -64"
9352           ;;
9353       esac
9354     fi
9355   fi
9356   rm -rf conftest*
9357   ;;
9358
9359 mips64*-*linux*)
9360   # Find out what ABI is being produced by ac_compile, and set linker
9361   # options accordingly.
9362   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9363   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9364   (eval $ac_compile) 2>&5
9365   ac_status=$?
9366   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9367   test $ac_status = 0; }; then
9368     emul=elf
9369     case `/usr/bin/file conftest.$ac_objext` in
9370       *32-bit*)
9371         emul="${emul}32"
9372         ;;
9373       *64-bit*)
9374         emul="${emul}64"
9375         ;;
9376     esac
9377     case `/usr/bin/file conftest.$ac_objext` in
9378       *MSB*)
9379         emul="${emul}btsmip"
9380         ;;
9381       *LSB*)
9382         emul="${emul}ltsmip"
9383         ;;
9384     esac
9385     case `/usr/bin/file conftest.$ac_objext` in
9386       *N32*)
9387         emul="${emul}n32"
9388         ;;
9389     esac
9390     LD="${LD-ld} -m $emul"
9391   fi
9392   rm -rf conftest*
9393   ;;
9394
9395 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9396 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9397   # Find out what ABI is being produced by ac_compile, and set linker
9398   # options accordingly.  Note that the listed cases only cover the
9399   # situations where additional linker options are needed (such as when
9400   # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9401   # vice versa); the common cases where no linker options are needed do
9402   # not appear in the list.
9403   echo 'int i;' > conftest.$ac_ext
9404   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9405   (eval $ac_compile) 2>&5
9406   ac_status=$?
9407   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9408   test $ac_status = 0; }; then
9409     case `/usr/bin/file conftest.o` in
9410       *32-bit*)
9411         case $host in
9412           x86_64-*kfreebsd*-gnu)
9413             LD="${LD-ld} -m elf_i386_fbsd"
9414             ;;
9415           x86_64-*linux*)
9416             case `/usr/bin/file conftest.o` in
9417               *x86-64*)
9418                 LD="${LD-ld} -m elf32_x86_64"
9419                 ;;
9420               *)
9421                 LD="${LD-ld} -m elf_i386"
9422                 ;;
9423             esac
9424             ;;
9425           powerpc64le-*linux*)
9426             LD="${LD-ld} -m elf32lppclinux"
9427             ;;
9428           powerpc64-*linux*)
9429             LD="${LD-ld} -m elf32ppclinux"
9430             ;;
9431           s390x-*linux*)
9432             LD="${LD-ld} -m elf_s390"
9433             ;;
9434           sparc64-*linux*)
9435             LD="${LD-ld} -m elf32_sparc"
9436             ;;
9437         esac
9438         ;;
9439       *64-bit*)
9440         case $host in
9441           x86_64-*kfreebsd*-gnu)
9442             LD="${LD-ld} -m elf_x86_64_fbsd"
9443             ;;
9444           x86_64-*linux*)
9445             LD="${LD-ld} -m elf_x86_64"
9446             ;;
9447           powerpcle-*linux*)
9448             LD="${LD-ld} -m elf64lppc"
9449             ;;
9450           powerpc-*linux*)
9451             LD="${LD-ld} -m elf64ppc"
9452             ;;
9453           s390*-*linux*|s390*-*tpf*)
9454             LD="${LD-ld} -m elf64_s390"
9455             ;;
9456           sparc*-*linux*)
9457             LD="${LD-ld} -m elf64_sparc"
9458             ;;
9459         esac
9460         ;;
9461     esac
9462   fi
9463   rm -rf conftest*
9464   ;;
9465
9466 *-*-sco3.2v5*)
9467   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9468   SAVE_CFLAGS=$CFLAGS
9469   CFLAGS="$CFLAGS -belf"
9470   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9471 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9472 if ${lt_cv_cc_needs_belf+:} false; then :
9473   $as_echo_n "(cached) " >&6
9474 else
9475   ac_ext=c
9476 ac_cpp='$CPP $CPPFLAGS'
9477 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9478 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9479 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9480
9481      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9482 /* end confdefs.h.  */
9483
9484 int
9485 main ()
9486 {
9487
9488   ;
9489   return 0;
9490 }
9491 _ACEOF
9492 if ac_fn_c_try_link "$LINENO"; then :
9493   lt_cv_cc_needs_belf=yes
9494 else
9495   lt_cv_cc_needs_belf=no
9496 fi
9497 rm -f core conftest.err conftest.$ac_objext \
9498     conftest$ac_exeext conftest.$ac_ext
9499      ac_ext=c
9500 ac_cpp='$CPP $CPPFLAGS'
9501 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9502 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9503 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9504
9505 fi
9506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9507 $as_echo "$lt_cv_cc_needs_belf" >&6; }
9508   if test yes != "$lt_cv_cc_needs_belf"; then
9509     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9510     CFLAGS=$SAVE_CFLAGS
9511   fi
9512   ;;
9513 *-*solaris*)
9514   # Find out what ABI is being produced by ac_compile, and set linker
9515   # options accordingly.
9516   echo 'int i;' > conftest.$ac_ext
9517   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9518   (eval $ac_compile) 2>&5
9519   ac_status=$?
9520   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9521   test $ac_status = 0; }; then
9522     case `/usr/bin/file conftest.o` in
9523     *64-bit*)
9524       case $lt_cv_prog_gnu_ld in
9525       yes*)
9526         case $host in
9527         i?86-*-solaris*|x86_64-*-solaris*)
9528           LD="${LD-ld} -m elf_x86_64"
9529           ;;
9530         sparc*-*-solaris*)
9531           LD="${LD-ld} -m elf64_sparc"
9532           ;;
9533         esac
9534         # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
9535         if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9536           LD=${LD-ld}_sol2
9537         fi
9538         ;;
9539       *)
9540         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9541           LD="${LD-ld} -64"
9542         fi
9543         ;;
9544       esac
9545       ;;
9546     esac
9547   fi
9548   rm -rf conftest*
9549   ;;
9550 esac
9551
9552 need_locks=$enable_libtool_lock
9553
9554 if test -n "$ac_tool_prefix"; then
9555   # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9556 set dummy ${ac_tool_prefix}mt; ac_word=$2
9557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9558 $as_echo_n "checking for $ac_word... " >&6; }
9559 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9560   $as_echo_n "(cached) " >&6
9561 else
9562   if test -n "$MANIFEST_TOOL"; then
9563   ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9564 else
9565 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9566 for as_dir in $PATH
9567 do
9568   IFS=$as_save_IFS
9569   test -z "$as_dir" && as_dir=.
9570     for ac_exec_ext in '' $ac_executable_extensions; do
9571   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9572     ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9573     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9574     break 2
9575   fi
9576 done
9577   done
9578 IFS=$as_save_IFS
9579
9580 fi
9581 fi
9582 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9583 if test -n "$MANIFEST_TOOL"; then
9584   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9585 $as_echo "$MANIFEST_TOOL" >&6; }
9586 else
9587   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9588 $as_echo "no" >&6; }
9589 fi
9590
9591
9592 fi
9593 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9594   ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9595   # Extract the first word of "mt", so it can be a program name with args.
9596 set dummy mt; ac_word=$2
9597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9598 $as_echo_n "checking for $ac_word... " >&6; }
9599 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9600   $as_echo_n "(cached) " >&6
9601 else
9602   if test -n "$ac_ct_MANIFEST_TOOL"; then
9603   ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9604 else
9605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9606 for as_dir in $PATH
9607 do
9608   IFS=$as_save_IFS
9609   test -z "$as_dir" && as_dir=.
9610     for ac_exec_ext in '' $ac_executable_extensions; do
9611   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9612     ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9613     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9614     break 2
9615   fi
9616 done
9617   done
9618 IFS=$as_save_IFS
9619
9620 fi
9621 fi
9622 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9623 if test -n "$ac_ct_MANIFEST_TOOL"; then
9624   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9625 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9626 else
9627   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9628 $as_echo "no" >&6; }
9629 fi
9630
9631   if test "x$ac_ct_MANIFEST_TOOL" = x; then
9632     MANIFEST_TOOL=":"
9633   else
9634     case $cross_compiling:$ac_tool_warned in
9635 yes:)
9636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9637 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9638 ac_tool_warned=yes ;;
9639 esac
9640     MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9641   fi
9642 else
9643   MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9644 fi
9645
9646 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9648 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9649 if ${lt_cv_path_mainfest_tool+:} false; then :
9650   $as_echo_n "(cached) " >&6
9651 else
9652   lt_cv_path_mainfest_tool=no
9653   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9654   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9655   cat conftest.err >&5
9656   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9657     lt_cv_path_mainfest_tool=yes
9658   fi
9659   rm -f conftest*
9660 fi
9661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9662 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
9663 if test yes != "$lt_cv_path_mainfest_tool"; then
9664   MANIFEST_TOOL=:
9665 fi
9666
9667
9668
9669
9670
9671
9672   case $host_os in
9673     rhapsody* | darwin*)
9674     if test -n "$ac_tool_prefix"; then
9675   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9676 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9678 $as_echo_n "checking for $ac_word... " >&6; }
9679 if ${ac_cv_prog_DSYMUTIL+:} false; then :
9680   $as_echo_n "(cached) " >&6
9681 else
9682   if test -n "$DSYMUTIL"; then
9683   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9684 else
9685 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9686 for as_dir in $PATH
9687 do
9688   IFS=$as_save_IFS
9689   test -z "$as_dir" && as_dir=.
9690     for ac_exec_ext in '' $ac_executable_extensions; do
9691   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9692     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9693     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9694     break 2
9695   fi
9696 done
9697   done
9698 IFS=$as_save_IFS
9699
9700 fi
9701 fi
9702 DSYMUTIL=$ac_cv_prog_DSYMUTIL
9703 if test -n "$DSYMUTIL"; then
9704   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9705 $as_echo "$DSYMUTIL" >&6; }
9706 else
9707   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9708 $as_echo "no" >&6; }
9709 fi
9710
9711
9712 fi
9713 if test -z "$ac_cv_prog_DSYMUTIL"; then
9714   ac_ct_DSYMUTIL=$DSYMUTIL
9715   # Extract the first word of "dsymutil", so it can be a program name with args.
9716 set dummy dsymutil; ac_word=$2
9717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9718 $as_echo_n "checking for $ac_word... " >&6; }
9719 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9720   $as_echo_n "(cached) " >&6
9721 else
9722   if test -n "$ac_ct_DSYMUTIL"; then
9723   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9724 else
9725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9726 for as_dir in $PATH
9727 do
9728   IFS=$as_save_IFS
9729   test -z "$as_dir" && as_dir=.
9730     for ac_exec_ext in '' $ac_executable_extensions; do
9731   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9732     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9733     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9734     break 2
9735   fi
9736 done
9737   done
9738 IFS=$as_save_IFS
9739
9740 fi
9741 fi
9742 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9743 if test -n "$ac_ct_DSYMUTIL"; then
9744   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9745 $as_echo "$ac_ct_DSYMUTIL" >&6; }
9746 else
9747   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9748 $as_echo "no" >&6; }
9749 fi
9750
9751   if test "x$ac_ct_DSYMUTIL" = x; then
9752     DSYMUTIL=":"
9753   else
9754     case $cross_compiling:$ac_tool_warned in
9755 yes:)
9756 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9757 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9758 ac_tool_warned=yes ;;
9759 esac
9760     DSYMUTIL=$ac_ct_DSYMUTIL
9761   fi
9762 else
9763   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9764 fi
9765
9766     if test -n "$ac_tool_prefix"; then
9767   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9768 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9770 $as_echo_n "checking for $ac_word... " >&6; }
9771 if ${ac_cv_prog_NMEDIT+:} false; then :
9772   $as_echo_n "(cached) " >&6
9773 else
9774   if test -n "$NMEDIT"; then
9775   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9776 else
9777 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9778 for as_dir in $PATH
9779 do
9780   IFS=$as_save_IFS
9781   test -z "$as_dir" && as_dir=.
9782     for ac_exec_ext in '' $ac_executable_extensions; do
9783   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9784     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9785     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9786     break 2
9787   fi
9788 done
9789   done
9790 IFS=$as_save_IFS
9791
9792 fi
9793 fi
9794 NMEDIT=$ac_cv_prog_NMEDIT
9795 if test -n "$NMEDIT"; then
9796   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9797 $as_echo "$NMEDIT" >&6; }
9798 else
9799   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9800 $as_echo "no" >&6; }
9801 fi
9802
9803
9804 fi
9805 if test -z "$ac_cv_prog_NMEDIT"; then
9806   ac_ct_NMEDIT=$NMEDIT
9807   # Extract the first word of "nmedit", so it can be a program name with args.
9808 set dummy nmedit; ac_word=$2
9809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9810 $as_echo_n "checking for $ac_word... " >&6; }
9811 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9812   $as_echo_n "(cached) " >&6
9813 else
9814   if test -n "$ac_ct_NMEDIT"; then
9815   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9816 else
9817 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9818 for as_dir in $PATH
9819 do
9820   IFS=$as_save_IFS
9821   test -z "$as_dir" && as_dir=.
9822     for ac_exec_ext in '' $ac_executable_extensions; do
9823   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9824     ac_cv_prog_ac_ct_NMEDIT="nmedit"
9825     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9826     break 2
9827   fi
9828 done
9829   done
9830 IFS=$as_save_IFS
9831
9832 fi
9833 fi
9834 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9835 if test -n "$ac_ct_NMEDIT"; then
9836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9837 $as_echo "$ac_ct_NMEDIT" >&6; }
9838 else
9839   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9840 $as_echo "no" >&6; }
9841 fi
9842
9843   if test "x$ac_ct_NMEDIT" = x; then
9844     NMEDIT=":"
9845   else
9846     case $cross_compiling:$ac_tool_warned in
9847 yes:)
9848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9849 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9850 ac_tool_warned=yes ;;
9851 esac
9852     NMEDIT=$ac_ct_NMEDIT
9853   fi
9854 else
9855   NMEDIT="$ac_cv_prog_NMEDIT"
9856 fi
9857
9858     if test -n "$ac_tool_prefix"; then
9859   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9860 set dummy ${ac_tool_prefix}lipo; ac_word=$2
9861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9862 $as_echo_n "checking for $ac_word... " >&6; }
9863 if ${ac_cv_prog_LIPO+:} false; then :
9864   $as_echo_n "(cached) " >&6
9865 else
9866   if test -n "$LIPO"; then
9867   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9868 else
9869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9870 for as_dir in $PATH
9871 do
9872   IFS=$as_save_IFS
9873   test -z "$as_dir" && as_dir=.
9874     for ac_exec_ext in '' $ac_executable_extensions; do
9875   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9876     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9877     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9878     break 2
9879   fi
9880 done
9881   done
9882 IFS=$as_save_IFS
9883
9884 fi
9885 fi
9886 LIPO=$ac_cv_prog_LIPO
9887 if test -n "$LIPO"; then
9888   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9889 $as_echo "$LIPO" >&6; }
9890 else
9891   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9892 $as_echo "no" >&6; }
9893 fi
9894
9895
9896 fi
9897 if test -z "$ac_cv_prog_LIPO"; then
9898   ac_ct_LIPO=$LIPO
9899   # Extract the first word of "lipo", so it can be a program name with args.
9900 set dummy lipo; ac_word=$2
9901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9902 $as_echo_n "checking for $ac_word... " >&6; }
9903 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9904   $as_echo_n "(cached) " >&6
9905 else
9906   if test -n "$ac_ct_LIPO"; then
9907   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9908 else
9909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9910 for as_dir in $PATH
9911 do
9912   IFS=$as_save_IFS
9913   test -z "$as_dir" && as_dir=.
9914     for ac_exec_ext in '' $ac_executable_extensions; do
9915   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9916     ac_cv_prog_ac_ct_LIPO="lipo"
9917     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9918     break 2
9919   fi
9920 done
9921   done
9922 IFS=$as_save_IFS
9923
9924 fi
9925 fi
9926 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9927 if test -n "$ac_ct_LIPO"; then
9928   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9929 $as_echo "$ac_ct_LIPO" >&6; }
9930 else
9931   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9932 $as_echo "no" >&6; }
9933 fi
9934
9935   if test "x$ac_ct_LIPO" = x; then
9936     LIPO=":"
9937   else
9938     case $cross_compiling:$ac_tool_warned in
9939 yes:)
9940 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9941 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9942 ac_tool_warned=yes ;;
9943 esac
9944     LIPO=$ac_ct_LIPO
9945   fi
9946 else
9947   LIPO="$ac_cv_prog_LIPO"
9948 fi
9949
9950     if test -n "$ac_tool_prefix"; then
9951   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9952 set dummy ${ac_tool_prefix}otool; ac_word=$2
9953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9954 $as_echo_n "checking for $ac_word... " >&6; }
9955 if ${ac_cv_prog_OTOOL+:} false; then :
9956   $as_echo_n "(cached) " >&6
9957 else
9958   if test -n "$OTOOL"; then
9959   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9960 else
9961 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9962 for as_dir in $PATH
9963 do
9964   IFS=$as_save_IFS
9965   test -z "$as_dir" && as_dir=.
9966     for ac_exec_ext in '' $ac_executable_extensions; do
9967   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9968     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9969     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9970     break 2
9971   fi
9972 done
9973   done
9974 IFS=$as_save_IFS
9975
9976 fi
9977 fi
9978 OTOOL=$ac_cv_prog_OTOOL
9979 if test -n "$OTOOL"; then
9980   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9981 $as_echo "$OTOOL" >&6; }
9982 else
9983   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9984 $as_echo "no" >&6; }
9985 fi
9986
9987
9988 fi
9989 if test -z "$ac_cv_prog_OTOOL"; then
9990   ac_ct_OTOOL=$OTOOL
9991   # Extract the first word of "otool", so it can be a program name with args.
9992 set dummy otool; ac_word=$2
9993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9994 $as_echo_n "checking for $ac_word... " >&6; }
9995 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
9996   $as_echo_n "(cached) " >&6
9997 else
9998   if test -n "$ac_ct_OTOOL"; then
9999   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
10000 else
10001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10002 for as_dir in $PATH
10003 do
10004   IFS=$as_save_IFS
10005   test -z "$as_dir" && as_dir=.
10006     for ac_exec_ext in '' $ac_executable_extensions; do
10007   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10008     ac_cv_prog_ac_ct_OTOOL="otool"
10009     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10010     break 2
10011   fi
10012 done
10013   done
10014 IFS=$as_save_IFS
10015
10016 fi
10017 fi
10018 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
10019 if test -n "$ac_ct_OTOOL"; then
10020   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
10021 $as_echo "$ac_ct_OTOOL" >&6; }
10022 else
10023   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10024 $as_echo "no" >&6; }
10025 fi
10026
10027   if test "x$ac_ct_OTOOL" = x; then
10028     OTOOL=":"
10029   else
10030     case $cross_compiling:$ac_tool_warned in
10031 yes:)
10032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10033 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10034 ac_tool_warned=yes ;;
10035 esac
10036     OTOOL=$ac_ct_OTOOL
10037   fi
10038 else
10039   OTOOL="$ac_cv_prog_OTOOL"
10040 fi
10041
10042     if test -n "$ac_tool_prefix"; then
10043   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
10044 set dummy ${ac_tool_prefix}otool64; ac_word=$2
10045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10046 $as_echo_n "checking for $ac_word... " >&6; }
10047 if ${ac_cv_prog_OTOOL64+:} false; then :
10048   $as_echo_n "(cached) " >&6
10049 else
10050   if test -n "$OTOOL64"; then
10051   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10052 else
10053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10054 for as_dir in $PATH
10055 do
10056   IFS=$as_save_IFS
10057   test -z "$as_dir" && as_dir=.
10058     for ac_exec_ext in '' $ac_executable_extensions; do
10059   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10060     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10061     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10062     break 2
10063   fi
10064 done
10065   done
10066 IFS=$as_save_IFS
10067
10068 fi
10069 fi
10070 OTOOL64=$ac_cv_prog_OTOOL64
10071 if test -n "$OTOOL64"; then
10072   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10073 $as_echo "$OTOOL64" >&6; }
10074 else
10075   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10076 $as_echo "no" >&6; }
10077 fi
10078
10079
10080 fi
10081 if test -z "$ac_cv_prog_OTOOL64"; then
10082   ac_ct_OTOOL64=$OTOOL64
10083   # Extract the first word of "otool64", so it can be a program name with args.
10084 set dummy otool64; ac_word=$2
10085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10086 $as_echo_n "checking for $ac_word... " >&6; }
10087 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10088   $as_echo_n "(cached) " >&6
10089 else
10090   if test -n "$ac_ct_OTOOL64"; then
10091   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10092 else
10093 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10094 for as_dir in $PATH
10095 do
10096   IFS=$as_save_IFS
10097   test -z "$as_dir" && as_dir=.
10098     for ac_exec_ext in '' $ac_executable_extensions; do
10099   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10100     ac_cv_prog_ac_ct_OTOOL64="otool64"
10101     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10102     break 2
10103   fi
10104 done
10105   done
10106 IFS=$as_save_IFS
10107
10108 fi
10109 fi
10110 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10111 if test -n "$ac_ct_OTOOL64"; then
10112   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10113 $as_echo "$ac_ct_OTOOL64" >&6; }
10114 else
10115   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10116 $as_echo "no" >&6; }
10117 fi
10118
10119   if test "x$ac_ct_OTOOL64" = x; then
10120     OTOOL64=":"
10121   else
10122     case $cross_compiling:$ac_tool_warned in
10123 yes:)
10124 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10125 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10126 ac_tool_warned=yes ;;
10127 esac
10128     OTOOL64=$ac_ct_OTOOL64
10129   fi
10130 else
10131   OTOOL64="$ac_cv_prog_OTOOL64"
10132 fi
10133
10134
10135
10136
10137
10138
10139
10140
10141
10142
10143
10144
10145
10146
10147
10148
10149
10150
10151
10152
10153
10154
10155
10156
10157
10158
10159
10160     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10161 $as_echo_n "checking for -single_module linker flag... " >&6; }
10162 if ${lt_cv_apple_cc_single_mod+:} false; then :
10163   $as_echo_n "(cached) " >&6
10164 else
10165   lt_cv_apple_cc_single_mod=no
10166       if test -z "$LT_MULTI_MODULE"; then
10167         # By default we will add the -single_module flag. You can override
10168         # by either setting the environment variable LT_MULTI_MODULE
10169         # non-empty at configure time, or by adding -multi_module to the
10170         # link flags.
10171         rm -rf libconftest.dylib*
10172         echo "int foo(void){return 1;}" > conftest.c
10173         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10174 -dynamiclib -Wl,-single_module conftest.c" >&5
10175         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10176           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10177         _lt_result=$?
10178         # If there is a non-empty error log, and "single_module"
10179         # appears in it, assume the flag caused a linker warning
10180         if test -s conftest.err && $GREP single_module conftest.err; then
10181           cat conftest.err >&5
10182         # Otherwise, if the output was created with a 0 exit code from
10183         # the compiler, it worked.
10184         elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10185           lt_cv_apple_cc_single_mod=yes
10186         else
10187           cat conftest.err >&5
10188         fi
10189         rm -rf libconftest.dylib*
10190         rm -f conftest.*
10191       fi
10192 fi
10193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10194 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10195
10196     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10197 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10198 if ${lt_cv_ld_exported_symbols_list+:} false; then :
10199   $as_echo_n "(cached) " >&6
10200 else
10201   lt_cv_ld_exported_symbols_list=no
10202       save_LDFLAGS=$LDFLAGS
10203       echo "_main" > conftest.sym
10204       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10205       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10206 /* end confdefs.h.  */
10207
10208 int
10209 main ()
10210 {
10211
10212   ;
10213   return 0;
10214 }
10215 _ACEOF
10216 if ac_fn_c_try_link "$LINENO"; then :
10217   lt_cv_ld_exported_symbols_list=yes
10218 else
10219   lt_cv_ld_exported_symbols_list=no
10220 fi
10221 rm -f core conftest.err conftest.$ac_objext \
10222     conftest$ac_exeext conftest.$ac_ext
10223         LDFLAGS=$save_LDFLAGS
10224
10225 fi
10226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10227 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10228
10229     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10230 $as_echo_n "checking for -force_load linker flag... " >&6; }
10231 if ${lt_cv_ld_force_load+:} false; then :
10232   $as_echo_n "(cached) " >&6
10233 else
10234   lt_cv_ld_force_load=no
10235       cat > conftest.c << _LT_EOF
10236 int forced_loaded() { return 2;}
10237 _LT_EOF
10238       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10239       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10240       echo "$AR cru libconftest.a conftest.o" >&5
10241       $AR cru libconftest.a conftest.o 2>&5
10242       echo "$RANLIB libconftest.a" >&5
10243       $RANLIB libconftest.a 2>&5
10244       cat > conftest.c << _LT_EOF
10245 int main() { return 0;}
10246 _LT_EOF
10247       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10248       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10249       _lt_result=$?
10250       if test -s conftest.err && $GREP force_load conftest.err; then
10251         cat conftest.err >&5
10252       elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10253         lt_cv_ld_force_load=yes
10254       else
10255         cat conftest.err >&5
10256       fi
10257         rm -f conftest.err libconftest.a conftest conftest.c
10258         rm -rf conftest.dSYM
10259
10260 fi
10261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10262 $as_echo "$lt_cv_ld_force_load" >&6; }
10263     case $host_os in
10264     rhapsody* | darwin1.[012])
10265       _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10266     darwin1.*)
10267       _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10268     darwin*) # darwin 5.x on
10269       # if running on 10.5 or later, the deployment target defaults
10270       # to the OS version, if on x86, and 10.4, the deployment
10271       # target defaults to 10.4. Don't you love it?
10272       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10273         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10274           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10275         10.[012][,.]*)
10276           _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10277         10.*)
10278           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10279       esac
10280     ;;
10281   esac
10282     if test yes = "$lt_cv_apple_cc_single_mod"; then
10283       _lt_dar_single_mod='$single_module'
10284     fi
10285     if test yes = "$lt_cv_ld_exported_symbols_list"; then
10286       _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10287     else
10288       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10289     fi
10290     if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10291       _lt_dsymutil='~$DSYMUTIL $lib || :'
10292     else
10293       _lt_dsymutil=
10294     fi
10295     ;;
10296   esac
10297
10298 # func_munge_path_list VARIABLE PATH
10299 # -----------------------------------
10300 # VARIABLE is name of variable containing _space_ separated list of
10301 # directories to be munged by the contents of PATH, which is string
10302 # having a format:
10303 # "DIR[:DIR]:"
10304 #       string "DIR[ DIR]" will be prepended to VARIABLE
10305 # ":DIR[:DIR]"
10306 #       string "DIR[ DIR]" will be appended to VARIABLE
10307 # "DIRP[:DIRP]::[DIRA:]DIRA"
10308 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10309 #       "DIRA[ DIRA]" will be appended to VARIABLE
10310 # "DIR[:DIR]"
10311 #       VARIABLE will be replaced by "DIR[ DIR]"
10312 func_munge_path_list ()
10313 {
10314     case x$2 in
10315     x)
10316         ;;
10317     *:)
10318         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10319         ;;
10320     x:*)
10321         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10322         ;;
10323     *::*)
10324         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10325         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10326         ;;
10327     *)
10328         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10329         ;;
10330     esac
10331 }
10332
10333 for ac_header in dlfcn.h
10334 do :
10335   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10336 "
10337 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10338   cat >>confdefs.h <<_ACEOF
10339 #define HAVE_DLFCN_H 1
10340 _ACEOF
10341
10342 fi
10343
10344 done
10345
10346
10347
10348
10349
10350
10351
10352 # Set options
10353
10354
10355
10356         enable_dlopen=no
10357
10358
10359   enable_win32_dll=no
10360
10361
10362             # Check whether --enable-shared was given.
10363 if test "${enable_shared+set}" = set; then :
10364   enableval=$enable_shared; p=${PACKAGE-default}
10365     case $enableval in
10366     yes) enable_shared=yes ;;
10367     no) enable_shared=no ;;
10368     *)
10369       enable_shared=no
10370       # Look at the argument we got.  We use all the common list separators.
10371       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10372       for pkg in $enableval; do
10373         IFS=$lt_save_ifs
10374         if test "X$pkg" = "X$p"; then
10375           enable_shared=yes
10376         fi
10377       done
10378       IFS=$lt_save_ifs
10379       ;;
10380     esac
10381 else
10382   enable_shared=yes
10383 fi
10384
10385
10386
10387
10388
10389
10390
10391
10392
10393   # Check whether --enable-static was given.
10394 if test "${enable_static+set}" = set; then :
10395   enableval=$enable_static; p=${PACKAGE-default}
10396     case $enableval in
10397     yes) enable_static=yes ;;
10398     no) enable_static=no ;;
10399     *)
10400      enable_static=no
10401       # Look at the argument we got.  We use all the common list separators.
10402       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10403       for pkg in $enableval; do
10404         IFS=$lt_save_ifs
10405         if test "X$pkg" = "X$p"; then
10406           enable_static=yes
10407         fi
10408       done
10409       IFS=$lt_save_ifs
10410       ;;
10411     esac
10412 else
10413   enable_static=yes
10414 fi
10415
10416
10417
10418
10419
10420
10421
10422
10423
10424
10425 # Check whether --with-pic was given.
10426 if test "${with_pic+set}" = set; then :
10427   withval=$with_pic; lt_p=${PACKAGE-default}
10428     case $withval in
10429     yes|no) pic_mode=$withval ;;
10430     *)
10431       pic_mode=default
10432       # Look at the argument we got.  We use all the common list separators.
10433       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10434       for lt_pkg in $withval; do
10435         IFS=$lt_save_ifs
10436         if test "X$lt_pkg" = "X$lt_p"; then
10437           pic_mode=yes
10438         fi
10439       done
10440       IFS=$lt_save_ifs
10441       ;;
10442     esac
10443 else
10444   pic_mode=default
10445 fi
10446
10447
10448
10449
10450
10451
10452
10453
10454   # Check whether --enable-fast-install was given.
10455 if test "${enable_fast_install+set}" = set; then :
10456   enableval=$enable_fast_install; p=${PACKAGE-default}
10457     case $enableval in
10458     yes) enable_fast_install=yes ;;
10459     no) enable_fast_install=no ;;
10460     *)
10461       enable_fast_install=no
10462       # Look at the argument we got.  We use all the common list separators.
10463       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10464       for pkg in $enableval; do
10465         IFS=$lt_save_ifs
10466         if test "X$pkg" = "X$p"; then
10467           enable_fast_install=yes
10468         fi
10469       done
10470       IFS=$lt_save_ifs
10471       ;;
10472     esac
10473 else
10474   enable_fast_install=yes
10475 fi
10476
10477
10478
10479
10480
10481
10482
10483
10484   shared_archive_member_spec=
10485 case $host,$enable_shared in
10486 power*-*-aix[5-9]*,yes)
10487   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
10488 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
10489
10490 # Check whether --with-aix-soname was given.
10491 if test "${with_aix_soname+set}" = set; then :
10492   withval=$with_aix_soname; case $withval in
10493     aix|svr4|both)
10494       ;;
10495     *)
10496       as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
10497       ;;
10498     esac
10499     lt_cv_with_aix_soname=$with_aix_soname
10500 else
10501   if ${lt_cv_with_aix_soname+:} false; then :
10502   $as_echo_n "(cached) " >&6
10503 else
10504   lt_cv_with_aix_soname=aix
10505 fi
10506
10507     with_aix_soname=$lt_cv_with_aix_soname
10508 fi
10509
10510   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
10511 $as_echo "$with_aix_soname" >&6; }
10512   if test aix != "$with_aix_soname"; then
10513     # For the AIX way of multilib, we name the shared archive member
10514     # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
10515     # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
10516     # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
10517     # the AIX toolchain works better with OBJECT_MODE set (default 32).
10518     if test 64 = "${OBJECT_MODE-32}"; then
10519       shared_archive_member_spec=shr_64
10520     else
10521       shared_archive_member_spec=shr
10522     fi
10523   fi
10524   ;;
10525 *)
10526   with_aix_soname=aix
10527   ;;
10528 esac
10529
10530
10531
10532
10533
10534
10535
10536
10537
10538
10539 # This can be used to rebuild libtool when needed
10540 LIBTOOL_DEPS=$ltmain
10541
10542 # Always use our own libtool.
10543 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10544
10545
10546
10547
10548
10549
10550
10551
10552
10553
10554
10555
10556
10557
10558
10559
10560
10561
10562
10563
10564
10565
10566
10567
10568
10569
10570
10571
10572
10573
10574 test -z "$LN_S" && LN_S="ln -s"
10575
10576
10577
10578
10579
10580
10581
10582
10583
10584
10585
10586
10587
10588
10589 if test -n "${ZSH_VERSION+set}"; then
10590    setopt NO_GLOB_SUBST
10591 fi
10592
10593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10594 $as_echo_n "checking for objdir... " >&6; }
10595 if ${lt_cv_objdir+:} false; then :
10596   $as_echo_n "(cached) " >&6
10597 else
10598   rm -f .libs 2>/dev/null
10599 mkdir .libs 2>/dev/null
10600 if test -d .libs; then
10601   lt_cv_objdir=.libs
10602 else
10603   # MS-DOS does not allow filenames that begin with a dot.
10604   lt_cv_objdir=_libs
10605 fi
10606 rmdir .libs 2>/dev/null
10607 fi
10608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10609 $as_echo "$lt_cv_objdir" >&6; }
10610 objdir=$lt_cv_objdir
10611
10612
10613
10614
10615
10616 cat >>confdefs.h <<_ACEOF
10617 #define LT_OBJDIR "$lt_cv_objdir/"
10618 _ACEOF
10619
10620
10621
10622
10623 case $host_os in
10624 aix3*)
10625   # AIX sometimes has problems with the GCC collect2 program.  For some
10626   # reason, if we set the COLLECT_NAMES environment variable, the problems
10627   # vanish in a puff of smoke.
10628   if test set != "${COLLECT_NAMES+set}"; then
10629     COLLECT_NAMES=
10630     export COLLECT_NAMES
10631   fi
10632   ;;
10633 esac
10634
10635 # Global variables:
10636 ofile=libtool
10637 can_build_shared=yes
10638
10639 # All known linkers require a '.a' archive for static linking (except MSVC,
10640 # which needs '.lib').
10641 libext=a
10642
10643 with_gnu_ld=$lt_cv_prog_gnu_ld
10644
10645 old_CC=$CC
10646 old_CFLAGS=$CFLAGS
10647
10648 # Set sane defaults for various variables
10649 test -z "$CC" && CC=cc
10650 test -z "$LTCC" && LTCC=$CC
10651 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10652 test -z "$LD" && LD=ld
10653 test -z "$ac_objext" && ac_objext=o
10654
10655 func_cc_basename $compiler
10656 cc_basename=$func_cc_basename_result
10657
10658
10659 # Only perform the check for file, if the check method requires it
10660 test -z "$MAGIC_CMD" && MAGIC_CMD=file
10661 case $deplibs_check_method in
10662 file_magic*)
10663   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10664     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10665 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10666 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10667   $as_echo_n "(cached) " >&6
10668 else
10669   case $MAGIC_CMD in
10670 [\\/*] |  ?:[\\/]*)
10671   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10672   ;;
10673 *)
10674   lt_save_MAGIC_CMD=$MAGIC_CMD
10675   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10676   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10677   for ac_dir in $ac_dummy; do
10678     IFS=$lt_save_ifs
10679     test -z "$ac_dir" && ac_dir=.
10680     if test -f "$ac_dir/${ac_tool_prefix}file"; then
10681       lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
10682       if test -n "$file_magic_test_file"; then
10683         case $deplibs_check_method in
10684         "file_magic "*)
10685           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10686           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10687           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10688             $EGREP "$file_magic_regex" > /dev/null; then
10689             :
10690           else
10691             cat <<_LT_EOF 1>&2
10692
10693 *** Warning: the command libtool uses to detect shared libraries,
10694 *** $file_magic_cmd, produces output that libtool cannot recognize.
10695 *** The result is that libtool may fail to recognize shared libraries
10696 *** as such.  This will affect the creation of libtool libraries that
10697 *** depend on shared libraries, but programs linked with such libtool
10698 *** libraries will work regardless of this problem.  Nevertheless, you
10699 *** may want to report the problem to your system manager and/or to
10700 *** bug-libtool@gnu.org
10701
10702 _LT_EOF
10703           fi ;;
10704         esac
10705       fi
10706       break
10707     fi
10708   done
10709   IFS=$lt_save_ifs
10710   MAGIC_CMD=$lt_save_MAGIC_CMD
10711   ;;
10712 esac
10713 fi
10714
10715 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10716 if test -n "$MAGIC_CMD"; then
10717   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10718 $as_echo "$MAGIC_CMD" >&6; }
10719 else
10720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10721 $as_echo "no" >&6; }
10722 fi
10723
10724
10725
10726
10727
10728 if test -z "$lt_cv_path_MAGIC_CMD"; then
10729   if test -n "$ac_tool_prefix"; then
10730     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10731 $as_echo_n "checking for file... " >&6; }
10732 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10733   $as_echo_n "(cached) " >&6
10734 else
10735   case $MAGIC_CMD in
10736 [\\/*] |  ?:[\\/]*)
10737   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10738   ;;
10739 *)
10740   lt_save_MAGIC_CMD=$MAGIC_CMD
10741   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10742   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10743   for ac_dir in $ac_dummy; do
10744     IFS=$lt_save_ifs
10745     test -z "$ac_dir" && ac_dir=.
10746     if test -f "$ac_dir/file"; then
10747       lt_cv_path_MAGIC_CMD=$ac_dir/"file"
10748       if test -n "$file_magic_test_file"; then
10749         case $deplibs_check_method in
10750         "file_magic "*)
10751           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10752           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10753           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10754             $EGREP "$file_magic_regex" > /dev/null; then
10755             :
10756           else
10757             cat <<_LT_EOF 1>&2
10758
10759 *** Warning: the command libtool uses to detect shared libraries,
10760 *** $file_magic_cmd, produces output that libtool cannot recognize.
10761 *** The result is that libtool may fail to recognize shared libraries
10762 *** as such.  This will affect the creation of libtool libraries that
10763 *** depend on shared libraries, but programs linked with such libtool
10764 *** libraries will work regardless of this problem.  Nevertheless, you
10765 *** may want to report the problem to your system manager and/or to
10766 *** bug-libtool@gnu.org
10767
10768 _LT_EOF
10769           fi ;;
10770         esac
10771       fi
10772       break
10773     fi
10774   done
10775   IFS=$lt_save_ifs
10776   MAGIC_CMD=$lt_save_MAGIC_CMD
10777   ;;
10778 esac
10779 fi
10780
10781 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10782 if test -n "$MAGIC_CMD"; then
10783   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10784 $as_echo "$MAGIC_CMD" >&6; }
10785 else
10786   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10787 $as_echo "no" >&6; }
10788 fi
10789
10790
10791   else
10792     MAGIC_CMD=:
10793   fi
10794 fi
10795
10796   fi
10797   ;;
10798 esac
10799
10800 # Use C for the default configuration in the libtool script
10801
10802 lt_save_CC=$CC
10803 ac_ext=c
10804 ac_cpp='$CPP $CPPFLAGS'
10805 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10806 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10807 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10808
10809
10810 # Source file extension for C test sources.
10811 ac_ext=c
10812
10813 # Object file extension for compiled C test sources.
10814 objext=o
10815 objext=$objext
10816
10817 # Code to be used in simple compile tests
10818 lt_simple_compile_test_code="int some_variable = 0;"
10819
10820 # Code to be used in simple link tests
10821 lt_simple_link_test_code='int main(){return(0);}'
10822
10823
10824
10825
10826
10827
10828
10829 # If no C compiler was specified, use CC.
10830 LTCC=${LTCC-"$CC"}
10831
10832 # If no C compiler flags were specified, use CFLAGS.
10833 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10834
10835 # Allow CC to be a program name with arguments.
10836 compiler=$CC
10837
10838 # Save the default compiler, since it gets overwritten when the other
10839 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10840 compiler_DEFAULT=$CC
10841
10842 # save warnings/boilerplate of simple test code
10843 ac_outfile=conftest.$ac_objext
10844 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10845 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10846 _lt_compiler_boilerplate=`cat conftest.err`
10847 $RM conftest*
10848
10849 ac_outfile=conftest.$ac_objext
10850 echo "$lt_simple_link_test_code" >conftest.$ac_ext
10851 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10852 _lt_linker_boilerplate=`cat conftest.err`
10853 $RM -r conftest*
10854
10855
10856 if test -n "$compiler"; then
10857
10858 lt_prog_compiler_no_builtin_flag=
10859
10860 if test yes = "$GCC"; then
10861   case $cc_basename in
10862   nvcc*)
10863     lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10864   *)
10865     lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10866   esac
10867
10868   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10869 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10870 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10871   $as_echo_n "(cached) " >&6
10872 else
10873   lt_cv_prog_compiler_rtti_exceptions=no
10874    ac_outfile=conftest.$ac_objext
10875    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10876    lt_compiler_flag="-fno-rtti -fno-exceptions"  ## exclude from sc_useless_quotes_in_assignment
10877    # Insert the option either (1) after the last *FLAGS variable, or
10878    # (2) before a word containing "conftest.", or (3) at the end.
10879    # Note that $ac_compile itself does not contain backslashes and begins
10880    # with a dollar sign (not a hyphen), so the echo should work correctly.
10881    # The option is referenced via a variable to avoid confusing sed.
10882    lt_compile=`echo "$ac_compile" | $SED \
10883    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10884    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10885    -e 's:$: $lt_compiler_flag:'`
10886    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10887    (eval "$lt_compile" 2>conftest.err)
10888    ac_status=$?
10889    cat conftest.err >&5
10890    echo "$as_me:$LINENO: \$? = $ac_status" >&5
10891    if (exit $ac_status) && test -s "$ac_outfile"; then
10892      # The compiler can only warn and ignore the option if not recognized
10893      # So say no if there are warnings other than the usual output.
10894      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10895      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10896      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10897        lt_cv_prog_compiler_rtti_exceptions=yes
10898      fi
10899    fi
10900    $RM conftest*
10901
10902 fi
10903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10904 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10905
10906 if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
10907     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10908 else
10909     :
10910 fi
10911
10912 fi
10913
10914
10915
10916
10917
10918
10919   lt_prog_compiler_wl=
10920 lt_prog_compiler_pic=
10921 lt_prog_compiler_static=
10922
10923
10924   if test yes = "$GCC"; then
10925     lt_prog_compiler_wl='-Wl,'
10926     lt_prog_compiler_static='-static'
10927
10928     case $host_os in
10929       aix*)
10930       # All AIX code is PIC.
10931       if test ia64 = "$host_cpu"; then
10932         # AIX 5 now supports IA64 processor
10933         lt_prog_compiler_static='-Bstatic'
10934       fi
10935       lt_prog_compiler_pic='-fPIC'
10936       ;;
10937
10938     amigaos*)
10939       case $host_cpu in
10940       powerpc)
10941             # see comment about AmigaOS4 .so support
10942             lt_prog_compiler_pic='-fPIC'
10943         ;;
10944       m68k)
10945             # FIXME: we need at least 68020 code to build shared libraries, but
10946             # adding the '-m68020' flag to GCC prevents building anything better,
10947             # like '-m68040'.
10948             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10949         ;;
10950       esac
10951       ;;
10952
10953     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10954       # PIC is the default for these OSes.
10955       ;;
10956
10957     mingw* | cygwin* | pw32* | os2* | cegcc*)
10958       # This hack is so that the source file can tell whether it is being
10959       # built for inclusion in a dll (and should export symbols for example).
10960       # Although the cygwin gcc ignores -fPIC, still need this for old-style
10961       # (--disable-auto-import) libraries
10962       lt_prog_compiler_pic='-DDLL_EXPORT'
10963       case $host_os in
10964       os2*)
10965         lt_prog_compiler_static='$wl-static'
10966         ;;
10967       esac
10968       ;;
10969
10970     darwin* | rhapsody*)
10971       # PIC is the default on this platform
10972       # Common symbols not allowed in MH_DYLIB files
10973       lt_prog_compiler_pic='-fno-common'
10974       ;;
10975
10976     haiku*)
10977       # PIC is the default for Haiku.
10978       # The "-static" flag exists, but is broken.
10979       lt_prog_compiler_static=
10980       ;;
10981
10982     hpux*)
10983       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10984       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
10985       # sets the default TLS model and affects inlining.
10986       case $host_cpu in
10987       hppa*64*)
10988         # +Z the default
10989         ;;
10990       *)
10991         lt_prog_compiler_pic='-fPIC'
10992         ;;
10993       esac
10994       ;;
10995
10996     interix[3-9]*)
10997       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
10998       # Instead, we relocate shared libraries at runtime.
10999       ;;
11000
11001     msdosdjgpp*)
11002       # Just because we use GCC doesn't mean we suddenly get shared libraries
11003       # on systems that don't support them.
11004       lt_prog_compiler_can_build_shared=no
11005       enable_shared=no
11006       ;;
11007
11008     *nto* | *qnx*)
11009       # QNX uses GNU C++, but need to define -shared option too, otherwise
11010       # it will coredump.
11011       lt_prog_compiler_pic='-fPIC -shared'
11012       ;;
11013
11014     sysv4*MP*)
11015       if test -d /usr/nec; then
11016         lt_prog_compiler_pic=-Kconform_pic
11017       fi
11018       ;;
11019
11020     *)
11021       lt_prog_compiler_pic='-fPIC'
11022       ;;
11023     esac
11024
11025     case $cc_basename in
11026     nvcc*) # Cuda Compiler Driver 2.2
11027       lt_prog_compiler_wl='-Xlinker '
11028       if test -n "$lt_prog_compiler_pic"; then
11029         lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
11030       fi
11031       ;;
11032     esac
11033   else
11034     # PORTME Check for flag to pass linker flags through the system compiler.
11035     case $host_os in
11036     aix*)
11037       lt_prog_compiler_wl='-Wl,'
11038       if test ia64 = "$host_cpu"; then
11039         # AIX 5 now supports IA64 processor
11040         lt_prog_compiler_static='-Bstatic'
11041       else
11042         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
11043       fi
11044       ;;
11045
11046     darwin* | rhapsody*)
11047       # PIC is the default on this platform
11048       # Common symbols not allowed in MH_DYLIB files
11049       lt_prog_compiler_pic='-fno-common'
11050       case $cc_basename in
11051       nagfor*)
11052         # NAG Fortran compiler
11053         lt_prog_compiler_wl='-Wl,-Wl,,'
11054         lt_prog_compiler_pic='-PIC'
11055         lt_prog_compiler_static='-Bstatic'
11056         ;;
11057       esac
11058       ;;
11059
11060     mingw* | cygwin* | pw32* | os2* | cegcc*)
11061       # This hack is so that the source file can tell whether it is being
11062       # built for inclusion in a dll (and should export symbols for example).
11063       lt_prog_compiler_pic='-DDLL_EXPORT'
11064       case $host_os in
11065       os2*)
11066         lt_prog_compiler_static='$wl-static'
11067         ;;
11068       esac
11069       ;;
11070
11071     hpux9* | hpux10* | hpux11*)
11072       lt_prog_compiler_wl='-Wl,'
11073       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11074       # not for PA HP-UX.
11075       case $host_cpu in
11076       hppa*64*|ia64*)
11077         # +Z the default
11078         ;;
11079       *)
11080         lt_prog_compiler_pic='+Z'
11081         ;;
11082       esac
11083       # Is there a better lt_prog_compiler_static that works with the bundled CC?
11084       lt_prog_compiler_static='$wl-a ${wl}archive'
11085       ;;
11086
11087     irix5* | irix6* | nonstopux*)
11088       lt_prog_compiler_wl='-Wl,'
11089       # PIC (with -KPIC) is the default.
11090       lt_prog_compiler_static='-non_shared'
11091       ;;
11092
11093     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11094       case $cc_basename in
11095       # old Intel for x86_64, which still supported -KPIC.
11096       ecc*)
11097         lt_prog_compiler_wl='-Wl,'
11098         lt_prog_compiler_pic='-KPIC'
11099         lt_prog_compiler_static='-static'
11100         ;;
11101       # icc used to be incompatible with GCC.
11102       # ICC 10 doesn't accept -KPIC any more.
11103       icc* | ifort*)
11104         lt_prog_compiler_wl='-Wl,'
11105         lt_prog_compiler_pic='-fPIC'
11106         lt_prog_compiler_static='-static'
11107         ;;
11108       # Lahey Fortran 8.1.
11109       lf95*)
11110         lt_prog_compiler_wl='-Wl,'
11111         lt_prog_compiler_pic='--shared'
11112         lt_prog_compiler_static='--static'
11113         ;;
11114       nagfor*)
11115         # NAG Fortran compiler
11116         lt_prog_compiler_wl='-Wl,-Wl,,'
11117         lt_prog_compiler_pic='-PIC'
11118         lt_prog_compiler_static='-Bstatic'
11119         ;;
11120       tcc*)
11121         # Fabrice Bellard et al's Tiny C Compiler
11122         lt_prog_compiler_wl='-Wl,'
11123         lt_prog_compiler_pic='-fPIC'
11124         lt_prog_compiler_static='-static'
11125         ;;
11126       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11127         # Portland Group compilers (*not* the Pentium gcc compiler,
11128         # which looks to be a dead project)
11129         lt_prog_compiler_wl='-Wl,'
11130         lt_prog_compiler_pic='-fpic'
11131         lt_prog_compiler_static='-Bstatic'
11132         ;;
11133       ccc*)
11134         lt_prog_compiler_wl='-Wl,'
11135         # All Alpha code is PIC.
11136         lt_prog_compiler_static='-non_shared'
11137         ;;
11138       xl* | bgxl* | bgf* | mpixl*)
11139         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11140         lt_prog_compiler_wl='-Wl,'
11141         lt_prog_compiler_pic='-qpic'
11142         lt_prog_compiler_static='-qstaticlink'
11143         ;;
11144       *)
11145         case `$CC -V 2>&1 | sed 5q` in
11146         *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11147           # Sun Fortran 8.3 passes all unrecognized flags to the linker
11148           lt_prog_compiler_pic='-KPIC'
11149           lt_prog_compiler_static='-Bstatic'
11150           lt_prog_compiler_wl=''
11151           ;;
11152         *Sun\ F* | *Sun*Fortran*)
11153           lt_prog_compiler_pic='-KPIC'
11154           lt_prog_compiler_static='-Bstatic'
11155           lt_prog_compiler_wl='-Qoption ld '
11156           ;;
11157         *Sun\ C*)
11158           # Sun C 5.9
11159           lt_prog_compiler_pic='-KPIC'
11160           lt_prog_compiler_static='-Bstatic'
11161           lt_prog_compiler_wl='-Wl,'
11162           ;;
11163         *Intel*\ [CF]*Compiler*)
11164           lt_prog_compiler_wl='-Wl,'
11165           lt_prog_compiler_pic='-fPIC'
11166           lt_prog_compiler_static='-static'
11167           ;;
11168         *Portland\ Group*)
11169           lt_prog_compiler_wl='-Wl,'
11170           lt_prog_compiler_pic='-fpic'
11171           lt_prog_compiler_static='-Bstatic'
11172           ;;
11173         esac
11174         ;;
11175       esac
11176       ;;
11177
11178     newsos6)
11179       lt_prog_compiler_pic='-KPIC'
11180       lt_prog_compiler_static='-Bstatic'
11181       ;;
11182
11183     *nto* | *qnx*)
11184       # QNX uses GNU C++, but need to define -shared option too, otherwise
11185       # it will coredump.
11186       lt_prog_compiler_pic='-fPIC -shared'
11187       ;;
11188
11189     osf3* | osf4* | osf5*)
11190       lt_prog_compiler_wl='-Wl,'
11191       # All OSF/1 code is PIC.
11192       lt_prog_compiler_static='-non_shared'
11193       ;;
11194
11195     rdos*)
11196       lt_prog_compiler_static='-non_shared'
11197       ;;
11198
11199     solaris*)
11200       lt_prog_compiler_pic='-KPIC'
11201       lt_prog_compiler_static='-Bstatic'
11202       case $cc_basename in
11203       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11204         lt_prog_compiler_wl='-Qoption ld ';;
11205       *)
11206         lt_prog_compiler_wl='-Wl,';;
11207       esac
11208       ;;
11209
11210     sunos4*)
11211       lt_prog_compiler_wl='-Qoption ld '
11212       lt_prog_compiler_pic='-PIC'
11213       lt_prog_compiler_static='-Bstatic'
11214       ;;
11215
11216     sysv4 | sysv4.2uw2* | sysv4.3*)
11217       lt_prog_compiler_wl='-Wl,'
11218       lt_prog_compiler_pic='-KPIC'
11219       lt_prog_compiler_static='-Bstatic'
11220       ;;
11221
11222     sysv4*MP*)
11223       if test -d /usr/nec; then
11224         lt_prog_compiler_pic='-Kconform_pic'
11225         lt_prog_compiler_static='-Bstatic'
11226       fi
11227       ;;
11228
11229     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11230       lt_prog_compiler_wl='-Wl,'
11231       lt_prog_compiler_pic='-KPIC'
11232       lt_prog_compiler_static='-Bstatic'
11233       ;;
11234
11235     unicos*)
11236       lt_prog_compiler_wl='-Wl,'
11237       lt_prog_compiler_can_build_shared=no
11238       ;;
11239
11240     uts4*)
11241       lt_prog_compiler_pic='-pic'
11242       lt_prog_compiler_static='-Bstatic'
11243       ;;
11244
11245     *)
11246       lt_prog_compiler_can_build_shared=no
11247       ;;
11248     esac
11249   fi
11250
11251 case $host_os in
11252   # For platforms that do not support PIC, -DPIC is meaningless:
11253   *djgpp*)
11254     lt_prog_compiler_pic=
11255     ;;
11256   *)
11257     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11258     ;;
11259 esac
11260
11261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11262 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11263 if ${lt_cv_prog_compiler_pic+:} false; then :
11264   $as_echo_n "(cached) " >&6
11265 else
11266   lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11267 fi
11268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11269 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
11270 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11271
11272 #
11273 # Check to make sure the PIC flag actually works.
11274 #
11275 if test -n "$lt_prog_compiler_pic"; then
11276   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
11277 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
11278 if ${lt_cv_prog_compiler_pic_works+:} false; then :
11279   $as_echo_n "(cached) " >&6
11280 else
11281   lt_cv_prog_compiler_pic_works=no
11282    ac_outfile=conftest.$ac_objext
11283    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11284    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"  ## exclude from sc_useless_quotes_in_assignment
11285    # Insert the option either (1) after the last *FLAGS variable, or
11286    # (2) before a word containing "conftest.", or (3) at the end.
11287    # Note that $ac_compile itself does not contain backslashes and begins
11288    # with a dollar sign (not a hyphen), so the echo should work correctly.
11289    # The option is referenced via a variable to avoid confusing sed.
11290    lt_compile=`echo "$ac_compile" | $SED \
11291    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11292    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11293    -e 's:$: $lt_compiler_flag:'`
11294    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11295    (eval "$lt_compile" 2>conftest.err)
11296    ac_status=$?
11297    cat conftest.err >&5
11298    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11299    if (exit $ac_status) && test -s "$ac_outfile"; then
11300      # The compiler can only warn and ignore the option if not recognized
11301      # So say no if there are warnings other than the usual output.
11302      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11303      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11304      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11305        lt_cv_prog_compiler_pic_works=yes
11306      fi
11307    fi
11308    $RM conftest*
11309
11310 fi
11311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
11312 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
11313
11314 if test yes = "$lt_cv_prog_compiler_pic_works"; then
11315     case $lt_prog_compiler_pic in
11316      "" | " "*) ;;
11317      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
11318      esac
11319 else
11320     lt_prog_compiler_pic=
11321      lt_prog_compiler_can_build_shared=no
11322 fi
11323
11324 fi
11325
11326
11327
11328
11329
11330
11331
11332
11333
11334
11335
11336 #
11337 # Check to make sure the static flag actually works.
11338 #
11339 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
11340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
11341 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
11342 if ${lt_cv_prog_compiler_static_works+:} false; then :
11343   $as_echo_n "(cached) " >&6
11344 else
11345   lt_cv_prog_compiler_static_works=no
11346    save_LDFLAGS=$LDFLAGS
11347    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
11348    echo "$lt_simple_link_test_code" > conftest.$ac_ext
11349    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11350      # The linker can only warn and ignore the option if not recognized
11351      # So say no if there are warnings
11352      if test -s conftest.err; then
11353        # Append any errors to the config.log.
11354        cat conftest.err 1>&5
11355        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11356        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11357        if diff conftest.exp conftest.er2 >/dev/null; then
11358          lt_cv_prog_compiler_static_works=yes
11359        fi
11360      else
11361        lt_cv_prog_compiler_static_works=yes
11362      fi
11363    fi
11364    $RM -r conftest*
11365    LDFLAGS=$save_LDFLAGS
11366
11367 fi
11368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
11369 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
11370
11371 if test yes = "$lt_cv_prog_compiler_static_works"; then
11372     :
11373 else
11374     lt_prog_compiler_static=
11375 fi
11376
11377
11378
11379
11380
11381
11382
11383   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11384 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11385 if ${lt_cv_prog_compiler_c_o+:} false; then :
11386   $as_echo_n "(cached) " >&6
11387 else
11388   lt_cv_prog_compiler_c_o=no
11389    $RM -r conftest 2>/dev/null
11390    mkdir conftest
11391    cd conftest
11392    mkdir out
11393    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11394
11395    lt_compiler_flag="-o out/conftest2.$ac_objext"
11396    # Insert the option either (1) after the last *FLAGS variable, or
11397    # (2) before a word containing "conftest.", or (3) at the end.
11398    # Note that $ac_compile itself does not contain backslashes and begins
11399    # with a dollar sign (not a hyphen), so the echo should work correctly.
11400    lt_compile=`echo "$ac_compile" | $SED \
11401    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11402    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11403    -e 's:$: $lt_compiler_flag:'`
11404    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11405    (eval "$lt_compile" 2>out/conftest.err)
11406    ac_status=$?
11407    cat out/conftest.err >&5
11408    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11409    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11410    then
11411      # The compiler can only warn and ignore the option if not recognized
11412      # So say no if there are warnings
11413      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11414      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11415      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11416        lt_cv_prog_compiler_c_o=yes
11417      fi
11418    fi
11419    chmod u+w . 2>&5
11420    $RM conftest*
11421    # SGI C++ compiler will create directory out/ii_files/ for
11422    # template instantiation
11423    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11424    $RM out/* && rmdir out
11425    cd ..
11426    $RM -r conftest
11427    $RM conftest*
11428
11429 fi
11430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11431 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11432
11433
11434
11435
11436
11437
11438   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11439 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11440 if ${lt_cv_prog_compiler_c_o+:} false; then :
11441   $as_echo_n "(cached) " >&6
11442 else
11443   lt_cv_prog_compiler_c_o=no
11444    $RM -r conftest 2>/dev/null
11445    mkdir conftest
11446    cd conftest
11447    mkdir out
11448    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11449
11450    lt_compiler_flag="-o out/conftest2.$ac_objext"
11451    # Insert the option either (1) after the last *FLAGS variable, or
11452    # (2) before a word containing "conftest.", or (3) at the end.
11453    # Note that $ac_compile itself does not contain backslashes and begins
11454    # with a dollar sign (not a hyphen), so the echo should work correctly.
11455    lt_compile=`echo "$ac_compile" | $SED \
11456    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11457    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11458    -e 's:$: $lt_compiler_flag:'`
11459    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11460    (eval "$lt_compile" 2>out/conftest.err)
11461    ac_status=$?
11462    cat out/conftest.err >&5
11463    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11464    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11465    then
11466      # The compiler can only warn and ignore the option if not recognized
11467      # So say no if there are warnings
11468      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11469      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11470      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11471        lt_cv_prog_compiler_c_o=yes
11472      fi
11473    fi
11474    chmod u+w . 2>&5
11475    $RM conftest*
11476    # SGI C++ compiler will create directory out/ii_files/ for
11477    # template instantiation
11478    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11479    $RM out/* && rmdir out
11480    cd ..
11481    $RM -r conftest
11482    $RM conftest*
11483
11484 fi
11485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11486 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11487
11488
11489
11490
11491 hard_links=nottested
11492 if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
11493   # do not overwrite the value of need_locks provided by the user
11494   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11495 $as_echo_n "checking if we can lock with hard links... " >&6; }
11496   hard_links=yes
11497   $RM conftest*
11498   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11499   touch conftest.a
11500   ln conftest.a conftest.b 2>&5 || hard_links=no
11501   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11502   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11503 $as_echo "$hard_links" >&6; }
11504   if test no = "$hard_links"; then
11505     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
11506 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
11507     need_locks=warn
11508   fi
11509 else
11510   need_locks=no
11511 fi
11512
11513
11514
11515
11516
11517
11518   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11519 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11520
11521   runpath_var=
11522   allow_undefined_flag=
11523   always_export_symbols=no
11524   archive_cmds=
11525   archive_expsym_cmds=
11526   compiler_needs_object=no
11527   enable_shared_with_static_runtimes=no
11528   export_dynamic_flag_spec=
11529   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11530   hardcode_automatic=no
11531   hardcode_direct=no
11532   hardcode_direct_absolute=no
11533   hardcode_libdir_flag_spec=
11534   hardcode_libdir_separator=
11535   hardcode_minus_L=no
11536   hardcode_shlibpath_var=unsupported
11537   inherit_rpath=no
11538   link_all_deplibs=unknown
11539   module_cmds=
11540   module_expsym_cmds=
11541   old_archive_from_new_cmds=
11542   old_archive_from_expsyms_cmds=
11543   thread_safe_flag_spec=
11544   whole_archive_flag_spec=
11545   # include_expsyms should be a list of space-separated symbols to be *always*
11546   # included in the symbol list
11547   include_expsyms=
11548   # exclude_expsyms can be an extended regexp of symbols to exclude
11549   # it will be wrapped by ' (' and ')$', so one must not match beginning or
11550   # end of line.  Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
11551   # as well as any symbol that contains 'd'.
11552   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11553   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11554   # platforms (ab)use it in PIC code, but their linkers get confused if
11555   # the symbol is explicitly referenced.  Since portable code cannot
11556   # rely on this symbol name, it's probably fine to never include it in
11557   # preloaded symbol tables.
11558   # Exclude shared library initialization/finalization symbols.
11559   extract_expsyms_cmds=
11560
11561   case $host_os in
11562   cygwin* | mingw* | pw32* | cegcc*)
11563     # FIXME: the MSVC++ port hasn't been tested in a loooong time
11564     # When not using gcc, we currently assume that we are using
11565     # Microsoft Visual C++.
11566     if test yes != "$GCC"; then
11567       with_gnu_ld=no
11568     fi
11569     ;;
11570   interix*)
11571     # we just hope/assume this is gcc and not c89 (= MSVC++)
11572     with_gnu_ld=yes
11573     ;;
11574   openbsd* | bitrig*)
11575     with_gnu_ld=no
11576     ;;
11577   esac
11578
11579   ld_shlibs=yes
11580
11581   # On some targets, GNU ld is compatible enough with the native linker
11582   # that we're better off using the native interface for both.
11583   lt_use_gnu_ld_interface=no
11584   if test yes = "$with_gnu_ld"; then
11585     case $host_os in
11586       aix*)
11587         # The AIX port of GNU ld has always aspired to compatibility
11588         # with the native linker.  However, as the warning in the GNU ld
11589         # block says, versions before 2.19.5* couldn't really create working
11590         # shared libraries, regardless of the interface used.
11591         case `$LD -v 2>&1` in
11592           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11593           *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11594           *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11595           *)
11596             lt_use_gnu_ld_interface=yes
11597             ;;
11598         esac
11599         ;;
11600       *)
11601         lt_use_gnu_ld_interface=yes
11602         ;;
11603     esac
11604   fi
11605
11606   if test yes = "$lt_use_gnu_ld_interface"; then
11607     # If archive_cmds runs LD, not CC, wlarc should be empty
11608     wlarc='$wl'
11609
11610     # Set some defaults for GNU ld with shared library support. These
11611     # are reset later if shared libraries are not supported. Putting them
11612     # here allows them to be overridden if necessary.
11613     runpath_var=LD_RUN_PATH
11614     hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11615     export_dynamic_flag_spec='$wl--export-dynamic'
11616     # ancient GNU ld didn't support --whole-archive et. al.
11617     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11618       whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
11619     else
11620       whole_archive_flag_spec=
11621     fi
11622     supports_anon_versioning=no
11623     case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
11624       *GNU\ gold*) supports_anon_versioning=yes ;;
11625       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11626       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11627       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11628       *\ 2.11.*) ;; # other 2.11 versions
11629       *) supports_anon_versioning=yes ;;
11630     esac
11631
11632     # See if GNU ld supports shared libraries.
11633     case $host_os in
11634     aix[3-9]*)
11635       # On AIX/PPC, the GNU linker is very broken
11636       if test ia64 != "$host_cpu"; then
11637         ld_shlibs=no
11638         cat <<_LT_EOF 1>&2
11639
11640 *** Warning: the GNU linker, at least up to release 2.19, is reported
11641 *** to be unable to reliably create shared libraries on AIX.
11642 *** Therefore, libtool is disabling shared libraries support.  If you
11643 *** really care for shared libraries, you may want to install binutils
11644 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11645 *** You will then need to restart the configuration process.
11646
11647 _LT_EOF
11648       fi
11649       ;;
11650
11651     amigaos*)
11652       case $host_cpu in
11653       powerpc)
11654             # see comment about AmigaOS4 .so support
11655             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11656             archive_expsym_cmds=''
11657         ;;
11658       m68k)
11659             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)'
11660             hardcode_libdir_flag_spec='-L$libdir'
11661             hardcode_minus_L=yes
11662         ;;
11663       esac
11664       ;;
11665
11666     beos*)
11667       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11668         allow_undefined_flag=unsupported
11669         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
11670         # support --undefined.  This deserves some investigation.  FIXME
11671         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11672       else
11673         ld_shlibs=no
11674       fi
11675       ;;
11676
11677     cygwin* | mingw* | pw32* | cegcc*)
11678       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11679       # as there is no search path for DLLs.
11680       hardcode_libdir_flag_spec='-L$libdir'
11681       export_dynamic_flag_spec='$wl--export-all-symbols'
11682       allow_undefined_flag=unsupported
11683       always_export_symbols=no
11684       enable_shared_with_static_runtimes=yes
11685       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'
11686       exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11687
11688       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11689         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11690         # If the export-symbols file already is a .def file, use it as
11691         # is; otherwise, prepend EXPORTS...
11692         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
11693           cp $export_symbols $output_objdir/$soname.def;
11694         else
11695           echo EXPORTS > $output_objdir/$soname.def;
11696           cat $export_symbols >> $output_objdir/$soname.def;
11697         fi~
11698         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11699       else
11700         ld_shlibs=no
11701       fi
11702       ;;
11703
11704     haiku*)
11705       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11706       link_all_deplibs=yes
11707       ;;
11708
11709     os2*)
11710       hardcode_libdir_flag_spec='-L$libdir'
11711       hardcode_minus_L=yes
11712       allow_undefined_flag=unsupported
11713       shrext_cmds=.dll
11714       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11715         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11716         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11717         $ECHO EXPORTS >> $output_objdir/$libname.def~
11718         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
11719         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11720         emximp -o $lib $output_objdir/$libname.def'
11721       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11722         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11723         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11724         $ECHO EXPORTS >> $output_objdir/$libname.def~
11725         prefix_cmds="$SED"~
11726         if test EXPORTS = "`$SED 1q $export_symbols`"; then
11727           prefix_cmds="$prefix_cmds -e 1d";
11728         fi~
11729         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
11730         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
11731         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11732         emximp -o $lib $output_objdir/$libname.def'
11733       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
11734       enable_shared_with_static_runtimes=yes
11735       ;;
11736
11737     interix[3-9]*)
11738       hardcode_direct=no
11739       hardcode_shlibpath_var=no
11740       hardcode_libdir_flag_spec='$wl-rpath,$libdir'
11741       export_dynamic_flag_spec='$wl-E'
11742       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11743       # Instead, shared libraries are loaded at an image base (0x10000000 by
11744       # default) and relocated if they conflict, which is a slow very memory
11745       # consuming and fragmenting process.  To avoid this, we pick a random,
11746       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11747       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
11748       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11749       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'
11750       ;;
11751
11752     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11753       tmp_diet=no
11754       if test linux-dietlibc = "$host_os"; then
11755         case $cc_basename in
11756           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
11757         esac
11758       fi
11759       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11760          && test no = "$tmp_diet"
11761       then
11762         tmp_addflag=' $pic_flag'
11763         tmp_sharedflag='-shared'
11764         case $cc_basename,$host_cpu in
11765         pgcc*)                          # Portland Group C compiler
11766           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'
11767           tmp_addflag=' $pic_flag'
11768           ;;
11769         pgf77* | pgf90* | pgf95* | pgfortran*)
11770                                         # Portland Group f77 and f90 compilers
11771           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'
11772           tmp_addflag=' $pic_flag -Mnomain' ;;
11773         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
11774           tmp_addflag=' -i_dynamic' ;;
11775         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
11776           tmp_addflag=' -i_dynamic -nofor_main' ;;
11777         ifc* | ifort*)                  # Intel Fortran compiler
11778           tmp_addflag=' -nofor_main' ;;
11779         lf95*)                          # Lahey Fortran 8.1
11780           whole_archive_flag_spec=
11781           tmp_sharedflag='--shared' ;;
11782         nagfor*)                        # NAGFOR 5.3
11783           tmp_sharedflag='-Wl,-shared' ;;
11784         xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11785           tmp_sharedflag='-qmkshrobj'
11786           tmp_addflag= ;;
11787         nvcc*)  # Cuda Compiler Driver 2.2
11788           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'
11789           compiler_needs_object=yes
11790           ;;
11791         esac
11792         case `$CC -V 2>&1 | sed 5q` in
11793         *Sun\ C*)                       # Sun C 5.9
11794           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'
11795           compiler_needs_object=yes
11796           tmp_sharedflag='-G' ;;
11797         *Sun\ F*)                       # Sun Fortran 8.3
11798           tmp_sharedflag='-G' ;;
11799         esac
11800         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11801
11802         if test yes = "$supports_anon_versioning"; then
11803           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11804             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11805             echo "local: *; };" >> $output_objdir/$libname.ver~
11806             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
11807         fi
11808
11809         case $cc_basename in
11810         tcc*)
11811           export_dynamic_flag_spec='-rdynamic'
11812           ;;
11813         xlf* | bgf* | bgxlf* | mpixlf*)
11814           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11815           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11816           hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11817           archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11818           if test yes = "$supports_anon_versioning"; then
11819             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11820               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11821               echo "local: *; };" >> $output_objdir/$libname.ver~
11822               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11823           fi
11824           ;;
11825         esac
11826       else
11827         ld_shlibs=no
11828       fi
11829       ;;
11830
11831     netbsd*)
11832       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11833         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11834         wlarc=
11835       else
11836         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11837         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11838       fi
11839       ;;
11840
11841     solaris*)
11842       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11843         ld_shlibs=no
11844         cat <<_LT_EOF 1>&2
11845
11846 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
11847 *** create shared libraries on Solaris systems.  Therefore, libtool
11848 *** is disabling shared libraries support.  We urge you to upgrade GNU
11849 *** binutils to release 2.9.1 or newer.  Another option is to modify
11850 *** your PATH or compiler configuration so that the native linker is
11851 *** used, and then restart.
11852
11853 _LT_EOF
11854       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11855         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11856         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11857       else
11858         ld_shlibs=no
11859       fi
11860       ;;
11861
11862     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11863       case `$LD -v 2>&1` in
11864         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11865         ld_shlibs=no
11866         cat <<_LT_EOF 1>&2
11867
11868 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
11869 *** reliably create shared libraries on SCO systems.  Therefore, libtool
11870 *** is disabling shared libraries support.  We urge you to upgrade GNU
11871 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
11872 *** your PATH or compiler configuration so that the native linker is
11873 *** used, and then restart.
11874
11875 _LT_EOF
11876         ;;
11877         *)
11878           # For security reasons, it is highly recommended that you always
11879           # use absolute paths for naming shared libraries, and exclude the
11880           # DT_RUNPATH tag from executables and libraries.  But doing so
11881           # requires that you compile everything twice, which is a pain.
11882           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11883             hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11884             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11885             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11886           else
11887             ld_shlibs=no
11888           fi
11889         ;;
11890       esac
11891       ;;
11892
11893     sunos4*)
11894       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11895       wlarc=
11896       hardcode_direct=yes
11897       hardcode_shlibpath_var=no
11898       ;;
11899
11900     *)
11901       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11902         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11903         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11904       else
11905         ld_shlibs=no
11906       fi
11907       ;;
11908     esac
11909
11910     if test no = "$ld_shlibs"; then
11911       runpath_var=
11912       hardcode_libdir_flag_spec=
11913       export_dynamic_flag_spec=
11914       whole_archive_flag_spec=
11915     fi
11916   else
11917     # PORTME fill in a description of your system's linker (not GNU ld)
11918     case $host_os in
11919     aix3*)
11920       allow_undefined_flag=unsupported
11921       always_export_symbols=yes
11922       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'
11923       # Note: this linker hardcodes the directories in LIBPATH if there
11924       # are no directories specified by -L.
11925       hardcode_minus_L=yes
11926       if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
11927         # Neither direct hardcoding nor static linking is supported with a
11928         # broken collect2.
11929         hardcode_direct=unsupported
11930       fi
11931       ;;
11932
11933     aix[4-9]*)
11934       if test ia64 = "$host_cpu"; then
11935         # On IA64, the linker does run time linking by default, so we don't
11936         # have to do anything special.
11937         aix_use_runtimelinking=no
11938         exp_sym_flag='-Bexport'
11939         no_entry_flag=
11940       else
11941         # If we're using GNU nm, then we don't want the "-C" option.
11942         # -C means demangle to GNU nm, but means don't demangle to AIX nm.
11943         # Without the "-l" option, or with the "-B" option, AIX nm treats
11944         # weak defined symbols like other global defined symbols, whereas
11945         # GNU nm marks them as "W".
11946         # While the 'weak' keyword is ignored in the Export File, we need
11947         # it in the Import File for the 'aix-soname' feature, so we have
11948         # to replace the "-B" option with "-P" for AIX nm.
11949         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11950           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'
11951         else
11952           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'
11953         fi
11954         aix_use_runtimelinking=no
11955
11956         # Test if we are trying to use run time linking or normal
11957         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
11958         # have runtime linking enabled, and use it for executables.
11959         # For shared libraries, we enable/disable runtime linking
11960         # depending on the kind of the shared library created -
11961         # when "with_aix_soname,aix_use_runtimelinking" is:
11962         # "aix,no"   lib.a(lib.so.V) shared, rtl:no,  for executables
11963         # "aix,yes"  lib.so          shared, rtl:yes, for executables
11964         #            lib.a           static archive
11965         # "both,no"  lib.so.V(shr.o) shared, rtl:yes
11966         #            lib.a(lib.so.V) shared, rtl:no,  for executables
11967         # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
11968         #            lib.a(lib.so.V) shared, rtl:no
11969         # "svr4,*"   lib.so.V(shr.o) shared, rtl:yes, for executables
11970         #            lib.a           static archive
11971         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11972           for ld_flag in $LDFLAGS; do
11973           if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
11974             aix_use_runtimelinking=yes
11975             break
11976           fi
11977           done
11978           if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
11979             # With aix-soname=svr4, we create the lib.so.V shared archives only,
11980             # so we don't have lib.a shared libs to link our executables.
11981             # We have to force runtime linking in this case.
11982             aix_use_runtimelinking=yes
11983             LDFLAGS="$LDFLAGS -Wl,-brtl"
11984           fi
11985           ;;
11986         esac
11987
11988         exp_sym_flag='-bexport'
11989         no_entry_flag='-bnoentry'
11990       fi
11991
11992       # When large executables or shared objects are built, AIX ld can
11993       # have problems creating the table of contents.  If linking a library
11994       # or program results in "error TOC overflow" add -mminimal-toc to
11995       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
11996       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
11997
11998       archive_cmds=''
11999       hardcode_direct=yes
12000       hardcode_direct_absolute=yes
12001       hardcode_libdir_separator=':'
12002       link_all_deplibs=yes
12003       file_list_spec='$wl-f,'
12004       case $with_aix_soname,$aix_use_runtimelinking in
12005       aix,*) ;; # traditional, no import file
12006       svr4,* | *,yes) # use import file
12007         # The Import File defines what to hardcode.
12008         hardcode_direct=no
12009         hardcode_direct_absolute=no
12010         ;;
12011       esac
12012
12013       if test yes = "$GCC"; then
12014         case $host_os in aix4.[012]|aix4.[012].*)
12015         # We only want to do this on AIX 4.2 and lower, the check
12016         # below for broken collect2 doesn't work under 4.3+
12017           collect2name=`$CC -print-prog-name=collect2`
12018           if test -f "$collect2name" &&
12019            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12020           then
12021           # We have reworked collect2
12022           :
12023           else
12024           # We have old collect2
12025           hardcode_direct=unsupported
12026           # It fails to find uninstalled libraries when the uninstalled
12027           # path is not listed in the libpath.  Setting hardcode_minus_L
12028           # to unsupported forces relinking
12029           hardcode_minus_L=yes
12030           hardcode_libdir_flag_spec='-L$libdir'
12031           hardcode_libdir_separator=
12032           fi
12033           ;;
12034         esac
12035         shared_flag='-shared'
12036         if test yes = "$aix_use_runtimelinking"; then
12037           shared_flag="$shared_flag "'$wl-G'
12038         fi
12039         # Need to ensure runtime linking is disabled for the traditional
12040         # shared library, or the linker may eventually find shared libraries
12041         # /with/ Import File - we do not want to mix them.
12042         shared_flag_aix='-shared'
12043         shared_flag_svr4='-shared $wl-G'
12044       else
12045         # not using gcc
12046         if test ia64 = "$host_cpu"; then
12047         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12048         # chokes on -Wl,-G. The following line is correct:
12049           shared_flag='-G'
12050         else
12051           if test yes = "$aix_use_runtimelinking"; then
12052             shared_flag='$wl-G'
12053           else
12054             shared_flag='$wl-bM:SRE'
12055           fi
12056           shared_flag_aix='$wl-bM:SRE'
12057           shared_flag_svr4='$wl-G'
12058         fi
12059       fi
12060
12061       export_dynamic_flag_spec='$wl-bexpall'
12062       # It seems that -bexpall does not export symbols beginning with
12063       # underscore (_), so it is better to generate a list of symbols to export.
12064       always_export_symbols=yes
12065       if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12066         # Warning - without using the other runtime loading flags (-brtl),
12067         # -berok will link without error, but may produce a broken library.
12068         allow_undefined_flag='-berok'
12069         # Determine the default libpath from the value encoded in an
12070         # empty executable.
12071         if test set = "${lt_cv_aix_libpath+set}"; then
12072   aix_libpath=$lt_cv_aix_libpath
12073 else
12074   if ${lt_cv_aix_libpath_+:} false; then :
12075   $as_echo_n "(cached) " >&6
12076 else
12077   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12078 /* end confdefs.h.  */
12079
12080 int
12081 main ()
12082 {
12083
12084   ;
12085   return 0;
12086 }
12087 _ACEOF
12088 if ac_fn_c_try_link "$LINENO"; then :
12089
12090   lt_aix_libpath_sed='
12091       /Import File Strings/,/^$/ {
12092           /^0/ {
12093               s/^0  *\([^ ]*\) *$/\1/
12094               p
12095           }
12096       }'
12097   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12098   # Check for a 64-bit object if we didn't find anything.
12099   if test -z "$lt_cv_aix_libpath_"; then
12100     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12101   fi
12102 fi
12103 rm -f core conftest.err conftest.$ac_objext \
12104     conftest$ac_exeext conftest.$ac_ext
12105   if test -z "$lt_cv_aix_libpath_"; then
12106     lt_cv_aix_libpath_=/usr/lib:/lib
12107   fi
12108
12109 fi
12110
12111   aix_libpath=$lt_cv_aix_libpath_
12112 fi
12113
12114         hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12115         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
12116       else
12117         if test ia64 = "$host_cpu"; then
12118           hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12119           allow_undefined_flag="-z nodefs"
12120           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"
12121         else
12122          # Determine the default libpath from the value encoded in an
12123          # empty executable.
12124          if test set = "${lt_cv_aix_libpath+set}"; then
12125   aix_libpath=$lt_cv_aix_libpath
12126 else
12127   if ${lt_cv_aix_libpath_+:} false; then :
12128   $as_echo_n "(cached) " >&6
12129 else
12130   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12131 /* end confdefs.h.  */
12132
12133 int
12134 main ()
12135 {
12136
12137   ;
12138   return 0;
12139 }
12140 _ACEOF
12141 if ac_fn_c_try_link "$LINENO"; then :
12142
12143   lt_aix_libpath_sed='
12144       /Import File Strings/,/^$/ {
12145           /^0/ {
12146               s/^0  *\([^ ]*\) *$/\1/
12147               p
12148           }
12149       }'
12150   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12151   # Check for a 64-bit object if we didn't find anything.
12152   if test -z "$lt_cv_aix_libpath_"; then
12153     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12154   fi
12155 fi
12156 rm -f core conftest.err conftest.$ac_objext \
12157     conftest$ac_exeext conftest.$ac_ext
12158   if test -z "$lt_cv_aix_libpath_"; then
12159     lt_cv_aix_libpath_=/usr/lib:/lib
12160   fi
12161
12162 fi
12163
12164   aix_libpath=$lt_cv_aix_libpath_
12165 fi
12166
12167          hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12168           # Warning - without using the other run time loading flags,
12169           # -berok will link without error, but may produce a broken library.
12170           no_undefined_flag=' $wl-bernotok'
12171           allow_undefined_flag=' $wl-berok'
12172           if test yes = "$with_gnu_ld"; then
12173             # We only use this code for GNU lds that support --whole-archive.
12174             whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12175           else
12176             # Exported symbols can be pulled into shared objects from archives
12177             whole_archive_flag_spec='$convenience'
12178           fi
12179           archive_cmds_need_lc=yes
12180           archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12181           # -brtl affects multiple linker settings, -berok does not and is overridden later
12182           compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12183           if test svr4 != "$with_aix_soname"; then
12184             # This is similar to how AIX traditionally builds its shared libraries.
12185             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'
12186           fi
12187           if test aix != "$with_aix_soname"; then
12188             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'
12189           else
12190             # used by -dlpreopen to get the symbols
12191             archive_expsym_cmds="$archive_expsym_cmds"'~$MV  $output_objdir/$realname.d/$soname $output_objdir'
12192           fi
12193           archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12194         fi
12195       fi
12196       ;;
12197
12198     amigaos*)
12199       case $host_cpu in
12200       powerpc)
12201             # see comment about AmigaOS4 .so support
12202             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12203             archive_expsym_cmds=''
12204         ;;
12205       m68k)
12206             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)'
12207             hardcode_libdir_flag_spec='-L$libdir'
12208             hardcode_minus_L=yes
12209         ;;
12210       esac
12211       ;;
12212
12213     bsdi[45]*)
12214       export_dynamic_flag_spec=-rdynamic
12215       ;;
12216
12217     cygwin* | mingw* | pw32* | cegcc*)
12218       # When not using gcc, we currently assume that we are using
12219       # Microsoft Visual C++.
12220       # hardcode_libdir_flag_spec is actually meaningless, as there is
12221       # no search path for DLLs.
12222       case $cc_basename in
12223       cl*)
12224         # Native MSVC
12225         hardcode_libdir_flag_spec=' '
12226         allow_undefined_flag=unsupported
12227         always_export_symbols=yes
12228         file_list_spec='@'
12229         # Tell ltmain to make .lib files, not .a files.
12230         libext=lib
12231         # Tell ltmain to make .dll files, not .so files.
12232         shrext_cmds=.dll
12233         # FIXME: Setting linknames here is a bad hack.
12234         archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12235         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
12236             cp "$export_symbols" "$output_objdir/$soname.def";
12237             echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12238           else
12239             $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12240           fi~
12241           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12242           linknames='
12243         # The linker will not automatically build a static lib if we build a DLL.
12244         # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12245         enable_shared_with_static_runtimes=yes
12246         exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12247         export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12248         # Don't use ranlib
12249         old_postinstall_cmds='chmod 644 $oldlib'
12250         postlink_cmds='lt_outputfile="@OUTPUT@"~
12251           lt_tool_outputfile="@TOOL_OUTPUT@"~
12252           case $lt_outputfile in
12253             *.exe|*.EXE) ;;
12254             *)
12255               lt_outputfile=$lt_outputfile.exe
12256               lt_tool_outputfile=$lt_tool_outputfile.exe
12257               ;;
12258           esac~
12259           if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
12260             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12261             $RM "$lt_outputfile.manifest";
12262           fi'
12263         ;;
12264       *)
12265         # Assume MSVC wrapper
12266         hardcode_libdir_flag_spec=' '
12267         allow_undefined_flag=unsupported
12268         # Tell ltmain to make .lib files, not .a files.
12269         libext=lib
12270         # Tell ltmain to make .dll files, not .so files.
12271         shrext_cmds=.dll
12272         # FIXME: Setting linknames here is a bad hack.
12273         archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12274         # The linker will automatically build a .lib file if we build a DLL.
12275         old_archive_from_new_cmds='true'
12276         # FIXME: Should let the user specify the lib program.
12277         old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12278         enable_shared_with_static_runtimes=yes
12279         ;;
12280       esac
12281       ;;
12282
12283     darwin* | rhapsody*)
12284
12285
12286   archive_cmds_need_lc=no
12287   hardcode_direct=no
12288   hardcode_automatic=yes
12289   hardcode_shlibpath_var=unsupported
12290   if test yes = "$lt_cv_ld_force_load"; then
12291     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\"`'
12292
12293   else
12294     whole_archive_flag_spec=''
12295   fi
12296   link_all_deplibs=yes
12297   allow_undefined_flag=$_lt_dar_allow_undefined
12298   case $cc_basename in
12299      ifort*|nagfor*) _lt_dar_can_shared=yes ;;
12300      *) _lt_dar_can_shared=$GCC ;;
12301   esac
12302   if test yes = "$_lt_dar_can_shared"; then
12303     output_verbose_link_cmd=func_echo_all
12304     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
12305     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
12306     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"
12307     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"
12308
12309   else
12310   ld_shlibs=no
12311   fi
12312
12313       ;;
12314
12315     dgux*)
12316       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12317       hardcode_libdir_flag_spec='-L$libdir'
12318       hardcode_shlibpath_var=no
12319       ;;
12320
12321     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
12322     # support.  Future versions do this automatically, but an explicit c++rt0.o
12323     # does not break anything, and helps significantly (at the cost of a little
12324     # extra space).
12325     freebsd2.2*)
12326       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
12327       hardcode_libdir_flag_spec='-R$libdir'
12328       hardcode_direct=yes
12329       hardcode_shlibpath_var=no
12330       ;;
12331
12332     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
12333     freebsd2.*)
12334       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12335       hardcode_direct=yes
12336       hardcode_minus_L=yes
12337       hardcode_shlibpath_var=no
12338       ;;
12339
12340     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12341     freebsd* | dragonfly*)
12342       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12343       hardcode_libdir_flag_spec='-R$libdir'
12344       hardcode_direct=yes
12345       hardcode_shlibpath_var=no
12346       ;;
12347
12348     hpux9*)
12349       if test yes = "$GCC"; then
12350         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'
12351       else
12352         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'
12353       fi
12354       hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12355       hardcode_libdir_separator=:
12356       hardcode_direct=yes
12357
12358       # hardcode_minus_L: Not really in the search PATH,
12359       # but as the default location of the library.
12360       hardcode_minus_L=yes
12361       export_dynamic_flag_spec='$wl-E'
12362       ;;
12363
12364     hpux10*)
12365       if test yes,no = "$GCC,$with_gnu_ld"; then
12366         archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12367       else
12368         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12369       fi
12370       if test no = "$with_gnu_ld"; then
12371         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12372         hardcode_libdir_separator=:
12373         hardcode_direct=yes
12374         hardcode_direct_absolute=yes
12375         export_dynamic_flag_spec='$wl-E'
12376         # hardcode_minus_L: Not really in the search PATH,
12377         # but as the default location of the library.
12378         hardcode_minus_L=yes
12379       fi
12380       ;;
12381
12382     hpux11*)
12383       if test yes,no = "$GCC,$with_gnu_ld"; then
12384         case $host_cpu in
12385         hppa*64*)
12386           archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12387           ;;
12388         ia64*)
12389           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12390           ;;
12391         *)
12392           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12393           ;;
12394         esac
12395       else
12396         case $host_cpu in
12397         hppa*64*)
12398           archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12399           ;;
12400         ia64*)
12401           archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12402           ;;
12403         *)
12404
12405           # Older versions of the 11.00 compiler do not understand -b yet
12406           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
12407           { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
12408 $as_echo_n "checking if $CC understands -b... " >&6; }
12409 if ${lt_cv_prog_compiler__b+:} false; then :
12410   $as_echo_n "(cached) " >&6
12411 else
12412   lt_cv_prog_compiler__b=no
12413    save_LDFLAGS=$LDFLAGS
12414    LDFLAGS="$LDFLAGS -b"
12415    echo "$lt_simple_link_test_code" > conftest.$ac_ext
12416    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12417      # The linker can only warn and ignore the option if not recognized
12418      # So say no if there are warnings
12419      if test -s conftest.err; then
12420        # Append any errors to the config.log.
12421        cat conftest.err 1>&5
12422        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12423        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12424        if diff conftest.exp conftest.er2 >/dev/null; then
12425          lt_cv_prog_compiler__b=yes
12426        fi
12427      else
12428        lt_cv_prog_compiler__b=yes
12429      fi
12430    fi
12431    $RM -r conftest*
12432    LDFLAGS=$save_LDFLAGS
12433
12434 fi
12435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
12436 $as_echo "$lt_cv_prog_compiler__b" >&6; }
12437
12438 if test yes = "$lt_cv_prog_compiler__b"; then
12439     archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12440 else
12441     archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12442 fi
12443
12444           ;;
12445         esac
12446       fi
12447       if test no = "$with_gnu_ld"; then
12448         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12449         hardcode_libdir_separator=:
12450
12451         case $host_cpu in
12452         hppa*64*|ia64*)
12453           hardcode_direct=no
12454           hardcode_shlibpath_var=no
12455           ;;
12456         *)
12457           hardcode_direct=yes
12458           hardcode_direct_absolute=yes
12459           export_dynamic_flag_spec='$wl-E'
12460
12461           # hardcode_minus_L: Not really in the search PATH,
12462           # but as the default location of the library.
12463           hardcode_minus_L=yes
12464           ;;
12465         esac
12466       fi
12467       ;;
12468
12469     irix5* | irix6* | nonstopux*)
12470       if test yes = "$GCC"; then
12471         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'
12472         # Try to use the -exported_symbol ld option, if it does not
12473         # work, assume that -exports_file does not work either and
12474         # implicitly export all symbols.
12475         # This should be the same for all languages, so no per-tag cache variable.
12476         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12477 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12478 if ${lt_cv_irix_exported_symbol+:} false; then :
12479   $as_echo_n "(cached) " >&6
12480 else
12481   save_LDFLAGS=$LDFLAGS
12482            LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
12483            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12484 /* end confdefs.h.  */
12485 int foo (void) { return 0; }
12486 _ACEOF
12487 if ac_fn_c_try_link "$LINENO"; then :
12488   lt_cv_irix_exported_symbol=yes
12489 else
12490   lt_cv_irix_exported_symbol=no
12491 fi
12492 rm -f core conftest.err conftest.$ac_objext \
12493     conftest$ac_exeext conftest.$ac_ext
12494            LDFLAGS=$save_LDFLAGS
12495 fi
12496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12497 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
12498         if test yes = "$lt_cv_irix_exported_symbol"; then
12499           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'
12500         fi
12501       else
12502         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'
12503         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'
12504       fi
12505       archive_cmds_need_lc='no'
12506       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12507       hardcode_libdir_separator=:
12508       inherit_rpath=yes
12509       link_all_deplibs=yes
12510       ;;
12511
12512     linux*)
12513       case $cc_basename in
12514       tcc*)
12515         # Fabrice Bellard et al's Tiny C Compiler
12516         ld_shlibs=yes
12517         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12518         ;;
12519       esac
12520       ;;
12521
12522     netbsd*)
12523       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12524         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
12525       else
12526         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
12527       fi
12528       hardcode_libdir_flag_spec='-R$libdir'
12529       hardcode_direct=yes
12530       hardcode_shlibpath_var=no
12531       ;;
12532
12533     newsos6)
12534       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12535       hardcode_direct=yes
12536       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12537       hardcode_libdir_separator=:
12538       hardcode_shlibpath_var=no
12539       ;;
12540
12541     *nto* | *qnx*)
12542       ;;
12543
12544     openbsd* | bitrig*)
12545       if test -f /usr/libexec/ld.so; then
12546         hardcode_direct=yes
12547         hardcode_shlibpath_var=no
12548         hardcode_direct_absolute=yes
12549         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
12550           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12551           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
12552           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12553           export_dynamic_flag_spec='$wl-E'
12554         else
12555           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12556           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12557         fi
12558       else
12559         ld_shlibs=no
12560       fi
12561       ;;
12562
12563     os2*)
12564       hardcode_libdir_flag_spec='-L$libdir'
12565       hardcode_minus_L=yes
12566       allow_undefined_flag=unsupported
12567       shrext_cmds=.dll
12568       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12569         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12570         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12571         $ECHO EXPORTS >> $output_objdir/$libname.def~
12572         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12573         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12574         emximp -o $lib $output_objdir/$libname.def'
12575       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12576         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12577         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12578         $ECHO EXPORTS >> $output_objdir/$libname.def~
12579         prefix_cmds="$SED"~
12580         if test EXPORTS = "`$SED 1q $export_symbols`"; then
12581           prefix_cmds="$prefix_cmds -e 1d";
12582         fi~
12583         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12584         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12585         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12586         emximp -o $lib $output_objdir/$libname.def'
12587       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12588       enable_shared_with_static_runtimes=yes
12589       ;;
12590
12591     osf3*)
12592       if test yes = "$GCC"; then
12593         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12594         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'
12595       else
12596         allow_undefined_flag=' -expect_unresolved \*'
12597         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'
12598       fi
12599       archive_cmds_need_lc='no'
12600       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12601       hardcode_libdir_separator=:
12602       ;;
12603
12604     osf4* | osf5*)      # as osf3* with the addition of -msym flag
12605       if test yes = "$GCC"; then
12606         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12607         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'
12608         hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12609       else
12610         allow_undefined_flag=' -expect_unresolved \*'
12611         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'
12612         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~
12613           $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'
12614
12615         # Both c and cxx compiler support -rpath directly
12616         hardcode_libdir_flag_spec='-rpath $libdir'
12617       fi
12618       archive_cmds_need_lc='no'
12619       hardcode_libdir_separator=:
12620       ;;
12621
12622     solaris*)
12623       no_undefined_flag=' -z defs'
12624       if test yes = "$GCC"; then
12625         wlarc='$wl'
12626         archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12627         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12628           $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'
12629       else
12630         case `$CC -V 2>&1` in
12631         *"Compilers 5.0"*)
12632           wlarc=''
12633           archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
12634           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12635             $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12636           ;;
12637         *)
12638           wlarc='$wl'
12639           archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12640           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12641             $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12642           ;;
12643         esac
12644       fi
12645       hardcode_libdir_flag_spec='-R$libdir'
12646       hardcode_shlibpath_var=no
12647       case $host_os in
12648       solaris2.[0-5] | solaris2.[0-5].*) ;;
12649       *)
12650         # The compiler driver will combine and reorder linker options,
12651         # but understands '-z linker_flag'.  GCC discards it without '$wl',
12652         # but is careful enough not to reorder.
12653         # Supported since Solaris 2.6 (maybe 2.5.1?)
12654         if test yes = "$GCC"; then
12655           whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
12656         else
12657           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12658         fi
12659         ;;
12660       esac
12661       link_all_deplibs=yes
12662       ;;
12663
12664     sunos4*)
12665       if test sequent = "$host_vendor"; then
12666         # Use $CC to link under sequent, because it throws in some extra .o
12667         # files that make .init and .fini sections work.
12668         archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12669       else
12670         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12671       fi
12672       hardcode_libdir_flag_spec='-L$libdir'
12673       hardcode_direct=yes
12674       hardcode_minus_L=yes
12675       hardcode_shlibpath_var=no
12676       ;;
12677
12678     sysv4)
12679       case $host_vendor in
12680         sni)
12681           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12682           hardcode_direct=yes # is this really true???
12683         ;;
12684         siemens)
12685           ## LD is ld it makes a PLAMLIB
12686           ## CC just makes a GrossModule.
12687           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12688           reload_cmds='$CC -r -o $output$reload_objs'
12689           hardcode_direct=no
12690         ;;
12691         motorola)
12692           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12693           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12694         ;;
12695       esac
12696       runpath_var='LD_RUN_PATH'
12697       hardcode_shlibpath_var=no
12698       ;;
12699
12700     sysv4.3*)
12701       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12702       hardcode_shlibpath_var=no
12703       export_dynamic_flag_spec='-Bexport'
12704       ;;
12705
12706     sysv4*MP*)
12707       if test -d /usr/nec; then
12708         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12709         hardcode_shlibpath_var=no
12710         runpath_var=LD_RUN_PATH
12711         hardcode_runpath_var=yes
12712         ld_shlibs=yes
12713       fi
12714       ;;
12715
12716     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12717       no_undefined_flag='$wl-z,text'
12718       archive_cmds_need_lc=no
12719       hardcode_shlibpath_var=no
12720       runpath_var='LD_RUN_PATH'
12721
12722       if test yes = "$GCC"; then
12723         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12724         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12725       else
12726         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12727         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12728       fi
12729       ;;
12730
12731     sysv5* | sco3.2v5* | sco5v6*)
12732       # Note: We CANNOT use -z defs as we might desire, because we do not
12733       # link with -lc, and that would cause any symbols used from libc to
12734       # always be unresolved, which means just about no library would
12735       # ever link correctly.  If we're not using GNU ld we use -z text
12736       # though, which does catch some bad symbols but isn't as heavy-handed
12737       # as -z defs.
12738       no_undefined_flag='$wl-z,text'
12739       allow_undefined_flag='$wl-z,nodefs'
12740       archive_cmds_need_lc=no
12741       hardcode_shlibpath_var=no
12742       hardcode_libdir_flag_spec='$wl-R,$libdir'
12743       hardcode_libdir_separator=':'
12744       link_all_deplibs=yes
12745       export_dynamic_flag_spec='$wl-Bexport'
12746       runpath_var='LD_RUN_PATH'
12747
12748       if test yes = "$GCC"; then
12749         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12750         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12751       else
12752         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12753         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12754       fi
12755       ;;
12756
12757     uts4*)
12758       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12759       hardcode_libdir_flag_spec='-L$libdir'
12760       hardcode_shlibpath_var=no
12761       ;;
12762
12763     *)
12764       ld_shlibs=no
12765       ;;
12766     esac
12767
12768     if test sni = "$host_vendor"; then
12769       case $host in
12770       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12771         export_dynamic_flag_spec='$wl-Blargedynsym'
12772         ;;
12773       esac
12774     fi
12775   fi
12776
12777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12778 $as_echo "$ld_shlibs" >&6; }
12779 test no = "$ld_shlibs" && can_build_shared=no
12780
12781 with_gnu_ld=$with_gnu_ld
12782
12783
12784
12785
12786
12787
12788
12789
12790
12791
12792
12793
12794
12795
12796
12797 #
12798 # Do we need to explicitly link libc?
12799 #
12800 case "x$archive_cmds_need_lc" in
12801 x|xyes)
12802   # Assume -lc should be added
12803   archive_cmds_need_lc=yes
12804
12805   if test yes,yes = "$GCC,$enable_shared"; then
12806     case $archive_cmds in
12807     *'~'*)
12808       # FIXME: we may have to deal with multi-command sequences.
12809       ;;
12810     '$CC '*)
12811       # Test whether the compiler implicitly links with -lc since on some
12812       # systems, -lgcc has to come before -lc. If gcc already passes -lc
12813       # to ld, don't add -lc before -lgcc.
12814       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12815 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12816 if ${lt_cv_archive_cmds_need_lc+:} false; then :
12817   $as_echo_n "(cached) " >&6
12818 else
12819   $RM conftest*
12820         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12821
12822         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12823   (eval $ac_compile) 2>&5
12824   ac_status=$?
12825   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12826   test $ac_status = 0; } 2>conftest.err; then
12827           soname=conftest
12828           lib=conftest
12829           libobjs=conftest.$ac_objext
12830           deplibs=
12831           wl=$lt_prog_compiler_wl
12832           pic_flag=$lt_prog_compiler_pic
12833           compiler_flags=-v
12834           linker_flags=-v
12835           verstring=
12836           output_objdir=.
12837           libname=conftest
12838           lt_save_allow_undefined_flag=$allow_undefined_flag
12839           allow_undefined_flag=
12840           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12841   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12842   ac_status=$?
12843   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12844   test $ac_status = 0; }
12845           then
12846             lt_cv_archive_cmds_need_lc=no
12847           else
12848             lt_cv_archive_cmds_need_lc=yes
12849           fi
12850           allow_undefined_flag=$lt_save_allow_undefined_flag
12851         else
12852           cat conftest.err 1>&5
12853         fi
12854         $RM conftest*
12855
12856 fi
12857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12858 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12859       archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12860       ;;
12861     esac
12862   fi
12863   ;;
12864 esac
12865
12866
12867
12868
12869
12870
12871
12872
12873
12874
12875
12876
12877
12878
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   { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
13018 $as_echo_n "checking dynamic linker characteristics... " >&6; }
13019
13020 if test yes = "$GCC"; then
13021   case $host_os in
13022     darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
13023     *) lt_awk_arg='/^libraries:/' ;;
13024   esac
13025   case $host_os in
13026     mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
13027     *) lt_sed_strip_eq='s|=/|/|g' ;;
13028   esac
13029   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
13030   case $lt_search_path_spec in
13031   *\;*)
13032     # if the path contains ";" then we assume it to be the separator
13033     # otherwise default to the standard path separator (i.e. ":") - it is
13034     # assumed that no part of a normal pathname contains ";" but that should
13035     # okay in the real world where ";" in dirpaths is itself problematic.
13036     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
13037     ;;
13038   *)
13039     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
13040     ;;
13041   esac
13042   # Ok, now we have the path, separated by spaces, we can step through it
13043   # and add multilib dir if necessary...
13044   lt_tmp_lt_search_path_spec=
13045   lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
13046   # ...but if some path component already ends with the multilib dir we assume
13047   # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
13048   case "$lt_multi_os_dir; $lt_search_path_spec " in
13049   "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
13050     lt_multi_os_dir=
13051     ;;
13052   esac
13053   for lt_sys_path in $lt_search_path_spec; do
13054     if test -d "$lt_sys_path$lt_multi_os_dir"; then
13055       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
13056     elif test -n "$lt_multi_os_dir"; then
13057       test -d "$lt_sys_path" && \
13058         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
13059     fi
13060   done
13061   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13062 BEGIN {RS = " "; FS = "/|\n";} {
13063   lt_foo = "";
13064   lt_count = 0;
13065   for (lt_i = NF; lt_i > 0; lt_i--) {
13066     if ($lt_i != "" && $lt_i != ".") {
13067       if ($lt_i == "..") {
13068         lt_count++;
13069       } else {
13070         if (lt_count == 0) {
13071           lt_foo = "/" $lt_i lt_foo;
13072         } else {
13073           lt_count--;
13074         }
13075       }
13076     }
13077   }
13078   if (lt_foo != "") { lt_freq[lt_foo]++; }
13079   if (lt_freq[lt_foo] == 1) { print lt_foo; }
13080 }'`
13081   # AWK program above erroneously prepends '/' to C:/dos/paths
13082   # for these hosts.
13083   case $host_os in
13084     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13085       $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13086   esac
13087   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13088 else
13089   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13090 fi
13091 library_names_spec=
13092 libname_spec='lib$name'
13093 soname_spec=
13094 shrext_cmds=.so
13095 postinstall_cmds=
13096 postuninstall_cmds=
13097 finish_cmds=
13098 finish_eval=
13099 shlibpath_var=
13100 shlibpath_overrides_runpath=unknown
13101 version_type=none
13102 dynamic_linker="$host_os ld.so"
13103 sys_lib_dlsearch_path_spec="/lib /usr/lib"
13104 need_lib_prefix=unknown
13105 hardcode_into_libs=no
13106
13107 # when you set need_version to no, make sure it does not cause -set_version
13108 # flags to be left without arguments
13109 need_version=unknown
13110
13111
13112
13113 case $host_os in
13114 aix3*)
13115   version_type=linux # correct to gnu/linux during the next big refactor
13116   library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13117   shlibpath_var=LIBPATH
13118
13119   # AIX 3 has no versioning support, so we append a major version to the name.
13120   soname_spec='$libname$release$shared_ext$major'
13121   ;;
13122
13123 aix[4-9]*)
13124   version_type=linux # correct to gnu/linux during the next big refactor
13125   need_lib_prefix=no
13126   need_version=no
13127   hardcode_into_libs=yes
13128   if test ia64 = "$host_cpu"; then
13129     # AIX 5 supports IA64
13130     library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13131     shlibpath_var=LD_LIBRARY_PATH
13132   else
13133     # With GCC up to 2.95.x, collect2 would create an import file
13134     # for dependence libraries.  The import file would start with
13135     # the line '#! .'.  This would cause the generated library to
13136     # depend on '.', always an invalid library.  This was fixed in
13137     # development snapshots of GCC prior to 3.0.
13138     case $host_os in
13139       aix4 | aix4.[01] | aix4.[01].*)
13140       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13141            echo ' yes '
13142            echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13143         :
13144       else
13145         can_build_shared=no
13146       fi
13147       ;;
13148     esac
13149     # Using Import Files as archive members, it is possible to support
13150     # filename-based versioning of shared library archives on AIX. While
13151     # this would work for both with and without runtime linking, it will
13152     # prevent static linking of such archives. So we do filename-based
13153     # shared library versioning with .so extension only, which is used
13154     # when both runtime linking and shared linking is enabled.
13155     # Unfortunately, runtime linking may impact performance, so we do
13156     # not want this to be the default eventually. Also, we use the
13157     # versioned .so libs for executables only if there is the -brtl
13158     # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13159     # To allow for filename-based versioning support, we need to create
13160     # libNAME.so.V as an archive file, containing:
13161     # *) an Import File, referring to the versioned filename of the
13162     #    archive as well as the shared archive member, telling the
13163     #    bitwidth (32 or 64) of that shared object, and providing the
13164     #    list of exported symbols of that shared object, eventually
13165     #    decorated with the 'weak' keyword
13166     # *) the shared object with the F_LOADONLY flag set, to really avoid
13167     #    it being seen by the linker.
13168     # At run time we better use the real file rather than another symlink,
13169     # but for link time we create the symlink libNAME.so -> libNAME.so.V
13170
13171     case $with_aix_soname,$aix_use_runtimelinking in
13172     # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13173     # soname into executable. Probably we can add versioning support to
13174     # collect2, so additional links can be useful in future.
13175     aix,yes) # traditional libtool
13176       dynamic_linker='AIX unversionable lib.so'
13177       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13178       # instead of lib<name>.a to let people know that these are not
13179       # typical AIX shared libraries.
13180       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13181       ;;
13182     aix,no) # traditional AIX only
13183       dynamic_linker='AIX lib.a(lib.so.V)'
13184       # We preserve .a as extension for shared libraries through AIX4.2
13185       # and later when we are not doing run time linking.
13186       library_names_spec='$libname$release.a $libname.a'
13187       soname_spec='$libname$release$shared_ext$major'
13188       ;;
13189     svr4,*) # full svr4 only
13190       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13191       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13192       # We do not specify a path in Import Files, so LIBPATH fires.
13193       shlibpath_overrides_runpath=yes
13194       ;;
13195     *,yes) # both, prefer svr4
13196       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13197       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13198       # unpreferred sharedlib libNAME.a needs extra handling
13199       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"'
13200       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"'
13201       # We do not specify a path in Import Files, so LIBPATH fires.
13202       shlibpath_overrides_runpath=yes
13203       ;;
13204     *,no) # both, prefer aix
13205       dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13206       library_names_spec='$libname$release.a $libname.a'
13207       soname_spec='$libname$release$shared_ext$major'
13208       # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13209       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)'
13210       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"'
13211       ;;
13212     esac
13213     shlibpath_var=LIBPATH
13214   fi
13215   ;;
13216
13217 amigaos*)
13218   case $host_cpu in
13219   powerpc)
13220     # Since July 2007 AmigaOS4 officially supports .so libraries.
13221     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13222     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13223     ;;
13224   m68k)
13225     library_names_spec='$libname.ixlibrary $libname.a'
13226     # Create ${libname}_ixlibrary.a entries in /sys/libs.
13227     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'
13228     ;;
13229   esac
13230   ;;
13231
13232 beos*)
13233   library_names_spec='$libname$shared_ext'
13234   dynamic_linker="$host_os ld.so"
13235   shlibpath_var=LIBRARY_PATH
13236   ;;
13237
13238 bsdi[45]*)
13239   version_type=linux # correct to gnu/linux during the next big refactor
13240   need_version=no
13241   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13242   soname_spec='$libname$release$shared_ext$major'
13243   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13244   shlibpath_var=LD_LIBRARY_PATH
13245   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13246   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13247   # the default ld.so.conf also contains /usr/contrib/lib and
13248   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13249   # libtool to hard-code these into programs
13250   ;;
13251
13252 cygwin* | mingw* | pw32* | cegcc*)
13253   version_type=windows
13254   shrext_cmds=.dll
13255   need_version=no
13256   need_lib_prefix=no
13257
13258   case $GCC,$cc_basename in
13259   yes,*)
13260     # gcc
13261     library_names_spec='$libname.dll.a'
13262     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13263     postinstall_cmds='base_file=`basename \$file`~
13264       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13265       dldir=$destdir/`dirname \$dlpath`~
13266       test -d \$dldir || mkdir -p \$dldir~
13267       $install_prog $dir/$dlname \$dldir/$dlname~
13268       chmod a+x \$dldir/$dlname~
13269       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13270         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13271       fi'
13272     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13273       dlpath=$dir/\$dldll~
13274        $RM \$dlpath'
13275     shlibpath_overrides_runpath=yes
13276
13277     case $host_os in
13278     cygwin*)
13279       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
13280       soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13281
13282       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
13283       ;;
13284     mingw* | cegcc*)
13285       # MinGW DLLs use traditional 'lib' prefix
13286       soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13287       ;;
13288     pw32*)
13289       # pw32 DLLs use 'pw' prefix rather than 'lib'
13290       library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13291       ;;
13292     esac
13293     dynamic_linker='Win32 ld.exe'
13294     ;;
13295
13296   *,cl*)
13297     # Native MSVC
13298     libname_spec='$name'
13299     soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13300     library_names_spec='$libname.dll.lib'
13301
13302     case $build_os in
13303     mingw*)
13304       sys_lib_search_path_spec=
13305       lt_save_ifs=$IFS
13306       IFS=';'
13307       for lt_path in $LIB
13308       do
13309         IFS=$lt_save_ifs
13310         # Let DOS variable expansion print the short 8.3 style file name.
13311         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
13312         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
13313       done
13314       IFS=$lt_save_ifs
13315       # Convert to MSYS style.
13316       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
13317       ;;
13318     cygwin*)
13319       # Convert to unix form, then to dos form, then back to unix form
13320       # but this time dos style (no spaces!) so that the unix form looks
13321       # like /cygdrive/c/PROGRA~1:/cygdr...
13322       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
13323       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
13324       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13325       ;;
13326     *)
13327       sys_lib_search_path_spec=$LIB
13328       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
13329         # It is most probably a Windows format PATH.
13330         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
13331       else
13332         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13333       fi
13334       # FIXME: find the short name or the path components, as spaces are
13335       # common. (e.g. "Program Files" -> "PROGRA~1")
13336       ;;
13337     esac
13338
13339     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13340     postinstall_cmds='base_file=`basename \$file`~
13341       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13342       dldir=$destdir/`dirname \$dlpath`~
13343       test -d \$dldir || mkdir -p \$dldir~
13344       $install_prog $dir/$dlname \$dldir/$dlname'
13345     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13346       dlpath=$dir/\$dldll~
13347        $RM \$dlpath'
13348     shlibpath_overrides_runpath=yes
13349     dynamic_linker='Win32 link.exe'
13350     ;;
13351
13352   *)
13353     # Assume MSVC wrapper
13354     library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
13355     dynamic_linker='Win32 ld.exe'
13356     ;;
13357   esac
13358   # FIXME: first we should search . and the directory the executable is in
13359   shlibpath_var=PATH
13360   ;;
13361
13362 darwin* | rhapsody*)
13363   dynamic_linker="$host_os dyld"
13364   version_type=darwin
13365   need_lib_prefix=no
13366   need_version=no
13367   library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
13368   soname_spec='$libname$release$major$shared_ext'
13369   shlibpath_overrides_runpath=yes
13370   shlibpath_var=DYLD_LIBRARY_PATH
13371   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
13372
13373   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
13374   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
13375   ;;
13376
13377 dgux*)
13378   version_type=linux # correct to gnu/linux during the next big refactor
13379   need_lib_prefix=no
13380   need_version=no
13381   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13382   soname_spec='$libname$release$shared_ext$major'
13383   shlibpath_var=LD_LIBRARY_PATH
13384   ;;
13385
13386 freebsd* | dragonfly*)
13387   # DragonFly does not have aout.  When/if they implement a new
13388   # versioning mechanism, adjust this.
13389   if test -x /usr/bin/objformat; then
13390     objformat=`/usr/bin/objformat`
13391   else
13392     case $host_os in
13393     freebsd[23].*) objformat=aout ;;
13394     *) objformat=elf ;;
13395     esac
13396   fi
13397   version_type=freebsd-$objformat
13398   case $version_type in
13399     freebsd-elf*)
13400       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13401       soname_spec='$libname$release$shared_ext$major'
13402       need_version=no
13403       need_lib_prefix=no
13404       ;;
13405     freebsd-*)
13406       library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13407       need_version=yes
13408       ;;
13409   esac
13410   shlibpath_var=LD_LIBRARY_PATH
13411   case $host_os in
13412   freebsd2.*)
13413     shlibpath_overrides_runpath=yes
13414     ;;
13415   freebsd3.[01]* | freebsdelf3.[01]*)
13416     shlibpath_overrides_runpath=yes
13417     hardcode_into_libs=yes
13418     ;;
13419   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
13420   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
13421     shlibpath_overrides_runpath=no
13422     hardcode_into_libs=yes
13423     ;;
13424   *) # from 4.6 on, and DragonFly
13425     shlibpath_overrides_runpath=yes
13426     hardcode_into_libs=yes
13427     ;;
13428   esac
13429   ;;
13430
13431 haiku*)
13432   version_type=linux # correct to gnu/linux during the next big refactor
13433   need_lib_prefix=no
13434   need_version=no
13435   dynamic_linker="$host_os runtime_loader"
13436   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13437   soname_spec='$libname$release$shared_ext$major'
13438   shlibpath_var=LIBRARY_PATH
13439   shlibpath_overrides_runpath=no
13440   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
13441   hardcode_into_libs=yes
13442   ;;
13443
13444 hpux9* | hpux10* | hpux11*)
13445   # Give a soname corresponding to the major version so that dld.sl refuses to
13446   # link against other versions.
13447   version_type=sunos
13448   need_lib_prefix=no
13449   need_version=no
13450   case $host_cpu in
13451   ia64*)
13452     shrext_cmds='.so'
13453     hardcode_into_libs=yes
13454     dynamic_linker="$host_os dld.so"
13455     shlibpath_var=LD_LIBRARY_PATH
13456     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13457     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13458     soname_spec='$libname$release$shared_ext$major'
13459     if test 32 = "$HPUX_IA64_MODE"; then
13460       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
13461       sys_lib_dlsearch_path_spec=/usr/lib/hpux32
13462     else
13463       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
13464       sys_lib_dlsearch_path_spec=/usr/lib/hpux64
13465     fi
13466     ;;
13467   hppa*64*)
13468     shrext_cmds='.sl'
13469     hardcode_into_libs=yes
13470     dynamic_linker="$host_os dld.sl"
13471     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
13472     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13473     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13474     soname_spec='$libname$release$shared_ext$major'
13475     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
13476     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13477     ;;
13478   *)
13479     shrext_cmds='.sl'
13480     dynamic_linker="$host_os dld.sl"
13481     shlibpath_var=SHLIB_PATH
13482     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
13483     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13484     soname_spec='$libname$release$shared_ext$major'
13485     ;;
13486   esac
13487   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
13488   postinstall_cmds='chmod 555 $lib'
13489   # or fails outright, so override atomically:
13490   install_override_mode=555
13491   ;;
13492
13493 interix[3-9]*)
13494   version_type=linux # correct to gnu/linux during the next big refactor
13495   need_lib_prefix=no
13496   need_version=no
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   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
13500   shlibpath_var=LD_LIBRARY_PATH
13501   shlibpath_overrides_runpath=no
13502   hardcode_into_libs=yes
13503   ;;
13504
13505 irix5* | irix6* | nonstopux*)
13506   case $host_os in
13507     nonstopux*) version_type=nonstopux ;;
13508     *)
13509         if test yes = "$lt_cv_prog_gnu_ld"; then
13510                 version_type=linux # correct to gnu/linux during the next big refactor
13511         else
13512                 version_type=irix
13513         fi ;;
13514   esac
13515   need_lib_prefix=no
13516   need_version=no
13517   soname_spec='$libname$release$shared_ext$major'
13518   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
13519   case $host_os in
13520   irix5* | nonstopux*)
13521     libsuff= shlibsuff=
13522     ;;
13523   *)
13524     case $LD in # libtool.m4 will add one of these switches to LD
13525     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
13526       libsuff= shlibsuff= libmagic=32-bit;;
13527     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
13528       libsuff=32 shlibsuff=N32 libmagic=N32;;
13529     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
13530       libsuff=64 shlibsuff=64 libmagic=64-bit;;
13531     *) libsuff= shlibsuff= libmagic=never-match;;
13532     esac
13533     ;;
13534   esac
13535   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
13536   shlibpath_overrides_runpath=no
13537   sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
13538   sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
13539   hardcode_into_libs=yes
13540   ;;
13541
13542 # No shared lib support for Linux oldld, aout, or coff.
13543 linux*oldld* | linux*aout* | linux*coff*)
13544   dynamic_linker=no
13545   ;;
13546
13547 linux*android*)
13548   version_type=none # Android doesn't support versioned libraries.
13549   need_lib_prefix=no
13550   need_version=no
13551   library_names_spec='$libname$release$shared_ext'
13552   soname_spec='$libname$release$shared_ext'
13553   finish_cmds=
13554   shlibpath_var=LD_LIBRARY_PATH
13555   shlibpath_overrides_runpath=yes
13556
13557   # This implies no fast_install, which is unacceptable.
13558   # Some rework will be needed to allow for fast_install
13559   # before this can be enabled.
13560   hardcode_into_libs=yes
13561
13562   dynamic_linker='Android linker'
13563   # Don't embed -rpath directories since the linker doesn't support them.
13564   hardcode_libdir_flag_spec='-L$libdir'
13565   ;;
13566
13567 # This must be glibc/ELF.
13568 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
13569   version_type=linux # correct to gnu/linux during the next big refactor
13570   need_lib_prefix=no
13571   need_version=no
13572   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13573   soname_spec='$libname$release$shared_ext$major'
13574   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
13575   shlibpath_var=LD_LIBRARY_PATH
13576   shlibpath_overrides_runpath=no
13577
13578   # Some binutils ld are patched to set DT_RUNPATH
13579   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
13580   $as_echo_n "(cached) " >&6
13581 else
13582   lt_cv_shlibpath_overrides_runpath=no
13583     save_LDFLAGS=$LDFLAGS
13584     save_libdir=$libdir
13585     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
13586          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
13587     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13588 /* end confdefs.h.  */
13589
13590 int
13591 main ()
13592 {
13593
13594   ;
13595   return 0;
13596 }
13597 _ACEOF
13598 if ac_fn_c_try_link "$LINENO"; then :
13599   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
13600   lt_cv_shlibpath_overrides_runpath=yes
13601 fi
13602 fi
13603 rm -f core conftest.err conftest.$ac_objext \
13604     conftest$ac_exeext conftest.$ac_ext
13605     LDFLAGS=$save_LDFLAGS
13606     libdir=$save_libdir
13607
13608 fi
13609
13610   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
13611
13612   # This implies no fast_install, which is unacceptable.
13613   # Some rework will be needed to allow for fast_install
13614   # before this can be enabled.
13615   hardcode_into_libs=yes
13616
13617   # Add ABI-specific directories to the system library path.
13618   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
13619
13620   # Ideally, we could use ldconfig to report *all* directores which are
13621   # searched for libraries, however this is still not possible.  Aside from not
13622   # being certain /sbin/ldconfig is available, command
13623   # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
13624   # even though it is searched at run-time.  Try to do the best guess by
13625   # appending ld.so.conf contents (and includes) to the search path.
13626   if test -f /etc/ld.so.conf; then
13627     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' ' '`
13628     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
13629   fi
13630
13631   # We used to test for /lib/ld.so.1 and disable shared libraries on
13632   # powerpc, because MkLinux only supported shared libraries with the
13633   # GNU dynamic linker.  Since this was broken with cross compilers,
13634   # most powerpc-linux boxes support dynamic linking these days and
13635   # people can always --disable-shared, the test was removed, and we
13636   # assume the GNU/Linux dynamic linker is in use.
13637   dynamic_linker='GNU/Linux ld.so'
13638   ;;
13639
13640 netbsd*)
13641   version_type=sunos
13642   need_lib_prefix=no
13643   need_version=no
13644   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13645     library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13646     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13647     dynamic_linker='NetBSD (a.out) ld.so'
13648   else
13649     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13650     soname_spec='$libname$release$shared_ext$major'
13651     dynamic_linker='NetBSD ld.elf_so'
13652   fi
13653   shlibpath_var=LD_LIBRARY_PATH
13654   shlibpath_overrides_runpath=yes
13655   hardcode_into_libs=yes
13656   ;;
13657
13658 newsos6)
13659   version_type=linux # correct to gnu/linux during the next big refactor
13660   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13661   shlibpath_var=LD_LIBRARY_PATH
13662   shlibpath_overrides_runpath=yes
13663   ;;
13664
13665 *nto* | *qnx*)
13666   version_type=qnx
13667   need_lib_prefix=no
13668   need_version=no
13669   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13670   soname_spec='$libname$release$shared_ext$major'
13671   shlibpath_var=LD_LIBRARY_PATH
13672   shlibpath_overrides_runpath=no
13673   hardcode_into_libs=yes
13674   dynamic_linker='ldqnx.so'
13675   ;;
13676
13677 openbsd* | bitrig*)
13678   version_type=sunos
13679   sys_lib_dlsearch_path_spec=/usr/lib
13680   need_lib_prefix=no
13681   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13682     need_version=no
13683   else
13684     need_version=yes
13685   fi
13686   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13687   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13688   shlibpath_var=LD_LIBRARY_PATH
13689   shlibpath_overrides_runpath=yes
13690   ;;
13691
13692 os2*)
13693   libname_spec='$name'
13694   version_type=windows
13695   shrext_cmds=.dll
13696   need_version=no
13697   need_lib_prefix=no
13698   # OS/2 can only load a DLL with a base name of 8 characters or less.
13699   soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
13700     v=$($ECHO $release$versuffix | tr -d .-);
13701     n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
13702     $ECHO $n$v`$shared_ext'
13703   library_names_spec='${libname}_dll.$libext'
13704   dynamic_linker='OS/2 ld.exe'
13705   shlibpath_var=BEGINLIBPATH
13706   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13707   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13708   postinstall_cmds='base_file=`basename \$file`~
13709     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
13710     dldir=$destdir/`dirname \$dlpath`~
13711     test -d \$dldir || mkdir -p \$dldir~
13712     $install_prog $dir/$dlname \$dldir/$dlname~
13713     chmod a+x \$dldir/$dlname~
13714     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13715       eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13716     fi'
13717   postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
13718     dlpath=$dir/\$dldll~
13719     $RM \$dlpath'
13720   ;;
13721
13722 osf3* | osf4* | osf5*)
13723   version_type=osf
13724   need_lib_prefix=no
13725   need_version=no
13726   soname_spec='$libname$release$shared_ext$major'
13727   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13728   shlibpath_var=LD_LIBRARY_PATH
13729   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13730   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13731   ;;
13732
13733 rdos*)
13734   dynamic_linker=no
13735   ;;
13736
13737 solaris*)
13738   version_type=linux # correct to gnu/linux during the next big refactor
13739   need_lib_prefix=no
13740   need_version=no
13741   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13742   soname_spec='$libname$release$shared_ext$major'
13743   shlibpath_var=LD_LIBRARY_PATH
13744   shlibpath_overrides_runpath=yes
13745   hardcode_into_libs=yes
13746   # ldd complains unless libraries are executable
13747   postinstall_cmds='chmod +x $lib'
13748   ;;
13749
13750 sunos4*)
13751   version_type=sunos
13752   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13753   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13754   shlibpath_var=LD_LIBRARY_PATH
13755   shlibpath_overrides_runpath=yes
13756   if test yes = "$with_gnu_ld"; then
13757     need_lib_prefix=no
13758   fi
13759   need_version=yes
13760   ;;
13761
13762 sysv4 | sysv4.3*)
13763   version_type=linux # correct to gnu/linux during the next big refactor
13764   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13765   soname_spec='$libname$release$shared_ext$major'
13766   shlibpath_var=LD_LIBRARY_PATH
13767   case $host_vendor in
13768     sni)
13769       shlibpath_overrides_runpath=no
13770       need_lib_prefix=no
13771       runpath_var=LD_RUN_PATH
13772       ;;
13773     siemens)
13774       need_lib_prefix=no
13775       ;;
13776     motorola)
13777       need_lib_prefix=no
13778       need_version=no
13779       shlibpath_overrides_runpath=no
13780       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13781       ;;
13782   esac
13783   ;;
13784
13785 sysv4*MP*)
13786   if test -d /usr/nec; then
13787     version_type=linux # correct to gnu/linux during the next big refactor
13788     library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
13789     soname_spec='$libname$shared_ext.$major'
13790     shlibpath_var=LD_LIBRARY_PATH
13791   fi
13792   ;;
13793
13794 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13795   version_type=sco
13796   need_lib_prefix=no
13797   need_version=no
13798   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
13799   soname_spec='$libname$release$shared_ext$major'
13800   shlibpath_var=LD_LIBRARY_PATH
13801   shlibpath_overrides_runpath=yes
13802   hardcode_into_libs=yes
13803   if test yes = "$with_gnu_ld"; then
13804     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13805   else
13806     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13807     case $host_os in
13808       sco3.2v5*)
13809         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13810         ;;
13811     esac
13812   fi
13813   sys_lib_dlsearch_path_spec='/usr/lib'
13814   ;;
13815
13816 tpf*)
13817   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
13818   version_type=linux # correct to gnu/linux during the next big refactor
13819   need_lib_prefix=no
13820   need_version=no
13821   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13822   shlibpath_var=LD_LIBRARY_PATH
13823   shlibpath_overrides_runpath=no
13824   hardcode_into_libs=yes
13825   ;;
13826
13827 uts4*)
13828   version_type=linux # correct to gnu/linux during the next big refactor
13829   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13830   soname_spec='$libname$release$shared_ext$major'
13831   shlibpath_var=LD_LIBRARY_PATH
13832   ;;
13833
13834 *)
13835   dynamic_linker=no
13836   ;;
13837 esac
13838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13839 $as_echo "$dynamic_linker" >&6; }
13840 test no = "$dynamic_linker" && can_build_shared=no
13841
13842 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13843 if test yes = "$GCC"; then
13844   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13845 fi
13846
13847 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
13848   sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
13849 fi
13850
13851 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
13852   sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
13853 fi
13854
13855 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
13856 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
13857
13858 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
13859 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
13860
13861 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
13862 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
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   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13961 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13962 hardcode_action=
13963 if test -n "$hardcode_libdir_flag_spec" ||
13964    test -n "$runpath_var" ||
13965    test yes = "$hardcode_automatic"; then
13966
13967   # We can hardcode non-existent directories.
13968   if test no != "$hardcode_direct" &&
13969      # If the only mechanism to avoid hardcoding is shlibpath_var, we
13970      # have to relink, otherwise we might link with an installed library
13971      # when we should be linking with a yet-to-be-installed one
13972      ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
13973      test no != "$hardcode_minus_L"; then
13974     # Linking always hardcodes the temporary library directory.
13975     hardcode_action=relink
13976   else
13977     # We can link without hardcoding, and we can hardcode nonexisting dirs.
13978     hardcode_action=immediate
13979   fi
13980 else
13981   # We cannot hardcode anything, or else we can only hardcode existing
13982   # directories.
13983   hardcode_action=unsupported
13984 fi
13985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
13986 $as_echo "$hardcode_action" >&6; }
13987
13988 if test relink = "$hardcode_action" ||
13989    test yes = "$inherit_rpath"; then
13990   # Fast installation is not supported
13991   enable_fast_install=no
13992 elif test yes = "$shlibpath_overrides_runpath" ||
13993      test no = "$enable_shared"; then
13994   # Fast installation is not necessary
13995   enable_fast_install=needless
13996 fi
13997
13998
13999
14000
14001
14002
14003   if test yes != "$enable_dlopen"; then
14004   enable_dlopen=unknown
14005   enable_dlopen_self=unknown
14006   enable_dlopen_self_static=unknown
14007 else
14008   lt_cv_dlopen=no
14009   lt_cv_dlopen_libs=
14010
14011   case $host_os in
14012   beos*)
14013     lt_cv_dlopen=load_add_on
14014     lt_cv_dlopen_libs=
14015     lt_cv_dlopen_self=yes
14016     ;;
14017
14018   mingw* | pw32* | cegcc*)
14019     lt_cv_dlopen=LoadLibrary
14020     lt_cv_dlopen_libs=
14021     ;;
14022
14023   cygwin*)
14024     lt_cv_dlopen=dlopen
14025     lt_cv_dlopen_libs=
14026     ;;
14027
14028   darwin*)
14029     # if libdl is installed we need to link against it
14030     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14031 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14032 if ${ac_cv_lib_dl_dlopen+:} false; then :
14033   $as_echo_n "(cached) " >&6
14034 else
14035   ac_check_lib_save_LIBS=$LIBS
14036 LIBS="-ldl  $LIBS"
14037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14038 /* end confdefs.h.  */
14039
14040 /* Override any GCC internal prototype to avoid an error.
14041    Use char because int might match the return type of a GCC
14042    builtin and then its argument prototype would still apply.  */
14043 #ifdef __cplusplus
14044 extern "C"
14045 #endif
14046 char dlopen ();
14047 int
14048 main ()
14049 {
14050 return dlopen ();
14051   ;
14052   return 0;
14053 }
14054 _ACEOF
14055 if ac_fn_c_try_link "$LINENO"; then :
14056   ac_cv_lib_dl_dlopen=yes
14057 else
14058   ac_cv_lib_dl_dlopen=no
14059 fi
14060 rm -f core conftest.err conftest.$ac_objext \
14061     conftest$ac_exeext conftest.$ac_ext
14062 LIBS=$ac_check_lib_save_LIBS
14063 fi
14064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14065 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14066 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14067   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14068 else
14069
14070     lt_cv_dlopen=dyld
14071     lt_cv_dlopen_libs=
14072     lt_cv_dlopen_self=yes
14073
14074 fi
14075
14076     ;;
14077
14078   tpf*)
14079     # Don't try to run any link tests for TPF.  We know it's impossible
14080     # because TPF is a cross-compiler, and we know how we open DSOs.
14081     lt_cv_dlopen=dlopen
14082     lt_cv_dlopen_libs=
14083     lt_cv_dlopen_self=no
14084     ;;
14085
14086   *)
14087     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14088 if test "x$ac_cv_func_shl_load" = xyes; then :
14089   lt_cv_dlopen=shl_load
14090 else
14091   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14092 $as_echo_n "checking for shl_load in -ldld... " >&6; }
14093 if ${ac_cv_lib_dld_shl_load+:} false; then :
14094   $as_echo_n "(cached) " >&6
14095 else
14096   ac_check_lib_save_LIBS=$LIBS
14097 LIBS="-ldld  $LIBS"
14098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14099 /* end confdefs.h.  */
14100
14101 /* Override any GCC internal prototype to avoid an error.
14102    Use char because int might match the return type of a GCC
14103    builtin and then its argument prototype would still apply.  */
14104 #ifdef __cplusplus
14105 extern "C"
14106 #endif
14107 char shl_load ();
14108 int
14109 main ()
14110 {
14111 return shl_load ();
14112   ;
14113   return 0;
14114 }
14115 _ACEOF
14116 if ac_fn_c_try_link "$LINENO"; then :
14117   ac_cv_lib_dld_shl_load=yes
14118 else
14119   ac_cv_lib_dld_shl_load=no
14120 fi
14121 rm -f core conftest.err conftest.$ac_objext \
14122     conftest$ac_exeext conftest.$ac_ext
14123 LIBS=$ac_check_lib_save_LIBS
14124 fi
14125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14126 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14127 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14128   lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14129 else
14130   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14131 if test "x$ac_cv_func_dlopen" = xyes; then :
14132   lt_cv_dlopen=dlopen
14133 else
14134   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14135 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14136 if ${ac_cv_lib_dl_dlopen+:} false; then :
14137   $as_echo_n "(cached) " >&6
14138 else
14139   ac_check_lib_save_LIBS=$LIBS
14140 LIBS="-ldl  $LIBS"
14141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14142 /* end confdefs.h.  */
14143
14144 /* Override any GCC internal prototype to avoid an error.
14145    Use char because int might match the return type of a GCC
14146    builtin and then its argument prototype would still apply.  */
14147 #ifdef __cplusplus
14148 extern "C"
14149 #endif
14150 char dlopen ();
14151 int
14152 main ()
14153 {
14154 return dlopen ();
14155   ;
14156   return 0;
14157 }
14158 _ACEOF
14159 if ac_fn_c_try_link "$LINENO"; then :
14160   ac_cv_lib_dl_dlopen=yes
14161 else
14162   ac_cv_lib_dl_dlopen=no
14163 fi
14164 rm -f core conftest.err conftest.$ac_objext \
14165     conftest$ac_exeext conftest.$ac_ext
14166 LIBS=$ac_check_lib_save_LIBS
14167 fi
14168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14169 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14170 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14171   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14172 else
14173   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14174 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
14175 if ${ac_cv_lib_svld_dlopen+:} false; then :
14176   $as_echo_n "(cached) " >&6
14177 else
14178   ac_check_lib_save_LIBS=$LIBS
14179 LIBS="-lsvld  $LIBS"
14180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14181 /* end confdefs.h.  */
14182
14183 /* Override any GCC internal prototype to avoid an error.
14184    Use char because int might match the return type of a GCC
14185    builtin and then its argument prototype would still apply.  */
14186 #ifdef __cplusplus
14187 extern "C"
14188 #endif
14189 char dlopen ();
14190 int
14191 main ()
14192 {
14193 return dlopen ();
14194   ;
14195   return 0;
14196 }
14197 _ACEOF
14198 if ac_fn_c_try_link "$LINENO"; then :
14199   ac_cv_lib_svld_dlopen=yes
14200 else
14201   ac_cv_lib_svld_dlopen=no
14202 fi
14203 rm -f core conftest.err conftest.$ac_objext \
14204     conftest$ac_exeext conftest.$ac_ext
14205 LIBS=$ac_check_lib_save_LIBS
14206 fi
14207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14208 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14209 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14210   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14211 else
14212   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14213 $as_echo_n "checking for dld_link in -ldld... " >&6; }
14214 if ${ac_cv_lib_dld_dld_link+:} false; then :
14215   $as_echo_n "(cached) " >&6
14216 else
14217   ac_check_lib_save_LIBS=$LIBS
14218 LIBS="-ldld  $LIBS"
14219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14220 /* end confdefs.h.  */
14221
14222 /* Override any GCC internal prototype to avoid an error.
14223    Use char because int might match the return type of a GCC
14224    builtin and then its argument prototype would still apply.  */
14225 #ifdef __cplusplus
14226 extern "C"
14227 #endif
14228 char dld_link ();
14229 int
14230 main ()
14231 {
14232 return dld_link ();
14233   ;
14234   return 0;
14235 }
14236 _ACEOF
14237 if ac_fn_c_try_link "$LINENO"; then :
14238   ac_cv_lib_dld_dld_link=yes
14239 else
14240   ac_cv_lib_dld_dld_link=no
14241 fi
14242 rm -f core conftest.err conftest.$ac_objext \
14243     conftest$ac_exeext conftest.$ac_ext
14244 LIBS=$ac_check_lib_save_LIBS
14245 fi
14246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14247 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14248 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14249   lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14250 fi
14251
14252
14253 fi
14254
14255
14256 fi
14257
14258
14259 fi
14260
14261
14262 fi
14263
14264
14265 fi
14266
14267     ;;
14268   esac
14269
14270   if test no = "$lt_cv_dlopen"; then
14271     enable_dlopen=no
14272   else
14273     enable_dlopen=yes
14274   fi
14275
14276   case $lt_cv_dlopen in
14277   dlopen)
14278     save_CPPFLAGS=$CPPFLAGS
14279     test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
14280
14281     save_LDFLAGS=$LDFLAGS
14282     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
14283
14284     save_LIBS=$LIBS
14285     LIBS="$lt_cv_dlopen_libs $LIBS"
14286
14287     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
14288 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
14289 if ${lt_cv_dlopen_self+:} false; then :
14290   $as_echo_n "(cached) " >&6
14291 else
14292           if test yes = "$cross_compiling"; then :
14293   lt_cv_dlopen_self=cross
14294 else
14295   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14296   lt_status=$lt_dlunknown
14297   cat > conftest.$ac_ext <<_LT_EOF
14298 #line $LINENO "configure"
14299 #include "confdefs.h"
14300
14301 #if HAVE_DLFCN_H
14302 #include <dlfcn.h>
14303 #endif
14304
14305 #include <stdio.h>
14306
14307 #ifdef RTLD_GLOBAL
14308 #  define LT_DLGLOBAL           RTLD_GLOBAL
14309 #else
14310 #  ifdef DL_GLOBAL
14311 #    define LT_DLGLOBAL         DL_GLOBAL
14312 #  else
14313 #    define LT_DLGLOBAL         0
14314 #  endif
14315 #endif
14316
14317 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14318    find out it does not work in some platform. */
14319 #ifndef LT_DLLAZY_OR_NOW
14320 #  ifdef RTLD_LAZY
14321 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14322 #  else
14323 #    ifdef DL_LAZY
14324 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14325 #    else
14326 #      ifdef RTLD_NOW
14327 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14328 #      else
14329 #        ifdef DL_NOW
14330 #          define LT_DLLAZY_OR_NOW      DL_NOW
14331 #        else
14332 #          define LT_DLLAZY_OR_NOW      0
14333 #        endif
14334 #      endif
14335 #    endif
14336 #  endif
14337 #endif
14338
14339 /* When -fvisibility=hidden is used, assume the code has been annotated
14340    correspondingly for the symbols needed.  */
14341 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14342 int fnord () __attribute__((visibility("default")));
14343 #endif
14344
14345 int fnord () { return 42; }
14346 int main ()
14347 {
14348   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14349   int status = $lt_dlunknown;
14350
14351   if (self)
14352     {
14353       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14354       else
14355         {
14356           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14357           else puts (dlerror ());
14358         }
14359       /* dlclose (self); */
14360     }
14361   else
14362     puts (dlerror ());
14363
14364   return status;
14365 }
14366 _LT_EOF
14367   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14368   (eval $ac_link) 2>&5
14369   ac_status=$?
14370   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14371   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14372     (./conftest; exit; ) >&5 2>/dev/null
14373     lt_status=$?
14374     case x$lt_status in
14375       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
14376       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
14377       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
14378     esac
14379   else :
14380     # compilation failed
14381     lt_cv_dlopen_self=no
14382   fi
14383 fi
14384 rm -fr conftest*
14385
14386
14387 fi
14388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
14389 $as_echo "$lt_cv_dlopen_self" >&6; }
14390
14391     if test yes = "$lt_cv_dlopen_self"; then
14392       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
14393       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
14394 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
14395 if ${lt_cv_dlopen_self_static+:} false; then :
14396   $as_echo_n "(cached) " >&6
14397 else
14398           if test yes = "$cross_compiling"; then :
14399   lt_cv_dlopen_self_static=cross
14400 else
14401   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14402   lt_status=$lt_dlunknown
14403   cat > conftest.$ac_ext <<_LT_EOF
14404 #line $LINENO "configure"
14405 #include "confdefs.h"
14406
14407 #if HAVE_DLFCN_H
14408 #include <dlfcn.h>
14409 #endif
14410
14411 #include <stdio.h>
14412
14413 #ifdef RTLD_GLOBAL
14414 #  define LT_DLGLOBAL           RTLD_GLOBAL
14415 #else
14416 #  ifdef DL_GLOBAL
14417 #    define LT_DLGLOBAL         DL_GLOBAL
14418 #  else
14419 #    define LT_DLGLOBAL         0
14420 #  endif
14421 #endif
14422
14423 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14424    find out it does not work in some platform. */
14425 #ifndef LT_DLLAZY_OR_NOW
14426 #  ifdef RTLD_LAZY
14427 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14428 #  else
14429 #    ifdef DL_LAZY
14430 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14431 #    else
14432 #      ifdef RTLD_NOW
14433 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14434 #      else
14435 #        ifdef DL_NOW
14436 #          define LT_DLLAZY_OR_NOW      DL_NOW
14437 #        else
14438 #          define LT_DLLAZY_OR_NOW      0
14439 #        endif
14440 #      endif
14441 #    endif
14442 #  endif
14443 #endif
14444
14445 /* When -fvisibility=hidden is used, assume the code has been annotated
14446    correspondingly for the symbols needed.  */
14447 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14448 int fnord () __attribute__((visibility("default")));
14449 #endif
14450
14451 int fnord () { return 42; }
14452 int main ()
14453 {
14454   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14455   int status = $lt_dlunknown;
14456
14457   if (self)
14458     {
14459       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14460       else
14461         {
14462           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14463           else puts (dlerror ());
14464         }
14465       /* dlclose (self); */
14466     }
14467   else
14468     puts (dlerror ());
14469
14470   return status;
14471 }
14472 _LT_EOF
14473   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14474   (eval $ac_link) 2>&5
14475   ac_status=$?
14476   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14477   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14478     (./conftest; exit; ) >&5 2>/dev/null
14479     lt_status=$?
14480     case x$lt_status in
14481       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
14482       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
14483       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
14484     esac
14485   else :
14486     # compilation failed
14487     lt_cv_dlopen_self_static=no
14488   fi
14489 fi
14490 rm -fr conftest*
14491
14492
14493 fi
14494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
14495 $as_echo "$lt_cv_dlopen_self_static" >&6; }
14496     fi
14497
14498     CPPFLAGS=$save_CPPFLAGS
14499     LDFLAGS=$save_LDFLAGS
14500     LIBS=$save_LIBS
14501     ;;
14502   esac
14503
14504   case $lt_cv_dlopen_self in
14505   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
14506   *) enable_dlopen_self=unknown ;;
14507   esac
14508
14509   case $lt_cv_dlopen_self_static in
14510   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
14511   *) enable_dlopen_self_static=unknown ;;
14512   esac
14513 fi
14514
14515
14516
14517
14518
14519
14520
14521
14522
14523
14524
14525
14526
14527
14528
14529
14530
14531 striplib=
14532 old_striplib=
14533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
14534 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
14535 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
14536   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
14537   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
14538   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14539 $as_echo "yes" >&6; }
14540 else
14541 # FIXME - insert some real tests, host_os isn't really good enough
14542   case $host_os in
14543   darwin*)
14544     if test -n "$STRIP"; then
14545       striplib="$STRIP -x"
14546       old_striplib="$STRIP -S"
14547       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14548 $as_echo "yes" >&6; }
14549     else
14550       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14551 $as_echo "no" >&6; }
14552     fi
14553     ;;
14554   *)
14555     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14556 $as_echo "no" >&6; }
14557     ;;
14558   esac
14559 fi
14560
14561
14562
14563
14564
14565
14566
14567
14568
14569
14570
14571
14572   # Report what library types will actually be built
14573   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
14574 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
14575   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
14576 $as_echo "$can_build_shared" >&6; }
14577
14578   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
14579 $as_echo_n "checking whether to build shared libraries... " >&6; }
14580   test no = "$can_build_shared" && enable_shared=no
14581
14582   # On AIX, shared libraries and static libraries use the same namespace, and
14583   # are all built from PIC.
14584   case $host_os in
14585   aix3*)
14586     test yes = "$enable_shared" && enable_static=no
14587     if test -n "$RANLIB"; then
14588       archive_cmds="$archive_cmds~\$RANLIB \$lib"
14589       postinstall_cmds='$RANLIB $lib'
14590     fi
14591     ;;
14592
14593   aix[4-9]*)
14594     if test ia64 != "$host_cpu"; then
14595       case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
14596       yes,aix,yes) ;;                   # shared object as lib.so file only
14597       yes,svr4,*) ;;                    # shared object as lib.so archive member only
14598       yes,*) enable_static=no ;;        # shared object in lib.a archive as well
14599       esac
14600     fi
14601     ;;
14602   esac
14603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
14604 $as_echo "$enable_shared" >&6; }
14605
14606   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
14607 $as_echo_n "checking whether to build static libraries... " >&6; }
14608   # Make sure either enable_shared or enable_static is yes.
14609   test yes = "$enable_shared" || enable_static=yes
14610   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
14611 $as_echo "$enable_static" >&6; }
14612
14613
14614
14615
14616 fi
14617 ac_ext=c
14618 ac_cpp='$CPP $CPPFLAGS'
14619 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14620 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14621 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14622
14623 CC=$lt_save_CC
14624
14625
14626
14627
14628
14629
14630
14631
14632
14633
14634
14635
14636
14637
14638
14639         ac_config_commands="$ac_config_commands libtool"
14640
14641
14642
14643
14644 # Only expand once:
14645
14646
14647
14648
14649 # pkg-config is only needed for these options, do not require it otherwise
14650 if test "$enable_systemd" = "yes" -o "$with_pyunbound" = "yes" -o "$with_pythonmod" = "yes"; then
14651
14652
14653
14654
14655
14656
14657
14658 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
14659         if test -n "$ac_tool_prefix"; then
14660   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
14661 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
14662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14663 $as_echo_n "checking for $ac_word... " >&6; }
14664 if ${ac_cv_path_PKG_CONFIG+:} false; then :
14665   $as_echo_n "(cached) " >&6
14666 else
14667   case $PKG_CONFIG in
14668   [\\/]* | ?:[\\/]*)
14669   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
14670   ;;
14671   *)
14672   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14673 for as_dir in $PATH
14674 do
14675   IFS=$as_save_IFS
14676   test -z "$as_dir" && as_dir=.
14677     for ac_exec_ext in '' $ac_executable_extensions; do
14678   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14679     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14680     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14681     break 2
14682   fi
14683 done
14684   done
14685 IFS=$as_save_IFS
14686
14687   ;;
14688 esac
14689 fi
14690 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
14691 if test -n "$PKG_CONFIG"; then
14692   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
14693 $as_echo "$PKG_CONFIG" >&6; }
14694 else
14695   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14696 $as_echo "no" >&6; }
14697 fi
14698
14699
14700 fi
14701 if test -z "$ac_cv_path_PKG_CONFIG"; then
14702   ac_pt_PKG_CONFIG=$PKG_CONFIG
14703   # Extract the first word of "pkg-config", so it can be a program name with args.
14704 set dummy pkg-config; ac_word=$2
14705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14706 $as_echo_n "checking for $ac_word... " >&6; }
14707 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
14708   $as_echo_n "(cached) " >&6
14709 else
14710   case $ac_pt_PKG_CONFIG in
14711   [\\/]* | ?:[\\/]*)
14712   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
14713   ;;
14714   *)
14715   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14716 for as_dir in $PATH
14717 do
14718   IFS=$as_save_IFS
14719   test -z "$as_dir" && as_dir=.
14720     for ac_exec_ext in '' $ac_executable_extensions; do
14721   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14722     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14723     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14724     break 2
14725   fi
14726 done
14727   done
14728 IFS=$as_save_IFS
14729
14730   ;;
14731 esac
14732 fi
14733 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
14734 if test -n "$ac_pt_PKG_CONFIG"; then
14735   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
14736 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
14737 else
14738   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14739 $as_echo "no" >&6; }
14740 fi
14741
14742   if test "x$ac_pt_PKG_CONFIG" = x; then
14743     PKG_CONFIG=""
14744   else
14745     case $cross_compiling:$ac_tool_warned in
14746 yes:)
14747 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
14748 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
14749 ac_tool_warned=yes ;;
14750 esac
14751     PKG_CONFIG=$ac_pt_PKG_CONFIG
14752   fi
14753 else
14754   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
14755 fi
14756
14757 fi
14758 if test -n "$PKG_CONFIG"; then
14759         _pkg_min_version=0.9.0
14760         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
14761 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
14762         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
14763                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14764 $as_echo "yes" >&6; }
14765         else
14766                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14767 $as_echo "no" >&6; }
14768                 PKG_CONFIG=""
14769         fi
14770 fi
14771 fi
14772
14773 # Checks for header files.
14774 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
14775 do :
14776   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14777 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
14778 "
14779 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14780   cat >>confdefs.h <<_ACEOF
14781 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14782 _ACEOF
14783
14784 fi
14785
14786 done
14787
14788 # net/if.h portability for Darwin see:
14789 # https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Header-Portability.html
14790 for ac_header in net/if.h
14791 do :
14792   ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
14793 #include <stdio.h>
14794 #ifdef STDC_HEADERS
14795 # include <stdlib.h>
14796 # include <stddef.h>
14797 #else
14798 # ifdef HAVE_STDLIB_H
14799 #  include <stdlib.h>
14800 # endif
14801 #endif
14802 #ifdef HAVE_SYS_SOCKET_H
14803 # include <sys/socket.h>
14804 #endif
14805
14806 "
14807 if test "x$ac_cv_header_net_if_h" = xyes; then :
14808   cat >>confdefs.h <<_ACEOF
14809 #define HAVE_NET_IF_H 1
14810 _ACEOF
14811
14812 fi
14813
14814 done
14815
14816
14817 # Check for Apple header. This uncovers TARGET_OS_IPHONE, TARGET_OS_TV or TARGET_OS_WATCH
14818 for ac_header in TargetConditionals.h
14819 do :
14820   ac_fn_c_check_header_compile "$LINENO" "TargetConditionals.h" "ac_cv_header_TargetConditionals_h" "$ac_includes_default
14821 "
14822 if test "x$ac_cv_header_TargetConditionals_h" = xyes; then :
14823   cat >>confdefs.h <<_ACEOF
14824 #define HAVE_TARGETCONDITIONALS_H 1
14825 _ACEOF
14826
14827 fi
14828
14829 done
14830
14831 for ac_header in netioapi.h
14832 do :
14833   ac_fn_c_check_header_compile "$LINENO" "netioapi.h" "ac_cv_header_netioapi_h" "$ac_includes_default
14834 #if HAVE_SYS_PARAM_H
14835 #include <sys/param.h>
14836 #endif
14837
14838 #ifdef HAVE_SYS_SOCKET_H
14839 #include <sys/socket.h>
14840 #endif
14841
14842 #ifdef HAVE_SYS_UIO_H
14843 #include <sys/uio.h>
14844 #endif
14845
14846 #ifdef HAVE_NETINET_IN_H
14847 #include <netinet/in.h>
14848 #endif
14849
14850 #ifdef HAVE_NETINET_TCP_H
14851 #include <netinet/tcp.h>
14852 #endif
14853
14854 #ifdef HAVE_ARPA_INET_H
14855 #include <arpa/inet.h>
14856 #endif
14857
14858 #ifdef HAVE_WINSOCK2_H
14859 #include <winsock2.h>
14860 #endif
14861
14862 #ifdef HAVE_WS2TCPIP_H
14863 #include <ws2tcpip.h>
14864 #endif
14865
14866 "
14867 if test "x$ac_cv_header_netioapi_h" = xyes; then :
14868   cat >>confdefs.h <<_ACEOF
14869 #define HAVE_NETIOAPI_H 1
14870 _ACEOF
14871
14872 fi
14873
14874 done
14875
14876
14877 # check for types.
14878 # Using own tests for int64* because autoconf builtin only give 32bit.
14879 ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
14880 if test "x$ac_cv_type_int8_t" = xyes; then :
14881
14882 else
14883
14884 cat >>confdefs.h <<_ACEOF
14885 #define int8_t signed char
14886 _ACEOF
14887
14888 fi
14889
14890 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
14891 if test "x$ac_cv_type_int16_t" = xyes; then :
14892
14893 else
14894
14895 cat >>confdefs.h <<_ACEOF
14896 #define int16_t short
14897 _ACEOF
14898
14899 fi
14900
14901 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
14902 if test "x$ac_cv_type_int32_t" = xyes; then :
14903
14904 else
14905
14906 cat >>confdefs.h <<_ACEOF
14907 #define int32_t int
14908 _ACEOF
14909
14910 fi
14911
14912 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
14913 if test "x$ac_cv_type_int64_t" = xyes; then :
14914
14915 else
14916
14917 cat >>confdefs.h <<_ACEOF
14918 #define int64_t long long
14919 _ACEOF
14920
14921 fi
14922
14923 ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
14924 if test "x$ac_cv_type_uint8_t" = xyes; then :
14925
14926 else
14927
14928 cat >>confdefs.h <<_ACEOF
14929 #define uint8_t unsigned char
14930 _ACEOF
14931
14932 fi
14933
14934 ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
14935 if test "x$ac_cv_type_uint16_t" = xyes; then :
14936
14937 else
14938
14939 cat >>confdefs.h <<_ACEOF
14940 #define uint16_t unsigned short
14941 _ACEOF
14942
14943 fi
14944
14945 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
14946 if test "x$ac_cv_type_uint32_t" = xyes; then :
14947
14948 else
14949
14950 cat >>confdefs.h <<_ACEOF
14951 #define uint32_t unsigned int
14952 _ACEOF
14953
14954 fi
14955
14956 ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
14957 if test "x$ac_cv_type_uint64_t" = xyes; then :
14958
14959 else
14960
14961 cat >>confdefs.h <<_ACEOF
14962 #define uint64_t unsigned long long
14963 _ACEOF
14964
14965 fi
14966
14967 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
14968 if test "x$ac_cv_type_size_t" = xyes; then :
14969
14970 else
14971
14972 cat >>confdefs.h <<_ACEOF
14973 #define size_t unsigned int
14974 _ACEOF
14975
14976 fi
14977
14978 ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
14979 if test "x$ac_cv_type_ssize_t" = xyes; then :
14980
14981 else
14982
14983 cat >>confdefs.h <<_ACEOF
14984 #define ssize_t int
14985 _ACEOF
14986
14987 fi
14988
14989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
14990 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
14991 if ${ac_cv_type_uid_t+:} false; then :
14992   $as_echo_n "(cached) " >&6
14993 else
14994   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14995 /* end confdefs.h.  */
14996 #include <sys/types.h>
14997
14998 _ACEOF
14999 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15000   $EGREP "uid_t" >/dev/null 2>&1; then :
15001   ac_cv_type_uid_t=yes
15002 else
15003   ac_cv_type_uid_t=no
15004 fi
15005 rm -f conftest*
15006
15007 fi
15008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
15009 $as_echo "$ac_cv_type_uid_t" >&6; }
15010 if test $ac_cv_type_uid_t = no; then
15011
15012 $as_echo "#define uid_t int" >>confdefs.h
15013
15014
15015 $as_echo "#define gid_t int" >>confdefs.h
15016
15017 fi
15018
15019 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15020 if test "x$ac_cv_type_pid_t" = xyes; then :
15021
15022 else
15023
15024 cat >>confdefs.h <<_ACEOF
15025 #define pid_t int
15026 _ACEOF
15027
15028 fi
15029
15030 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
15031 if test "x$ac_cv_type_off_t" = xyes; then :
15032
15033 else
15034
15035 cat >>confdefs.h <<_ACEOF
15036 #define off_t long int
15037 _ACEOF
15038
15039 fi
15040
15041 ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "
15042 $ac_includes_default
15043 #ifdef HAVE_WINSOCK2_H
15044 #  include <winsock2.h>
15045 #endif
15046
15047 "
15048 if test "x$ac_cv_type_u_char" = xyes; then :
15049
15050 else
15051
15052 $as_echo "#define u_char unsigned char" >>confdefs.h
15053
15054 fi
15055
15056 ac_fn_c_check_type "$LINENO" "rlim_t" "ac_cv_type_rlim_t" "
15057 $ac_includes_default
15058 #ifdef HAVE_SYS_RESOURCE_H
15059 #  include <sys/resource.h>
15060 #endif
15061
15062 "
15063 if test "x$ac_cv_type_rlim_t" = xyes; then :
15064
15065 else
15066
15067 $as_echo "#define rlim_t unsigned long" >>confdefs.h
15068
15069 fi
15070
15071
15072 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
15073 $ac_includes_default
15074 #ifdef HAVE_SYS_SOCKET_H
15075 #  include <sys/socket.h>
15076 #endif
15077 #ifdef HAVE_WS2TCPIP_H
15078 #  include <ws2tcpip.h>
15079 #endif
15080
15081 "
15082 if test "x$ac_cv_type_socklen_t" = xyes; then :
15083
15084 else
15085
15086 $as_echo "#define socklen_t int" >>confdefs.h
15087
15088 fi
15089
15090  ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
15091 $ac_includes_default
15092 #ifdef HAVE_SYS_TYPES_H
15093 # include <sys/types.h>
15094 #endif
15095 #ifdef HAVE_NETINET_IN_H
15096 # include <netinet/in.h>
15097 #endif
15098
15099 "
15100 if test "x$ac_cv_type_in_addr_t" = xyes; then :
15101
15102 else
15103
15104 $as_echo "#define in_addr_t uint32_t" >>confdefs.h
15105
15106 fi
15107
15108  ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "
15109 $ac_includes_default
15110 #ifdef HAVE_SYS_TYPES_H
15111 # include <sys/types.h>
15112 #endif
15113 #ifdef HAVE_NETINET_IN_H
15114 # include <netinet/in.h>
15115 #endif
15116
15117 "
15118 if test "x$ac_cv_type_in_port_t" = xyes; then :
15119
15120 else
15121
15122 $as_echo "#define in_port_t uint16_t" >>confdefs.h
15123
15124 fi
15125
15126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memcmp compares unsigned" >&5
15127 $as_echo_n "checking if memcmp compares unsigned... " >&6; }
15128 if test "$cross_compiling" = yes; then :
15129    { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile no" >&5
15130 $as_echo "cross-compile no" >&6; }
15131
15132 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15133
15134   case " $LIBOBJS " in
15135   *" memcmp.$ac_objext "* ) ;;
15136   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15137  ;;
15138 esac
15139
15140
15141 else
15142   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15143 /* end confdefs.h.  */
15144
15145 #include <stdio.h>
15146 #include <stdlib.h>
15147 #include <string.h>
15148 int main(void)
15149 {
15150         char a = 255, b = 0;
15151         if(memcmp(&a, &b, 1) < 0)
15152                 return 1;
15153         return 0;
15154 }
15155
15156 _ACEOF
15157 if ac_fn_c_try_run "$LINENO"; then :
15158   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15159 $as_echo "yes" >&6; }
15160 else
15161    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15162 $as_echo "no" >&6; }
15163
15164 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15165
15166   case " $LIBOBJS " in
15167   *" memcmp.$ac_objext "* ) ;;
15168   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15169  ;;
15170 esac
15171
15172
15173 fi
15174 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15175   conftest.$ac_objext conftest.beam conftest.$ac_ext
15176 fi
15177
15178
15179 # The cast to long int works around a bug in the HP C Compiler
15180 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15181 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15182 # This bug is HP SR number 8606223364.
15183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
15184 $as_echo_n "checking size of time_t... " >&6; }
15185 if ${ac_cv_sizeof_time_t+:} false; then :
15186   $as_echo_n "(cached) " >&6
15187 else
15188   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "
15189 $ac_includes_default
15190 #ifdef TIME_WITH_SYS_TIME
15191 # include <sys/time.h>
15192 # include <time.h>
15193 #else
15194 # ifdef HAVE_SYS_TIME_H
15195 #  include <sys/time.h>
15196 # else
15197 #  include <time.h>
15198 # endif
15199 #endif
15200
15201 "; then :
15202
15203 else
15204   if test "$ac_cv_type_time_t" = yes; then
15205      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15206 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15207 as_fn_error 77 "cannot compute sizeof (time_t)
15208 See \`config.log' for more details" "$LINENO" 5; }
15209    else
15210      ac_cv_sizeof_time_t=0
15211    fi
15212 fi
15213
15214 fi
15215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
15216 $as_echo "$ac_cv_sizeof_time_t" >&6; }
15217
15218
15219
15220 cat >>confdefs.h <<_ACEOF
15221 #define SIZEOF_TIME_T $ac_cv_sizeof_time_t
15222 _ACEOF
15223
15224
15225 # The cast to long int works around a bug in the HP C Compiler
15226 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15227 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15228 # This bug is HP SR number 8606223364.
15229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
15230 $as_echo_n "checking size of size_t... " >&6; }
15231 if ${ac_cv_sizeof_size_t+:} false; then :
15232   $as_echo_n "(cached) " >&6
15233 else
15234   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t"        "$ac_includes_default"; then :
15235
15236 else
15237   if test "$ac_cv_type_size_t" = yes; then
15238      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15239 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15240 as_fn_error 77 "cannot compute sizeof (size_t)
15241 See \`config.log' for more details" "$LINENO" 5; }
15242    else
15243      ac_cv_sizeof_size_t=0
15244    fi
15245 fi
15246
15247 fi
15248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
15249 $as_echo "$ac_cv_sizeof_size_t" >&6; }
15250
15251
15252
15253 cat >>confdefs.h <<_ACEOF
15254 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
15255 _ACEOF
15256
15257
15258
15259 # add option to disable the evil rpath
15260
15261 # Check whether --enable-rpath was given.
15262 if test "${enable_rpath+set}" = set; then :
15263   enableval=$enable_rpath; enable_rpath=$enableval
15264 else
15265   enable_rpath=yes
15266 fi
15267
15268 if test "x$enable_rpath" = xno; then
15269                 ac_config_commands="$ac_config_commands disable-rpath"
15270
15271 fi
15272
15273
15274
15275 # check to see if libraries are needed for these functions.
15276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
15277 $as_echo_n "checking for library containing inet_pton... " >&6; }
15278 if ${ac_cv_search_inet_pton+:} false; then :
15279   $as_echo_n "(cached) " >&6
15280 else
15281   ac_func_search_save_LIBS=$LIBS
15282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15283 /* end confdefs.h.  */
15284
15285 /* Override any GCC internal prototype to avoid an error.
15286    Use char because int might match the return type of a GCC
15287    builtin and then its argument prototype would still apply.  */
15288 #ifdef __cplusplus
15289 extern "C"
15290 #endif
15291 char inet_pton ();
15292 int
15293 main ()
15294 {
15295 return inet_pton ();
15296   ;
15297   return 0;
15298 }
15299 _ACEOF
15300 for ac_lib in '' nsl; do
15301   if test -z "$ac_lib"; then
15302     ac_res="none required"
15303   else
15304     ac_res=-l$ac_lib
15305     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15306   fi
15307   if ac_fn_c_try_link "$LINENO"; then :
15308   ac_cv_search_inet_pton=$ac_res
15309 fi
15310 rm -f core conftest.err conftest.$ac_objext \
15311     conftest$ac_exeext
15312   if ${ac_cv_search_inet_pton+:} false; then :
15313   break
15314 fi
15315 done
15316 if ${ac_cv_search_inet_pton+:} false; then :
15317
15318 else
15319   ac_cv_search_inet_pton=no
15320 fi
15321 rm conftest.$ac_ext
15322 LIBS=$ac_func_search_save_LIBS
15323 fi
15324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
15325 $as_echo "$ac_cv_search_inet_pton" >&6; }
15326 ac_res=$ac_cv_search_inet_pton
15327 if test "$ac_res" != no; then :
15328   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15329
15330 fi
15331
15332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
15333 $as_echo_n "checking for library containing socket... " >&6; }
15334 if ${ac_cv_search_socket+:} false; then :
15335   $as_echo_n "(cached) " >&6
15336 else
15337   ac_func_search_save_LIBS=$LIBS
15338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15339 /* end confdefs.h.  */
15340
15341 /* Override any GCC internal prototype to avoid an error.
15342    Use char because int might match the return type of a GCC
15343    builtin and then its argument prototype would still apply.  */
15344 #ifdef __cplusplus
15345 extern "C"
15346 #endif
15347 char socket ();
15348 int
15349 main ()
15350 {
15351 return socket ();
15352   ;
15353   return 0;
15354 }
15355 _ACEOF
15356 for ac_lib in '' socket; do
15357   if test -z "$ac_lib"; then
15358     ac_res="none required"
15359   else
15360     ac_res=-l$ac_lib
15361     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15362   fi
15363   if ac_fn_c_try_link "$LINENO"; then :
15364   ac_cv_search_socket=$ac_res
15365 fi
15366 rm -f core conftest.err conftest.$ac_objext \
15367     conftest$ac_exeext
15368   if ${ac_cv_search_socket+:} false; then :
15369   break
15370 fi
15371 done
15372 if ${ac_cv_search_socket+:} false; then :
15373
15374 else
15375   ac_cv_search_socket=no
15376 fi
15377 rm conftest.$ac_ext
15378 LIBS=$ac_func_search_save_LIBS
15379 fi
15380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
15381 $as_echo "$ac_cv_search_socket" >&6; }
15382 ac_res=$ac_cv_search_socket
15383 if test "$ac_res" != no; then :
15384   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15385
15386 fi
15387
15388
15389 # check whether strptime also works
15390
15391 # check some functions of the OS before linking libs (while still runnable).
15392 for ac_header in unistd.h
15393 do :
15394   ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
15395 if test "x$ac_cv_header_unistd_h" = xyes; then :
15396   cat >>confdefs.h <<_ACEOF
15397 #define HAVE_UNISTD_H 1
15398 _ACEOF
15399
15400 fi
15401
15402 done
15403
15404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
15405 $as_echo_n "checking for working chown... " >&6; }
15406 if ${ac_cv_func_chown_works+:} false; then :
15407   $as_echo_n "(cached) " >&6
15408 else
15409   if test "$cross_compiling" = yes; then :
15410   ac_cv_func_chown_works=no
15411 else
15412   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15413 /* end confdefs.h.  */
15414 $ac_includes_default
15415 #include <fcntl.h>
15416
15417 int
15418 main ()
15419 {
15420   char *f = "conftest.chown";
15421   struct stat before, after;
15422
15423   if (creat (f, 0600) < 0)
15424     return 1;
15425   if (stat (f, &before) < 0)
15426     return 1;
15427   if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
15428     return 1;
15429   if (stat (f, &after) < 0)
15430     return 1;
15431   return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
15432
15433   ;
15434   return 0;
15435 }
15436 _ACEOF
15437 if ac_fn_c_try_run "$LINENO"; then :
15438   ac_cv_func_chown_works=yes
15439 else
15440   ac_cv_func_chown_works=no
15441 fi
15442 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15443   conftest.$ac_objext conftest.beam conftest.$ac_ext
15444 fi
15445
15446 rm -f conftest.chown
15447
15448 fi
15449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
15450 $as_echo "$ac_cv_func_chown_works" >&6; }
15451 if test $ac_cv_func_chown_works = yes; then
15452
15453 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
15454
15455 fi
15456
15457 for ac_header in vfork.h
15458 do :
15459   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15460 if test "x$ac_cv_header_vfork_h" = xyes; then :
15461   cat >>confdefs.h <<_ACEOF
15462 #define HAVE_VFORK_H 1
15463 _ACEOF
15464
15465 fi
15466
15467 done
15468
15469 for ac_func in fork vfork
15470 do :
15471   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15472 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15473 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15474   cat >>confdefs.h <<_ACEOF
15475 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15476 _ACEOF
15477
15478 fi
15479 done
15480
15481 if test "x$ac_cv_func_fork" = xyes; then
15482   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15483 $as_echo_n "checking for working fork... " >&6; }
15484 if ${ac_cv_func_fork_works+:} false; then :
15485   $as_echo_n "(cached) " >&6
15486 else
15487   if test "$cross_compiling" = yes; then :
15488   ac_cv_func_fork_works=cross
15489 else
15490   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15491 /* end confdefs.h.  */
15492 $ac_includes_default
15493 int
15494 main ()
15495 {
15496
15497           /* By Ruediger Kuhlmann. */
15498           return fork () < 0;
15499
15500   ;
15501   return 0;
15502 }
15503 _ACEOF
15504 if ac_fn_c_try_run "$LINENO"; then :
15505   ac_cv_func_fork_works=yes
15506 else
15507   ac_cv_func_fork_works=no
15508 fi
15509 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15510   conftest.$ac_objext conftest.beam conftest.$ac_ext
15511 fi
15512
15513 fi
15514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15515 $as_echo "$ac_cv_func_fork_works" >&6; }
15516
15517 else
15518   ac_cv_func_fork_works=$ac_cv_func_fork
15519 fi
15520 if test "x$ac_cv_func_fork_works" = xcross; then
15521   case $host in
15522     *-*-amigaos* | *-*-msdosdjgpp*)
15523       # Override, as these systems have only a dummy fork() stub
15524       ac_cv_func_fork_works=no
15525       ;;
15526     *)
15527       ac_cv_func_fork_works=yes
15528       ;;
15529   esac
15530   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15531 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15532 fi
15533 ac_cv_func_vfork_works=$ac_cv_func_vfork
15534 if test "x$ac_cv_func_vfork" = xyes; then
15535   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15536 $as_echo_n "checking for working vfork... " >&6; }
15537 if ${ac_cv_func_vfork_works+:} false; then :
15538   $as_echo_n "(cached) " >&6
15539 else
15540   if test "$cross_compiling" = yes; then :
15541   ac_cv_func_vfork_works=cross
15542 else
15543   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15544 /* end confdefs.h.  */
15545 /* Thanks to Paul Eggert for this test.  */
15546 $ac_includes_default
15547 #include <sys/wait.h>
15548 #ifdef HAVE_VFORK_H
15549 # include <vfork.h>
15550 #endif
15551 /* On some sparc systems, changes by the child to local and incoming
15552    argument registers are propagated back to the parent.  The compiler
15553    is told about this with #include <vfork.h>, but some compilers
15554    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
15555    static variable whose address is put into a register that is
15556    clobbered by the vfork.  */
15557 static void
15558 #ifdef __cplusplus
15559 sparc_address_test (int arg)
15560 # else
15561 sparc_address_test (arg) int arg;
15562 #endif
15563 {
15564   static pid_t child;
15565   if (!child) {
15566     child = vfork ();
15567     if (child < 0) {
15568       perror ("vfork");
15569       _exit(2);
15570     }
15571     if (!child) {
15572       arg = getpid();
15573       write(-1, "", 0);
15574       _exit (arg);
15575     }
15576   }
15577 }
15578
15579 int
15580 main ()
15581 {
15582   pid_t parent = getpid ();
15583   pid_t child;
15584
15585   sparc_address_test (0);
15586
15587   child = vfork ();
15588
15589   if (child == 0) {
15590     /* Here is another test for sparc vfork register problems.  This
15591        test uses lots of local variables, at least as many local
15592        variables as main has allocated so far including compiler
15593        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
15594        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
15595        reuse the register of parent for one of the local variables,
15596        since it will think that parent can't possibly be used any more
15597        in this routine.  Assigning to the local variable will thus
15598        munge parent in the parent process.  */
15599     pid_t
15600       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15601       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15602     /* Convince the compiler that p..p7 are live; otherwise, it might
15603        use the same hardware register for all 8 local variables.  */
15604     if (p != p1 || p != p2 || p != p3 || p != p4
15605         || p != p5 || p != p6 || p != p7)
15606       _exit(1);
15607
15608     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15609        from child file descriptors.  If the child closes a descriptor
15610        before it execs or exits, this munges the parent's descriptor
15611        as well.  Test for this by closing stdout in the child.  */
15612     _exit(close(fileno(stdout)) != 0);
15613   } else {
15614     int status;
15615     struct stat st;
15616
15617     while (wait(&status) != child)
15618       ;
15619     return (
15620          /* Was there some problem with vforking?  */
15621          child < 0
15622
15623          /* Did the child fail?  (This shouldn't happen.)  */
15624          || status
15625
15626          /* Did the vfork/compiler bug occur?  */
15627          || parent != getpid()
15628
15629          /* Did the file descriptor bug occur?  */
15630          || fstat(fileno(stdout), &st) != 0
15631          );
15632   }
15633 }
15634 _ACEOF
15635 if ac_fn_c_try_run "$LINENO"; then :
15636   ac_cv_func_vfork_works=yes
15637 else
15638   ac_cv_func_vfork_works=no
15639 fi
15640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15641   conftest.$ac_objext conftest.beam conftest.$ac_ext
15642 fi
15643
15644 fi
15645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15646 $as_echo "$ac_cv_func_vfork_works" >&6; }
15647
15648 fi;
15649 if test "x$ac_cv_func_fork_works" = xcross; then
15650   ac_cv_func_vfork_works=$ac_cv_func_vfork
15651   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15652 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15653 fi
15654
15655 if test "x$ac_cv_func_vfork_works" = xyes; then
15656
15657 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15658
15659 else
15660
15661 $as_echo "#define vfork fork" >>confdefs.h
15662
15663 fi
15664 if test "x$ac_cv_func_fork_works" = xyes; then
15665
15666 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15667
15668 fi
15669
15670
15671 $as_echo "#define RETSIGTYPE void" >>confdefs.h
15672
15673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15674 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15675 if ${ac_cv_sys_largefile_source+:} false; then :
15676   $as_echo_n "(cached) " >&6
15677 else
15678   while :; do
15679   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15680 /* end confdefs.h.  */
15681 #include <sys/types.h> /* for off_t */
15682      #include <stdio.h>
15683 int
15684 main ()
15685 {
15686 int (*fp) (FILE *, off_t, int) = fseeko;
15687      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15688   ;
15689   return 0;
15690 }
15691 _ACEOF
15692 if ac_fn_c_try_link "$LINENO"; then :
15693   ac_cv_sys_largefile_source=no; break
15694 fi
15695 rm -f core conftest.err conftest.$ac_objext \
15696     conftest$ac_exeext conftest.$ac_ext
15697   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15698 /* end confdefs.h.  */
15699 #define _LARGEFILE_SOURCE 1
15700 #include <sys/types.h> /* for off_t */
15701      #include <stdio.h>
15702 int
15703 main ()
15704 {
15705 int (*fp) (FILE *, off_t, int) = fseeko;
15706      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15707   ;
15708   return 0;
15709 }
15710 _ACEOF
15711 if ac_fn_c_try_link "$LINENO"; then :
15712   ac_cv_sys_largefile_source=1; break
15713 fi
15714 rm -f core conftest.err conftest.$ac_objext \
15715     conftest$ac_exeext conftest.$ac_ext
15716   ac_cv_sys_largefile_source=unknown
15717   break
15718 done
15719 fi
15720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15721 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15722 case $ac_cv_sys_largefile_source in #(
15723   no | unknown) ;;
15724   *)
15725 cat >>confdefs.h <<_ACEOF
15726 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15727 _ACEOF
15728 ;;
15729 esac
15730 rm -rf conftest*
15731
15732 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15733 # in glibc 2.1.3, but that breaks too many other things.
15734 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15735 if test $ac_cv_sys_largefile_source != unknown; then
15736
15737 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15738
15739 fi
15740
15741
15742 # Check whether --enable-largefile was given.
15743 if test "${enable_largefile+set}" = set; then :
15744   enableval=$enable_largefile;
15745 fi
15746
15747 if test "$enable_largefile" != no; then
15748
15749   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15750 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
15751 if ${ac_cv_sys_largefile_CC+:} false; then :
15752   $as_echo_n "(cached) " >&6
15753 else
15754   ac_cv_sys_largefile_CC=no
15755      if test "$GCC" != yes; then
15756        ac_save_CC=$CC
15757        while :; do
15758          # IRIX 6.2 and later do not support large files by default,
15759          # so use the C compiler's -n32 option if that helps.
15760          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15761 /* end confdefs.h.  */
15762 #include <sys/types.h>
15763  /* Check that off_t can represent 2**63 - 1 correctly.
15764     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15765     since some C++ compilers masquerading as C compilers
15766     incorrectly reject 9223372036854775807.  */
15767 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15768   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15769                        && LARGE_OFF_T % 2147483647 == 1)
15770                       ? 1 : -1];
15771 int
15772 main ()
15773 {
15774
15775   ;
15776   return 0;
15777 }
15778 _ACEOF
15779          if ac_fn_c_try_compile "$LINENO"; then :
15780   break
15781 fi
15782 rm -f core conftest.err conftest.$ac_objext
15783          CC="$CC -n32"
15784          if ac_fn_c_try_compile "$LINENO"; then :
15785   ac_cv_sys_largefile_CC=' -n32'; break
15786 fi
15787 rm -f core conftest.err conftest.$ac_objext
15788          break
15789        done
15790        CC=$ac_save_CC
15791        rm -f conftest.$ac_ext
15792     fi
15793 fi
15794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15795 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
15796   if test "$ac_cv_sys_largefile_CC" != no; then
15797     CC=$CC$ac_cv_sys_largefile_CC
15798   fi
15799
15800   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15801 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15802 if ${ac_cv_sys_file_offset_bits+:} false; then :
15803   $as_echo_n "(cached) " >&6
15804 else
15805   while :; do
15806   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15807 /* end confdefs.h.  */
15808 #include <sys/types.h>
15809  /* Check that off_t can represent 2**63 - 1 correctly.
15810     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15811     since some C++ compilers masquerading as C compilers
15812     incorrectly reject 9223372036854775807.  */
15813 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15814   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15815                        && LARGE_OFF_T % 2147483647 == 1)
15816                       ? 1 : -1];
15817 int
15818 main ()
15819 {
15820
15821   ;
15822   return 0;
15823 }
15824 _ACEOF
15825 if ac_fn_c_try_compile "$LINENO"; then :
15826   ac_cv_sys_file_offset_bits=no; break
15827 fi
15828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15829   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15830 /* end confdefs.h.  */
15831 #define _FILE_OFFSET_BITS 64
15832 #include <sys/types.h>
15833  /* Check that off_t can represent 2**63 - 1 correctly.
15834     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15835     since some C++ compilers masquerading as C compilers
15836     incorrectly reject 9223372036854775807.  */
15837 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15838   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15839                        && LARGE_OFF_T % 2147483647 == 1)
15840                       ? 1 : -1];
15841 int
15842 main ()
15843 {
15844
15845   ;
15846   return 0;
15847 }
15848 _ACEOF
15849 if ac_fn_c_try_compile "$LINENO"; then :
15850   ac_cv_sys_file_offset_bits=64; break
15851 fi
15852 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15853   ac_cv_sys_file_offset_bits=unknown
15854   break
15855 done
15856 fi
15857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15858 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
15859 case $ac_cv_sys_file_offset_bits in #(
15860   no | unknown) ;;
15861   *)
15862 cat >>confdefs.h <<_ACEOF
15863 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
15864 _ACEOF
15865 ;;
15866 esac
15867 rm -rf conftest*
15868   if test $ac_cv_sys_file_offset_bits = unknown; then
15869     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15870 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
15871 if ${ac_cv_sys_large_files+:} false; then :
15872   $as_echo_n "(cached) " >&6
15873 else
15874   while :; do
15875   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15876 /* end confdefs.h.  */
15877 #include <sys/types.h>
15878  /* Check that off_t can represent 2**63 - 1 correctly.
15879     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15880     since some C++ compilers masquerading as C compilers
15881     incorrectly reject 9223372036854775807.  */
15882 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15883   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15884                        && LARGE_OFF_T % 2147483647 == 1)
15885                       ? 1 : -1];
15886 int
15887 main ()
15888 {
15889
15890   ;
15891   return 0;
15892 }
15893 _ACEOF
15894 if ac_fn_c_try_compile "$LINENO"; then :
15895   ac_cv_sys_large_files=no; break
15896 fi
15897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15898   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15899 /* end confdefs.h.  */
15900 #define _LARGE_FILES 1
15901 #include <sys/types.h>
15902  /* Check that off_t can represent 2**63 - 1 correctly.
15903     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15904     since some C++ compilers masquerading as C compilers
15905     incorrectly reject 9223372036854775807.  */
15906 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15907   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15908                        && LARGE_OFF_T % 2147483647 == 1)
15909                       ? 1 : -1];
15910 int
15911 main ()
15912 {
15913
15914   ;
15915   return 0;
15916 }
15917 _ACEOF
15918 if ac_fn_c_try_compile "$LINENO"; then :
15919   ac_cv_sys_large_files=1; break
15920 fi
15921 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15922   ac_cv_sys_large_files=unknown
15923   break
15924 done
15925 fi
15926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15927 $as_echo "$ac_cv_sys_large_files" >&6; }
15928 case $ac_cv_sys_large_files in #(
15929   no | unknown) ;;
15930   *)
15931 cat >>confdefs.h <<_ACEOF
15932 #define _LARGE_FILES $ac_cv_sys_large_files
15933 _ACEOF
15934 ;;
15935 esac
15936 rm -rf conftest*
15937   fi
15938
15939
15940 fi
15941
15942
15943
15944
15945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC" >&5
15946 $as_echo_n "checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC... " >&6; }
15947 cache=_D_LARGEFILE_SOURCE_1
15948 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
15949   $as_echo_n "(cached) " >&6
15950 else
15951
15952 echo '
15953 #include <stdio.h>
15954 int test() {
15955         int a = fseeko(stdin, 0, 0);
15956         return a;
15957 }
15958 ' > conftest.c
15959 echo 'void f(){}' >>conftest.c
15960 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
15961 eval "cv_prog_cc_flag_needed_$cache=no"
15962 else
15963
15964 if test -z "`$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`"; then
15965 eval "cv_prog_cc_flag_needed_$cache=yes"
15966 else
15967 eval "cv_prog_cc_flag_needed_$cache=fail"
15968 #echo 'Test with flag fails too!'
15969 #cat conftest.c
15970 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15971 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15972 #exit 1
15973 fi
15974
15975 fi
15976 rm -f conftest conftest.c conftest.o
15977
15978 fi
15979
15980 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
15981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15982 $as_echo "yes" >&6; }
15983 :
15984 CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE=1"
15985 else
15986 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
15987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15988 $as_echo "no" >&6; }
15989 #echo 'Test with flag is no!'
15990 #cat conftest.c
15991 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15992 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15993 #exit 1
15994 :
15995
15996 else
15997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
15998 $as_echo "failed" >&6; }
15999 :
16000
16001 fi
16002 fi
16003
16004
16005
16006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nonblocking sockets work" >&5
16007 $as_echo_n "checking if nonblocking sockets work... " >&6; }
16008 if echo $host | grep mingw >/dev/null; then
16009         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (windows)" >&5
16010 $as_echo "no (windows)" >&6; }
16011
16012 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
16013
16014 else
16015 if test "$cross_compiling" = yes; then :
16016
16017         { $as_echo "$as_me:${as_lineno-$LINENO}: result: crosscompile(yes)" >&5
16018 $as_echo "crosscompile(yes)" >&6; }
16019
16020 else
16021   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16022 /* end confdefs.h.  */
16023
16024
16025 #include <stdio.h>
16026 #include <string.h>
16027 #include <stdlib.h>
16028 #include <fcntl.h>
16029 #include <errno.h>
16030 #ifdef HAVE_SYS_TYPES_H
16031 #include <sys/types.h>
16032 #endif
16033 #ifdef HAVE_SYS_SOCKET_H
16034 #include <sys/socket.h>
16035 #endif
16036 #ifdef HAVE_NETINET_IN_H
16037 #include <netinet/in.h>
16038 #endif
16039 #ifdef HAVE_ARPA_INET_H
16040 #include <arpa/inet.h>
16041 #endif
16042 #ifdef HAVE_UNISTD_H
16043 #include <unistd.h>
16044 #endif
16045 #ifdef HAVE_TIME_H
16046 #include <time.h>
16047 #endif
16048
16049 int main(void)
16050 {
16051         int port;
16052         int sfd, cfd;
16053         int num = 10;
16054         int i, p;
16055         struct sockaddr_in a;
16056         /* test if select and nonblocking reads work well together */
16057         /* open port.
16058            fork child to send 10 messages.
16059            select to read.
16060            then try to nonblocking read the 10 messages
16061            then, nonblocking read must give EAGAIN
16062         */
16063
16064         port = 12345 + (time(0)%32);
16065         sfd = socket(PF_INET, SOCK_DGRAM, 0);
16066         if(sfd == -1) {
16067                 perror("socket");
16068                 return 1;
16069         }
16070         memset(&a, 0, sizeof(a));
16071         a.sin_family = AF_INET;
16072         a.sin_port = htons(port);
16073         a.sin_addr.s_addr = inet_addr("127.0.0.1");
16074         if(bind(sfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
16075                 perror("bind");
16076                 return 1;
16077         }
16078         if(fcntl(sfd, F_SETFL, O_NONBLOCK) == -1) {
16079                 perror("fcntl");
16080                 return 1;
16081         }
16082
16083         cfd = socket(PF_INET, SOCK_DGRAM, 0);
16084         if(cfd == -1) {
16085                 perror("client socket");
16086                 return 1;
16087         }
16088         a.sin_port = 0;
16089         if(bind(cfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
16090                 perror("client bind");
16091                 return 1;
16092         }
16093         a.sin_port = htons(port);
16094
16095         /* no handler, causes exit in 10 seconds */
16096         alarm(10);
16097
16098         /* send and receive on the socket */
16099         if((p=fork()) == 0) {
16100                 for(i=0; i<num; i++) {
16101                         if(sendto(cfd, &i, sizeof(i), 0,
16102                                 (struct sockaddr*)&a, sizeof(a)) < 0) {
16103                                 perror("sendto");
16104                                 return 1;
16105                         }
16106                 }
16107         } else {
16108                 /* parent */
16109                 fd_set rset;
16110                 int x;
16111                 if(p == -1) {
16112                         perror("fork");
16113                         return 1;
16114                 }
16115                 FD_ZERO(&rset);
16116                 FD_SET(sfd, &rset);
16117                 if(select(sfd+1, &rset, NULL, NULL, NULL) < 1) {
16118                         perror("select");
16119                         return 1;
16120                 }
16121                 i = 0;
16122                 while(i < num) {
16123                         if(recv(sfd, &x, sizeof(x), 0) != sizeof(x)) {
16124                                 if(errno == EAGAIN)
16125                                         continue;
16126                                 perror("recv");
16127                                 return 1;
16128                         }
16129                         i++;
16130                 }
16131                 /* now we want to get EAGAIN: nonblocking goodness */
16132                 errno = 0;
16133                 recv(sfd, &x, sizeof(x), 0);
16134                 if(errno != EAGAIN) {
16135                         perror("trying to recv again");
16136                         return 1;
16137                 }
16138                 /* EAGAIN encountered */
16139         }
16140
16141         close(sfd);
16142         close(cfd);
16143         return 0;
16144 }
16145
16146 _ACEOF
16147 if ac_fn_c_try_run "$LINENO"; then :
16148
16149         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16150 $as_echo "yes" >&6; }
16151
16152 else
16153
16154         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16155 $as_echo "no" >&6; }
16156
16157 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
16158
16159
16160 fi
16161 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16162   conftest.$ac_objext conftest.beam conftest.$ac_ext
16163 fi
16164
16165 fi
16166
16167
16168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir has one arg" >&5
16169 $as_echo_n "checking whether mkdir has one arg... " >&6; }
16170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16171 /* end confdefs.h.  */
16172
16173 #include <stdio.h>
16174 #include <unistd.h>
16175 #ifdef HAVE_WINSOCK2_H
16176 #include <winsock2.h>
16177 #endif
16178 #ifdef HAVE_SYS_STAT_H
16179 #include <sys/stat.h>
16180 #endif
16181
16182 int
16183 main ()
16184 {
16185
16186         (void)mkdir("directory");
16187
16188   ;
16189   return 0;
16190 }
16191 _ACEOF
16192 if ac_fn_c_try_compile "$LINENO"; then :
16193   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16194 $as_echo "yes" >&6; }
16195
16196 $as_echo "#define MKDIR_HAS_ONE_ARG 1" >>confdefs.h
16197
16198
16199 else
16200   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16201 $as_echo "no" >&6; }
16202
16203 fi
16204 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16205
16206 for ac_func in strptime
16207 do :
16208   ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
16209 if test "x$ac_cv_func_strptime" = xyes; then :
16210   cat >>confdefs.h <<_ACEOF
16211 #define HAVE_STRPTIME 1
16212 _ACEOF
16213
16214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strptime works" >&5
16215 $as_echo_n "checking whether strptime works... " >&6; }
16216 if test c${cross_compiling} = cno; then
16217 if test "$cross_compiling" = yes; then :
16218   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16219 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16220 as_fn_error $? "cannot run test program while cross compiling
16221 See \`config.log' for more details" "$LINENO" 5; }
16222 else
16223   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16224 /* end confdefs.h.  */
16225
16226 #define _XOPEN_SOURCE 600
16227 #include <time.h>
16228 int main(void) { struct tm tm; char *res;
16229 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);
16230 if (!res) return 2;
16231 res = strptime("20070207111842", "%Y%m%d%H%M%S", &tm);
16232 if (!res) return 1; return 0; }
16233
16234 _ACEOF
16235 if ac_fn_c_try_run "$LINENO"; then :
16236   eval "ac_cv_c_strptime_works=yes"
16237 else
16238   eval "ac_cv_c_strptime_works=no"
16239 fi
16240 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16241   conftest.$ac_objext conftest.beam conftest.$ac_ext
16242 fi
16243
16244 else
16245 eval "ac_cv_c_strptime_works=maybe"
16246 fi
16247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_strptime_works" >&5
16248 $as_echo "$ac_cv_c_strptime_works" >&6; }
16249 if test $ac_cv_c_strptime_works = no; then
16250 case " $LIBOBJS " in
16251   *" strptime.$ac_objext "* ) ;;
16252   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16253  ;;
16254 esac
16255
16256 else
16257
16258 cat >>confdefs.h <<_ACEOF
16259 #define STRPTIME_WORKS 1
16260 _ACEOF
16261
16262 fi
16263
16264 else
16265   case " $LIBOBJS " in
16266   *" strptime.$ac_objext "* ) ;;
16267   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16268  ;;
16269 esac
16270
16271 fi
16272 done
16273
16274
16275 # check if we can use SO_REUSEPORT
16276 reuseport_default=0
16277 if echo "$host" | $GREP -i -e linux >/dev/null; then reuseport_default=1; fi
16278 if echo "$host" | $GREP -i -e dragonfly >/dev/null; then reuseport_default=1; fi
16279 if test "$reuseport_default" = 1; then
16280
16281 $as_echo "#define REUSEPORT_DEFAULT 1" >>confdefs.h
16282
16283 else
16284
16285 $as_echo "#define REUSEPORT_DEFAULT 0" >>confdefs.h
16286
16287 fi
16288
16289 # Include systemd.m4 - begin
16290 #   macros for configuring systemd
16291 #   Copyright 2015, Sami Kerola, CloudFlare.
16292 #   BSD licensed.
16293 # Check whether --enable-systemd was given.
16294 if test "${enable_systemd+set}" = set; then :
16295   enableval=$enable_systemd;
16296 else
16297   enable_systemd=no
16298 fi
16299
16300 have_systemd=no
16301 if test "x$enable_systemd" != xno; then :
16302
16303
16304
16305 pkg_failed=no
16306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD" >&5
16307 $as_echo_n "checking for SYSTEMD... " >&6; }
16308
16309 if test -n "$SYSTEMD_CFLAGS"; then
16310     pkg_cv_SYSTEMD_CFLAGS="$SYSTEMD_CFLAGS"
16311  elif test -n "$PKG_CONFIG"; then
16312     if test -n "$PKG_CONFIG" && \
16313     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16314   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16315   ac_status=$?
16316   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16317   test $ac_status = 0; }; then
16318   pkg_cv_SYSTEMD_CFLAGS=`$PKG_CONFIG --cflags "libsystemd" 2>/dev/null`
16319                       test "x$?" != "x0" && pkg_failed=yes
16320 else
16321   pkg_failed=yes
16322 fi
16323  else
16324     pkg_failed=untried
16325 fi
16326 if test -n "$SYSTEMD_LIBS"; then
16327     pkg_cv_SYSTEMD_LIBS="$SYSTEMD_LIBS"
16328  elif test -n "$PKG_CONFIG"; then
16329     if test -n "$PKG_CONFIG" && \
16330     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16331   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16332   ac_status=$?
16333   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16334   test $ac_status = 0; }; then
16335   pkg_cv_SYSTEMD_LIBS=`$PKG_CONFIG --libs "libsystemd" 2>/dev/null`
16336                       test "x$?" != "x0" && pkg_failed=yes
16337 else
16338   pkg_failed=yes
16339 fi
16340  else
16341     pkg_failed=untried
16342 fi
16343
16344
16345
16346 if test $pkg_failed = yes; then
16347         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16348 $as_echo "no" >&6; }
16349
16350 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16351         _pkg_short_errors_supported=yes
16352 else
16353         _pkg_short_errors_supported=no
16354 fi
16355         if test $_pkg_short_errors_supported = yes; then
16356                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd" 2>&1`
16357         else
16358                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd" 2>&1`
16359         fi
16360         # Put the nasty error message in config.log where it belongs
16361         echo "$SYSTEMD_PKG_ERRORS" >&5
16362
16363         have_systemd=no
16364 elif test $pkg_failed = untried; then
16365         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16366 $as_echo "no" >&6; }
16367         have_systemd=no
16368 else
16369         SYSTEMD_CFLAGS=$pkg_cv_SYSTEMD_CFLAGS
16370         SYSTEMD_LIBS=$pkg_cv_SYSTEMD_LIBS
16371         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16372 $as_echo "yes" >&6; }
16373         have_systemd=yes
16374 fi
16375                 if test "x$have_systemd" != "xyes"; then :
16376
16377
16378 pkg_failed=no
16379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD_DAEMON" >&5
16380 $as_echo_n "checking for SYSTEMD_DAEMON... " >&6; }
16381
16382 if test -n "$SYSTEMD_DAEMON_CFLAGS"; then
16383     pkg_cv_SYSTEMD_DAEMON_CFLAGS="$SYSTEMD_DAEMON_CFLAGS"
16384  elif test -n "$PKG_CONFIG"; then
16385     if test -n "$PKG_CONFIG" && \
16386     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16387   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16388   ac_status=$?
16389   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16390   test $ac_status = 0; }; then
16391   pkg_cv_SYSTEMD_DAEMON_CFLAGS=`$PKG_CONFIG --cflags "libsystemd-daemon" 2>/dev/null`
16392                       test "x$?" != "x0" && pkg_failed=yes
16393 else
16394   pkg_failed=yes
16395 fi
16396  else
16397     pkg_failed=untried
16398 fi
16399 if test -n "$SYSTEMD_DAEMON_LIBS"; then
16400     pkg_cv_SYSTEMD_DAEMON_LIBS="$SYSTEMD_DAEMON_LIBS"
16401  elif test -n "$PKG_CONFIG"; then
16402     if test -n "$PKG_CONFIG" && \
16403     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16404   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16405   ac_status=$?
16406   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16407   test $ac_status = 0; }; then
16408   pkg_cv_SYSTEMD_DAEMON_LIBS=`$PKG_CONFIG --libs "libsystemd-daemon" 2>/dev/null`
16409                       test "x$?" != "x0" && pkg_failed=yes
16410 else
16411   pkg_failed=yes
16412 fi
16413  else
16414     pkg_failed=untried
16415 fi
16416
16417
16418
16419 if test $pkg_failed = yes; then
16420         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16421 $as_echo "no" >&6; }
16422
16423 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16424         _pkg_short_errors_supported=yes
16425 else
16426         _pkg_short_errors_supported=no
16427 fi
16428         if test $_pkg_short_errors_supported = yes; then
16429                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16430         else
16431                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16432         fi
16433         # Put the nasty error message in config.log where it belongs
16434         echo "$SYSTEMD_DAEMON_PKG_ERRORS" >&5
16435
16436         have_systemd_daemon=no
16437 elif test $pkg_failed = untried; then
16438         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16439 $as_echo "no" >&6; }
16440         have_systemd_daemon=no
16441 else
16442         SYSTEMD_DAEMON_CFLAGS=$pkg_cv_SYSTEMD_DAEMON_CFLAGS
16443         SYSTEMD_DAEMON_LIBS=$pkg_cv_SYSTEMD_DAEMON_LIBS
16444         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16445 $as_echo "yes" >&6; }
16446         have_systemd_daemon=yes
16447 fi
16448                 if test "x$have_systemd_daemon" = "xyes"; then :
16449   have_systemd=yes
16450 fi
16451
16452 fi
16453         case $enable_systemd:$have_systemd in #(
16454   yes:no) :
16455     as_fn_error $? "systemd enabled but libsystemd not found" "$LINENO" 5 ;; #(
16456   *:yes) :
16457
16458 $as_echo "#define HAVE_SYSTEMD 1" >>confdefs.h
16459
16460                 LIBS="$LIBS $SYSTEMD_LIBS"
16461
16462          ;; #(
16463   *) :
16464      ;;
16465 esac
16466
16467
16468 fi
16469  if test "x$have_systemd" = xyes; then
16470   USE_SYSTEMD_TRUE=
16471   USE_SYSTEMD_FALSE='#'
16472 else
16473   USE_SYSTEMD_TRUE='#'
16474   USE_SYSTEMD_FALSE=
16475 fi
16476
16477
16478 # Include systemd.m4 - end
16479
16480 # set memory allocation checking if requested
16481 # Check whether --enable-alloc-checks was given.
16482 if test "${enable_alloc_checks+set}" = set; then :
16483   enableval=$enable_alloc_checks;
16484 fi
16485
16486 # Check whether --enable-alloc-lite was given.
16487 if test "${enable_alloc_lite+set}" = set; then :
16488   enableval=$enable_alloc_lite;
16489 fi
16490
16491 # Check whether --enable-alloc-nonregional was given.
16492 if test "${enable_alloc_nonregional+set}" = set; then :
16493   enableval=$enable_alloc_nonregional;
16494 fi
16495
16496 if test x_$enable_alloc_nonregional = x_yes; then
16497
16498 $as_echo "#define UNBOUND_ALLOC_NONREGIONAL 1" >>confdefs.h
16499
16500 fi
16501 if test x_$enable_alloc_checks = x_yes; then
16502
16503 $as_echo "#define UNBOUND_ALLOC_STATS 1" >>confdefs.h
16504
16505         SLDNS_ALLOCCHECK_EXTRA_OBJ="alloc.lo log.lo"
16506
16507         ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ="alloc.lo"
16508
16509 else
16510         if test x_$enable_alloc_lite = x_yes; then
16511
16512 $as_echo "#define UNBOUND_ALLOC_LITE 1" >>confdefs.h
16513
16514         else
16515
16516         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
16517 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
16518         if test "$cross_compiling" = yes; then :
16519   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (crosscompile)" >&5
16520 $as_echo "no (crosscompile)" >&6; }
16521         case " $LIBOBJS " in
16522   *" malloc.$ac_objext "* ) ;;
16523   *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
16524  ;;
16525 esac
16526
16527
16528 cat >>confdefs.h <<_ACEOF
16529 #define malloc rpl_malloc_unbound
16530 _ACEOF
16531
16532 else
16533   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16534 /* end confdefs.h.  */
16535 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
16536 #include <stdlib.h>
16537 #else
16538 char *malloc ();
16539 #endif
16540
16541 int
16542 main ()
16543 {
16544  if(malloc(0) != 0) return 1;
16545   ;
16546   return 0;
16547 }
16548
16549 _ACEOF
16550 if ac_fn_c_try_run "$LINENO"; then :
16551   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16552 $as_echo "no" >&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   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16566 $as_echo "yes" >&6; }
16567
16568 $as_echo "#define HAVE_MALLOC 1" >>confdefs.h
16569
16570 fi
16571 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16572   conftest.$ac_objext conftest.beam conftest.$ac_ext
16573 fi
16574
16575
16576         fi
16577 fi
16578
16579 # check windows threads (we use them, not pthreads, on windows).
16580 if test "$on_mingw" = "yes"; then
16581 # check windows threads
16582         for ac_header in windows.h
16583 do :
16584   ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
16585 "
16586 if test "x$ac_cv_header_windows_h" = xyes; then :
16587   cat >>confdefs.h <<_ACEOF
16588 #define HAVE_WINDOWS_H 1
16589 _ACEOF
16590
16591 fi
16592
16593 done
16594
16595         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CreateThread" >&5
16596 $as_echo_n "checking for CreateThread... " >&6; }
16597         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16598 /* end confdefs.h.  */
16599
16600 #ifdef HAVE_WINDOWS_H
16601 #include <windows.h>
16602 #endif
16603
16604 int
16605 main ()
16606 {
16607
16608         HANDLE t = CreateThread(NULL, 0, NULL, NULL, 0, NULL);
16609
16610   ;
16611   return 0;
16612 }
16613 _ACEOF
16614 if ac_fn_c_try_compile "$LINENO"; then :
16615   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16616 $as_echo "yes" >&6; }
16617
16618 $as_echo "#define HAVE_WINDOWS_THREADS 1" >>confdefs.h
16619
16620
16621 else
16622   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16623 $as_echo "no" >&6; }
16624
16625 fi
16626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16627
16628 else
16629 # not on mingw, check thread libraries.
16630
16631 # check for thread library.
16632 # check this first, so that the pthread lib does not get linked in via
16633 # libssl or libpython, and thus distorts the tests, and we end up using
16634 # the non-threadsafe C libraries.
16635
16636 # Check whether --with-pthreads was given.
16637 if test "${with_pthreads+set}" = set; then :
16638   withval=$with_pthreads;
16639 else
16640    withval="yes"
16641 fi
16642
16643 ub_have_pthreads=no
16644 if test x_$withval != x_no; then
16645
16646
16647 ac_ext=c
16648 ac_cpp='$CPP $CPPFLAGS'
16649 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16650 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16651 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16652
16653 ax_pthread_ok=no
16654
16655 # We used to check for pthread.h first, but this fails if pthread.h
16656 # requires special compiler flags (e.g. on True64 or Sequent).
16657 # It gets checked for in the link test anyway.
16658
16659 # First of all, check if the user has set any of the PTHREAD_LIBS,
16660 # etcetera environment variables, and if threads linking works using
16661 # them:
16662 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16663         save_CFLAGS="$CFLAGS"
16664         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16665         save_LIBS="$LIBS"
16666         LIBS="$PTHREAD_LIBS $LIBS"
16667         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16668 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
16669         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16670 /* end confdefs.h.  */
16671
16672 /* Override any GCC internal prototype to avoid an error.
16673    Use char because int might match the return type of a GCC
16674    builtin and then its argument prototype would still apply.  */
16675 #ifdef __cplusplus
16676 extern "C"
16677 #endif
16678 char pthread_join ();
16679 int
16680 main ()
16681 {
16682 return pthread_join ();
16683   ;
16684   return 0;
16685 }
16686 _ACEOF
16687 if ac_fn_c_try_link "$LINENO"; then :
16688   ax_pthread_ok=yes
16689 fi
16690 rm -f core conftest.err conftest.$ac_objext \
16691     conftest$ac_exeext conftest.$ac_ext
16692         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16693 $as_echo "$ax_pthread_ok" >&6; }
16694         if test x"$ax_pthread_ok" = xno; then
16695                 PTHREAD_LIBS=""
16696                 PTHREAD_CFLAGS=""
16697         fi
16698         LIBS="$save_LIBS"
16699         CFLAGS="$save_CFLAGS"
16700 fi
16701
16702 # We must check for the threads library under a number of different
16703 # names; the ordering is very important because some systems
16704 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16705 # libraries is broken (non-POSIX).
16706
16707 # Create a list of thread flags to try.  Items starting with a "-" are
16708 # C compiler flags, and other items are library names, except for "none"
16709 # which indicates that we try without any flags at all, and "pthread-config"
16710 # which is a program returning the flags for the Pth emulation library.
16711
16712 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
16713
16714 # The ordering *is* (sometimes) important.  Some notes on the
16715 # individual items follow:
16716
16717 # pthreads: AIX (must check this before -lpthread)
16718 # none: in case threads are in libc; should be tried before -Kthread and
16719 #       other compiler flags to prevent continual compiler warnings
16720 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16721 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16722 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16723 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16724 # -pthreads: Solaris/gcc
16725 # -mthreads: Mingw32/gcc, Lynx/gcc
16726 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16727 #      doesn't hurt to check since this sometimes defines pthreads too;
16728 #      also defines -D_REENTRANT)
16729 #      ... -mt is also the pthreads flag for HP/aCC
16730 # pthread: Linux, etcetera
16731 # --thread-safe: KAI C++
16732 # pthread-config: use pthread-config program (for GNU Pth library)
16733
16734 case ${host_os} in
16735         solaris*)
16736
16737         # On Solaris (at least, for some versions), libc contains stubbed
16738         # (non-functional) versions of the pthreads routines, so link-based
16739         # tests will erroneously succeed.  (We need to link with -pthreads/-mt/
16740         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
16741         # a function called by this macro, so we could check for that, but
16742         # who knows whether they'll stub that too in a future libc.)  So,
16743         # we'll just look for -pthreads and -lpthread first:
16744
16745         ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
16746         ;;
16747
16748         darwin*)
16749         ax_pthread_flags="-pthread $ax_pthread_flags"
16750         ;;
16751 esac
16752
16753 # Clang doesn't consider unrecognized options an error unless we specify
16754 # -Werror. We throw in some extra Clang-specific options to ensure that
16755 # this doesn't happen for GCC, which also accepts -Werror.
16756
16757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs -Werror to reject unknown flags" >&5
16758 $as_echo_n "checking if compiler needs -Werror to reject unknown flags... " >&6; }
16759 save_CFLAGS="$CFLAGS"
16760 ax_pthread_extra_flags="-Werror"
16761 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wunknown-warning-option -Wsizeof-array-argument"
16762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16763 /* end confdefs.h.  */
16764 int foo(void);
16765 int
16766 main ()
16767 {
16768 foo()
16769   ;
16770   return 0;
16771 }
16772 _ACEOF
16773 if ac_fn_c_try_compile "$LINENO"; then :
16774   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16775 $as_echo "yes" >&6; }
16776 else
16777   ax_pthread_extra_flags=
16778                    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16779 $as_echo "no" >&6; }
16780 fi
16781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16782 CFLAGS="$save_CFLAGS"
16783
16784 if test x"$ax_pthread_ok" = xno; then
16785 for flag in $ax_pthread_flags; do
16786
16787         case $flag in
16788                 none)
16789                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
16790 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
16791                 ;;
16792
16793                 -*)
16794                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
16795 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
16796                 PTHREAD_CFLAGS="$flag"
16797                 ;;
16798
16799                 pthread-config)
16800                 # Extract the first word of "pthread-config", so it can be a program name with args.
16801 set dummy pthread-config; ac_word=$2
16802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16803 $as_echo_n "checking for $ac_word... " >&6; }
16804 if ${ac_cv_prog_ax_pthread_config+:} false; then :
16805   $as_echo_n "(cached) " >&6
16806 else
16807   if test -n "$ax_pthread_config"; then
16808   ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
16809 else
16810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16811 for as_dir in $PATH
16812 do
16813   IFS=$as_save_IFS
16814   test -z "$as_dir" && as_dir=.
16815     for ac_exec_ext in '' $ac_executable_extensions; do
16816   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16817     ac_cv_prog_ax_pthread_config="yes"
16818     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16819     break 2
16820   fi
16821 done
16822   done
16823 IFS=$as_save_IFS
16824
16825   test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
16826 fi
16827 fi
16828 ax_pthread_config=$ac_cv_prog_ax_pthread_config
16829 if test -n "$ax_pthread_config"; then
16830   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
16831 $as_echo "$ax_pthread_config" >&6; }
16832 else
16833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16834 $as_echo "no" >&6; }
16835 fi
16836
16837
16838                 if test x"$ax_pthread_config" = xno; then continue; fi
16839                 PTHREAD_CFLAGS="`pthread-config --cflags`"
16840                 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16841                 ;;
16842
16843                 *)
16844                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
16845 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
16846                 PTHREAD_LIBS="-l$flag"
16847                 ;;
16848         esac
16849
16850         save_LIBS="$LIBS"
16851         save_CFLAGS="$CFLAGS"
16852         LIBS="$PTHREAD_LIBS $LIBS"
16853         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
16854
16855         # Check for various functions.  We must include pthread.h,
16856         # since some functions may be macros.  (On the Sequent, we
16857         # need a special flag -Kthread to make this header compile.)
16858         # We check for pthread_join because it is in -lpthread on IRIX
16859         # while pthread_create is in libc.  We check for pthread_attr_init
16860         # due to DEC craziness with -lpthreads.  We check for
16861         # pthread_cleanup_push because it is one of the few pthread
16862         # functions on Solaris that doesn't have a non-functional libc stub.
16863         # We try pthread_create on general principles.
16864         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16865 /* end confdefs.h.  */
16866 #include <pthread.h>
16867                         static void routine(void *a) { *((int*)a) = 0; }
16868                         static void *start_routine(void *a) { return a; }
16869 int
16870 main ()
16871 {
16872 pthread_t th; pthread_attr_t attr;
16873                         pthread_create(&th, 0, start_routine, 0);
16874                         pthread_join(th, 0);
16875                         pthread_attr_init(&attr);
16876                         pthread_cleanup_push(routine, 0);
16877                         pthread_cleanup_pop(0) /* ; */
16878   ;
16879   return 0;
16880 }
16881 _ACEOF
16882 if ac_fn_c_try_link "$LINENO"; then :
16883   ax_pthread_ok=yes
16884 fi
16885 rm -f core conftest.err conftest.$ac_objext \
16886     conftest$ac_exeext conftest.$ac_ext
16887
16888         LIBS="$save_LIBS"
16889         CFLAGS="$save_CFLAGS"
16890
16891         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16892 $as_echo "$ax_pthread_ok" >&6; }
16893         if test "x$ax_pthread_ok" = xyes; then
16894                 break;
16895         fi
16896
16897         PTHREAD_LIBS=""
16898         PTHREAD_CFLAGS=""
16899 done
16900 fi
16901
16902 # Various other checks:
16903 if test "x$ax_pthread_ok" = xyes; then
16904         save_LIBS="$LIBS"
16905         LIBS="$PTHREAD_LIBS $LIBS"
16906         save_CFLAGS="$CFLAGS"
16907         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16908
16909         # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
16910         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
16911 $as_echo_n "checking for joinable pthread attribute... " >&6; }
16912         attr_name=unknown
16913         for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
16914             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16915 /* end confdefs.h.  */
16916 #include <pthread.h>
16917 int
16918 main ()
16919 {
16920 int attr = $attr; return attr /* ; */
16921   ;
16922   return 0;
16923 }
16924 _ACEOF
16925 if ac_fn_c_try_link "$LINENO"; then :
16926   attr_name=$attr; break
16927 fi
16928 rm -f core conftest.err conftest.$ac_objext \
16929     conftest$ac_exeext conftest.$ac_ext
16930         done
16931         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
16932 $as_echo "$attr_name" >&6; }
16933         if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
16934
16935 cat >>confdefs.h <<_ACEOF
16936 #define PTHREAD_CREATE_JOINABLE $attr_name
16937 _ACEOF
16938
16939         fi
16940
16941         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
16942 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
16943         flag=no
16944         case ${host_os} in
16945             aix* | freebsd* | darwin*) flag="-D_THREAD_SAFE";;
16946             osf* | hpux*) flag="-D_REENTRANT";;
16947             solaris*)
16948             if test "$GCC" = "yes"; then
16949                 flag="-D_REENTRANT"
16950             else
16951                 # TODO: What about Clang on Solaris?
16952                 flag="-mt -D_REENTRANT"
16953             fi
16954             ;;
16955         esac
16956         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $flag" >&5
16957 $as_echo "$flag" >&6; }
16958         if test "x$flag" != xno; then
16959             PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16960         fi
16961
16962         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
16963 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
16964 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
16965   $as_echo_n "(cached) " >&6
16966 else
16967
16968                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16969 /* end confdefs.h.  */
16970 #include <pthread.h>
16971 int
16972 main ()
16973 {
16974 int i = PTHREAD_PRIO_INHERIT;
16975   ;
16976   return 0;
16977 }
16978 _ACEOF
16979 if ac_fn_c_try_link "$LINENO"; then :
16980   ax_cv_PTHREAD_PRIO_INHERIT=yes
16981 else
16982   ax_cv_PTHREAD_PRIO_INHERIT=no
16983 fi
16984 rm -f core conftest.err conftest.$ac_objext \
16985     conftest$ac_exeext conftest.$ac_ext
16986
16987 fi
16988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
16989 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
16990         if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
16991
16992 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
16993
16994 fi
16995
16996         LIBS="$save_LIBS"
16997         CFLAGS="$save_CFLAGS"
16998
16999         # More AIX lossage: compile with *_r variant
17000         if test "x$GCC" != xyes; then
17001             case $host_os in
17002                 aix*)
17003                 case "x/$CC" in #(
17004   x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
17005     #handle absolute path differently from PATH based program lookup
17006                    case "x$CC" in #(
17007   x/*) :
17008     if as_fn_executable_p ${CC}_r; then :
17009   PTHREAD_CC="${CC}_r"
17010 fi ;; #(
17011   *) :
17012     for ac_prog in ${CC}_r
17013 do
17014   # Extract the first word of "$ac_prog", so it can be a program name with args.
17015 set dummy $ac_prog; ac_word=$2
17016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17017 $as_echo_n "checking for $ac_word... " >&6; }
17018 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
17019   $as_echo_n "(cached) " >&6
17020 else
17021   if test -n "$PTHREAD_CC"; then
17022   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
17023 else
17024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17025 for as_dir in $PATH
17026 do
17027   IFS=$as_save_IFS
17028   test -z "$as_dir" && as_dir=.
17029     for ac_exec_ext in '' $ac_executable_extensions; do
17030   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17031     ac_cv_prog_PTHREAD_CC="$ac_prog"
17032     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17033     break 2
17034   fi
17035 done
17036   done
17037 IFS=$as_save_IFS
17038
17039 fi
17040 fi
17041 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
17042 if test -n "$PTHREAD_CC"; then
17043   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
17044 $as_echo "$PTHREAD_CC" >&6; }
17045 else
17046   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17047 $as_echo "no" >&6; }
17048 fi
17049
17050
17051   test -n "$PTHREAD_CC" && break
17052 done
17053 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
17054  ;;
17055 esac ;; #(
17056   *) :
17057      ;;
17058 esac
17059                 ;;
17060             esac
17061         fi
17062 fi
17063
17064 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
17065
17066
17067
17068
17069
17070 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
17071 if test x"$ax_pthread_ok" = xyes; then
17072
17073
17074 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
17075
17076                 if test -n "$PTHREAD_LIBS"; then
17077                   LIBS="$PTHREAD_LIBS $LIBS"
17078                 fi
17079                 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
17080                 CC="$PTHREAD_CC"
17081                 ub_have_pthreads=yes
17082                 ac_fn_c_check_type "$LINENO" "pthread_spinlock_t" "ac_cv_type_pthread_spinlock_t" "#include <pthread.h>
17083 "
17084 if test "x$ac_cv_type_pthread_spinlock_t" = xyes; then :
17085
17086 cat >>confdefs.h <<_ACEOF
17087 #define HAVE_PTHREAD_SPINLOCK_T 1
17088 _ACEOF
17089
17090
17091 fi
17092 ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
17093 "
17094 if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then :
17095
17096 cat >>confdefs.h <<_ACEOF
17097 #define HAVE_PTHREAD_RWLOCK_T 1
17098 _ACEOF
17099
17100
17101 fi
17102
17103
17104                 if echo "$CFLAGS" | $GREP -e "-pthread" >/dev/null; then
17105                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread unused during linking" >&5
17106 $as_echo_n "checking if -pthread unused during linking... " >&6; }
17107                 # catch clang warning 'argument unused during compilation'
17108                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17109 /* end confdefs.h.  */
17110 $ac_includes_default
17111
17112 int main(void) {return 0;}
17113
17114 _ACEOF
17115                 pthread_unused="yes"
17116                 # first compile
17117                 echo "$CC $CFLAGS -c conftest.c -o conftest.o" >&5
17118                 $CC $CFLAGS -c conftest.c -o conftest.o 2>&5 >&5
17119                 if test $? = 0; then
17120                         # then link
17121                         echo "$CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest contest.o" >&5
17122                         $CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest conftest.o 2>&5 >&5
17123                         if test $? -ne 0; then
17124                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17125 $as_echo "yes" >&6; }
17126                                 CFLAGS=`echo "$CFLAGS" | sed -e 's/-pthread//'`
17127                                 PTHREAD_CFLAGS_ONLY="-pthread"
17128
17129                         else
17130                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17131 $as_echo "no" >&6; }
17132                         fi
17133                 else
17134                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17135 $as_echo "no" >&6; }
17136                 fi # endif cc successful
17137                 rm -f conftest conftest.c conftest.o
17138                 fi # endif -pthread in CFLAGS
17139
17140
17141         :
17142 else
17143         ax_pthread_ok=no
17144
17145 fi
17146 ac_ext=c
17147 ac_cpp='$CPP $CPPFLAGS'
17148 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17149 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17150 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17151
17152
17153 fi
17154
17155 # check solaris thread library
17156
17157 # Check whether --with-solaris-threads was given.
17158 if test "${with_solaris_threads+set}" = set; then :
17159   withval=$with_solaris_threads;
17160 else
17161    withval="no"
17162 fi
17163
17164 ub_have_sol_threads=no
17165 if test x_$withval != x_no; then
17166         if test x_$ub_have_pthreads != x_no; then
17167             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&5
17168 $as_echo "$as_me: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&2;}
17169         else
17170         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing thr_create" >&5
17171 $as_echo_n "checking for library containing thr_create... " >&6; }
17172 if ${ac_cv_search_thr_create+:} false; then :
17173   $as_echo_n "(cached) " >&6
17174 else
17175   ac_func_search_save_LIBS=$LIBS
17176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17177 /* end confdefs.h.  */
17178
17179 /* Override any GCC internal prototype to avoid an error.
17180    Use char because int might match the return type of a GCC
17181    builtin and then its argument prototype would still apply.  */
17182 #ifdef __cplusplus
17183 extern "C"
17184 #endif
17185 char thr_create ();
17186 int
17187 main ()
17188 {
17189 return thr_create ();
17190   ;
17191   return 0;
17192 }
17193 _ACEOF
17194 for ac_lib in '' thread; do
17195   if test -z "$ac_lib"; then
17196     ac_res="none required"
17197   else
17198     ac_res=-l$ac_lib
17199     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17200   fi
17201   if ac_fn_c_try_link "$LINENO"; then :
17202   ac_cv_search_thr_create=$ac_res
17203 fi
17204 rm -f core conftest.err conftest.$ac_objext \
17205     conftest$ac_exeext
17206   if ${ac_cv_search_thr_create+:} false; then :
17207   break
17208 fi
17209 done
17210 if ${ac_cv_search_thr_create+:} false; then :
17211
17212 else
17213   ac_cv_search_thr_create=no
17214 fi
17215 rm conftest.$ac_ext
17216 LIBS=$ac_func_search_save_LIBS
17217 fi
17218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_thr_create" >&5
17219 $as_echo "$ac_cv_search_thr_create" >&6; }
17220 ac_res=$ac_cv_search_thr_create
17221 if test "$ac_res" != no; then :
17222   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17223
17224
17225 $as_echo "#define HAVE_SOLARIS_THREADS 1" >>confdefs.h
17226
17227
17228
17229
17230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -mt" >&5
17231 $as_echo_n "checking whether $CC supports -mt... " >&6; }
17232 cache=`echo mt | sed 'y%.=/+-%___p_%'`
17233 if eval \${cv_prog_cc_flag_$cache+:} false; then :
17234   $as_echo_n "(cached) " >&6
17235 else
17236
17237 echo 'void f(void){}' >conftest.c
17238 if test -z "`$CC $CPPFLAGS $CFLAGS -mt -c conftest.c 2>&1`"; then
17239 eval "cv_prog_cc_flag_$cache=yes"
17240 else
17241 eval "cv_prog_cc_flag_$cache=no"
17242 fi
17243 rm -f conftest conftest.o conftest.c
17244
17245 fi
17246
17247 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
17248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17249 $as_echo "yes" >&6; }
17250 :
17251 CFLAGS="$CFLAGS -mt"
17252 else
17253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17254 $as_echo "no" >&6; }
17255 :
17256 CFLAGS="$CFLAGS -D_REENTRANT"
17257 fi
17258
17259                 ub_have_sol_threads=yes
17260
17261 else
17262
17263                 as_fn_error $? "no solaris threads found." "$LINENO" 5
17264
17265 fi
17266
17267         fi
17268 fi
17269
17270 fi # end of non-mingw check of thread libraries
17271
17272 # Check for SYSLOG_FACILITY
17273
17274 # Check whether --with-syslog-facility was given.
17275 if test "${with_syslog_facility+set}" = set; then :
17276   withval=$with_syslog_facility;  UNBOUND_SYSLOG_FACILITY="$withval"
17277 fi
17278
17279 case "${UNBOUND_SYSLOG_FACILITY}" in
17280
17281   LOCAL[0-7]) UNBOUND_SYSLOG_FACILITY="LOG_${UNBOUND_SYSLOG_FACILITY}" ;;
17282
17283            *) UNBOUND_SYSLOG_FACILITY="LOG_DAEMON" ;;
17284
17285 esac
17286
17287 cat >>confdefs.h <<_ACEOF
17288 #define UB_SYSLOG_FACILITY ${UNBOUND_SYSLOG_FACILITY}
17289 _ACEOF
17290
17291
17292 # Check for dynamic library module
17293
17294 # Check whether --with-dynlibmodule was given.
17295 if test "${with_dynlibmodule+set}" = set; then :
17296   withval=$with_dynlibmodule;
17297 else
17298    withval="no"
17299 fi
17300
17301
17302 if test x_$withval != x_no; then
17303
17304 $as_echo "#define WITH_DYNLIBMODULE 1" >>confdefs.h
17305
17306   WITH_DYNLIBMODULE=yes
17307
17308   DYNLIBMOD_OBJ="dynlibmod.lo"
17309
17310   DYNLIBMOD_HEADER='$(srcdir)/dynlibmod/dynlibmod.h'
17311
17312   if test $on_mingw = "no"; then
17313     # link with -ldl if not already there, for all executables because
17314     # dlopen call is in the dynlib module.  For unbound executable, also
17315     # export symbols.
17316     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
17317 $as_echo_n "checking for library containing dlopen... " >&6; }
17318 if ${ac_cv_search_dlopen+:} false; then :
17319   $as_echo_n "(cached) " >&6
17320 else
17321   ac_func_search_save_LIBS=$LIBS
17322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17323 /* end confdefs.h.  */
17324
17325 /* Override any GCC internal prototype to avoid an error.
17326    Use char because int might match the return type of a GCC
17327    builtin and then its argument prototype would still apply.  */
17328 #ifdef __cplusplus
17329 extern "C"
17330 #endif
17331 char dlopen ();
17332 int
17333 main ()
17334 {
17335 return dlopen ();
17336   ;
17337   return 0;
17338 }
17339 _ACEOF
17340 for ac_lib in '' dl; do
17341   if test -z "$ac_lib"; then
17342     ac_res="none required"
17343   else
17344     ac_res=-l$ac_lib
17345     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17346   fi
17347   if ac_fn_c_try_link "$LINENO"; then :
17348   ac_cv_search_dlopen=$ac_res
17349 fi
17350 rm -f core conftest.err conftest.$ac_objext \
17351     conftest$ac_exeext
17352   if ${ac_cv_search_dlopen+:} false; then :
17353   break
17354 fi
17355 done
17356 if ${ac_cv_search_dlopen+:} false; then :
17357
17358 else
17359   ac_cv_search_dlopen=no
17360 fi
17361 rm conftest.$ac_ext
17362 LIBS=$ac_func_search_save_LIBS
17363 fi
17364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
17365 $as_echo "$ac_cv_search_dlopen" >&6; }
17366 ac_res=$ac_cv_search_dlopen
17367 if test "$ac_res" != no; then :
17368   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17369
17370 fi
17371
17372     DYNLIBMOD_EXTRALIBS="-export-dynamic"
17373   else
17374     DYNLIBMOD_EXTRALIBS="-Wl,--export-all-symbols,--out-implib,libunbound.dll.a"
17375   fi
17376
17377 fi
17378
17379 # Check for PyUnbound
17380
17381 # Check whether --with-pyunbound was given.
17382 if test "${with_pyunbound+set}" = set; then :
17383   withval=$with_pyunbound;
17384 else
17385    withval="no"
17386 fi
17387
17388
17389 ub_test_python=no
17390 ub_with_pyunbound=no
17391 if test x_$withval != x_no; then
17392    ub_with_pyunbound=yes
17393    ub_test_python=yes
17394 fi
17395
17396 # Check for Python module
17397
17398 # Check whether --with-pythonmodule was given.
17399 if test "${with_pythonmodule+set}" = set; then :
17400   withval=$with_pythonmodule;
17401 else
17402    withval="no"
17403 fi
17404
17405
17406 ub_with_pythonmod=no
17407 if test x_$withval != x_no; then
17408    ub_with_pythonmod=yes
17409    ub_test_python=yes
17410 fi
17411
17412 # Check for Python & SWIG only on PyUnbound or PyModule
17413 if test x_$ub_test_python != x_no; then
17414
17415    # Check for Python
17416    ub_have_python=no
17417    ac_save_LIBS="$LIBS"
17418         #
17419         # Allow the use of a (user set) custom python version
17420         #
17421
17422
17423         # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
17424 set dummy python$PYTHON_VERSION; ac_word=$2
17425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17426 $as_echo_n "checking for $ac_word... " >&6; }
17427 if ${ac_cv_path_PYTHON+:} false; then :
17428   $as_echo_n "(cached) " >&6
17429 else
17430   case $PYTHON in
17431   [\\/]* | ?:[\\/]*)
17432   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
17433   ;;
17434   *)
17435   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17436 for as_dir in $PATH
17437 do
17438   IFS=$as_save_IFS
17439   test -z "$as_dir" && as_dir=.
17440     for ac_exec_ext in '' $ac_executable_extensions; do
17441   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17442     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
17443     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17444     break 2
17445   fi
17446 done
17447   done
17448 IFS=$as_save_IFS
17449
17450   ;;
17451 esac
17452 fi
17453 PYTHON=$ac_cv_path_PYTHON
17454 if test -n "$PYTHON"; then
17455   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
17456 $as_echo "$PYTHON" >&6; }
17457 else
17458   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17459 $as_echo "no" >&6; }
17460 fi
17461
17462
17463         if test -z "$PYTHON"; then
17464            as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
17465            PYTHON_VERSION=""
17466         fi
17467
17468         if test -z "$PYTHON_VERSION"; then
17469                 PYTHON_VERSION=`$PYTHON -c "import sys; \
17470                         print(sys.version.split()[0])"`
17471         fi
17472
17473         # Check if you have sysconfig
17474         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the sysconfig Python module" >&5
17475 $as_echo_n "checking for the sysconfig Python module... " >&6; }
17476         if ac_sysconfig_result=`$PYTHON -c "import sysconfig" 2>&1`; then
17477                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17478 $as_echo "yes" >&6; }
17479                 sysconfig_module="sysconfig"
17480                 # if yes, use sysconfig, because distutils is deprecated.
17481         else
17482                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17483 $as_echo "no" >&6; }
17484                 # if no, try to use distutils
17485
17486                 #
17487                 # Check if you have distutils, else fail
17488                 #
17489                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
17490 $as_echo_n "checking for the distutils Python package... " >&6; }
17491                 if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then
17492                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17493 $as_echo "yes" >&6; }
17494                 else
17495                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17496 $as_echo "no" >&6; }
17497                         as_fn_error $? "cannot import Python module \"distutils\".
17498         Please check your Python installation. The error was:
17499         $ac_distutils_result" "$LINENO" 5
17500                         PYTHON_VERSION=""
17501                 fi
17502
17503                 sysconfig_module="distutils.sysconfig"
17504         fi
17505
17506         #
17507         # Check for Python include path
17508         #
17509         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
17510 $as_echo_n "checking for Python include path... " >&6; }
17511         if test -z "$PYTHON_CPPFLAGS"; then
17512                 if test "$sysconfig_module" = "sysconfig"; then
17513                         python_path=`$PYTHON -c 'import sysconfig; \
17514                                 print(sysconfig.get_path("include"));'`
17515                 else
17516                         python_path=`$PYTHON -c "import distutils.sysconfig; \
17517                                 print(distutils.sysconfig.get_python_inc());"`
17518                 fi
17519                 if test -n "${python_path}"; then
17520                         python_path="-I$python_path"
17521                 fi
17522                 PYTHON_CPPFLAGS=$python_path
17523         fi
17524         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
17525 $as_echo "$PYTHON_CPPFLAGS" >&6; }
17526
17527
17528         #
17529         # Check for Python library path
17530         #
17531         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
17532 $as_echo_n "checking for Python library path... " >&6; }
17533         if test -z "$PYTHON_LDFLAGS"; then
17534                 PYTHON_LDFLAGS=`$PYTHON -c "from $sysconfig_module import *; \
17535                         print('-L'+get_config_var('LIBDIR')+' -L'+get_config_var('LIBDEST')+' '+get_config_var('BLDLIBRARY'));"`
17536         fi
17537         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
17538 $as_echo "$PYTHON_LDFLAGS" >&6; }
17539
17540
17541         if test -z "$PYTHON_LIBDIR"; then
17542                 PYTHON_LIBDIR=`$PYTHON -c "from $sysconfig_module import *; \
17543                         print(get_config_var('LIBDIR'));"`
17544         fi
17545
17546         #
17547         # Check for site packages
17548         #
17549         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
17550 $as_echo_n "checking for Python site-packages path... " >&6; }
17551         if test -z "$PYTHON_SITE_PKG"; then
17552                 if test "$sysconfig_module" = "sysconfig"; then
17553                         PYTHON_SITE_PKG=`$PYTHON -c 'import sysconfig; \
17554                                 print(sysconfig.get_path("platlib"));'`
17555                 else
17556                         PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
17557                                 print(distutils.sysconfig.get_python_lib(1,0));"`
17558                 fi
17559         fi
17560         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
17561 $as_echo "$PYTHON_SITE_PKG" >&6; }
17562
17563
17564         #
17565         # final check to see if everything compiles alright
17566         #
17567         { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
17568 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
17569         ac_ext=c
17570 ac_cpp='$CPP $CPPFLAGS'
17571 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17572 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17573 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17574
17575         # save current global flags
17576         ac_save_LIBS="$LIBS"
17577         ac_save_CPPFLAGS="$CPPFLAGS"
17578
17579         LIBS="$LIBS $PYTHON_LDFLAGS"
17580         CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17581         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17582 /* end confdefs.h.  */
17583
17584                 #include <Python.h>
17585
17586 int
17587 main ()
17588 {
17589
17590                 Py_Initialize();
17591
17592   ;
17593   return 0;
17594 }
17595 _ACEOF
17596 if ac_fn_c_try_link "$LINENO"; then :
17597   pythonexists=yes
17598 else
17599   pythonexists=no
17600 fi
17601 rm -f core conftest.err conftest.$ac_objext \
17602     conftest$ac_exeext conftest.$ac_ext
17603
17604         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
17605 $as_echo "$pythonexists" >&6; }
17606
17607         if test ! "$pythonexists" = "yes"; then
17608            as_fn_error $? "
17609   Could not link test program to Python. Maybe the main Python library has been
17610   installed in some non-standard library path. If so, pass it to configure,
17611   via the LDFLAGS environment variable.
17612   Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
17613   ============================================================================
17614    ERROR!
17615    You probably have to install the development version of the Python package
17616    for your distribution.  The exact name of this package varies among them.
17617   ============================================================================
17618            " "$LINENO" 5
17619           PYTHON_VERSION=""
17620         fi
17621         ac_ext=c
17622 ac_cpp='$CPP $CPPFLAGS'
17623 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17624 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17625 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17626
17627         # turn back to default flags
17628         CPPFLAGS="$ac_save_CPPFLAGS"
17629         LIBS="$ac_save_LIBS"
17630
17631         #
17632         # all done!
17633         #
17634
17635    if test ! -z "$PYTHON_VERSION"; then
17636         if test `$PYTHON -c "print('$PYTHON_VERSION' >= '2.4.0')"` = "False"; then
17637                 as_fn_error $? "Python version >= 2.4.0 is required" "$LINENO" 5
17638         fi
17639
17640       PY_MAJOR_VERSION="`$PYTHON -c \"import sys; print(sys.version_info[0])\"`"
17641
17642       # Have Python
17643
17644 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
17645
17646       if test x_$ub_with_pythonmod != x_no; then
17647         if test -n "$LIBS"; then
17648           LIBS="$PYTHON_LDFLAGS $LIBS"
17649         else
17650           LIBS="$PYTHON_LDFLAGS"
17651         fi
17652       fi
17653       PYTHON_LIBS="$PYTHON_LDFLAGS"
17654
17655       if test -n "$CPPFLAGS"; then
17656         CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17657       else
17658         CPPFLAGS="$PYTHON_CPPFLAGS"
17659       fi
17660       if test "$PYTHON_LIBDIR" != "/usr/lib" -a "$PYTHON_LIBDIR" != "" -a "$PYTHON_LIBDIR" != "/usr/lib64"; then
17661
17662         if test "x$enable_rpath" = xyes; then
17663                 if echo "$PYTHON_LIBDIR" | grep "^/" >/dev/null; then
17664                         RUNTIME_PATH="$RUNTIME_PATH -R$PYTHON_LIBDIR"
17665                 fi
17666         fi
17667
17668       fi
17669       ub_have_python=yes
17670       if test -n "$PKG_CONFIG" && \
17671     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"python\${PY_MAJOR_VERSION}\"\""; } >&5
17672   ($PKG_CONFIG --exists --print-errors ""python${PY_MAJOR_VERSION}"") 2>&5
17673   ac_status=$?
17674   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17675   test $ac_status = 0; }; then
17676   PC_PY_DEPENDENCY="python${PY_MAJOR_VERSION}"
17677 else
17678   PC_PY_DEPENDENCY="python"
17679 fi
17680
17681
17682       # Check for SWIG
17683       ub_have_swig=no
17684       # Check whether --enable-swig-version-check was given.
17685 if test "${enable_swig_version_check+set}" = set; then :
17686   enableval=$enable_swig_version_check;
17687 fi
17688
17689       if test "$enable_swig_version_check" = "yes"; then
17690
17691         # Extract the first word of "swig", so it can be a program name with args.
17692 set dummy swig; ac_word=$2
17693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17694 $as_echo_n "checking for $ac_word... " >&6; }
17695 if ${ac_cv_path_SWIG+:} false; then :
17696   $as_echo_n "(cached) " >&6
17697 else
17698   case $SWIG in
17699   [\\/]* | ?:[\\/]*)
17700   ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17701   ;;
17702   *)
17703   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17704 for as_dir in $PATH
17705 do
17706   IFS=$as_save_IFS
17707   test -z "$as_dir" && as_dir=.
17708     for ac_exec_ext in '' $ac_executable_extensions; do
17709   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17710     ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17711     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17712     break 2
17713   fi
17714 done
17715   done
17716 IFS=$as_save_IFS
17717
17718   ;;
17719 esac
17720 fi
17721 SWIG=$ac_cv_path_SWIG
17722 if test -n "$SWIG"; then
17723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17724 $as_echo "$SWIG" >&6; }
17725 else
17726   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17727 $as_echo "no" >&6; }
17728 fi
17729
17730
17731         if test -z "$SWIG" ; then
17732                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17733 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17734                 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17735         elif test -n "2.0.1" ; then
17736                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17737 $as_echo_n "checking for SWIG version... " >&6; }
17738                 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'`
17739                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17740 $as_echo "$swig_version" >&6; }
17741                 if test -n "$swig_version" ; then
17742                         # Calculate the required version number components
17743                         required=2.0.1
17744                         required_major=`echo $required | sed 's/[^0-9].*//'`
17745                         if test -z "$required_major" ; then
17746                                 required_major=0
17747                         fi
17748                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17749                         required_minor=`echo $required | sed 's/[^0-9].*//'`
17750                         if test -z "$required_minor" ; then
17751                                 required_minor=0
17752                         fi
17753                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17754                         required_patch=`echo $required | sed 's/[^0-9].*//'`
17755                         if test -z "$required_patch" ; then
17756                                 required_patch=0
17757                         fi
17758                         # Calculate the available version number components
17759                         available=$swig_version
17760                         available_major=`echo $available | sed 's/[^0-9].*//'`
17761                         if test -z "$available_major" ; then
17762                                 available_major=0
17763                         fi
17764                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17765                         available_minor=`echo $available | sed 's/[^0-9].*//'`
17766                         if test -z "$available_minor" ; then
17767                                 available_minor=0
17768                         fi
17769                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17770                         available_patch=`echo $available | sed 's/[^0-9].*//'`
17771                         if test -z "$available_patch" ; then
17772                                 available_patch=0
17773                         fi
17774                         badversion=0
17775                         if test $available_major -lt $required_major ; then
17776                                 badversion=1
17777                         fi
17778                         if test $available_major -eq $required_major \
17779                                 -a $available_minor -lt $required_minor ; then
17780                                 badversion=1
17781                         fi
17782                         if test $available_major -eq $required_major \
17783                                 -a $available_minor -eq $required_minor \
17784                                 -a $available_patch -lt $required_patch ; then
17785                                 badversion=1
17786                         fi
17787                         if test $badversion -eq 1 ; then
17788                                 { $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
17789 $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;}
17790                                 SWIG='echo "Error: SWIG version >= 2.0.1 is required.  You have '"$swig_version"'.  You should look at http://www.swig.org" ; false'
17791                         else
17792                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
17793 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
17794                                 SWIG_LIB=`$SWIG -swiglib`
17795                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
17796 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
17797                         fi
17798                 else
17799                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
17800 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
17801                         SWIG='echo "Error: Cannot determine SWIG version.  You should look at http://www.swig.org" ; false'
17802                 fi
17803         fi
17804
17805
17806       else
17807
17808         # Extract the first word of "swig", so it can be a program name with args.
17809 set dummy swig; ac_word=$2
17810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17811 $as_echo_n "checking for $ac_word... " >&6; }
17812 if ${ac_cv_path_SWIG+:} false; then :
17813   $as_echo_n "(cached) " >&6
17814 else
17815   case $SWIG in
17816   [\\/]* | ?:[\\/]*)
17817   ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17818   ;;
17819   *)
17820   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17821 for as_dir in $PATH
17822 do
17823   IFS=$as_save_IFS
17824   test -z "$as_dir" && as_dir=.
17825     for ac_exec_ext in '' $ac_executable_extensions; do
17826   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17827     ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17828     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17829     break 2
17830   fi
17831 done
17832   done
17833 IFS=$as_save_IFS
17834
17835   ;;
17836 esac
17837 fi
17838 SWIG=$ac_cv_path_SWIG
17839 if test -n "$SWIG"; then
17840   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17841 $as_echo "$SWIG" >&6; }
17842 else
17843   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17844 $as_echo "no" >&6; }
17845 fi
17846
17847
17848         if test -z "$SWIG" ; then
17849                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17850 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17851                 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17852         elif test -n "" ; then
17853                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17854 $as_echo_n "checking for SWIG version... " >&6; }
17855                 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'`
17856                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17857 $as_echo "$swig_version" >&6; }
17858                 if test -n "$swig_version" ; then
17859                         # Calculate the required version number components
17860                         required=
17861                         required_major=`echo $required | sed 's/[^0-9].*//'`
17862                         if test -z "$required_major" ; then
17863                                 required_major=0
17864                         fi
17865                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17866                         required_minor=`echo $required | sed 's/[^0-9].*//'`
17867                         if test -z "$required_minor" ; then
17868                                 required_minor=0
17869                         fi
17870                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17871                         required_patch=`echo $required | sed 's/[^0-9].*//'`
17872                         if test -z "$required_patch" ; then
17873                                 required_patch=0
17874                         fi
17875                         # Calculate the available version number components
17876                         available=$swig_version
17877                         available_major=`echo $available | sed 's/[^0-9].*//'`
17878                         if test -z "$available_major" ; then
17879                                 available_major=0
17880                         fi
17881                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17882                         available_minor=`echo $available | sed 's/[^0-9].*//'`
17883                         if test -z "$available_minor" ; then
17884                                 available_minor=0
17885                         fi
17886                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17887                         available_patch=`echo $available | sed 's/[^0-9].*//'`
17888                         if test -z "$available_patch" ; then
17889                                 available_patch=0
17890                         fi
17891                         badversion=0
17892                         if test $available_major -lt $required_major ; then
17893                                 badversion=1
17894                         fi
17895                         if test $available_major -eq $required_major \
17896                                 -a $available_minor -lt $required_minor ; then
17897                                 badversion=1
17898                         fi
17899                         if test $available_major -eq $required_major \
17900                                 -a $available_minor -eq $required_minor \
17901                                 -a $available_patch -lt $required_patch ; then
17902                                 badversion=1
17903                         fi
17904                         if test $badversion -eq 1 ; then
17905                                 { $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
17906 $as_echo "$as_me: WARNING: SWIG version >=  is required.  You have $swig_version.  You should look at http://www.swig.org" >&2;}
17907                                 SWIG='echo "Error: SWIG version >=  is required.  You have '"$swig_version"'.  You should look at http://www.swig.org" ; false'
17908                         else
17909                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
17910 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
17911                                 SWIG_LIB=`$SWIG -swiglib`
17912                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
17913 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
17914                         fi
17915                 else
17916                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
17917 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
17918                         SWIG='echo "Error: Cannot determine SWIG version.  You should look at http://www.swig.org" ; false'
17919                 fi
17920         fi
17921
17922
17923       fi
17924       { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG" >&5
17925 $as_echo_n "checking SWIG... " >&6; }
17926       if test ! -x "$SWIG"; then
17927          as_fn_error $? "failed to find swig tool, install it, or do not build Python module and PyUnbound" "$LINENO" 5
17928       else
17929
17930 $as_echo "#define HAVE_SWIG 1" >>confdefs.h
17931
17932          swig="$SWIG"
17933
17934          { $as_echo "$as_me:${as_lineno-$LINENO}: result: present" >&5
17935 $as_echo "present" >&6; }
17936
17937          # If have Python & SWIG
17938          # Declare PythonMod
17939          if test x_$ub_with_pythonmod != x_no; then
17940
17941 $as_echo "#define WITH_PYTHONMODULE 1" >>confdefs.h
17942
17943             WITH_PYTHONMODULE=yes
17944
17945             PYTHONMOD_OBJ="pythonmod.lo pythonmod_utils.lo"
17946
17947             PYTHONMOD_HEADER='$(srcdir)/pythonmod/pythonmod.h'
17948
17949             PYTHONMOD_INSTALL=pythonmod-install
17950
17951             PYTHONMOD_UNINSTALL=pythonmod-uninstall
17952
17953          fi
17954
17955          # Declare PyUnbound
17956          if test x_$ub_with_pyunbound != x_no; then
17957
17958 $as_echo "#define WITH_PYUNBOUND 1" >>confdefs.h
17959
17960             WITH_PYUNBOUND=yes
17961
17962             PYUNBOUND_OBJ="libunbound_wrap.lo"
17963
17964             PYUNBOUND_TARGET="_unbound.la"
17965
17966             PYUNBOUND_INSTALL=pyunbound-install
17967
17968             PYUNBOUND_UNINSTALL=pyunbound-uninstall
17969
17970          fi
17971       fi
17972    else
17973       { $as_echo "$as_me:${as_lineno-$LINENO}: result: *** Python libraries not found, won't build PythonMod or PyUnbound ***" >&5
17974 $as_echo "*** Python libraries not found, won't build PythonMod or PyUnbound ***" >&6; }
17975       ub_with_pyunbound=no
17976       ub_with_pythonmod=no
17977    fi
17978 fi
17979
17980 if test "`uname`" = "NetBSD"; then
17981         NETBSD_LINTFLAGS='"-D__RENAME(x)=" -D_NETINET_IN_H_'
17982
17983 fi
17984
17985 if test "`uname`" = "Linux"; then
17986         # splint cannot parse modern c99 header files
17987         GCC_DOCKER_LINTFLAGS='-syntax'
17988
17989 fi
17990 CONFIG_DATE=`date +%Y%m%d`
17991
17992
17993 # Checks for libraries.
17994
17995 # libnss
17996 USE_NSS="no"
17997
17998 # Check whether --with-nss was given.
17999 if test "${with_nss+set}" = set; then :
18000   withval=$with_nss;
18001         USE_NSS="yes"
18002
18003 $as_echo "#define HAVE_NSS 1" >>confdefs.h
18004
18005         if test "$withval" != "" -a "$withval" != "yes"; then
18006                 CPPFLAGS="$CPPFLAGS -I$withval/include/nss3"
18007                 LDFLAGS="$LDFLAGS -L$withval/lib"
18008
18009         if test "x$enable_rpath" = xyes; then
18010                 if echo "$withval/lib" | grep "^/" >/dev/null; then
18011                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
18012                 fi
18013         fi
18014
18015                 CPPFLAGS="-I$withval/include/nspr4 $CPPFLAGS"
18016         else
18017                 CPPFLAGS="$CPPFLAGS -I/usr/include/nss3"
18018                 CPPFLAGS="-I/usr/include/nspr4 $CPPFLAGS"
18019         fi
18020         LIBS="$LIBS -lnss3 -lnspr4"
18021         SSLLIB=""
18022         PC_CRYPTO_DEPENDENCY="nss nspr"
18023
18024
18025
18026 fi
18027
18028
18029 # libnettle
18030 USE_NETTLE="no"
18031
18032 # Check whether --with-nettle was given.
18033 if test "${with_nettle+set}" = set; then :
18034   withval=$with_nettle;
18035         USE_NETTLE="yes"
18036
18037 $as_echo "#define HAVE_NETTLE 1" >>confdefs.h
18038
18039         for ac_header in nettle/dsa-compat.h
18040 do :
18041   ac_fn_c_check_header_compile "$LINENO" "nettle/dsa-compat.h" "ac_cv_header_nettle_dsa_compat_h" "$ac_includes_default
18042 "
18043 if test "x$ac_cv_header_nettle_dsa_compat_h" = xyes; then :
18044   cat >>confdefs.h <<_ACEOF
18045 #define HAVE_NETTLE_DSA_COMPAT_H 1
18046 _ACEOF
18047
18048 fi
18049
18050 done
18051
18052         if test "$withval" != "" -a "$withval" != "yes"; then
18053                 CPPFLAGS="$CPPFLAGS -I$withval/include/nettle"
18054                 LDFLAGS="$LDFLAGS -L$withval/lib"
18055
18056         if test "x$enable_rpath" = xyes; then
18057                 if echo "$withval/lib" | grep "^/" >/dev/null; then
18058                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
18059                 fi
18060         fi
18061
18062         else
18063                 CPPFLAGS="$CPPFLAGS -I/usr/include/nettle"
18064         fi
18065         LIBS="$LIBS -lhogweed -lnettle -lgmp"
18066         SSLLIB=""
18067         PC_CRYPTO_DEPENDENCY="hogweed nettle"
18068
18069
18070
18071 fi
18072
18073
18074 # openssl
18075 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18076
18077
18078 # Check whether --with-ssl was given.
18079 if test "${with_ssl+set}" = set; then :
18080   withval=$with_ssl;
18081
18082 else
18083
18084             withval="yes"
18085
18086 fi
18087
18088     if test x_$withval = x_no; then
18089         as_fn_error $? "Need SSL library to do digital signature cryptography" "$LINENO" 5
18090     fi
18091
18092     withval=$withval
18093     if test x_$withval != x_no; then
18094         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL" >&5
18095 $as_echo_n "checking for SSL... " >&6; }
18096         if test -n "$withval"; then
18097                                                                                 if test ! -f "$withval/include/openssl/ssl.h" -a -f "$withval/openssl/ssl.h"; then
18098                         ssldir="$withval"
18099                         found_ssl="yes"
18100                         withval=""
18101                         ssldir_include="$ssldir"
18102                                                 ssldir_lib=`echo $ssldir | sed -e 's/include/lib/'`
18103                         if test -f "$ssldir_lib/libssl.a" -o -f "$ssldir_lib/libssl.so"; then
18104                                 : # found here
18105                         else
18106                                 ssldir_lib=`echo $ssldir | sed -e 's/include/lib64/'`
18107                                 if test -f "$ssldir_lib/libssl.a" -o -f "$ssldir_lib/libssl.so"; then
18108                                         : # found here
18109                                 else
18110                                         as_fn_error $? "Could not find openssl lib file, $ssldir_lib/libssl.so,a, pass like \"/usr/local\" or \"/usr/include/openssl11\"" "$LINENO" 5
18111                                 fi
18112                         fi
18113                 fi
18114         fi
18115         if test x_$withval = x_ -o x_$withval = x_yes; then
18116             withval="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw /usr"
18117         fi
18118         for dir in $withval; do
18119             ssldir="$dir"
18120             if test -f "$dir/include/openssl/ssl.h"; then
18121                 found_ssl="yes"
18122                 ssldir_include="$ssldir/include"
18123                 if test ! -d "$ssldir/lib" -a -d "$ssldir/lib64"; then
18124                         ssldir_lib="$ssldir/lib64"
18125                 else
18126                         ssldir_lib="$ssldir/lib"
18127                 fi
18128                 break;
18129             fi
18130         done
18131         if test x_$found_ssl != x_yes; then
18132             as_fn_error $? "Cannot find the SSL libraries in $withval" "$LINENO" 5
18133         else
18134             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $ssldir" >&5
18135 $as_echo "found in $ssldir" >&6; }
18136
18137 cat >>confdefs.h <<_ACEOF
18138 #define HAVE_SSL /**/
18139 _ACEOF
18140
18141             HAVE_SSL=yes
18142                         if test "$ssldir" != "/usr"; then
18143                     CPPFLAGS="$CPPFLAGS -I$ssldir_include"
18144                     LIBSSL_CPPFLAGS="$LIBSSL_CPPFLAGS -I$ssldir_include"
18145                     LDFLAGS="$LDFLAGS -L$ssldir_lib"
18146                     LIBSSL_LDFLAGS="$LIBSSL_LDFLAGS -L$ssldir_lib"
18147
18148         if test "x$enable_rpath" = xyes; then
18149                 if echo "$ssldir_lib" | grep "^/" >/dev/null; then
18150                         RUNTIME_PATH="$RUNTIME_PATH -R$ssldir_lib"
18151                 fi
18152         fi
18153
18154             fi
18155
18156             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EVP_sha256 in -lcrypto" >&5
18157 $as_echo_n "checking for EVP_sha256 in -lcrypto... " >&6; }
18158             LIBS="$LIBS -lcrypto"
18159             LIBSSL_LIBS="$LIBSSL_LIBS -lcrypto"
18160             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18161 /* end confdefs.h.  */
18162
18163 int
18164 main ()
18165 {
18166
18167                 int EVP_sha256(void);
18168                 (void)EVP_sha256();
18169
18170   ;
18171   return 0;
18172 }
18173 _ACEOF
18174 if ac_fn_c_try_link "$LINENO"; then :
18175
18176                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18177 $as_echo "yes" >&6; }
18178
18179 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18180
18181
18182 else
18183
18184                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18185 $as_echo "no" >&6; }
18186                 # check if -lwsock32 or -lgdi32 are needed.
18187                 BAKLIBS="$LIBS"
18188                 BAKSSLLIBS="$LIBSSL_LIBS"
18189                 LIBS="$LIBS -lgdi32 -lws2_32"
18190                 LIBSSL_LIBS="$LIBSSL_LIBS -lgdi32 -lws2_32"
18191                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -lgdi32" >&5
18192 $as_echo_n "checking if -lcrypto needs -lgdi32... " >&6; }
18193                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18194 /* end confdefs.h.  */
18195
18196 int
18197 main ()
18198 {
18199
18200                     int EVP_sha256(void);
18201                     (void)EVP_sha256();
18202
18203   ;
18204   return 0;
18205 }
18206 _ACEOF
18207 if ac_fn_c_try_link "$LINENO"; then :
18208
18209
18210 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18211
18212                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18213 $as_echo "yes" >&6; }
18214
18215 else
18216
18217                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18218 $as_echo "no" >&6; }
18219                     LIBS="$BAKLIBS"
18220                     LIBSSL_LIBS="$BAKSSLLIBS"
18221                     LIBS="$LIBS -ldl"
18222                     LIBSSL_LIBS="$LIBSSL_LIBS -ldl"
18223                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl" >&5
18224 $as_echo_n "checking if -lcrypto needs -ldl... " >&6; }
18225                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18226 /* end confdefs.h.  */
18227
18228 int
18229 main ()
18230 {
18231
18232                         int EVP_sha256(void);
18233                         (void)EVP_sha256();
18234
18235   ;
18236   return 0;
18237 }
18238 _ACEOF
18239 if ac_fn_c_try_link "$LINENO"; then :
18240
18241
18242 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18243
18244                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18245 $as_echo "yes" >&6; }
18246
18247 else
18248
18249                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18250 $as_echo "no" >&6; }
18251                         LIBS="$BAKLIBS"
18252                         LIBSSL_LIBS="$BAKSSLLIBS"
18253                         LIBS="$LIBS -ldl -pthread"
18254                         LIBSSL_LIBS="$LIBSSL_LIBS -ldl -pthread"
18255                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl -pthread" >&5
18256 $as_echo_n "checking if -lcrypto needs -ldl -pthread... " >&6; }
18257                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18258 /* end confdefs.h.  */
18259
18260 int
18261 main ()
18262 {
18263
18264                             int EVP_sha256(void);
18265                             (void)EVP_sha256();
18266
18267   ;
18268   return 0;
18269 }
18270 _ACEOF
18271 if ac_fn_c_try_link "$LINENO"; then :
18272
18273
18274 $as_echo "#define HAVE_EVP_SHA256 1" >>confdefs.h
18275
18276                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18277 $as_echo "yes" >&6; }
18278
18279 else
18280
18281                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18282 $as_echo "no" >&6; }
18283                             as_fn_error $? "OpenSSL found in $ssldir, but version 0.9.7 or higher is required" "$LINENO" 5
18284
18285 fi
18286 rm -f core conftest.err conftest.$ac_objext \
18287     conftest$ac_exeext conftest.$ac_ext
18288
18289 fi
18290 rm -f core conftest.err conftest.$ac_objext \
18291     conftest$ac_exeext conftest.$ac_ext
18292
18293 fi
18294 rm -f core conftest.err conftest.$ac_objext \
18295     conftest$ac_exeext conftest.$ac_ext
18296
18297 fi
18298 rm -f core conftest.err conftest.$ac_objext \
18299     conftest$ac_exeext conftest.$ac_ext
18300         fi
18301
18302
18303     fi
18304 for ac_header in openssl/ssl.h
18305 do :
18306   ac_fn_c_check_header_compile "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default
18307 "
18308 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
18309   cat >>confdefs.h <<_ACEOF
18310 #define HAVE_OPENSSL_SSL_H 1
18311 _ACEOF
18312
18313 fi
18314
18315 done
18316
18317 for ac_header in openssl/err.h
18318 do :
18319   ac_fn_c_check_header_compile "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default
18320 "
18321 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
18322   cat >>confdefs.h <<_ACEOF
18323 #define HAVE_OPENSSL_ERR_H 1
18324 _ACEOF
18325
18326 fi
18327
18328 done
18329
18330 for ac_header in openssl/rand.h
18331 do :
18332   ac_fn_c_check_header_compile "$LINENO" "openssl/rand.h" "ac_cv_header_openssl_rand_h" "$ac_includes_default
18333 "
18334 if test "x$ac_cv_header_openssl_rand_h" = xyes; then :
18335   cat >>confdefs.h <<_ACEOF
18336 #define HAVE_OPENSSL_RAND_H 1
18337 _ACEOF
18338
18339 fi
18340
18341 done
18342
18343
18344
18345
18346 # check if libssl needs libdl
18347 BAKLIBS="$LIBS"
18348 LIBS="-lssl $LIBS"
18349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs libdl" >&5
18350 $as_echo_n "checking if libssl needs libdl... " >&6; }
18351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18352 /* end confdefs.h.  */
18353
18354 /* Override any GCC internal prototype to avoid an error.
18355    Use char because int might match the return type of a GCC
18356    builtin and then its argument prototype would still apply.  */
18357 #ifdef __cplusplus
18358 extern "C"
18359 #endif
18360 char SSL_CTX_new ();
18361 int
18362 main ()
18363 {
18364 return SSL_CTX_new ();
18365   ;
18366   return 0;
18367 }
18368 _ACEOF
18369 if ac_fn_c_try_link "$LINENO"; then :
18370
18371         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18372 $as_echo "no" >&6; }
18373         LIBS="$BAKLIBS"
18374
18375 else
18376
18377         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18378 $as_echo "yes" >&6; }
18379         LIBS="$BAKLIBS"
18380         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
18381 $as_echo_n "checking for library containing dlopen... " >&6; }
18382 if ${ac_cv_search_dlopen+:} false; then :
18383   $as_echo_n "(cached) " >&6
18384 else
18385   ac_func_search_save_LIBS=$LIBS
18386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18387 /* end confdefs.h.  */
18388
18389 /* Override any GCC internal prototype to avoid an error.
18390    Use char because int might match the return type of a GCC
18391    builtin and then its argument prototype would still apply.  */
18392 #ifdef __cplusplus
18393 extern "C"
18394 #endif
18395 char dlopen ();
18396 int
18397 main ()
18398 {
18399 return dlopen ();
18400   ;
18401   return 0;
18402 }
18403 _ACEOF
18404 for ac_lib in '' dl; do
18405   if test -z "$ac_lib"; then
18406     ac_res="none required"
18407   else
18408     ac_res=-l$ac_lib
18409     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18410   fi
18411   if ac_fn_c_try_link "$LINENO"; then :
18412   ac_cv_search_dlopen=$ac_res
18413 fi
18414 rm -f core conftest.err conftest.$ac_objext \
18415     conftest$ac_exeext
18416   if ${ac_cv_search_dlopen+:} false; then :
18417   break
18418 fi
18419 done
18420 if ${ac_cv_search_dlopen+:} false; then :
18421
18422 else
18423   ac_cv_search_dlopen=no
18424 fi
18425 rm conftest.$ac_ext
18426 LIBS=$ac_func_search_save_LIBS
18427 fi
18428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
18429 $as_echo "$ac_cv_search_dlopen" >&6; }
18430 ac_res=$ac_cv_search_dlopen
18431 if test "$ac_res" != no; then :
18432   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18433
18434 fi
18435
18436
18437 fi
18438 rm -f core conftest.err conftest.$ac_objext \
18439     conftest$ac_exeext conftest.$ac_ext
18440 SSLLIB="-lssl"
18441
18442 PC_CRYPTO_DEPENDENCY=""
18443
18444
18445 # check if -lcrypt32 is needed because CAPIENG needs that. (on windows)
18446 BAKLIBS="$LIBS"
18447 LIBS="-lssl $LIBS"
18448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs -lcrypt32" >&5
18449 $as_echo_n "checking if libssl needs -lcrypt32... " >&6; }
18450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18451 /* end confdefs.h.  */
18452
18453 int
18454 main ()
18455 {
18456
18457         int EVP_sha256(void);
18458         (void)EVP_sha256();
18459
18460   ;
18461   return 0;
18462 }
18463 _ACEOF
18464 if ac_fn_c_try_link "$LINENO"; then :
18465
18466         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18467 $as_echo "no" >&6; }
18468         LIBS="$BAKLIBS"
18469
18470 else
18471
18472         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18473 $as_echo "yes" >&6; }
18474         LIBS="$BAKLIBS"
18475         LIBS="$LIBS -lcrypt32"
18476
18477 fi
18478 rm -f core conftest.err conftest.$ac_objext \
18479     conftest$ac_exeext conftest.$ac_ext
18480
18481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LibreSSL" >&5
18482 $as_echo_n "checking for LibreSSL... " >&6; }
18483 if grep VERSION_TEXT $ssldir_include/openssl/opensslv.h | grep "LibreSSL" >/dev/null; then
18484         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18485 $as_echo "yes" >&6; }
18486
18487 $as_echo "#define HAVE_LIBRESSL 1" >>confdefs.h
18488
18489         # libressl provides these compat functions, but they may also be
18490         # declared by the OS in libc.  See if they have been declared.
18491         ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
18492 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
18493   ac_have_decl=1
18494 else
18495   ac_have_decl=0
18496 fi
18497
18498 cat >>confdefs.h <<_ACEOF
18499 #define HAVE_DECL_STRLCPY $ac_have_decl
18500 _ACEOF
18501 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
18502 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
18503   ac_have_decl=1
18504 else
18505   ac_have_decl=0
18506 fi
18507
18508 cat >>confdefs.h <<_ACEOF
18509 #define HAVE_DECL_STRLCAT $ac_have_decl
18510 _ACEOF
18511 ac_fn_c_check_decl "$LINENO" "arc4random" "ac_cv_have_decl_arc4random" "$ac_includes_default"
18512 if test "x$ac_cv_have_decl_arc4random" = xyes; then :
18513   ac_have_decl=1
18514 else
18515   ac_have_decl=0
18516 fi
18517
18518 cat >>confdefs.h <<_ACEOF
18519 #define HAVE_DECL_ARC4RANDOM $ac_have_decl
18520 _ACEOF
18521 ac_fn_c_check_decl "$LINENO" "arc4random_uniform" "ac_cv_have_decl_arc4random_uniform" "$ac_includes_default"
18522 if test "x$ac_cv_have_decl_arc4random_uniform" = xyes; then :
18523   ac_have_decl=1
18524 else
18525   ac_have_decl=0
18526 fi
18527
18528 cat >>confdefs.h <<_ACEOF
18529 #define HAVE_DECL_ARC4RANDOM_UNIFORM $ac_have_decl
18530 _ACEOF
18531
18532 else
18533         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18534 $as_echo "no" >&6; }
18535 fi
18536 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
18537 do :
18538   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18539 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
18540 "
18541 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18542   cat >>confdefs.h <<_ACEOF
18543 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18544 _ACEOF
18545
18546 fi
18547
18548 done
18549
18550 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
18551 do :
18552   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18553 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18554 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18555   cat >>confdefs.h <<_ACEOF
18556 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18557 _ACEOF
18558
18559 fi
18560 done
18561
18562
18563 # these check_funcs need -lssl
18564 BAKLIBS="$LIBS"
18565 LIBS="-lssl $LIBS"
18566 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
18567 do :
18568   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18569 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18570 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18571   cat >>confdefs.h <<_ACEOF
18572 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18573 _ACEOF
18574
18575 fi
18576 done
18577
18578 LIBS="$BAKLIBS"
18579
18580 ac_fn_c_check_decl "$LINENO" "SSL_COMP_get_compression_methods" "ac_cv_have_decl_SSL_COMP_get_compression_methods" "
18581 $ac_includes_default
18582 #ifdef HAVE_OPENSSL_ERR_H
18583 #include <openssl/err.h>
18584 #endif
18585
18586 #ifdef HAVE_OPENSSL_RAND_H
18587 #include <openssl/rand.h>
18588 #endif
18589
18590 #ifdef HAVE_OPENSSL_CONF_H
18591 #include <openssl/conf.h>
18592 #endif
18593
18594 #ifdef HAVE_OPENSSL_ENGINE_H
18595 #include <openssl/engine.h>
18596 #endif
18597 #include <openssl/ssl.h>
18598 #include <openssl/evp.h>
18599
18600 "
18601 if test "x$ac_cv_have_decl_SSL_COMP_get_compression_methods" = xyes; then :
18602   ac_have_decl=1
18603 else
18604   ac_have_decl=0
18605 fi
18606
18607 cat >>confdefs.h <<_ACEOF
18608 #define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS $ac_have_decl
18609 _ACEOF
18610 ac_fn_c_check_decl "$LINENO" "sk_SSL_COMP_pop_free" "ac_cv_have_decl_sk_SSL_COMP_pop_free" "
18611 $ac_includes_default
18612 #ifdef HAVE_OPENSSL_ERR_H
18613 #include <openssl/err.h>
18614 #endif
18615
18616 #ifdef HAVE_OPENSSL_RAND_H
18617 #include <openssl/rand.h>
18618 #endif
18619
18620 #ifdef HAVE_OPENSSL_CONF_H
18621 #include <openssl/conf.h>
18622 #endif
18623
18624 #ifdef HAVE_OPENSSL_ENGINE_H
18625 #include <openssl/engine.h>
18626 #endif
18627 #include <openssl/ssl.h>
18628 #include <openssl/evp.h>
18629
18630 "
18631 if test "x$ac_cv_have_decl_sk_SSL_COMP_pop_free" = xyes; then :
18632   ac_have_decl=1
18633 else
18634   ac_have_decl=0
18635 fi
18636
18637 cat >>confdefs.h <<_ACEOF
18638 #define HAVE_DECL_SK_SSL_COMP_POP_FREE $ac_have_decl
18639 _ACEOF
18640 ac_fn_c_check_decl "$LINENO" "SSL_CTX_set_ecdh_auto" "ac_cv_have_decl_SSL_CTX_set_ecdh_auto" "
18641 $ac_includes_default
18642 #ifdef HAVE_OPENSSL_ERR_H
18643 #include <openssl/err.h>
18644 #endif
18645
18646 #ifdef HAVE_OPENSSL_RAND_H
18647 #include <openssl/rand.h>
18648 #endif
18649
18650 #ifdef HAVE_OPENSSL_CONF_H
18651 #include <openssl/conf.h>
18652 #endif
18653
18654 #ifdef HAVE_OPENSSL_ENGINE_H
18655 #include <openssl/engine.h>
18656 #endif
18657 #include <openssl/ssl.h>
18658 #include <openssl/evp.h>
18659
18660 "
18661 if test "x$ac_cv_have_decl_SSL_CTX_set_ecdh_auto" = xyes; then :
18662   ac_have_decl=1
18663 else
18664   ac_have_decl=0
18665 fi
18666
18667 cat >>confdefs.h <<_ACEOF
18668 #define HAVE_DECL_SSL_CTX_SET_ECDH_AUTO $ac_have_decl
18669 _ACEOF
18670
18671
18672 if test "$ac_cv_func_HMAC_Init_ex" = "yes"; then
18673 # check function return type.
18674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the return type of HMAC_Init_ex" >&5
18675 $as_echo_n "checking the return type of HMAC_Init_ex... " >&6; }
18676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18677 /* end confdefs.h.  */
18678
18679 #ifdef HAVE_OPENSSL_ERR_H
18680 #include <openssl/err.h>
18681 #endif
18682
18683 #ifdef HAVE_OPENSSL_RAND_H
18684 #include <openssl/rand.h>
18685 #endif
18686
18687 #ifdef HAVE_OPENSSL_CONF_H
18688 #include <openssl/conf.h>
18689 #endif
18690
18691 #ifdef HAVE_OPENSSL_ENGINE_H
18692 #include <openssl/engine.h>
18693 #endif
18694 #include <openssl/ssl.h>
18695 #include <openssl/evp.h>
18696
18697 int
18698 main ()
18699 {
18700
18701         HMAC_CTX* hmac_ctx = NULL;
18702         void* hmac_key = NULL;
18703         const EVP_MD* digest = NULL;
18704         int x = HMAC_Init_ex(hmac_ctx, hmac_key, 32, digest, NULL);
18705         (void)x;
18706
18707   ;
18708   return 0;
18709 }
18710 _ACEOF
18711 if ac_fn_c_try_compile "$LINENO"; then :
18712
18713         { $as_echo "$as_me:${as_lineno-$LINENO}: result: int" >&5
18714 $as_echo "int" >&6; }
18715
18716 else
18717
18718         { $as_echo "$as_me:${as_lineno-$LINENO}: result: void" >&5
18719 $as_echo "void" >&6; }
18720
18721 $as_echo "#define HMAC_INIT_EX_RETURNS_VOID 1" >>confdefs.h
18722
18723
18724 fi
18725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18726 fi
18727
18728 fi
18729
18730
18731 # libbsd
18732
18733 # Check whether --with-libbsd was given.
18734 if test "${with_libbsd+set}" = set; then :
18735   withval=$with_libbsd;
18736         for ac_header in bsd/string.h bsd/stdlib.h
18737 do :
18738   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18739 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
18740 "
18741 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18742   cat >>confdefs.h <<_ACEOF
18743 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18744 _ACEOF
18745
18746 fi
18747
18748 done
18749
18750         if test "x$ac_cv_header_bsd_string_h" = xyes -a "x$ac_cv_header_bsd_stdlib_h" = xyes; then
18751                 for func in strlcpy strlcat arc4random arc4random_uniform reallocarray; do
18752                         as_ac_Search=`$as_echo "ac_cv_search_$func" | $as_tr_sh`
18753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing $func" >&5
18754 $as_echo_n "checking for library containing $func... " >&6; }
18755 if eval \${$as_ac_Search+:} false; then :
18756   $as_echo_n "(cached) " >&6
18757 else
18758   ac_func_search_save_LIBS=$LIBS
18759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18760 /* end confdefs.h.  */
18761
18762 /* Override any GCC internal prototype to avoid an error.
18763    Use char because int might match the return type of a GCC
18764    builtin and then its argument prototype would still apply.  */
18765 #ifdef __cplusplus
18766 extern "C"
18767 #endif
18768 char $func ();
18769 int
18770 main ()
18771 {
18772 return $func ();
18773   ;
18774   return 0;
18775 }
18776 _ACEOF
18777 for ac_lib in '' bsd; do
18778   if test -z "$ac_lib"; then
18779     ac_res="none required"
18780   else
18781     ac_res=-l$ac_lib
18782     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18783   fi
18784   if ac_fn_c_try_link "$LINENO"; then :
18785   eval "$as_ac_Search=\$ac_res"
18786 fi
18787 rm -f core conftest.err conftest.$ac_objext \
18788     conftest$ac_exeext
18789   if eval \${$as_ac_Search+:} false; then :
18790   break
18791 fi
18792 done
18793 if eval \${$as_ac_Search+:} false; then :
18794
18795 else
18796   eval "$as_ac_Search=no"
18797 fi
18798 rm conftest.$ac_ext
18799 LIBS=$ac_func_search_save_LIBS
18800 fi
18801 eval ac_res=\$$as_ac_Search
18802                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18803 $as_echo "$ac_res" >&6; }
18804 eval ac_res=\$$as_ac_Search
18805 if test "$ac_res" != no; then :
18806   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18807
18808
18809 $as_echo "#define HAVE_LIBBSD 1" >>confdefs.h
18810
18811                                 PC_LIBBSD_DEPENDENCY=libbsd
18812
18813
18814 fi
18815
18816                 done
18817         fi
18818
18819 fi
18820
18821
18822 # Check whether --enable-sha1 was given.
18823 if test "${enable_sha1+set}" = set; then :
18824   enableval=$enable_sha1;
18825 fi
18826
18827 case "$enable_sha1" in
18828         no)
18829         ;;
18830         yes|*)
18831
18832 $as_echo "#define USE_SHA1 1" >>confdefs.h
18833
18834         ;;
18835 esac
18836
18837
18838 # Check whether --enable-sha2 was given.
18839 if test "${enable_sha2+set}" = set; then :
18840   enableval=$enable_sha2;
18841 fi
18842
18843 case "$enable_sha2" in
18844         no)
18845         ;;
18846         yes|*)
18847
18848 $as_echo "#define USE_SHA2 1" >>confdefs.h
18849
18850         ;;
18851 esac
18852
18853 # Check whether --enable-subnet was given.
18854 if test "${enable_subnet+set}" = set; then :
18855   enableval=$enable_subnet;
18856 fi
18857
18858 case "$enable_subnet" in
18859         yes)
18860
18861 $as_echo "#define CLIENT_SUBNET 1" >>confdefs.h
18862
18863         SUBNET_OBJ="edns-subnet.lo subnetmod.lo addrtree.lo subnet-whitelist.lo"
18864
18865         SUBNET_HEADER='$(srcdir)/edns-subnet/subnetmod.h $(srcdir)/edns-subnet/edns-subnet.h $(srcdir)/edns-subnet/subnet-whitelist.h $(srcdir)/edns-subnet/addrtree.h'
18866
18867         ;;
18868         no|*)
18869         ;;
18870 esac
18871
18872 # check whether gost also works
18873
18874 # Check whether --enable-gost was given.
18875 if test "${enable_gost+set}" = set; then :
18876   enableval=$enable_gost;
18877 fi
18878
18879 use_gost="no"
18880 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18881 case "$enable_gost" in
18882         no)
18883         ;;
18884         *)
18885         ac_fn_c_check_func "$LINENO" "EVP_PKEY_set_type_str" "ac_cv_func_EVP_PKEY_set_type_str"
18886 if test "x$ac_cv_func_EVP_PKEY_set_type_str" = xyes; then :
18887   :
18888 else
18889   as_fn_error $? "OpenSSL 1.0.0 is needed for GOST support" "$LINENO" 5
18890 fi
18891
18892         ac_fn_c_check_func "$LINENO" "EC_KEY_new" "ac_cv_func_EC_KEY_new"
18893 if test "x$ac_cv_func_EC_KEY_new" = xyes; then :
18894
18895 else
18896   as_fn_error $? "OpenSSL does not support ECC, needed for GOST support" "$LINENO" 5
18897 fi
18898
18899
18900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GOST works" >&5
18901 $as_echo_n "checking if GOST works... " >&6; }
18902 if test c${cross_compiling} = cno; then
18903 BAKCFLAGS="$CFLAGS"
18904 if test -n "$ssldir"; then
18905         CFLAGS="$CFLAGS -Wl,-rpath,$ssldir_lib"
18906 fi
18907 if test "$cross_compiling" = yes; then :
18908   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18909 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18910 as_fn_error $? "cannot run test program while cross compiling
18911 See \`config.log' for more details" "$LINENO" 5; }
18912 else
18913   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18914 /* end confdefs.h.  */
18915
18916 #include <string.h>
18917 #include <openssl/ssl.h>
18918 #include <openssl/evp.h>
18919 #include <openssl/engine.h>
18920 #include <openssl/conf.h>
18921 /* routine to load gost (from sldns) */
18922 int load_gost_id(void)
18923 {
18924         static int gost_id = 0;
18925         const EVP_PKEY_ASN1_METHOD* meth;
18926         ENGINE* e;
18927
18928         if(gost_id) return gost_id;
18929
18930         /* see if configuration loaded gost implementation from other engine*/
18931         meth = EVP_PKEY_asn1_find_str(NULL, "gost2001", -1);
18932         if(meth) {
18933                 EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
18934                 return gost_id;
18935         }
18936
18937         /* see if engine can be loaded already */
18938         e = ENGINE_by_id("gost");
18939         if(!e) {
18940                 /* load it ourself, in case statically linked */
18941                 ENGINE_load_builtin_engines();
18942                 ENGINE_load_dynamic();
18943                 e = ENGINE_by_id("gost");
18944         }
18945         if(!e) {
18946                 /* no gost engine in openssl */
18947                 return 0;
18948         }
18949         if(!ENGINE_set_default(e, ENGINE_METHOD_ALL)) {
18950                 ENGINE_finish(e);
18951                 ENGINE_free(e);
18952                 return 0;
18953         }
18954
18955         meth = EVP_PKEY_asn1_find_str(&e, "gost2001", -1);
18956         if(!meth) {
18957                 /* algo not found */
18958                 ENGINE_finish(e);
18959                 ENGINE_free(e);
18960                 return 0;
18961         }
18962         EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
18963         return gost_id;
18964 }
18965 int main(void) {
18966         EVP_MD_CTX* ctx;
18967         const EVP_MD* md;
18968         unsigned char digest[64]; /* its a 256-bit digest, so uses 32 bytes */
18969         const char* str = "Hello world";
18970         const unsigned char check[] = {
18971                 0x40 , 0xed , 0xf8 , 0x56 , 0x5a , 0xc5 , 0x36 , 0xe1 ,
18972                 0x33 , 0x7c , 0x7e , 0x87 , 0x62 , 0x1c , 0x42 , 0xe0 ,
18973                 0x17 , 0x1b , 0x5e , 0xce , 0xa8 , 0x46 , 0x65 , 0x4d ,
18974                 0x8d , 0x3e , 0x22 , 0x9b , 0xe1 , 0x30 , 0x19 , 0x9d
18975         };
18976         OPENSSL_config(NULL);
18977         (void)load_gost_id();
18978         md = EVP_get_digestbyname("md_gost94");
18979         if(!md) return 1;
18980         memset(digest, 0, sizeof(digest));
18981         ctx = EVP_MD_CTX_create();
18982         if(!ctx) return 2;
18983         if(!EVP_DigestInit_ex(ctx, md, NULL)) return 3;
18984         if(!EVP_DigestUpdate(ctx, str, 10)) return 4;
18985         if(!EVP_DigestFinal_ex(ctx, digest, NULL)) return 5;
18986         /* uncomment to see the hash calculated.
18987                 {int i;
18988                 for(i=0; i<32; i++)
18989                         printf(" %2.2x", (int)digest[i]);
18990                 printf("\n");}
18991         */
18992         if(memcmp(digest, check, sizeof(check)) != 0)
18993                 return 6;
18994         return 0;
18995 }
18996
18997 _ACEOF
18998 if ac_fn_c_try_run "$LINENO"; then :
18999   eval "ac_cv_c_gost_works=yes"
19000 else
19001   eval "ac_cv_c_gost_works=no"
19002 fi
19003 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19004   conftest.$ac_objext conftest.beam conftest.$ac_ext
19005 fi
19006
19007 CFLAGS="$BAKCFLAGS"
19008 else
19009 eval "ac_cv_c_gost_works=maybe"
19010 fi
19011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_gost_works" >&5
19012 $as_echo "$ac_cv_c_gost_works" >&6; }
19013
19014         if test "$ac_cv_c_gost_works" != no; then
19015                 use_gost="yes"
19016
19017 $as_echo "#define USE_GOST 1" >>confdefs.h
19018
19019         fi
19020         ;;
19021 esac
19022 fi
19023 # Check whether --enable-ecdsa was given.
19024 if test "${enable_ecdsa+set}" = set; then :
19025   enableval=$enable_ecdsa;
19026 fi
19027
19028 use_ecdsa="no"
19029 case "$enable_ecdsa" in
19030     no)
19031       ;;
19032     *)
19033       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19034               ac_fn_c_check_func "$LINENO" "ECDSA_sign" "ac_cv_func_ECDSA_sign"
19035 if test "x$ac_cv_func_ECDSA_sign" = xyes; then :
19036
19037 else
19038   as_fn_error $? "OpenSSL does not support ECDSA: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19039 fi
19040
19041               ac_fn_c_check_func "$LINENO" "SHA384_Init" "ac_cv_func_SHA384_Init"
19042 if test "x$ac_cv_func_SHA384_Init" = xyes; then :
19043
19044 else
19045   as_fn_error $? "OpenSSL does not support SHA384: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19046 fi
19047
19048               ac_fn_c_check_decl "$LINENO" "NID_X9_62_prime256v1" "ac_cv_have_decl_NID_X9_62_prime256v1" "$ac_includes_default
19049 #include <openssl/evp.h>
19050
19051 "
19052 if test "x$ac_cv_have_decl_NID_X9_62_prime256v1" = xyes; then :
19053   ac_have_decl=1
19054 else
19055   ac_have_decl=0
19056 fi
19057
19058 cat >>confdefs.h <<_ACEOF
19059 #define HAVE_DECL_NID_X9_62_PRIME256V1 $ac_have_decl
19060 _ACEOF
19061 if test $ac_have_decl = 1; then :
19062
19063 else
19064   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19065 fi
19066 ac_fn_c_check_decl "$LINENO" "NID_secp384r1" "ac_cv_have_decl_NID_secp384r1" "$ac_includes_default
19067 #include <openssl/evp.h>
19068
19069 "
19070 if test "x$ac_cv_have_decl_NID_secp384r1" = xyes; then :
19071   ac_have_decl=1
19072 else
19073   ac_have_decl=0
19074 fi
19075
19076 cat >>confdefs.h <<_ACEOF
19077 #define HAVE_DECL_NID_SECP384R1 $ac_have_decl
19078 _ACEOF
19079 if test $ac_have_decl = 1; then :
19080
19081 else
19082   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
19083 fi
19084
19085               # see if OPENSSL 1.0.0 or later (has EVP MD and Verify independency)
19086               { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openssl supports SHA2 and ECDSA with EVP" >&5
19087 $as_echo_n "checking if openssl supports SHA2 and ECDSA with EVP... " >&6; }
19088               if grep OPENSSL_VERSION_TEXT $ssldir_include/openssl/opensslv.h | grep "OpenSSL" >/dev/null; then
19089                 if grep OPENSSL_VERSION_NUMBER $ssldir_include/openssl/opensslv.h | grep 0x0 >/dev/null; then
19090                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19091 $as_echo "no" >&6; }
19092
19093 cat >>confdefs.h <<_ACEOF
19094 #define USE_ECDSA_EVP_WORKAROUND 1
19095 _ACEOF
19096
19097                 else
19098                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19099 $as_echo "yes" >&6; }
19100                 fi
19101               else
19102                 # not OpenSSL, thus likely LibreSSL, which supports it
19103                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19104 $as_echo "yes" >&6; }
19105               fi
19106       fi
19107       # we now know we have ECDSA and the required curves.
19108
19109 cat >>confdefs.h <<_ACEOF
19110 #define USE_ECDSA 1
19111 _ACEOF
19112
19113       use_ecdsa="yes"
19114       ;;
19115 esac
19116
19117 # Check whether --enable-dsa was given.
19118 if test "${enable_dsa+set}" = set; then :
19119   enableval=$enable_dsa;
19120 fi
19121
19122 use_dsa="no"
19123 case "$enable_dsa" in
19124     yes)
19125       # detect if DSA is supported, and turn it off if not.
19126       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19127       ac_fn_c_check_func "$LINENO" "DSA_SIG_new" "ac_cv_func_DSA_SIG_new"
19128 if test "x$ac_cv_func_DSA_SIG_new" = xyes; then :
19129
19130       as_ac_Type=`$as_echo "ac_cv_type_DSA_SIG*" | $as_tr_sh`
19131 ac_fn_c_check_type "$LINENO" "DSA_SIG*" "$as_ac_Type" "
19132 $ac_includes_default
19133 #ifdef HAVE_OPENSSL_ERR_H
19134 #include <openssl/err.h>
19135 #endif
19136
19137 #ifdef HAVE_OPENSSL_RAND_H
19138 #include <openssl/rand.h>
19139 #endif
19140
19141 #ifdef HAVE_OPENSSL_CONF_H
19142 #include <openssl/conf.h>
19143 #endif
19144
19145 #ifdef HAVE_OPENSSL_ENGINE_H
19146 #include <openssl/engine.h>
19147 #endif
19148
19149 "
19150 if eval test \"x\$"$as_ac_Type"\" = x"yes"; then :
19151
19152
19153 cat >>confdefs.h <<_ACEOF
19154 #define USE_DSA 1
19155 _ACEOF
19156
19157
19158 else
19159   if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
19160                fi
19161 fi
19162
19163
19164 else
19165   if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
19166                fi
19167 fi
19168
19169       else
19170
19171 cat >>confdefs.h <<_ACEOF
19172 #define USE_DSA 1
19173 _ACEOF
19174
19175       fi
19176       ;;
19177     *)
19178       # disable dsa by default, RFC 8624 section 3.1, validators MUST NOT
19179       # support DSA for DNSSEC Validation.
19180       ;;
19181 esac
19182
19183
19184 # Check whether --with-deprecate-rsa-1024 was given.
19185 if test "${with_deprecate_rsa_1024+set}" = set; then :
19186   withval=$with_deprecate_rsa_1024;
19187 fi
19188
19189 if test "$with_deprecate_rsa_1024" = "yes"; then
19190
19191 $as_echo "#define DEPRECATE_RSA_1024 1" >>confdefs.h
19192
19193 fi
19194
19195 # Check whether --enable-ed25519 was given.
19196 if test "${enable_ed25519+set}" = set; then :
19197   enableval=$enable_ed25519;
19198 fi
19199
19200 use_ed25519="no"
19201 case "$enable_ed25519" in
19202     no)
19203       ;;
19204     *)
19205       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19206               ac_fn_c_check_decl "$LINENO" "NID_ED25519" "ac_cv_have_decl_NID_ED25519" "$ac_includes_default
19207 #include <openssl/evp.h>
19208
19209 "
19210 if test "x$ac_cv_have_decl_NID_ED25519" = xyes; then :
19211   ac_have_decl=1
19212 else
19213   ac_have_decl=0
19214 fi
19215
19216 cat >>confdefs.h <<_ACEOF
19217 #define HAVE_DECL_NID_ED25519 $ac_have_decl
19218 _ACEOF
19219 if test $ac_have_decl = 1; then :
19220
19221                 use_ed25519="yes"
19222
19223 else
19224    if test "x$enable_ed25519" = "xyes"; then as_fn_error $? "OpenSSL does not support ED25519 and you used --enable-ed25519." "$LINENO" 5
19225                 fi
19226 fi
19227
19228       fi
19229       if test $USE_NETTLE = "yes"; then
19230                 for ac_header in nettle/eddsa.h
19231 do :
19232   ac_fn_c_check_header_compile "$LINENO" "nettle/eddsa.h" "ac_cv_header_nettle_eddsa_h" "$ac_includes_default
19233 "
19234 if test "x$ac_cv_header_nettle_eddsa_h" = xyes; then :
19235   cat >>confdefs.h <<_ACEOF
19236 #define HAVE_NETTLE_EDDSA_H 1
19237 _ACEOF
19238  use_ed25519="yes"
19239 fi
19240
19241 done
19242
19243       fi
19244       if test $use_ed25519 = "yes"; then
19245
19246 cat >>confdefs.h <<_ACEOF
19247 #define USE_ED25519 1
19248 _ACEOF
19249
19250       fi
19251       ;;
19252 esac
19253
19254 # Check whether --enable-ed448 was given.
19255 if test "${enable_ed448+set}" = set; then :
19256   enableval=$enable_ed448;
19257 fi
19258
19259 use_ed448="no"
19260 case "$enable_ed448" in
19261     no)
19262       ;;
19263     *)
19264       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
19265               ac_fn_c_check_decl "$LINENO" "NID_ED448" "ac_cv_have_decl_NID_ED448" "$ac_includes_default
19266 #include <openssl/evp.h>
19267
19268 "
19269 if test "x$ac_cv_have_decl_NID_ED448" = xyes; then :
19270   ac_have_decl=1
19271 else
19272   ac_have_decl=0
19273 fi
19274
19275 cat >>confdefs.h <<_ACEOF
19276 #define HAVE_DECL_NID_ED448 $ac_have_decl
19277 _ACEOF
19278 if test $ac_have_decl = 1; then :
19279
19280                 use_ed448="yes"
19281
19282 else
19283    if test "x$enable_ed448" = "xyes"; then as_fn_error $? "OpenSSL does not support ED448 and you used --enable-ed448." "$LINENO" 5
19284                 fi
19285 fi
19286
19287       fi
19288       if test $use_ed448 = "yes"; then
19289
19290 cat >>confdefs.h <<_ACEOF
19291 #define USE_ED448 1
19292 _ACEOF
19293
19294       fi
19295       ;;
19296 esac
19297
19298 # Check whether --enable-event-api was given.
19299 if test "${enable_event_api+set}" = set; then :
19300   enableval=$enable_event_api;
19301 fi
19302
19303 case "$enable_event_api" in
19304     yes)
19305       UNBOUND_EVENT_INSTALL=unbound-event-install
19306
19307       UNBOUND_EVENT_UNINSTALL=unbound-event-uninstall
19308
19309       ;;
19310     *)
19311       ;;
19312 esac
19313
19314 # Check whether --enable-tfo-client was given.
19315 if test "${enable_tfo_client+set}" = set; then :
19316   enableval=$enable_tfo_client;
19317 fi
19318
19319 case "$enable_tfo_client" in
19320         yes)
19321                 case "$host_os" in
19322                         linux*) ac_fn_c_check_decl "$LINENO" "MSG_FASTOPEN" "ac_cv_have_decl_MSG_FASTOPEN" "$ac_includes_default
19323 #include <netinet/tcp.h>
19324
19325 "
19326 if test "x$ac_cv_have_decl_MSG_FASTOPEN" = xyes; then :
19327   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
19328 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
19329 else
19330   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
19331 fi
19332
19333
19334 cat >>confdefs.h <<_ACEOF
19335 #define USE_MSG_FASTOPEN 1
19336 _ACEOF
19337
19338                                 ;;
19339                         darwin*) ac_fn_c_check_decl "$LINENO" "CONNECT_RESUME_ON_READ_WRITE" "ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" "$ac_includes_default
19340 #include <sys/socket.h>
19341
19342 "
19343 if test "x$ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" = xyes; then :
19344   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
19345 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
19346 else
19347   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
19348 fi
19349
19350
19351 cat >>confdefs.h <<_ACEOF
19352 #define USE_OSX_MSG_FASTOPEN 1
19353 _ACEOF
19354
19355                                 ;;
19356                 esac
19357                 ;;
19358         no|*)
19359                 ;;
19360 esac
19361
19362 # Check whether --enable-tfo-server was given.
19363 if test "${enable_tfo_server+set}" = set; then :
19364   enableval=$enable_tfo_server;
19365 fi
19366
19367 case "$enable_tfo_server" in
19368         yes)
19369               ac_fn_c_check_decl "$LINENO" "TCP_FASTOPEN" "ac_cv_have_decl_TCP_FASTOPEN" "$ac_includes_default
19370 #include <netinet/tcp.h>
19371
19372 "
19373 if test "x$ac_cv_have_decl_TCP_FASTOPEN" = xyes; then :
19374   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&5
19375 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&2;}
19376 else
19377   as_fn_error $? "TCP Fast Open is not available for server mode: please rerun without --enable-tfo-server" "$LINENO" 5
19378 fi
19379
19380
19381 cat >>confdefs.h <<_ACEOF
19382 #define USE_TCP_FASTOPEN 1
19383 _ACEOF
19384
19385                 ;;
19386         no|*)
19387                 ;;
19388 esac
19389
19390 # check for libevent
19391
19392 # Check whether --with-libevent was given.
19393 if test "${with_libevent+set}" = set; then :
19394   withval=$with_libevent;
19395 else
19396    with_libevent="no"
19397 fi
19398
19399 if test "x_$with_libevent" != x_no; then
19400
19401 $as_echo "#define USE_LIBEVENT 1" >>confdefs.h
19402
19403         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libevent" >&5
19404 $as_echo_n "checking for libevent... " >&6; }
19405         if test "x_$with_libevent" = x_ -o "x_$with_libevent" = x_yes; then
19406             with_libevent="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19407         fi
19408         for dir in $with_libevent; do
19409             thedir="$dir"
19410             if test -f "$dir/include/event.h" -o -f "$dir/include/event2/event.h"; then
19411                 found_libevent="yes"
19412                                                                 if test "$thedir" != "/usr"; then
19413                                     CPPFLAGS="$CPPFLAGS -I$thedir/include"
19414                                 fi
19415                                 break;
19416                     fi
19417         done
19418         if test x_$found_libevent != x_yes; then
19419                 if test -f "$dir/event.h" -a \( -f "$dir/libevent.la" -o -f "$dir/libev.la" \) ; then
19420                         # libevent source directory
19421                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19422 $as_echo "found in $thedir" >&6; }
19423                         CPPFLAGS="$CPPFLAGS -I$thedir -I$thedir/include"
19424                         BAK_LDFLAGS_SET="1"
19425                         BAK_LDFLAGS="$LDFLAGS"
19426                         # remove evdns from linking
19427                         mkdir build >/dev/null 2>&1
19428                         mkdir build/libevent >/dev/null 2>&1
19429                         mkdir build/libevent/.libs >/dev/null 2>&1
19430                         ev_files_o=`ls $thedir/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19431                         ev_files_lo=`ls $thedir/*.lo | grep -v evdns\.lo | grep -v bufferevent_openssl\.lo`
19432                         ev_files_libso=`ls $thedir/.libs/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19433                         cp $ev_files_o build/libevent
19434                         cp $ev_files_lo build/libevent
19435                         cp $ev_files_libso build/libevent/.libs
19436                         LATE_LDFLAGS="build/libevent/*.lo -lm"
19437                         LDFLAGS="build/libevent/*.o $LDFLAGS -lm"
19438                 else
19439             as_fn_error $? "Cannot find the libevent library in $with_libevent
19440 You can restart ./configure --with-libevent=no to use a builtin alternative.
19441 Please note that this alternative is not as capable as libevent when using
19442 large outgoing port ranges.  " "$LINENO" 5
19443                 fi
19444         else
19445             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19446 $as_echo "found in $thedir" >&6; }
19447                     if test ! -f $thedir/lib/libevent.a -a ! -f $thedir/lib/libevent.so -a -d "$thedir/lib/event2"; then
19448                     LDFLAGS="$LDFLAGS -L$thedir/lib/event2"
19449
19450         if test "x$enable_rpath" = xyes; then
19451                 if echo "$thedir/lib/event2" | grep "^/" >/dev/null; then
19452                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib/event2"
19453                 fi
19454         fi
19455
19456             else
19457                                     if test "$thedir" != "/usr" -a "$thedir" != ""; then
19458                         LDFLAGS="$LDFLAGS -L$thedir/lib"
19459
19460         if test "x$enable_rpath" = xyes; then
19461                 if echo "$thedir/lib" | grep "^/" >/dev/null; then
19462                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib"
19463                 fi
19464         fi
19465
19466                     fi
19467             fi
19468         fi
19469         # check for library used by libevent after 1.3c
19470         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19471 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19472 if ${ac_cv_search_clock_gettime+:} false; then :
19473   $as_echo_n "(cached) " >&6
19474 else
19475   ac_func_search_save_LIBS=$LIBS
19476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19477 /* end confdefs.h.  */
19478
19479 /* Override any GCC internal prototype to avoid an error.
19480    Use char because int might match the return type of a GCC
19481    builtin and then its argument prototype would still apply.  */
19482 #ifdef __cplusplus
19483 extern "C"
19484 #endif
19485 char clock_gettime ();
19486 int
19487 main ()
19488 {
19489 return clock_gettime ();
19490   ;
19491   return 0;
19492 }
19493 _ACEOF
19494 for ac_lib in '' rt; do
19495   if test -z "$ac_lib"; then
19496     ac_res="none required"
19497   else
19498     ac_res=-l$ac_lib
19499     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19500   fi
19501   if ac_fn_c_try_link "$LINENO"; then :
19502   ac_cv_search_clock_gettime=$ac_res
19503 fi
19504 rm -f core conftest.err conftest.$ac_objext \
19505     conftest$ac_exeext
19506   if ${ac_cv_search_clock_gettime+:} false; then :
19507   break
19508 fi
19509 done
19510 if ${ac_cv_search_clock_gettime+:} false; then :
19511
19512 else
19513   ac_cv_search_clock_gettime=no
19514 fi
19515 rm conftest.$ac_ext
19516 LIBS=$ac_func_search_save_LIBS
19517 fi
19518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19519 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19520 ac_res=$ac_cv_search_clock_gettime
19521 if test "$ac_res" != no; then :
19522   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19523
19524 fi
19525
19526
19527         # is the event.h header libev or libevent?
19528         for ac_header in event.h
19529 do :
19530   ac_fn_c_check_header_compile "$LINENO" "event.h" "ac_cv_header_event_h" "$ac_includes_default
19531 "
19532 if test "x$ac_cv_header_event_h" = xyes; then :
19533   cat >>confdefs.h <<_ACEOF
19534 #define HAVE_EVENT_H 1
19535 _ACEOF
19536
19537 fi
19538
19539 done
19540
19541         ac_fn_c_check_decl "$LINENO" "EV_VERSION_MAJOR" "ac_cv_have_decl_EV_VERSION_MAJOR" "$ac_includes_default
19542 #include <event.h>
19543
19544 "
19545 if test "x$ac_cv_have_decl_EV_VERSION_MAJOR" = xyes; then :
19546
19547                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19548 $as_echo_n "checking for library containing event_set... " >&6; }
19549 if ${ac_cv_search_event_set+:} false; then :
19550   $as_echo_n "(cached) " >&6
19551 else
19552   ac_func_search_save_LIBS=$LIBS
19553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19554 /* end confdefs.h.  */
19555
19556 /* Override any GCC internal prototype to avoid an error.
19557    Use char because int might match the return type of a GCC
19558    builtin and then its argument prototype would still apply.  */
19559 #ifdef __cplusplus
19560 extern "C"
19561 #endif
19562 char event_set ();
19563 int
19564 main ()
19565 {
19566 return event_set ();
19567   ;
19568   return 0;
19569 }
19570 _ACEOF
19571 for ac_lib in '' ev; do
19572   if test -z "$ac_lib"; then
19573     ac_res="none required"
19574   else
19575     ac_res=-l$ac_lib
19576     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19577   fi
19578   if ac_fn_c_try_link "$LINENO"; then :
19579   ac_cv_search_event_set=$ac_res
19580 fi
19581 rm -f core conftest.err conftest.$ac_objext \
19582     conftest$ac_exeext
19583   if ${ac_cv_search_event_set+:} false; then :
19584   break
19585 fi
19586 done
19587 if ${ac_cv_search_event_set+:} false; then :
19588
19589 else
19590   ac_cv_search_event_set=no
19591 fi
19592 rm conftest.$ac_ext
19593 LIBS=$ac_func_search_save_LIBS
19594 fi
19595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19596 $as_echo "$ac_cv_search_event_set" >&6; }
19597 ac_res=$ac_cv_search_event_set
19598 if test "$ac_res" != no; then :
19599   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19600
19601 fi
19602
19603
19604 else
19605
19606                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19607 $as_echo_n "checking for library containing event_set... " >&6; }
19608 if ${ac_cv_search_event_set+:} false; then :
19609   $as_echo_n "(cached) " >&6
19610 else
19611   ac_func_search_save_LIBS=$LIBS
19612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19613 /* end confdefs.h.  */
19614
19615 /* Override any GCC internal prototype to avoid an error.
19616    Use char because int might match the return type of a GCC
19617    builtin and then its argument prototype would still apply.  */
19618 #ifdef __cplusplus
19619 extern "C"
19620 #endif
19621 char event_set ();
19622 int
19623 main ()
19624 {
19625 return event_set ();
19626   ;
19627   return 0;
19628 }
19629 _ACEOF
19630 for ac_lib in '' event; do
19631   if test -z "$ac_lib"; then
19632     ac_res="none required"
19633   else
19634     ac_res=-l$ac_lib
19635     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19636   fi
19637   if ac_fn_c_try_link "$LINENO"; then :
19638   ac_cv_search_event_set=$ac_res
19639 fi
19640 rm -f core conftest.err conftest.$ac_objext \
19641     conftest$ac_exeext
19642   if ${ac_cv_search_event_set+:} false; then :
19643   break
19644 fi
19645 done
19646 if ${ac_cv_search_event_set+:} false; then :
19647
19648 else
19649   ac_cv_search_event_set=no
19650 fi
19651 rm conftest.$ac_ext
19652 LIBS=$ac_func_search_save_LIBS
19653 fi
19654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19655 $as_echo "$ac_cv_search_event_set" >&6; }
19656 ac_res=$ac_cv_search_event_set
19657 if test "$ac_res" != no; then :
19658   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19659
19660 fi
19661
19662
19663 fi
19664
19665         for ac_func in event_base_free
19666 do :
19667   ac_fn_c_check_func "$LINENO" "event_base_free" "ac_cv_func_event_base_free"
19668 if test "x$ac_cv_func_event_base_free" = xyes; then :
19669   cat >>confdefs.h <<_ACEOF
19670 #define HAVE_EVENT_BASE_FREE 1
19671 _ACEOF
19672
19673 fi
19674 done
19675  # only in libevent 1.2 and later
19676         for ac_func in event_base_once
19677 do :
19678   ac_fn_c_check_func "$LINENO" "event_base_once" "ac_cv_func_event_base_once"
19679 if test "x$ac_cv_func_event_base_once" = xyes; then :
19680   cat >>confdefs.h <<_ACEOF
19681 #define HAVE_EVENT_BASE_ONCE 1
19682 _ACEOF
19683
19684 fi
19685 done
19686  # only in libevent 1.4.1 and later
19687         for ac_func in event_base_new
19688 do :
19689   ac_fn_c_check_func "$LINENO" "event_base_new" "ac_cv_func_event_base_new"
19690 if test "x$ac_cv_func_event_base_new" = xyes; then :
19691   cat >>confdefs.h <<_ACEOF
19692 #define HAVE_EVENT_BASE_NEW 1
19693 _ACEOF
19694
19695 fi
19696 done
19697  # only in libevent 1.4.1 and later
19698         for ac_func in event_base_get_method
19699 do :
19700   ac_fn_c_check_func "$LINENO" "event_base_get_method" "ac_cv_func_event_base_get_method"
19701 if test "x$ac_cv_func_event_base_get_method" = xyes; then :
19702   cat >>confdefs.h <<_ACEOF
19703 #define HAVE_EVENT_BASE_GET_METHOD 1
19704 _ACEOF
19705
19706 fi
19707 done
19708  # only in libevent 1.4.3 and later
19709         for ac_func in ev_loop
19710 do :
19711   ac_fn_c_check_func "$LINENO" "ev_loop" "ac_cv_func_ev_loop"
19712 if test "x$ac_cv_func_ev_loop" = xyes; then :
19713   cat >>confdefs.h <<_ACEOF
19714 #define HAVE_EV_LOOP 1
19715 _ACEOF
19716
19717 fi
19718 done
19719  # only in libev. (tested on 3.51)
19720         for ac_func in ev_default_loop
19721 do :
19722   ac_fn_c_check_func "$LINENO" "ev_default_loop" "ac_cv_func_ev_default_loop"
19723 if test "x$ac_cv_func_ev_default_loop" = xyes; then :
19724   cat >>confdefs.h <<_ACEOF
19725 #define HAVE_EV_DEFAULT_LOOP 1
19726 _ACEOF
19727
19728 fi
19729 done
19730  # only in libev. (tested on 4.00)
19731         for ac_func in event_assign
19732 do :
19733   ac_fn_c_check_func "$LINENO" "event_assign" "ac_cv_func_event_assign"
19734 if test "x$ac_cv_func_event_assign" = xyes; then :
19735   cat >>confdefs.h <<_ACEOF
19736 #define HAVE_EVENT_ASSIGN 1
19737 _ACEOF
19738
19739 fi
19740 done
19741  # in libevent, for thread-safety
19742         ac_fn_c_check_decl "$LINENO" "evsignal_assign" "ac_cv_have_decl_evsignal_assign" "$ac_includes_default
19743 #ifdef HAVE_EVENT_H
19744 #  include <event.h>
19745 #else
19746 #  include \"event2/event.h\"
19747 #endif
19748
19749 "
19750 if test "x$ac_cv_have_decl_evsignal_assign" = xyes; then :
19751   ac_have_decl=1
19752 else
19753   ac_have_decl=0
19754 fi
19755
19756 cat >>confdefs.h <<_ACEOF
19757 #define HAVE_DECL_EVSIGNAL_ASSIGN $ac_have_decl
19758 _ACEOF
19759
19760         PC_LIBEVENT_DEPENDENCY="libevent"
19761
19762         if test -n "$BAK_LDFLAGS_SET"; then
19763                 LDFLAGS="$BAK_LDFLAGS"
19764         fi
19765 else
19766
19767 $as_echo "#define USE_MINI_EVENT 1" >>confdefs.h
19768
19769 fi
19770
19771 # check for libexpat
19772
19773 # Check whether --with-libexpat was given.
19774 if test "${with_libexpat+set}" = set; then :
19775   withval=$with_libexpat;
19776 else
19777    withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19778 fi
19779
19780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
19781 $as_echo_n "checking for libexpat... " >&6; }
19782 found_libexpat="no"
19783 for dir in $withval ; do
19784             if test -f "$dir/include/expat.h"; then
19785                 found_libexpat="yes"
19786                                 if test "$dir" != "/usr"; then
19787                     CPPFLAGS="$CPPFLAGS -I$dir/include"
19788                     LDFLAGS="$LDFLAGS -L$dir/lib"
19789                 fi
19790                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19791 $as_echo "found in $dir" >&6; }
19792                 break;
19793             fi
19794 done
19795 if test x_$found_libexpat != x_yes; then
19796         as_fn_error $? "Could not find libexpat, expat.h" "$LINENO" 5
19797 fi
19798 for ac_header in expat.h
19799 do :
19800   ac_fn_c_check_header_compile "$LINENO" "expat.h" "ac_cv_header_expat_h" "$ac_includes_default
19801 "
19802 if test "x$ac_cv_header_expat_h" = xyes; then :
19803   cat >>confdefs.h <<_ACEOF
19804 #define HAVE_EXPAT_H 1
19805 _ACEOF
19806
19807 fi
19808
19809 done
19810
19811 ac_fn_c_check_decl "$LINENO" "XML_StopParser" "ac_cv_have_decl_XML_StopParser" "$ac_includes_default
19812 #include <expat.h>
19813
19814 "
19815 if test "x$ac_cv_have_decl_XML_StopParser" = xyes; then :
19816   ac_have_decl=1
19817 else
19818   ac_have_decl=0
19819 fi
19820
19821 cat >>confdefs.h <<_ACEOF
19822 #define HAVE_DECL_XML_STOPPARSER $ac_have_decl
19823 _ACEOF
19824
19825
19826 # hiredis (redis C client for cachedb)
19827
19828 # Check whether --with-libhiredis was given.
19829 if test "${with_libhiredis+set}" = set; then :
19830   withval=$with_libhiredis;
19831 else
19832    withval="no"
19833 fi
19834
19835 found_libhiredis="no"
19836 if test x_$withval = x_yes -o x_$withval != x_no; then
19837    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libhiredis" >&5
19838 $as_echo_n "checking for libhiredis... " >&6; }
19839    if test x_$withval = x_ -o x_$withval = x_yes; then
19840             withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19841    fi
19842    for dir in $withval ; do
19843             if test -f "$dir/include/hiredis/hiredis.h"; then
19844                 found_libhiredis="yes"
19845                                 if test "$dir" != "/usr"; then
19846                     CPPFLAGS="$CPPFLAGS -I$dir/include"
19847                     LDFLAGS="$LDFLAGS -L$dir/lib"
19848                 fi
19849                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19850 $as_echo "found in $dir" >&6; }
19851
19852 $as_echo "#define USE_REDIS 1" >>confdefs.h
19853
19854                 LIBS="$LIBS -lhiredis"
19855                 break;
19856             fi
19857     done
19858     if test x_$found_libhiredis != x_yes; then
19859         as_fn_error $? "Could not find libhiredis, hiredis.h" "$LINENO" 5
19860     fi
19861     for ac_header in hiredis/hiredis.h
19862 do :
19863   ac_fn_c_check_header_compile "$LINENO" "hiredis/hiredis.h" "ac_cv_header_hiredis_hiredis_h" "$ac_includes_default
19864 "
19865 if test "x$ac_cv_header_hiredis_hiredis_h" = xyes; then :
19866   cat >>confdefs.h <<_ACEOF
19867 #define HAVE_HIREDIS_HIREDIS_H 1
19868 _ACEOF
19869
19870 fi
19871
19872 done
19873
19874     ac_fn_c_check_decl "$LINENO" "redisConnect" "ac_cv_have_decl_redisConnect" "$ac_includes_default
19875     #include <hiredis/hiredis.h>
19876
19877 "
19878 if test "x$ac_cv_have_decl_redisConnect" = xyes; then :
19879   ac_have_decl=1
19880 else
19881   ac_have_decl=0
19882 fi
19883
19884 cat >>confdefs.h <<_ACEOF
19885 #define HAVE_DECL_REDISCONNECT $ac_have_decl
19886 _ACEOF
19887
19888 fi
19889
19890 # nghttp2
19891
19892 # Check whether --with-libnghttp2 was given.
19893 if test "${with_libnghttp2+set}" = set; then :
19894   withval=$with_libnghttp2;
19895 else
19896    withval="no"
19897 fi
19898
19899 found_libnghttp2="no"
19900 if test x_$withval = x_yes -o x_$withval != x_no; then
19901    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnghttp2" >&5
19902 $as_echo_n "checking for libnghttp2... " >&6; }
19903    if test x_$withval = x_ -o x_$withval = x_yes; then
19904             withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19905    fi
19906    for dir in $withval ; do
19907             if test -f "$dir/include/nghttp2/nghttp2.h"; then
19908                 found_libnghttp2="yes"
19909                                 if test "$dir" != "/usr"; then
19910                     CPPFLAGS="$CPPFLAGS -I$dir/include"
19911                     LDFLAGS="$LDFLAGS -L$dir/lib"
19912                 fi
19913                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19914 $as_echo "found in $dir" >&6; }
19915
19916 $as_echo "#define HAVE_NGHTTP2 1" >>confdefs.h
19917
19918                 LIBS="$LIBS -lnghttp2"
19919                 break;
19920             fi
19921     done
19922     if test x_$found_libnghttp2 != x_yes; then
19923         as_fn_error $? "Could not find libnghttp2, nghttp2.h" "$LINENO" 5
19924     fi
19925     for ac_header in nghttp2/nghttp2.h
19926 do :
19927   ac_fn_c_check_header_compile "$LINENO" "nghttp2/nghttp2.h" "ac_cv_header_nghttp2_nghttp2_h" "$ac_includes_default
19928 "
19929 if test "x$ac_cv_header_nghttp2_nghttp2_h" = xyes; then :
19930   cat >>confdefs.h <<_ACEOF
19931 #define HAVE_NGHTTP2_NGHTTP2_H 1
19932 _ACEOF
19933
19934 fi
19935
19936 done
19937
19938     ac_fn_c_check_decl "$LINENO" "nghttp2_session_server_new" "ac_cv_have_decl_nghttp2_session_server_new" "$ac_includes_default
19939     #include <nghttp2/nghttp2.h>
19940
19941 "
19942 if test "x$ac_cv_have_decl_nghttp2_session_server_new" = xyes; then :
19943   ac_have_decl=1
19944 else
19945   ac_have_decl=0
19946 fi
19947
19948 cat >>confdefs.h <<_ACEOF
19949 #define HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW $ac_have_decl
19950 _ACEOF
19951
19952 fi
19953
19954 # set static linking for uninstalled libraries if requested
19955
19956 staticexe=""
19957 # Check whether --enable-static-exe was given.
19958 if test "${enable_static_exe+set}" = set; then :
19959   enableval=$enable_static_exe;
19960 fi
19961
19962 if test x_$enable_static_exe = x_yes; then
19963         staticexe="-static"
19964         if test "$on_mingw" = yes; then
19965                 staticexe="-all-static"
19966                 # for static compile, include gdi32 and zlib here.
19967                 if echo $LIBS | grep 'lgdi32' >/dev/null; then
19968                         :
19969                 else
19970                         LIBS="$LIBS -lgdi32"
19971                 fi
19972                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
19973 $as_echo_n "checking for compress in -lz... " >&6; }
19974 if ${ac_cv_lib_z_compress+:} false; then :
19975   $as_echo_n "(cached) " >&6
19976 else
19977   ac_check_lib_save_LIBS=$LIBS
19978 LIBS="-lz  $LIBS"
19979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19980 /* end confdefs.h.  */
19981
19982 /* Override any GCC internal prototype to avoid an error.
19983    Use char because int might match the return type of a GCC
19984    builtin and then its argument prototype would still apply.  */
19985 #ifdef __cplusplus
19986 extern "C"
19987 #endif
19988 char compress ();
19989 int
19990 main ()
19991 {
19992 return compress ();
19993   ;
19994   return 0;
19995 }
19996 _ACEOF
19997 if ac_fn_c_try_link "$LINENO"; then :
19998   ac_cv_lib_z_compress=yes
19999 else
20000   ac_cv_lib_z_compress=no
20001 fi
20002 rm -f core conftest.err conftest.$ac_objext \
20003     conftest$ac_exeext conftest.$ac_ext
20004 LIBS=$ac_check_lib_save_LIBS
20005 fi
20006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
20007 $as_echo "$ac_cv_lib_z_compress" >&6; }
20008 if test "x$ac_cv_lib_z_compress" = xyes; then :
20009    LIBS="$LIBS -lz"
20010 fi
20011
20012                 LIBS="$LIBS -l:libssp.a"
20013         fi
20014 fi
20015
20016 # set full static linking if requested
20017 # Check whether --enable-fully-static was given.
20018 if test "${enable_fully_static+set}" = set; then :
20019   enableval=$enable_fully_static;
20020 fi
20021
20022 if test x_$enable_fully_static = x_yes; then
20023         staticexe="-all-static"
20024         if test "$on_mingw" = yes; then
20025                 # for static compile, include gdi32 and zlib here.
20026                 if echo $LIBS | grep 'lgdi32' >/dev/null; then
20027                         :
20028                 else
20029                         LIBS="$LIBS -lgdi32"
20030                 fi
20031                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
20032 $as_echo_n "checking for compress in -lz... " >&6; }
20033 if ${ac_cv_lib_z_compress+:} false; then :
20034   $as_echo_n "(cached) " >&6
20035 else
20036   ac_check_lib_save_LIBS=$LIBS
20037 LIBS="-lz  $LIBS"
20038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20039 /* end confdefs.h.  */
20040
20041 /* Override any GCC internal prototype to avoid an error.
20042    Use char because int might match the return type of a GCC
20043    builtin and then its argument prototype would still apply.  */
20044 #ifdef __cplusplus
20045 extern "C"
20046 #endif
20047 char compress ();
20048 int
20049 main ()
20050 {
20051 return compress ();
20052   ;
20053   return 0;
20054 }
20055 _ACEOF
20056 if ac_fn_c_try_link "$LINENO"; then :
20057   ac_cv_lib_z_compress=yes
20058 else
20059   ac_cv_lib_z_compress=no
20060 fi
20061 rm -f core conftest.err conftest.$ac_objext \
20062     conftest$ac_exeext conftest.$ac_ext
20063 LIBS=$ac_check_lib_save_LIBS
20064 fi
20065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
20066 $as_echo "$ac_cv_lib_z_compress" >&6; }
20067 if test "x$ac_cv_lib_z_compress" = xyes; then :
20068    LIBS="$LIBS -lz"
20069 fi
20070
20071                 LIBS="$LIBS -l:libssp.a"
20072         fi
20073 fi
20074
20075 # set lock checking if requested
20076 # Check whether --enable-lock_checks was given.
20077 if test "${enable_lock_checks+set}" = set; then :
20078   enableval=$enable_lock_checks;
20079 fi
20080
20081 if test x_$enable_lock_checks = x_yes; then
20082
20083 $as_echo "#define ENABLE_LOCK_CHECKS 1" >>confdefs.h
20084
20085         CHECKLOCK_OBJ="checklocks.lo"
20086
20087 fi
20088
20089
20090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
20091 $as_echo_n "checking for getaddrinfo... " >&6; }
20092 ac_cv_func_getaddrinfo=no
20093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20094 /* end confdefs.h.  */
20095
20096 #ifdef __cplusplus
20097 extern "C"
20098 {
20099 #endif
20100 char* getaddrinfo();
20101 char* (*f) () = getaddrinfo;
20102 #ifdef __cplusplus
20103 }
20104 #endif
20105 int main() {
20106         ;
20107         return 0;
20108 }
20109
20110 _ACEOF
20111 if ac_fn_c_try_link "$LINENO"; then :
20112   ac_cv_func_getaddrinfo="yes"
20113 if test "$ac_cv_header_windows_h" = "yes"; then
20114
20115 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
20116
20117         USE_WINSOCK="1"
20118         if echo $LIBS | grep 'lws2_32' >/dev/null; then
20119                 :
20120         else
20121                 LIBS="$LIBS -lws2_32"
20122         fi
20123 fi
20124
20125 else
20126   ORIGLIBS="$LIBS"
20127 LIBS="$LIBS -lws2_32"
20128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20129 /* end confdefs.h.  */
20130
20131 #ifdef HAVE_WS2TCPIP_H
20132 #include <ws2tcpip.h>
20133 #endif
20134
20135 int
20136 main ()
20137 {
20138
20139         (void)getaddrinfo(NULL, NULL, NULL, NULL);
20140
20141
20142   ;
20143   return 0;
20144 }
20145 _ACEOF
20146 if ac_fn_c_try_link "$LINENO"; then :
20147
20148 ac_cv_func_getaddrinfo="yes"
20149
20150 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
20151
20152 USE_WINSOCK="1"
20153
20154 else
20155
20156 ac_cv_func_getaddrinfo="no"
20157 LIBS="$ORIGLIBS"
20158
20159 fi
20160 rm -f core conftest.err conftest.$ac_objext \
20161     conftest$ac_exeext conftest.$ac_ext
20162
20163 fi
20164 rm -f core conftest.err conftest.$ac_objext \
20165     conftest$ac_exeext conftest.$ac_ext
20166
20167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getaddrinfo" >&5
20168 $as_echo "$ac_cv_func_getaddrinfo" >&6; }
20169 if test $ac_cv_func_getaddrinfo = yes; then
20170
20171 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
20172
20173 fi
20174
20175 if test "$USE_WINSOCK" = 1; then
20176
20177 $as_echo "#define UB_ON_WINDOWS 1" >>confdefs.h
20178
20179         for ac_header in iphlpapi.h
20180 do :
20181   ac_fn_c_check_header_compile "$LINENO" "iphlpapi.h" "ac_cv_header_iphlpapi_h" "$ac_includes_default
20182 #include <windows.h>
20183
20184 "
20185 if test "x$ac_cv_header_iphlpapi_h" = xyes; then :
20186   cat >>confdefs.h <<_ACEOF
20187 #define HAVE_IPHLPAPI_H 1
20188 _ACEOF
20189
20190 fi
20191
20192 done
20193
20194         if test -n "$ac_tool_prefix"; then
20195   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
20196 set dummy ${ac_tool_prefix}windres; ac_word=$2
20197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20198 $as_echo_n "checking for $ac_word... " >&6; }
20199 if ${ac_cv_prog_WINDRES+:} false; then :
20200   $as_echo_n "(cached) " >&6
20201 else
20202   if test -n "$WINDRES"; then
20203   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
20204 else
20205 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20206 for as_dir in $PATH
20207 do
20208   IFS=$as_save_IFS
20209   test -z "$as_dir" && as_dir=.
20210     for ac_exec_ext in '' $ac_executable_extensions; do
20211   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20212     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
20213     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20214     break 2
20215   fi
20216 done
20217   done
20218 IFS=$as_save_IFS
20219
20220 fi
20221 fi
20222 WINDRES=$ac_cv_prog_WINDRES
20223 if test -n "$WINDRES"; then
20224   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
20225 $as_echo "$WINDRES" >&6; }
20226 else
20227   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20228 $as_echo "no" >&6; }
20229 fi
20230
20231
20232 fi
20233 if test -z "$ac_cv_prog_WINDRES"; then
20234   ac_ct_WINDRES=$WINDRES
20235   # Extract the first word of "windres", so it can be a program name with args.
20236 set dummy windres; ac_word=$2
20237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20238 $as_echo_n "checking for $ac_word... " >&6; }
20239 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
20240   $as_echo_n "(cached) " >&6
20241 else
20242   if test -n "$ac_ct_WINDRES"; then
20243   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
20244 else
20245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20246 for as_dir in $PATH
20247 do
20248   IFS=$as_save_IFS
20249   test -z "$as_dir" && as_dir=.
20250     for ac_exec_ext in '' $ac_executable_extensions; do
20251   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20252     ac_cv_prog_ac_ct_WINDRES="windres"
20253     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20254     break 2
20255   fi
20256 done
20257   done
20258 IFS=$as_save_IFS
20259
20260 fi
20261 fi
20262 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
20263 if test -n "$ac_ct_WINDRES"; then
20264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
20265 $as_echo "$ac_ct_WINDRES" >&6; }
20266 else
20267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20268 $as_echo "no" >&6; }
20269 fi
20270
20271   if test "x$ac_ct_WINDRES" = x; then
20272     WINDRES=""
20273   else
20274     case $cross_compiling:$ac_tool_warned in
20275 yes:)
20276 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
20277 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
20278 ac_tool_warned=yes ;;
20279 esac
20280     WINDRES=$ac_ct_WINDRES
20281   fi
20282 else
20283   WINDRES="$ac_cv_prog_WINDRES"
20284 fi
20285
20286         LIBS="$LIBS -liphlpapi -lcrypt32"
20287         WINAPPS="unbound-service-install.exe unbound-service-remove.exe anchor-update.exe"
20288
20289         WIN_DAEMON_SRC="winrc/win_svc.c winrc/w_inst.c"
20290
20291         WIN_DAEMON_OBJ="win_svc.lo w_inst.lo"
20292
20293         WIN_DAEMON_OBJ_LINK="rsrc_unbound.o"
20294
20295         WIN_HOST_OBJ_LINK="rsrc_unbound_host.o"
20296
20297         WIN_UBANCHOR_OBJ_LINK="rsrc_unbound_anchor.o log.lo locks.lo"
20298
20299         WIN_CONTROL_OBJ_LINK="rsrc_unbound_control.o"
20300
20301         WIN_CHECKCONF_OBJ_LINK="rsrc_unbound_checkconf.o"
20302
20303
20304 $as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h
20305
20306 fi
20307 if test $ac_cv_func_getaddrinfo = no; then
20308         case " $LIBOBJS " in
20309   *" fake-rfc2553.$ac_objext "* ) ;;
20310   *) LIBOBJS="$LIBOBJS fake-rfc2553.$ac_objext"
20311  ;;
20312 esac
20313
20314 fi
20315 # check after getaddrinfo for its libraries
20316
20317 # check ioctlsocket
20318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctlsocket" >&5
20319 $as_echo_n "checking for ioctlsocket... " >&6; }
20320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20321 /* end confdefs.h.  */
20322
20323 #ifdef HAVE_WINSOCK2_H
20324 #include <winsock2.h>
20325 #endif
20326
20327 int
20328 main ()
20329 {
20330
20331         (void)ioctlsocket(0, 0, NULL);
20332
20333   ;
20334   return 0;
20335 }
20336 _ACEOF
20337 if ac_fn_c_try_link "$LINENO"; then :
20338
20339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20340 $as_echo "yes" >&6; }
20341
20342 $as_echo "#define HAVE_IOCTLSOCKET 1" >>confdefs.h
20343
20344
20345 else
20346   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20347 $as_echo "no" >&6; }
20348 fi
20349 rm -f core conftest.err conftest.$ac_objext \
20350     conftest$ac_exeext conftest.$ac_ext
20351
20352
20353 # see if daemon(3) exists, and if it is deprecated.
20354 for ac_func in daemon
20355 do :
20356   ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
20357 if test "x$ac_cv_func_daemon" = xyes; then :
20358   cat >>confdefs.h <<_ACEOF
20359 #define HAVE_DAEMON 1
20360 _ACEOF
20361
20362 fi
20363 done
20364
20365 if test $ac_cv_func_daemon = yes; then
20366
20367
20368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if daemon is deprecated" >&5
20369 $as_echo_n "checking if daemon is deprecated... " >&6; }
20370 cache=`echo daemon | sed 'y%.=/+-%___p_%'`
20371 if eval \${cv_cc_deprecated_$cache+:} false; then :
20372   $as_echo_n "(cached) " >&6
20373 else
20374
20375 echo '
20376 #include <stdlib.h>
20377 #include <unistd.h>
20378 ' >conftest.c
20379 echo 'void f(){ (void)daemon(0, 0); }' >>conftest.c
20380 if test -z "`$CC $CPPFLAGS $CFLAGS -c conftest.c 2>&1 | grep -e deprecated -e unavailable`"; then
20381 eval "cv_cc_deprecated_$cache=no"
20382 else
20383 eval "cv_cc_deprecated_$cache=yes"
20384 fi
20385 rm -f conftest conftest.o conftest.c
20386
20387 fi
20388
20389 if eval "test \"`echo '$cv_cc_deprecated_'$cache`\" = yes"; then
20390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20391 $as_echo "yes" >&6; }
20392
20393 cat >>confdefs.h <<_ACEOF
20394 #define DEPRECATED_DAEMON 1
20395 _ACEOF
20396
20397 :
20398
20399 else
20400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20401 $as_echo "no" >&6; }
20402 :
20403
20404 fi
20405
20406 fi
20407
20408 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_len" "ac_cv_member_struct_sockaddr_un_sun_len" "
20409 $ac_includes_default
20410 #ifdef HAVE_SYS_UN_H
20411 #include <sys/un.h>
20412 #endif
20413
20414 "
20415 if test "x$ac_cv_member_struct_sockaddr_un_sun_len" = xyes; then :
20416
20417 cat >>confdefs.h <<_ACEOF
20418 #define HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 1
20419 _ACEOF
20420
20421
20422 fi
20423
20424 ac_fn_c_check_member "$LINENO" "struct in_pktinfo" "ipi_spec_dst" "ac_cv_member_struct_in_pktinfo_ipi_spec_dst" "
20425 $ac_includes_default
20426 #if HAVE_SYS_PARAM_H
20427 #include <sys/param.h>
20428 #endif
20429
20430 #ifdef HAVE_SYS_SOCKET_H
20431 #include <sys/socket.h>
20432 #endif
20433
20434 #ifdef HAVE_SYS_UIO_H
20435 #include <sys/uio.h>
20436 #endif
20437
20438 #ifdef HAVE_NETINET_IN_H
20439 #include <netinet/in.h>
20440 #endif
20441
20442 #ifdef HAVE_NETINET_TCP_H
20443 #include <netinet/tcp.h>
20444 #endif
20445
20446 #ifdef HAVE_ARPA_INET_H
20447 #include <arpa/inet.h>
20448 #endif
20449
20450 #ifdef HAVE_WINSOCK2_H
20451 #include <winsock2.h>
20452 #endif
20453
20454 #ifdef HAVE_WS2TCPIP_H
20455 #include <ws2tcpip.h>
20456 #endif
20457
20458 "
20459 if test "x$ac_cv_member_struct_in_pktinfo_ipi_spec_dst" = xyes; then :
20460
20461 cat >>confdefs.h <<_ACEOF
20462 #define HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST 1
20463 _ACEOF
20464
20465
20466 fi
20467
20468
20469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htobe64" >&5
20470 $as_echo_n "checking for htobe64... " >&6; }
20471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20472 /* end confdefs.h.  */
20473
20474 #include <stdio.h>
20475 #ifdef HAVE_ENDIAN_H
20476 #  include <endian.h>
20477 #endif
20478 #ifdef HAVE_SYS_ENDIAN_H
20479 #  include <sys/endian.h>
20480 #endif
20481
20482 int
20483 main ()
20484 {
20485 unsigned long long x = htobe64(0); printf("%u", (unsigned)x);
20486   ;
20487   return 0;
20488 }
20489 _ACEOF
20490 if ac_fn_c_try_link "$LINENO"; then :
20491   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20492 $as_echo "yes" >&6; }
20493
20494 $as_echo "#define HAVE_HTOBE64 1" >>confdefs.h
20495
20496 else
20497   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20498 $as_echo "no" >&6; }
20499 fi
20500 rm -f core conftest.err conftest.$ac_objext \
20501     conftest$ac_exeext conftest.$ac_ext
20502
20503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for be64toh" >&5
20504 $as_echo_n "checking for be64toh... " >&6; }
20505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20506 /* end confdefs.h.  */
20507
20508 #include <stdio.h>
20509 #ifdef HAVE_ENDIAN_H
20510 #  include <endian.h>
20511 #endif
20512 #ifdef HAVE_SYS_ENDIAN_H
20513 #  include <sys/endian.h>
20514 #endif
20515
20516 int
20517 main ()
20518 {
20519 unsigned long long x = be64toh(0); printf("%u", (unsigned)x);
20520   ;
20521   return 0;
20522 }
20523 _ACEOF
20524 if ac_fn_c_try_link "$LINENO"; then :
20525   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20526 $as_echo "yes" >&6; }
20527
20528 $as_echo "#define HAVE_BE64TOH 1" >>confdefs.h
20529
20530 else
20531   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20532 $as_echo "no" >&6; }
20533 fi
20534 rm -f core conftest.err conftest.$ac_objext \
20535     conftest$ac_exeext conftest.$ac_ext
20536
20537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setusercontext" >&5
20538 $as_echo_n "checking for library containing setusercontext... " >&6; }
20539 if ${ac_cv_search_setusercontext+:} false; then :
20540   $as_echo_n "(cached) " >&6
20541 else
20542   ac_func_search_save_LIBS=$LIBS
20543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20544 /* end confdefs.h.  */
20545
20546 /* Override any GCC internal prototype to avoid an error.
20547    Use char because int might match the return type of a GCC
20548    builtin and then its argument prototype would still apply.  */
20549 #ifdef __cplusplus
20550 extern "C"
20551 #endif
20552 char setusercontext ();
20553 int
20554 main ()
20555 {
20556 return setusercontext ();
20557   ;
20558   return 0;
20559 }
20560 _ACEOF
20561 for ac_lib in '' util; do
20562   if test -z "$ac_lib"; then
20563     ac_res="none required"
20564   else
20565     ac_res=-l$ac_lib
20566     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20567   fi
20568   if ac_fn_c_try_link "$LINENO"; then :
20569   ac_cv_search_setusercontext=$ac_res
20570 fi
20571 rm -f core conftest.err conftest.$ac_objext \
20572     conftest$ac_exeext
20573   if ${ac_cv_search_setusercontext+:} false; then :
20574   break
20575 fi
20576 done
20577 if ${ac_cv_search_setusercontext+:} false; then :
20578
20579 else
20580   ac_cv_search_setusercontext=no
20581 fi
20582 rm conftest.$ac_ext
20583 LIBS=$ac_func_search_save_LIBS
20584 fi
20585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setusercontext" >&5
20586 $as_echo "$ac_cv_search_setusercontext" >&6; }
20587 ac_res=$ac_cv_search_setusercontext
20588 if test "$ac_res" != no; then :
20589   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20590
20591 fi
20592
20593 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
20594 do :
20595   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20596 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20597 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
20598   cat >>confdefs.h <<_ACEOF
20599 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20600 _ACEOF
20601
20602 fi
20603 done
20604
20605 for ac_func in setresuid
20606 do :
20607   ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
20608 if test "x$ac_cv_func_setresuid" = xyes; then :
20609   cat >>confdefs.h <<_ACEOF
20610 #define HAVE_SETRESUID 1
20611 _ACEOF
20612
20613 else
20614   for ac_func in setreuid
20615 do :
20616   ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid"
20617 if test "x$ac_cv_func_setreuid" = xyes; then :
20618   cat >>confdefs.h <<_ACEOF
20619 #define HAVE_SETREUID 1
20620 _ACEOF
20621
20622 fi
20623 done
20624
20625 fi
20626 done
20627
20628 for ac_func in setresgid
20629 do :
20630   ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
20631 if test "x$ac_cv_func_setresgid" = xyes; then :
20632   cat >>confdefs.h <<_ACEOF
20633 #define HAVE_SETRESGID 1
20634 _ACEOF
20635
20636 else
20637   for ac_func in setregid
20638 do :
20639   ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid"
20640 if test "x$ac_cv_func_setregid" = xyes; then :
20641   cat >>confdefs.h <<_ACEOF
20642 #define HAVE_SETREGID 1
20643 _ACEOF
20644
20645 fi
20646 done
20647
20648 fi
20649 done
20650
20651
20652 # check if setreuid en setregid fail, on MacOSX10.4(darwin8).
20653 if echo $host_os | grep darwin8 > /dev/null; then
20654
20655 $as_echo "#define DARWIN_BROKEN_SETREUID 1" >>confdefs.h
20656
20657 fi
20658 ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "
20659 $ac_includes_default
20660 #ifdef HAVE_NETINET_IN_H
20661 #include <netinet/in.h>
20662 #endif
20663
20664 #ifdef HAVE_NETINET_TCP_H
20665 #include <netinet/tcp.h>
20666 #endif
20667
20668 #ifdef HAVE_ARPA_INET_H
20669 #include <arpa/inet.h>
20670 #endif
20671
20672 #ifdef HAVE_WINSOCK2_H
20673 #include <winsock2.h>
20674 #endif
20675
20676 #ifdef HAVE_WS2TCPIP_H
20677 #include <ws2tcpip.h>
20678 #endif
20679
20680 "
20681 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
20682   ac_have_decl=1
20683 else
20684   ac_have_decl=0
20685 fi
20686
20687 cat >>confdefs.h <<_ACEOF
20688 #define HAVE_DECL_INET_PTON $ac_have_decl
20689 _ACEOF
20690 ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "
20691 $ac_includes_default
20692 #ifdef HAVE_NETINET_IN_H
20693 #include <netinet/in.h>
20694 #endif
20695
20696 #ifdef HAVE_NETINET_TCP_H
20697 #include <netinet/tcp.h>
20698 #endif
20699
20700 #ifdef HAVE_ARPA_INET_H
20701 #include <arpa/inet.h>
20702 #endif
20703
20704 #ifdef HAVE_WINSOCK2_H
20705 #include <winsock2.h>
20706 #endif
20707
20708 #ifdef HAVE_WS2TCPIP_H
20709 #include <ws2tcpip.h>
20710 #endif
20711
20712 "
20713 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
20714   ac_have_decl=1
20715 else
20716   ac_have_decl=0
20717 fi
20718
20719 cat >>confdefs.h <<_ACEOF
20720 #define HAVE_DECL_INET_NTOP $ac_have_decl
20721 _ACEOF
20722
20723 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
20724 if test "x$ac_cv_func_inet_aton" = xyes; then :
20725   $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
20726
20727 else
20728   case " $LIBOBJS " in
20729   *" inet_aton.$ac_objext "* ) ;;
20730   *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
20731  ;;
20732 esac
20733
20734 fi
20735
20736
20737 ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
20738 if test "x$ac_cv_func_inet_pton" = xyes; then :
20739   $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h
20740
20741 else
20742   case " $LIBOBJS " in
20743   *" inet_pton.$ac_objext "* ) ;;
20744   *) LIBOBJS="$LIBOBJS inet_pton.$ac_objext"
20745  ;;
20746 esac
20747
20748 fi
20749
20750
20751 ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
20752 if test "x$ac_cv_func_inet_ntop" = xyes; then :
20753   $as_echo "#define HAVE_INET_NTOP 1" >>confdefs.h
20754
20755 else
20756   case " $LIBOBJS " in
20757   *" inet_ntop.$ac_objext "* ) ;;
20758   *) LIBOBJS="$LIBOBJS inet_ntop.$ac_objext"
20759  ;;
20760 esac
20761
20762 fi
20763
20764
20765 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
20766 if test "x$ac_cv_func_snprintf" = xyes; then :
20767   $as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
20768
20769 else
20770   case " $LIBOBJS " in
20771   *" snprintf.$ac_objext "* ) ;;
20772   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20773  ;;
20774 esac
20775
20776 fi
20777
20778
20779 # test if snprintf return the proper length
20780 if test "x$ac_cv_func_snprintf" = xyes; then
20781     if test c${cross_compiling} = cno; then
20782         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for correct snprintf return value" >&5
20783 $as_echo_n "checking for correct snprintf return value... " >&6; }
20784         if test "$cross_compiling" = yes; then :
20785   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20786 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20787 as_fn_error $? "cannot run test program while cross compiling
20788 See \`config.log' for more details" "$LINENO" 5; }
20789 else
20790   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20791 /* end confdefs.h.  */
20792 $ac_includes_default
20793
20794 int main(void) { return !(snprintf(NULL, 0, "test") == 4); }
20795
20796 _ACEOF
20797 if ac_fn_c_try_run "$LINENO"; then :
20798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20799 $as_echo "yes" >&6; }
20800 else
20801
20802                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20803 $as_echo "no" >&6; }
20804
20805 $as_echo "#define SNPRINTF_RET_BROKEN /**/" >>confdefs.h
20806
20807                 case " $LIBOBJS " in
20808   *" snprintf.$ac_objext "* ) ;;
20809   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20810  ;;
20811 esac
20812
20813
20814 fi
20815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20816   conftest.$ac_objext conftest.beam conftest.$ac_ext
20817 fi
20818
20819     fi
20820 fi
20821 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
20822 if test "x$ac_cv_func_strlcat" = xyes; then :
20823   $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
20824
20825 else
20826   case " $LIBOBJS " in
20827   *" strlcat.$ac_objext "* ) ;;
20828   *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
20829  ;;
20830 esac
20831
20832 fi
20833
20834
20835 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
20836 if test "x$ac_cv_func_strlcpy" = xyes; then :
20837   $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
20838
20839 else
20840   case " $LIBOBJS " in
20841   *" strlcpy.$ac_objext "* ) ;;
20842   *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
20843  ;;
20844 esac
20845
20846 fi
20847
20848
20849 ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
20850 if test "x$ac_cv_func_memmove" = xyes; then :
20851   $as_echo "#define HAVE_MEMMOVE 1" >>confdefs.h
20852
20853 else
20854   case " $LIBOBJS " in
20855   *" memmove.$ac_objext "* ) ;;
20856   *) LIBOBJS="$LIBOBJS memmove.$ac_objext"
20857  ;;
20858 esac
20859
20860 fi
20861
20862
20863 ac_fn_c_check_func "$LINENO" "gmtime_r" "ac_cv_func_gmtime_r"
20864 if test "x$ac_cv_func_gmtime_r" = xyes; then :
20865   $as_echo "#define HAVE_GMTIME_R 1" >>confdefs.h
20866
20867 else
20868   case " $LIBOBJS " in
20869   *" gmtime_r.$ac_objext "* ) ;;
20870   *) LIBOBJS="$LIBOBJS gmtime_r.$ac_objext"
20871  ;;
20872 esac
20873
20874 fi
20875
20876
20877 ac_fn_c_check_func "$LINENO" "isblank" "ac_cv_func_isblank"
20878 if test "x$ac_cv_func_isblank" = xyes; then :
20879   $as_echo "#define HAVE_ISBLANK 1" >>confdefs.h
20880
20881 else
20882   case " $LIBOBJS " in
20883   *" isblank.$ac_objext "* ) ;;
20884   *) LIBOBJS="$LIBOBJS isblank.$ac_objext"
20885  ;;
20886 esac
20887
20888 fi
20889
20890
20891 ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero"
20892 if test "x$ac_cv_func_explicit_bzero" = xyes; then :
20893   $as_echo "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h
20894
20895 else
20896   case " $LIBOBJS " in
20897   *" explicit_bzero.$ac_objext "* ) ;;
20898   *) LIBOBJS="$LIBOBJS explicit_bzero.$ac_objext"
20899  ;;
20900 esac
20901
20902 fi
20903
20904
20905 LIBOBJ_WITHOUT_CTIMEARC4="$LIBOBJS"
20906
20907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for reallocarray" >&5
20908 $as_echo_n "checking for reallocarray... " >&6; }
20909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20910 /* end confdefs.h.  */
20911 $ac_includes_default
20912
20913 #ifndef _OPENBSD_SOURCE
20914 #define _OPENBSD_SOURCE 1
20915 #endif
20916 #include <stdlib.h>
20917 int main(void) {
20918         void* p = reallocarray(NULL, 10, 100);
20919         free(p);
20920         return 0;
20921 }
20922
20923 _ACEOF
20924 if ac_fn_c_try_link "$LINENO"; then :
20925   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20926 $as_echo "yes" >&6; }
20927
20928 $as_echo "#define HAVE_REALLOCARRAY 1" >>confdefs.h
20929
20930
20931 else
20932
20933         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20934 $as_echo "no" >&6; }
20935         case " $LIBOBJS " in
20936   *" reallocarray.$ac_objext "* ) ;;
20937   *) LIBOBJS="$LIBOBJS reallocarray.$ac_objext"
20938  ;;
20939 esac
20940
20941
20942 fi
20943 rm -f core conftest.err conftest.$ac_objext \
20944     conftest$ac_exeext conftest.$ac_ext
20945 ac_fn_c_check_decl "$LINENO" "reallocarray" "ac_cv_have_decl_reallocarray" "$ac_includes_default"
20946 if test "x$ac_cv_have_decl_reallocarray" = xyes; then :
20947   ac_have_decl=1
20948 else
20949   ac_have_decl=0
20950 fi
20951
20952 cat >>confdefs.h <<_ACEOF
20953 #define HAVE_DECL_REALLOCARRAY $ac_have_decl
20954 _ACEOF
20955
20956 if test "$USE_NSS" = "no"; then
20957         ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
20958 if test "x$ac_cv_func_arc4random" = xyes; then :
20959   $as_echo "#define HAVE_ARC4RANDOM 1" >>confdefs.h
20960
20961 else
20962   case " $LIBOBJS " in
20963   *" arc4random.$ac_objext "* ) ;;
20964   *) LIBOBJS="$LIBOBJS arc4random.$ac_objext"
20965  ;;
20966 esac
20967
20968 fi
20969
20970
20971         ac_fn_c_check_func "$LINENO" "arc4random_uniform" "ac_cv_func_arc4random_uniform"
20972 if test "x$ac_cv_func_arc4random_uniform" = xyes; then :
20973   $as_echo "#define HAVE_ARC4RANDOM_UNIFORM 1" >>confdefs.h
20974
20975 else
20976   case " $LIBOBJS " in
20977   *" arc4random_uniform.$ac_objext "* ) ;;
20978   *) LIBOBJS="$LIBOBJS arc4random_uniform.$ac_objext"
20979  ;;
20980 esac
20981
20982 fi
20983
20984
20985         if test "$ac_cv_func_arc4random" = "no"; then
20986                 case " $LIBOBJS " in
20987   *" arc4_lock.$ac_objext "* ) ;;
20988   *) LIBOBJS="$LIBOBJS arc4_lock.$ac_objext"
20989  ;;
20990 esac
20991
20992                 for ac_func in getentropy
20993 do :
20994   ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
20995 if test "x$ac_cv_func_getentropy" = xyes; then :
20996   cat >>confdefs.h <<_ACEOF
20997 #define HAVE_GETENTROPY 1
20998 _ACEOF
20999
21000 else
21001
21002                     if test "$USE_WINSOCK" = 1; then
21003                         case " $LIBOBJS " in
21004   *" getentropy_win.$ac_objext "* ) ;;
21005   *) LIBOBJS="$LIBOBJS getentropy_win.$ac_objext"
21006  ;;
21007 esac
21008
21009                     else
21010                         case "$host" in
21011                         Darwin|*darwin*)
21012                                 case " $LIBOBJS " in
21013   *" getentropy_osx.$ac_objext "* ) ;;
21014   *) LIBOBJS="$LIBOBJS getentropy_osx.$ac_objext"
21015  ;;
21016 esac
21017
21018                         ;;
21019                         *solaris*|*sunos*|SunOS)
21020                                 case " $LIBOBJS " in
21021   *" getentropy_solaris.$ac_objext "* ) ;;
21022   *) LIBOBJS="$LIBOBJS getentropy_solaris.$ac_objext"
21023  ;;
21024 esac
21025
21026                                 for ac_header in sys/sha2.h
21027 do :
21028   ac_fn_c_check_header_compile "$LINENO" "sys/sha2.h" "ac_cv_header_sys_sha2_h" "$ac_includes_default
21029 "
21030 if test "x$ac_cv_header_sys_sha2_h" = xyes; then :
21031   cat >>confdefs.h <<_ACEOF
21032 #define HAVE_SYS_SHA2_H 1
21033 _ACEOF
21034
21035 else
21036
21037                                         for ac_func in SHA512_Update
21038 do :
21039   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
21040 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
21041   cat >>confdefs.h <<_ACEOF
21042 #define HAVE_SHA512_UPDATE 1
21043 _ACEOF
21044
21045 else
21046
21047                                                 case " $LIBOBJS " in
21048   *" sha512.$ac_objext "* ) ;;
21049   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
21050  ;;
21051 esac
21052
21053
21054 fi
21055 done
21056
21057
21058 fi
21059
21060 done
21061
21062                                 if test "$ac_cv_header_sys_sha2_h" = "yes"; then
21063                                         # this lib needed for sha2 on solaris
21064                                         LIBS="$LIBS -lmd"
21065                                 fi
21066                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
21067 $as_echo_n "checking for library containing clock_gettime... " >&6; }
21068 if ${ac_cv_search_clock_gettime+:} false; then :
21069   $as_echo_n "(cached) " >&6
21070 else
21071   ac_func_search_save_LIBS=$LIBS
21072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21073 /* end confdefs.h.  */
21074
21075 /* Override any GCC internal prototype to avoid an error.
21076    Use char because int might match the return type of a GCC
21077    builtin and then its argument prototype would still apply.  */
21078 #ifdef __cplusplus
21079 extern "C"
21080 #endif
21081 char clock_gettime ();
21082 int
21083 main ()
21084 {
21085 return clock_gettime ();
21086   ;
21087   return 0;
21088 }
21089 _ACEOF
21090 for ac_lib in '' rt; do
21091   if test -z "$ac_lib"; then
21092     ac_res="none required"
21093   else
21094     ac_res=-l$ac_lib
21095     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21096   fi
21097   if ac_fn_c_try_link "$LINENO"; then :
21098   ac_cv_search_clock_gettime=$ac_res
21099 fi
21100 rm -f core conftest.err conftest.$ac_objext \
21101     conftest$ac_exeext
21102   if ${ac_cv_search_clock_gettime+:} false; then :
21103   break
21104 fi
21105 done
21106 if ${ac_cv_search_clock_gettime+:} false; then :
21107
21108 else
21109   ac_cv_search_clock_gettime=no
21110 fi
21111 rm conftest.$ac_ext
21112 LIBS=$ac_func_search_save_LIBS
21113 fi
21114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
21115 $as_echo "$ac_cv_search_clock_gettime" >&6; }
21116 ac_res=$ac_cv_search_clock_gettime
21117 if test "$ac_res" != no; then :
21118   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21119
21120 fi
21121
21122                         ;;
21123                         *freebsd*|*FreeBSD)
21124                                 case " $LIBOBJS " in
21125   *" getentropy_freebsd.$ac_objext "* ) ;;
21126   *) LIBOBJS="$LIBOBJS getentropy_freebsd.$ac_objext"
21127  ;;
21128 esac
21129
21130                         ;;
21131                         *linux*|Linux|*)
21132                                 case " $LIBOBJS " in
21133   *" getentropy_linux.$ac_objext "* ) ;;
21134   *) LIBOBJS="$LIBOBJS getentropy_linux.$ac_objext"
21135  ;;
21136 esac
21137
21138                                 for ac_func in SHA512_Update
21139 do :
21140   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
21141 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
21142   cat >>confdefs.h <<_ACEOF
21143 #define HAVE_SHA512_UPDATE 1
21144 _ACEOF
21145
21146 else
21147
21148
21149 $as_echo "#define COMPAT_SHA512 1" >>confdefs.h
21150
21151                                         case " $LIBOBJS " in
21152   *" sha512.$ac_objext "* ) ;;
21153   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
21154  ;;
21155 esac
21156
21157
21158 fi
21159 done
21160
21161                                 for ac_header in sys/sysctl.h
21162 do :
21163   ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default
21164 "
21165 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
21166   cat >>confdefs.h <<_ACEOF
21167 #define HAVE_SYS_SYSCTL_H 1
21168 _ACEOF
21169
21170 fi
21171
21172 done
21173
21174                                 for ac_func in getauxval
21175 do :
21176   ac_fn_c_check_func "$LINENO" "getauxval" "ac_cv_func_getauxval"
21177 if test "x$ac_cv_func_getauxval" = xyes; then :
21178   cat >>confdefs.h <<_ACEOF
21179 #define HAVE_GETAUXVAL 1
21180 _ACEOF
21181
21182 fi
21183 done
21184
21185                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
21186 $as_echo_n "checking for library containing clock_gettime... " >&6; }
21187 if ${ac_cv_search_clock_gettime+:} false; then :
21188   $as_echo_n "(cached) " >&6
21189 else
21190   ac_func_search_save_LIBS=$LIBS
21191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21192 /* end confdefs.h.  */
21193
21194 /* Override any GCC internal prototype to avoid an error.
21195    Use char because int might match the return type of a GCC
21196    builtin and then its argument prototype would still apply.  */
21197 #ifdef __cplusplus
21198 extern "C"
21199 #endif
21200 char clock_gettime ();
21201 int
21202 main ()
21203 {
21204 return clock_gettime ();
21205   ;
21206   return 0;
21207 }
21208 _ACEOF
21209 for ac_lib in '' rt; do
21210   if test -z "$ac_lib"; then
21211     ac_res="none required"
21212   else
21213     ac_res=-l$ac_lib
21214     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21215   fi
21216   if ac_fn_c_try_link "$LINENO"; then :
21217   ac_cv_search_clock_gettime=$ac_res
21218 fi
21219 rm -f core conftest.err conftest.$ac_objext \
21220     conftest$ac_exeext
21221   if ${ac_cv_search_clock_gettime+:} false; then :
21222   break
21223 fi
21224 done
21225 if ${ac_cv_search_clock_gettime+:} false; then :
21226
21227 else
21228   ac_cv_search_clock_gettime=no
21229 fi
21230 rm conftest.$ac_ext
21231 LIBS=$ac_func_search_save_LIBS
21232 fi
21233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
21234 $as_echo "$ac_cv_search_clock_gettime" >&6; }
21235 ac_res=$ac_cv_search_clock_gettime
21236 if test "$ac_res" != no; then :
21237   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21238
21239 fi
21240
21241                         ;;
21242                         esac
21243                     fi
21244
21245 fi
21246 done
21247
21248         fi
21249 fi
21250 LIBOBJ_WITHOUT_CTIME="$LIBOBJS"
21251
21252 ac_fn_c_check_func "$LINENO" "ctime_r" "ac_cv_func_ctime_r"
21253 if test "x$ac_cv_func_ctime_r" = xyes; then :
21254   $as_echo "#define HAVE_CTIME_R 1" >>confdefs.h
21255
21256 else
21257   case " $LIBOBJS " in
21258   *" ctime_r.$ac_objext "* ) ;;
21259   *) LIBOBJS="$LIBOBJS ctime_r.$ac_objext"
21260  ;;
21261 esac
21262
21263 fi
21264
21265
21266 ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
21267 if test "x$ac_cv_func_strsep" = xyes; then :
21268   $as_echo "#define HAVE_STRSEP 1" >>confdefs.h
21269
21270 else
21271   case " $LIBOBJS " in
21272   *" strsep.$ac_objext "* ) ;;
21273   *) LIBOBJS="$LIBOBJS strsep.$ac_objext"
21274  ;;
21275 esac
21276
21277 fi
21278
21279
21280
21281 # Check whether --enable-allsymbols was given.
21282 if test "${enable_allsymbols+set}" = set; then :
21283   enableval=$enable_allsymbols;
21284 fi
21285
21286 case "$enable_allsymbols" in
21287         yes)
21288         COMMON_OBJ_ALL_SYMBOLS=""
21289         UBSYMS=""
21290         EXTRALINK="libunbound.la"
21291
21292 $as_echo "#define EXPORT_ALL_SYMBOLS 1" >>confdefs.h
21293
21294         ;;
21295         no|*)
21296         COMMON_OBJ_ALL_SYMBOLS='$(COMMON_OBJ)'
21297         UBSYMS='-export-symbols $(srcdir)/libunbound/ubsyms.def'
21298         EXTRALINK=""
21299         ;;
21300 esac
21301
21302
21303
21304 if test x_$enable_lock_checks = x_yes; then
21305         UBSYMS="-export-symbols clubsyms.def"
21306         cp ${srcdir}/libunbound/ubsyms.def clubsyms.def
21307         echo lock_protect >> clubsyms.def
21308         echo lock_unprotect >> clubsyms.def
21309         echo lock_get_mem >> clubsyms.def
21310         echo checklock_start >> clubsyms.def
21311         echo checklock_stop >> clubsyms.def
21312         echo checklock_lock >> clubsyms.def
21313         echo checklock_unlock >> clubsyms.def
21314         echo checklock_init >> clubsyms.def
21315         echo checklock_thrcreate >> clubsyms.def
21316         echo checklock_thrjoin >> clubsyms.def
21317 fi
21318
21319 # check for dnstap if requested
21320
21321   # Check whether --enable-dnstap was given.
21322 if test "${enable_dnstap+set}" = set; then :
21323   enableval=$enable_dnstap; opt_dnstap=$enableval
21324 else
21325   opt_dnstap=no
21326 fi
21327
21328
21329
21330 # Check whether --with-dnstap-socket-path was given.
21331 if test "${with_dnstap_socket_path+set}" = set; then :
21332   withval=$with_dnstap_socket_path; opt_dnstap_socket_path=$withval
21333 else
21334   opt_dnstap_socket_path="$UNBOUND_RUN_DIR/dnstap.sock"
21335 fi
21336
21337
21338   if test "x$opt_dnstap" != "xno"; then
21339     # Extract the first word of "protoc-c", so it can be a program name with args.
21340 set dummy protoc-c; ac_word=$2
21341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21342 $as_echo_n "checking for $ac_word... " >&6; }
21343 if ${ac_cv_path_PROTOC_C+:} false; then :
21344   $as_echo_n "(cached) " >&6
21345 else
21346   case $PROTOC_C in
21347   [\\/]* | ?:[\\/]*)
21348   ac_cv_path_PROTOC_C="$PROTOC_C" # Let the user override the test with a path.
21349   ;;
21350   *)
21351   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21352 for as_dir in $PATH
21353 do
21354   IFS=$as_save_IFS
21355   test -z "$as_dir" && as_dir=.
21356     for ac_exec_ext in '' $ac_executable_extensions; do
21357   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21358     ac_cv_path_PROTOC_C="$as_dir/$ac_word$ac_exec_ext"
21359     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21360     break 2
21361   fi
21362 done
21363   done
21364 IFS=$as_save_IFS
21365
21366   ;;
21367 esac
21368 fi
21369 PROTOC_C=$ac_cv_path_PROTOC_C
21370 if test -n "$PROTOC_C"; then
21371   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROTOC_C" >&5
21372 $as_echo "$PROTOC_C" >&6; }
21373 else
21374   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21375 $as_echo "no" >&6; }
21376 fi
21377
21378
21379     if test -z "$PROTOC_C"; then
21380       as_fn_error $? "The protoc-c program was not found. Please install protobuf-c!" "$LINENO" 5
21381     fi
21382
21383 # Check whether --with-protobuf-c was given.
21384 if test "${with_protobuf_c+set}" = set; then :
21385   withval=$with_protobuf_c;
21386           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
21387           if test -f $withval/include/google/protobuf-c/protobuf-c.h; then
21388             CFLAGS="$CFLAGS -I$withval/include/google"
21389           else
21390             CFLAGS="$CFLAGS -I$withval/include"
21391           fi
21392           LDFLAGS="$LDFLAGS -L$withval/lib"
21393
21394 else
21395
21396           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
21397           if test -f /usr/include/google/protobuf-c/protobuf-c.h; then
21398             CFLAGS="$CFLAGS -I/usr/include/google"
21399           else
21400             if test -f /usr/local/include/google/protobuf-c/protobuf-c.h; then
21401               CFLAGS="$CFLAGS -I/usr/local/include/google"
21402               LDFLAGS="$LDFLAGS -L/usr/local/lib"
21403             fi
21404           fi
21405
21406 fi
21407
21408     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing protobuf_c_message_pack" >&5
21409 $as_echo_n "checking for library containing protobuf_c_message_pack... " >&6; }
21410 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21411   $as_echo_n "(cached) " >&6
21412 else
21413   ac_func_search_save_LIBS=$LIBS
21414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21415 /* end confdefs.h.  */
21416
21417 /* Override any GCC internal prototype to avoid an error.
21418    Use char because int might match the return type of a GCC
21419    builtin and then its argument prototype would still apply.  */
21420 #ifdef __cplusplus
21421 extern "C"
21422 #endif
21423 char protobuf_c_message_pack ();
21424 int
21425 main ()
21426 {
21427 return protobuf_c_message_pack ();
21428   ;
21429   return 0;
21430 }
21431 _ACEOF
21432 for ac_lib in '' protobuf-c; do
21433   if test -z "$ac_lib"; then
21434     ac_res="none required"
21435   else
21436     ac_res=-l$ac_lib
21437     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21438   fi
21439   if ac_fn_c_try_link "$LINENO"; then :
21440   ac_cv_search_protobuf_c_message_pack=$ac_res
21441 fi
21442 rm -f core conftest.err conftest.$ac_objext \
21443     conftest$ac_exeext
21444   if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21445   break
21446 fi
21447 done
21448 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
21449
21450 else
21451   ac_cv_search_protobuf_c_message_pack=no
21452 fi
21453 rm conftest.$ac_ext
21454 LIBS=$ac_func_search_save_LIBS
21455 fi
21456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_protobuf_c_message_pack" >&5
21457 $as_echo "$ac_cv_search_protobuf_c_message_pack" >&6; }
21458 ac_res=$ac_cv_search_protobuf_c_message_pack
21459 if test "$ac_res" != no; then :
21460   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21461
21462 else
21463   as_fn_error $? "The protobuf-c library was not found. Please install protobuf-c!" "$LINENO" 5
21464 fi
21465
21466
21467
21468 $as_echo "#define USE_DNSTAP 1" >>confdefs.h
21469
21470         ENABLE_DNSTAP=1
21471
21472
21473
21474         hdr_dnstap_socket_path="`echo $opt_dnstap_socket_path | sed -e 's/\\\\/\\\\\\\\/g'`"
21475
21476
21477 cat >>confdefs.h <<_ACEOF
21478 #define DNSTAP_SOCKET_PATH "$hdr_dnstap_socket_path"
21479 _ACEOF
21480
21481         DNSTAP_SOCKET_PATH="$hdr_dnstap_socket_path"
21482
21483         DNSTAP_SOCKET_TESTBIN='unbound-dnstap-socket$(EXEEXT)'
21484
21485         DNSTAP_SRC="dnstap/dnstap.c dnstap/dnstap.pb-c.c dnstap/dnstap_fstrm.c dnstap/dtstream.c"
21486
21487         DNSTAP_OBJ="dnstap.lo dnstap.pb-c.lo dnstap_fstrm.lo dtstream.lo"
21488
21489
21490   else
21491
21492         ENABLE_DNSTAP=0
21493
21494
21495
21496   fi
21497
21498
21499 # check for dnscrypt if requested
21500
21501   # Check whether --enable-dnscrypt was given.
21502 if test "${enable_dnscrypt+set}" = set; then :
21503   enableval=$enable_dnscrypt; opt_dnscrypt=$enableval
21504 else
21505   opt_dnscrypt=no
21506 fi
21507
21508
21509   if test "x$opt_dnscrypt" != "xno"; then
21510
21511 # Check whether --with-libsodium was given.
21512 if test "${with_libsodium+set}" = set; then :
21513   withval=$with_libsodium;
21514         CFLAGS="$CFLAGS -I$withval/include"
21515         LDFLAGS="$LDFLAGS -L$withval/lib"
21516
21517 fi
21518
21519     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_init" >&5
21520 $as_echo_n "checking for library containing sodium_init... " >&6; }
21521 if ${ac_cv_search_sodium_init+:} false; then :
21522   $as_echo_n "(cached) " >&6
21523 else
21524   ac_func_search_save_LIBS=$LIBS
21525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21526 /* end confdefs.h.  */
21527
21528 /* Override any GCC internal prototype to avoid an error.
21529    Use char because int might match the return type of a GCC
21530    builtin and then its argument prototype would still apply.  */
21531 #ifdef __cplusplus
21532 extern "C"
21533 #endif
21534 char sodium_init ();
21535 int
21536 main ()
21537 {
21538 return sodium_init ();
21539   ;
21540   return 0;
21541 }
21542 _ACEOF
21543 for ac_lib in '' sodium; do
21544   if test -z "$ac_lib"; then
21545     ac_res="none required"
21546   else
21547     ac_res=-l$ac_lib
21548     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21549   fi
21550   if ac_fn_c_try_link "$LINENO"; then :
21551   ac_cv_search_sodium_init=$ac_res
21552 fi
21553 rm -f core conftest.err conftest.$ac_objext \
21554     conftest$ac_exeext
21555   if ${ac_cv_search_sodium_init+:} false; then :
21556   break
21557 fi
21558 done
21559 if ${ac_cv_search_sodium_init+:} false; then :
21560
21561 else
21562   ac_cv_search_sodium_init=no
21563 fi
21564 rm conftest.$ac_ext
21565 LIBS=$ac_func_search_save_LIBS
21566 fi
21567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_init" >&5
21568 $as_echo "$ac_cv_search_sodium_init" >&6; }
21569 ac_res=$ac_cv_search_sodium_init
21570 if test "$ac_res" != no; then :
21571   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21572
21573 else
21574   as_fn_error $? "The sodium library was not found. Please install sodium!" "$LINENO" 5
21575 fi
21576
21577     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21578 $as_echo_n "checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm... " >&6; }
21579 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21580   $as_echo_n "(cached) " >&6
21581 else
21582   ac_func_search_save_LIBS=$LIBS
21583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21584 /* end confdefs.h.  */
21585
21586 /* Override any GCC internal prototype to avoid an error.
21587    Use char because int might match the return type of a GCC
21588    builtin and then its argument prototype would still apply.  */
21589 #ifdef __cplusplus
21590 extern "C"
21591 #endif
21592 char crypto_box_curve25519xchacha20poly1305_beforenm ();
21593 int
21594 main ()
21595 {
21596 return crypto_box_curve25519xchacha20poly1305_beforenm ();
21597   ;
21598   return 0;
21599 }
21600 _ACEOF
21601 for ac_lib in '' sodium; do
21602   if test -z "$ac_lib"; then
21603     ac_res="none required"
21604   else
21605     ac_res=-l$ac_lib
21606     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21607   fi
21608   if ac_fn_c_try_link "$LINENO"; then :
21609   ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=$ac_res
21610 fi
21611 rm -f core conftest.err conftest.$ac_objext \
21612     conftest$ac_exeext
21613   if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21614   break
21615 fi
21616 done
21617 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21618
21619 else
21620   ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=no
21621 fi
21622 rm conftest.$ac_ext
21623 LIBS=$ac_func_search_save_LIBS
21624 fi
21625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21626 $as_echo "$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&6; }
21627 ac_res=$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm
21628 if test "$ac_res" != no; then :
21629   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21630
21631             ENABLE_DNSCRYPT_XCHACHA20=1
21632
21633
21634 $as_echo "#define USE_DNSCRYPT_XCHACHA20 1" >>confdefs.h
21635
21636
21637 else
21638
21639             ENABLE_DNSCRYPT_XCHACHA20=0
21640
21641
21642 fi
21643
21644     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_set_misuse_handler" >&5
21645 $as_echo_n "checking for library containing sodium_set_misuse_handler... " >&6; }
21646 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21647   $as_echo_n "(cached) " >&6
21648 else
21649   ac_func_search_save_LIBS=$LIBS
21650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21651 /* end confdefs.h.  */
21652
21653 /* Override any GCC internal prototype to avoid an error.
21654    Use char because int might match the return type of a GCC
21655    builtin and then its argument prototype would still apply.  */
21656 #ifdef __cplusplus
21657 extern "C"
21658 #endif
21659 char sodium_set_misuse_handler ();
21660 int
21661 main ()
21662 {
21663 return sodium_set_misuse_handler ();
21664   ;
21665   return 0;
21666 }
21667 _ACEOF
21668 for ac_lib in '' sodium; do
21669   if test -z "$ac_lib"; then
21670     ac_res="none required"
21671   else
21672     ac_res=-l$ac_lib
21673     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21674   fi
21675   if ac_fn_c_try_link "$LINENO"; then :
21676   ac_cv_search_sodium_set_misuse_handler=$ac_res
21677 fi
21678 rm -f core conftest.err conftest.$ac_objext \
21679     conftest$ac_exeext
21680   if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21681   break
21682 fi
21683 done
21684 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21685
21686 else
21687   ac_cv_search_sodium_set_misuse_handler=no
21688 fi
21689 rm conftest.$ac_ext
21690 LIBS=$ac_func_search_save_LIBS
21691 fi
21692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_set_misuse_handler" >&5
21693 $as_echo "$ac_cv_search_sodium_set_misuse_handler" >&6; }
21694 ac_res=$ac_cv_search_sodium_set_misuse_handler
21695 if test "$ac_res" != no; then :
21696   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21697
21698
21699 $as_echo "#define SODIUM_MISUSE_HANDLER 1" >>confdefs.h
21700
21701
21702 fi
21703
21704
21705
21706 $as_echo "#define USE_DNSCRYPT 1" >>confdefs.h
21707
21708         ENABLE_DNSCRYPT=1
21709
21710
21711         DNSCRYPT_SRC="dnscrypt/dnscrypt.c"
21712
21713         DNSCRYPT_OBJ="dnscrypt.lo"
21714
21715
21716   else
21717     ENABLE_DNSCRYPT_XCHACHA20=0
21718
21719
21720         ENABLE_DNSCRYPT=0
21721
21722
21723
21724   fi
21725
21726
21727 # check for cachedb if requested
21728 # Check whether --enable-cachedb was given.
21729 if test "${enable_cachedb+set}" = set; then :
21730   enableval=$enable_cachedb;
21731 fi
21732
21733 # turn on cachedb when hiredis support is enabled.
21734 if test "$found_libhiredis" = "yes"; then enable_cachedb="yes"; fi
21735 case "$enable_cachedb" in
21736     yes)
21737
21738 $as_echo "#define USE_CACHEDB 1" >>confdefs.h
21739
21740         CACHEDB_SRC="cachedb/cachedb.c cachedb/redis.c"
21741
21742         CACHEDB_OBJ="cachedb.lo redis.lo"
21743
21744         ;;
21745     no|*)
21746         # nothing
21747         ;;
21748 esac
21749
21750 # check for ipsecmod if requested
21751 # Check whether --enable-ipsecmod was given.
21752 if test "${enable_ipsecmod+set}" = set; then :
21753   enableval=$enable_ipsecmod;
21754 fi
21755
21756 case "$enable_ipsecmod" in
21757         yes)
21758
21759 $as_echo "#define USE_IPSECMOD 1" >>confdefs.h
21760
21761                 IPSECMOD_OBJ="ipsecmod.lo ipsecmod-whitelist.lo"
21762
21763                 IPSECMOD_HEADER='$(srcdir)/ipsecmod/ipsecmod.h $(srcdir)/ipsecmod/ipsecmod-whitelist.h'
21764
21765                 ;;
21766         no|*)
21767                 # nothing
21768                 ;;
21769 esac
21770
21771 # check for ipset if requested
21772 # Check whether --enable-ipset was given.
21773 if test "${enable_ipset+set}" = set; then :
21774   enableval=$enable_ipset;
21775 fi
21776
21777 case "$enable_ipset" in
21778     yes)
21779
21780 $as_echo "#define USE_IPSET 1" >>confdefs.h
21781
21782                 IPSET_SRC="ipset/ipset.c"
21783
21784                 IPSET_OBJ="ipset.lo"
21785
21786
21787                 # mnl
21788
21789 # Check whether --with-libmnl was given.
21790 if test "${with_libmnl+set}" = set; then :
21791   withval=$with_libmnl;
21792 else
21793    withval="yes"
21794 fi
21795
21796                 found_libmnl="no"
21797                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmnl" >&5
21798 $as_echo_n "checking for libmnl... " >&6; }
21799                 if test x_$withval = x_ -o x_$withval = x_yes; then
21800                         withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
21801                 fi
21802                 for dir in $withval ; do
21803                         if test -f "$dir/include/libmnl/libmnl.h" -o -f "$dir/include/libmnl/libmnl/libmnl.h"; then
21804                                 found_libmnl="yes"
21805                                                                 extralibmnl=""
21806                                 if test -f "$dir/include/libmnl/libmnl/libmnl.h"; then
21807                                         extralibmnl="/libmnl"
21808                                 fi
21809                                 if test "$dir" != "/usr" -o -n "$extralibmnl"; then
21810                                         CPPFLAGS="$CPPFLAGS -I$dir/include$extralibmnl"
21811                                 fi
21812                                 if test "$dir" != "/usr"; then
21813                                         LDFLAGS="$LDFLAGS -L$dir/lib"
21814                                 fi
21815                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
21816 $as_echo "found in $dir" >&6; }
21817                                 LIBS="$LIBS -lmnl"
21818                                 break;
21819                         fi
21820                 done
21821                 if test x_$found_libmnl != x_yes; then
21822                         as_fn_error $? "Could not find libmnl, libmnl.h" "$LINENO" 5
21823                 fi
21824                 ;;
21825     no|*)
21826         # nothing
21827                 ;;
21828 esac
21829 # Check whether --enable-explicit-port-randomisation was given.
21830 if test "${enable_explicit_port_randomisation+set}" = set; then :
21831   enableval=$enable_explicit_port_randomisation;
21832 fi
21833
21834 case "$enable_explicit_port_randomisation" in
21835         no)
21836
21837 $as_echo "#define DISABLE_EXPLICIT_PORT_RANDOMISATION 1" >>confdefs.h
21838
21839                 ;;
21840         yes|*)
21841                 ;;
21842 esac
21843
21844 if echo "$host" | $GREP -i -e linux >/dev/null; then
21845         # Check whether --enable-linux-ip-local-port-range was given.
21846 if test "${enable_linux_ip_local_port_range+set}" = set; then :
21847   enableval=$enable_linux_ip_local_port_range;
21848 fi
21849
21850         case "$enable_linux_ip_local_port_range" in
21851                 yes)
21852
21853 $as_echo "#define USE_LINUX_IP_LOCAL_PORT_RANGE 1" >>confdefs.h
21854
21855                         ;;
21856                 no|*)
21857                         ;;
21858         esac
21859 fi
21860
21861
21862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ${MAKE:-make} supports $< with implicit rule in scope" >&5
21863 $as_echo_n "checking if ${MAKE:-make} supports $< with implicit rule in scope... " >&6; }
21864 # on openBSD, the implicit rule make $< work.
21865 # on Solaris, it does not work ($? is changed sources, $^ lists dependencies).
21866 # gmake works.
21867 cat >conftest.make <<EOF
21868 all:    conftest.lo
21869
21870 conftest.lo foo.lo bla.lo:
21871         if test -f "\$<"; then touch \$@; fi
21872
21873 .SUFFIXES: .lo
21874 .c.lo:
21875         if test -f "\$<"; then touch \$@; fi
21876
21877 conftest.lo:        conftest.dir/conftest.c
21878 EOF
21879 mkdir conftest.dir
21880 touch conftest.dir/conftest.c
21881 rm -f conftest.lo conftest.c
21882 ${MAKE:-make} -f conftest.make >/dev/null
21883 rm -f conftest.make conftest.c conftest.dir/conftest.c
21884 rm -rf conftest.dir
21885 if test ! -f conftest.lo; then
21886         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21887 $as_echo "no" >&6; }
21888         SOURCEDETERMINE='echo "$^" | awk "-F " "{print \$$1;}" > .source'
21889         SOURCEFILE='`cat .source`'
21890 else
21891         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21892 $as_echo "yes" >&6; }
21893         SOURCEDETERMINE=':'
21894         SOURCEFILE='$<'
21895 fi
21896 rm -f conftest.lo
21897
21898
21899
21900 # see if we want to build the library or everything
21901 ALLTARGET="alltargets"
21902 INSTALLTARGET="install-all"
21903
21904 # Check whether --with-libunbound-only was given.
21905 if test "${with_libunbound_only+set}" = set; then :
21906   withval=$with_libunbound_only;
21907         if test "$withval" = "yes"; then
21908                 ALLTARGET="lib"
21909                 INSTALLTARGET="install-lib"
21910         fi
21911
21912 fi
21913
21914 if test $ALLTARGET = "alltargets"; then
21915         if test $USE_NSS = "yes"; then
21916                 as_fn_error $? "--with-nss can only be used in combination with --with-libunbound-only." "$LINENO" 5
21917         fi
21918         if test $USE_NETTLE = "yes"; then
21919                 as_fn_error $? "--with-nettle can only be used in combination with --with-libunbound-only." "$LINENO" 5
21920         fi
21921 fi
21922
21923
21924
21925
21926
21927   { $as_echo "$as_me:${as_lineno-$LINENO}: Stripping extension flags..." >&5
21928 $as_echo "$as_me: Stripping extension flags..." >&6;}
21929
21930   if echo $CFLAGS | grep " -D_GNU_SOURCE" >/dev/null 2>&1; then
21931     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_GNU_SOURCE//g'`"
21932
21933 $as_echo "#define OMITTED__D_GNU_SOURCE 1" >>confdefs.h
21934
21935   fi
21936
21937
21938   if echo $CFLAGS | grep " -D_BSD_SOURCE" >/dev/null 2>&1; then
21939     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_BSD_SOURCE//g'`"
21940
21941 $as_echo "#define OMITTED__D_BSD_SOURCE 1" >>confdefs.h
21942
21943   fi
21944
21945
21946   if echo $CFLAGS | grep " -D_DEFAULT_SOURCE" >/dev/null 2>&1; then
21947     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_DEFAULT_SOURCE//g'`"
21948
21949 $as_echo "#define OMITTED__D_DEFAULT_SOURCE 1" >>confdefs.h
21950
21951   fi
21952
21953
21954   if echo $CFLAGS | grep " -D__EXTENSIONS__" >/dev/null 2>&1; then
21955     CFLAGS="`echo $CFLAGS | sed -e 's/ -D__EXTENSIONS__//g'`"
21956
21957 $as_echo "#define OMITTED__D__EXTENSIONS__ 1" >>confdefs.h
21958
21959   fi
21960
21961
21962   if echo $CFLAGS | grep " -D_POSIX_C_SOURCE=200112" >/dev/null 2>&1; then
21963     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_POSIX_C_SOURCE=200112//g'`"
21964
21965 $as_echo "#define OMITTED__D_POSIX_C_SOURCE_200112 1" >>confdefs.h
21966
21967   fi
21968
21969
21970   if echo $CFLAGS | grep " -D_XOPEN_SOURCE=600" >/dev/null 2>&1; then
21971     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE=600//g'`"
21972
21973 $as_echo "#define OMITTED__D_XOPEN_SOURCE_600 1" >>confdefs.h
21974
21975   fi
21976
21977
21978   if echo $CFLAGS | grep " -D_XOPEN_SOURCE_EXTENDED=1" >/dev/null 2>&1; then
21979     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE_EXTENDED=1//g'`"
21980
21981 $as_echo "#define OMITTED__D_XOPEN_SOURCE_EXTENDED_1 1" >>confdefs.h
21982
21983   fi
21984
21985
21986   if echo $CFLAGS | grep " -D_ALL_SOURCE" >/dev/null 2>&1; then
21987     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_ALL_SOURCE//g'`"
21988
21989 $as_echo "#define OMITTED__D_ALL_SOURCE 1" >>confdefs.h
21990
21991   fi
21992
21993
21994   if echo $CFLAGS | grep " -D_LARGEFILE_SOURCE=1" >/dev/null 2>&1; then
21995     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_LARGEFILE_SOURCE=1//g'`"
21996
21997 $as_echo "#define OMITTED__D_LARGEFILE_SOURCE_1 1" >>confdefs.h
21998
21999   fi
22000
22001
22002 if test -n "$LATE_LDFLAGS"; then
22003   LDFLAGS="$LATE_LDFLAGS $LDFLAGS"
22004 fi
22005 # remove start spaces
22006 LDFLAGS=`echo "$LDFLAGS"|sed -e 's/^ *//'`
22007 LIBS=`echo "$LIBS"|sed -e 's/^ *//'`
22008
22009
22010 cat >>confdefs.h <<_ACEOF
22011 #define MAXSYSLOGMSGLEN 10240
22012 _ACEOF
22013
22014
22015
22016
22017 version=1.16.2
22018
22019 date=`date +'%b %e, %Y'`
22020
22021
22022 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"
22023
22024 ac_config_headers="$ac_config_headers config.h"
22025
22026 cat >confcache <<\_ACEOF
22027 # This file is a shell script that caches the results of configure
22028 # tests run on this system so they can be shared between configure
22029 # scripts and configure runs, see configure's option --config-cache.
22030 # It is not useful on other systems.  If it contains results you don't
22031 # want to keep, you may remove or edit it.
22032 #
22033 # config.status only pays attention to the cache file if you give it
22034 # the --recheck option to rerun configure.
22035 #
22036 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22037 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22038 # following values.
22039
22040 _ACEOF
22041
22042 # The following way of writing the cache mishandles newlines in values,
22043 # but we know of no workaround that is simple, portable, and efficient.
22044 # So, we kill variables containing newlines.
22045 # Ultrix sh set writes to stderr and can't be redirected directly,
22046 # and sets the high bit in the cache file unless we assign to the vars.
22047 (
22048   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
22049     eval ac_val=\$$ac_var
22050     case $ac_val in #(
22051     *${as_nl}*)
22052       case $ac_var in #(
22053       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
22054 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
22055       esac
22056       case $ac_var in #(
22057       _ | IFS | as_nl) ;; #(
22058       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
22059       *) { eval $ac_var=; unset $ac_var;} ;;
22060       esac ;;
22061     esac
22062   done
22063
22064   (set) 2>&1 |
22065     case $as_nl`(ac_space=' '; set) 2>&1` in #(
22066     *${as_nl}ac_space=\ *)
22067       # `set' does not quote correctly, so add quotes: double-quote
22068       # substitution turns \\\\ into \\, and sed turns \\ into \.
22069       sed -n \
22070         "s/'/'\\\\''/g;
22071           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22072       ;; #(
22073     *)
22074       # `set' quotes correctly as required by POSIX, so do not add quotes.
22075       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
22076       ;;
22077     esac |
22078     sort
22079 ) |
22080   sed '
22081      /^ac_cv_env_/b end
22082      t clear
22083      :clear
22084      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22085      t end
22086      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22087      :end' >>confcache
22088 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
22089   if test -w "$cache_file"; then
22090     if test "x$cache_file" != "x/dev/null"; then
22091       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
22092 $as_echo "$as_me: updating cache $cache_file" >&6;}
22093       if test ! -f "$cache_file" || test -h "$cache_file"; then
22094         cat confcache >"$cache_file"
22095       else
22096         case $cache_file in #(
22097         */* | ?:*)
22098           mv -f confcache "$cache_file"$$ &&
22099           mv -f "$cache_file"$$ "$cache_file" ;; #(
22100         *)
22101           mv -f confcache "$cache_file" ;;
22102         esac
22103       fi
22104     fi
22105   else
22106     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
22107 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
22108   fi
22109 fi
22110 rm -f confcache
22111
22112 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22113 # Let make expand exec_prefix.
22114 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22115
22116 DEFS=-DHAVE_CONFIG_H
22117
22118 ac_libobjs=
22119 ac_ltlibobjs=
22120 U=
22121 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22122   # 1. Remove the extension, and $U if already installed.
22123   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
22124   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
22125   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
22126   #    will be set to the directory where LIBOBJS objects are built.
22127   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
22128   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
22129 done
22130 LIBOBJS=$ac_libobjs
22131
22132 LTLIBOBJS=$ac_ltlibobjs
22133
22134
22135 if test -z "${USE_SYSTEMD_TRUE}" && test -z "${USE_SYSTEMD_FALSE}"; then
22136   as_fn_error $? "conditional \"USE_SYSTEMD\" was never defined.
22137 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22138 fi
22139
22140 : "${CONFIG_STATUS=./config.status}"
22141 ac_write_fail=0
22142 ac_clean_files_save=$ac_clean_files
22143 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22144 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
22145 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
22146 as_write_fail=0
22147 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
22148 #! $SHELL
22149 # Generated by $as_me.
22150 # Run this file to recreate the current configuration.
22151 # Compiler output produced by configure, useful for debugging
22152 # configure, is in config.log if it exists.
22153
22154 debug=false
22155 ac_cs_recheck=false
22156 ac_cs_silent=false
22157
22158 SHELL=\${CONFIG_SHELL-$SHELL}
22159 export SHELL
22160 _ASEOF
22161 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
22162 ## -------------------- ##
22163 ## M4sh Initialization. ##
22164 ## -------------------- ##
22165
22166 # Be more Bourne compatible
22167 DUALCASE=1; export DUALCASE # for MKS sh
22168 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22169   emulate sh
22170   NULLCMD=:
22171   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
22172   # is contrary to our usage.  Disable this feature.
22173   alias -g '${1+"$@"}'='"$@"'
22174   setopt NO_GLOB_SUBST
22175 else
22176   case `(set -o) 2>/dev/null` in #(
22177   *posix*) :
22178     set -o posix ;; #(
22179   *) :
22180      ;;
22181 esac
22182 fi
22183
22184
22185 as_nl='
22186 '
22187 export as_nl
22188 # Printing a long string crashes Solaris 7 /usr/bin/printf.
22189 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
22190 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
22191 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
22192 # Prefer a ksh shell builtin over an external printf program on Solaris,
22193 # but without wasting forks for bash or zsh.
22194 if test -z "$BASH_VERSION$ZSH_VERSION" \
22195     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
22196   as_echo='print -r --'
22197   as_echo_n='print -rn --'
22198 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
22199   as_echo='printf %s\n'
22200   as_echo_n='printf %s'
22201 else
22202   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
22203     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
22204     as_echo_n='/usr/ucb/echo -n'
22205   else
22206     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
22207     as_echo_n_body='eval
22208       arg=$1;
22209       case $arg in #(
22210       *"$as_nl"*)
22211         expr "X$arg" : "X\\(.*\\)$as_nl";
22212         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
22213       esac;
22214       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
22215     '
22216     export as_echo_n_body
22217     as_echo_n='sh -c $as_echo_n_body as_echo'
22218   fi
22219   export as_echo_body
22220   as_echo='sh -c $as_echo_body as_echo'
22221 fi
22222
22223 # The user is always right.
22224 if test "${PATH_SEPARATOR+set}" != set; then
22225   PATH_SEPARATOR=:
22226   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
22227     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
22228       PATH_SEPARATOR=';'
22229   }
22230 fi
22231
22232
22233 # IFS
22234 # We need space, tab and new line, in precisely that order.  Quoting is
22235 # there to prevent editors from complaining about space-tab.
22236 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
22237 # splitting by setting IFS to empty value.)
22238 IFS=" ""        $as_nl"
22239
22240 # Find who we are.  Look in the path if we contain no directory separator.
22241 as_myself=
22242 case $0 in #((
22243   *[\\/]* ) as_myself=$0 ;;
22244   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22245 for as_dir in $PATH
22246 do
22247   IFS=$as_save_IFS
22248   test -z "$as_dir" && as_dir=.
22249     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22250   done
22251 IFS=$as_save_IFS
22252
22253      ;;
22254 esac
22255 # We did not find ourselves, most probably we were run as `sh COMMAND'
22256 # in which case we are not to be found in the path.
22257 if test "x$as_myself" = x; then
22258   as_myself=$0
22259 fi
22260 if test ! -f "$as_myself"; then
22261   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
22262   exit 1
22263 fi
22264
22265 # Unset variables that we do not need and which cause bugs (e.g. in
22266 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
22267 # suppresses any "Segmentation fault" message there.  '((' could
22268 # trigger a bug in pdksh 5.2.14.
22269 for as_var in BASH_ENV ENV MAIL MAILPATH
22270 do eval test x\${$as_var+set} = xset \
22271   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
22272 done
22273 PS1='$ '
22274 PS2='> '
22275 PS4='+ '
22276
22277 # NLS nuisances.
22278 LC_ALL=C
22279 export LC_ALL
22280 LANGUAGE=C
22281 export LANGUAGE
22282
22283 # CDPATH.
22284 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22285
22286
22287 # as_fn_error STATUS ERROR [LINENO LOG_FD]
22288 # ----------------------------------------
22289 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
22290 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22291 # script with STATUS, using 1 if that was 0.
22292 as_fn_error ()
22293 {
22294   as_status=$1; test $as_status -eq 0 && as_status=1
22295   if test "$4"; then
22296     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
22297     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
22298   fi
22299   $as_echo "$as_me: error: $2" >&2
22300   as_fn_exit $as_status
22301 } # as_fn_error
22302
22303
22304 # as_fn_set_status STATUS
22305 # -----------------------
22306 # Set $? to STATUS, without forking.
22307 as_fn_set_status ()
22308 {
22309   return $1
22310 } # as_fn_set_status
22311
22312 # as_fn_exit STATUS
22313 # -----------------
22314 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
22315 as_fn_exit ()
22316 {
22317   set +e
22318   as_fn_set_status $1
22319   exit $1
22320 } # as_fn_exit
22321
22322 # as_fn_unset VAR
22323 # ---------------
22324 # Portably unset VAR.
22325 as_fn_unset ()
22326 {
22327   { eval $1=; unset $1;}
22328 }
22329 as_unset=as_fn_unset
22330 # as_fn_append VAR VALUE
22331 # ----------------------
22332 # Append the text in VALUE to the end of the definition contained in VAR. Take
22333 # advantage of any shell optimizations that allow amortized linear growth over
22334 # repeated appends, instead of the typical quadratic growth present in naive
22335 # implementations.
22336 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
22337   eval 'as_fn_append ()
22338   {
22339     eval $1+=\$2
22340   }'
22341 else
22342   as_fn_append ()
22343   {
22344     eval $1=\$$1\$2
22345   }
22346 fi # as_fn_append
22347
22348 # as_fn_arith ARG...
22349 # ------------------
22350 # Perform arithmetic evaluation on the ARGs, and store the result in the
22351 # global $as_val. Take advantage of shells that can avoid forks. The arguments
22352 # must be portable across $(()) and expr.
22353 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
22354   eval 'as_fn_arith ()
22355   {
22356     as_val=$(( $* ))
22357   }'
22358 else
22359   as_fn_arith ()
22360   {
22361     as_val=`expr "$@" || test $? -eq 1`
22362   }
22363 fi # as_fn_arith
22364
22365
22366 if expr a : '\(a\)' >/dev/null 2>&1 &&
22367    test "X`expr 00001 : '.*\(...\)'`" = X001; then
22368   as_expr=expr
22369 else
22370   as_expr=false
22371 fi
22372
22373 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
22374   as_basename=basename
22375 else
22376   as_basename=false
22377 fi
22378
22379 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
22380   as_dirname=dirname
22381 else
22382   as_dirname=false
22383 fi
22384
22385 as_me=`$as_basename -- "$0" ||
22386 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22387          X"$0" : 'X\(//\)$' \| \
22388          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
22389 $as_echo X/"$0" |
22390     sed '/^.*\/\([^/][^/]*\)\/*$/{
22391             s//\1/
22392             q
22393           }
22394           /^X\/\(\/\/\)$/{
22395             s//\1/
22396             q
22397           }
22398           /^X\/\(\/\).*/{
22399             s//\1/
22400             q
22401           }
22402           s/.*/./; q'`
22403
22404 # Avoid depending upon Character Ranges.
22405 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22406 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22407 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22408 as_cr_digits='0123456789'
22409 as_cr_alnum=$as_cr_Letters$as_cr_digits
22410
22411 ECHO_C= ECHO_N= ECHO_T=
22412 case `echo -n x` in #(((((
22413 -n*)
22414   case `echo 'xy\c'` in
22415   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
22416   xy)  ECHO_C='\c';;
22417   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
22418        ECHO_T=' ';;
22419   esac;;
22420 *)
22421   ECHO_N='-n';;
22422 esac
22423
22424 rm -f conf$$ conf$$.exe conf$$.file
22425 if test -d conf$$.dir; then
22426   rm -f conf$$.dir/conf$$.file
22427 else
22428   rm -f conf$$.dir
22429   mkdir conf$$.dir 2>/dev/null
22430 fi
22431 if (echo >conf$$.file) 2>/dev/null; then
22432   if ln -s conf$$.file conf$$ 2>/dev/null; then
22433     as_ln_s='ln -s'
22434     # ... but there are two gotchas:
22435     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
22436     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22437     # In both cases, we have to default to `cp -pR'.
22438     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22439       as_ln_s='cp -pR'
22440   elif ln conf$$.file conf$$ 2>/dev/null; then
22441     as_ln_s=ln
22442   else
22443     as_ln_s='cp -pR'
22444   fi
22445 else
22446   as_ln_s='cp -pR'
22447 fi
22448 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
22449 rmdir conf$$.dir 2>/dev/null
22450
22451
22452 # as_fn_mkdir_p
22453 # -------------
22454 # Create "$as_dir" as a directory, including parents if necessary.
22455 as_fn_mkdir_p ()
22456 {
22457
22458   case $as_dir in #(
22459   -*) as_dir=./$as_dir;;
22460   esac
22461   test -d "$as_dir" || eval $as_mkdir_p || {
22462     as_dirs=
22463     while :; do
22464       case $as_dir in #(
22465       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
22466       *) as_qdir=$as_dir;;
22467       esac
22468       as_dirs="'$as_qdir' $as_dirs"
22469       as_dir=`$as_dirname -- "$as_dir" ||
22470 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22471          X"$as_dir" : 'X\(//\)[^/]' \| \
22472          X"$as_dir" : 'X\(//\)$' \| \
22473          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
22474 $as_echo X"$as_dir" |
22475     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22476             s//\1/
22477             q
22478           }
22479           /^X\(\/\/\)[^/].*/{
22480             s//\1/
22481             q
22482           }
22483           /^X\(\/\/\)$/{
22484             s//\1/
22485             q
22486           }
22487           /^X\(\/\).*/{
22488             s//\1/
22489             q
22490           }
22491           s/.*/./; q'`
22492       test -d "$as_dir" && break
22493     done
22494     test -z "$as_dirs" || eval "mkdir $as_dirs"
22495   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
22496
22497
22498 } # as_fn_mkdir_p
22499 if mkdir -p . 2>/dev/null; then
22500   as_mkdir_p='mkdir -p "$as_dir"'
22501 else
22502   test -d ./-p && rmdir ./-p
22503   as_mkdir_p=false
22504 fi
22505
22506
22507 # as_fn_executable_p FILE
22508 # -----------------------
22509 # Test if FILE is an executable regular file.
22510 as_fn_executable_p ()
22511 {
22512   test -f "$1" && test -x "$1"
22513 } # as_fn_executable_p
22514 as_test_x='test -x'
22515 as_executable_p=as_fn_executable_p
22516
22517 # Sed expression to map a string onto a valid CPP name.
22518 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
22519
22520 # Sed expression to map a string onto a valid variable name.
22521 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
22522
22523
22524 exec 6>&1
22525 ## ----------------------------------- ##
22526 ## Main body of $CONFIG_STATUS script. ##
22527 ## ----------------------------------- ##
22528 _ASEOF
22529 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
22530
22531 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22532 # Save the log message, to keep $0 and so on meaningful, and to
22533 # report actual input values of CONFIG_FILES etc. instead of their
22534 # values after options handling.
22535 ac_log="
22536 This file was extended by unbound $as_me 1.16.2, which was
22537 generated by GNU Autoconf 2.69.  Invocation command line was
22538
22539   CONFIG_FILES    = $CONFIG_FILES
22540   CONFIG_HEADERS  = $CONFIG_HEADERS
22541   CONFIG_LINKS    = $CONFIG_LINKS
22542   CONFIG_COMMANDS = $CONFIG_COMMANDS
22543   $ $0 $@
22544
22545 on `(hostname || uname -n) 2>/dev/null | sed 1q`
22546 "
22547
22548 _ACEOF
22549
22550 case $ac_config_files in *"
22551 "*) set x $ac_config_files; shift; ac_config_files=$*;;
22552 esac
22553
22554 case $ac_config_headers in *"
22555 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
22556 esac
22557
22558
22559 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22560 # Files that config.status was made for.
22561 config_files="$ac_config_files"
22562 config_headers="$ac_config_headers"
22563 config_commands="$ac_config_commands"
22564
22565 _ACEOF
22566
22567 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22568 ac_cs_usage="\
22569 \`$as_me' instantiates files and other configuration actions
22570 from templates according to the current configuration.  Unless the files
22571 and actions are specified as TAGs, all are instantiated by default.
22572
22573 Usage: $0 [OPTION]... [TAG]...
22574
22575   -h, --help       print this help, then exit
22576   -V, --version    print version number and configuration settings, then exit
22577       --config     print configuration, then exit
22578   -q, --quiet, --silent
22579                    do not print progress messages
22580   -d, --debug      don't remove temporary files
22581       --recheck    update $as_me by reconfiguring in the same conditions
22582       --file=FILE[:TEMPLATE]
22583                    instantiate the configuration file FILE
22584       --header=FILE[:TEMPLATE]
22585                    instantiate the configuration header FILE
22586
22587 Configuration files:
22588 $config_files
22589
22590 Configuration headers:
22591 $config_headers
22592
22593 Configuration commands:
22594 $config_commands
22595
22596 Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>."
22597
22598 _ACEOF
22599 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22600 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
22601 ac_cs_version="\\
22602 unbound config.status 1.16.2
22603 configured by $0, generated by GNU Autoconf 2.69,
22604   with options \\"\$ac_cs_config\\"
22605
22606 Copyright (C) 2012 Free Software Foundation, Inc.
22607 This config.status script is free software; the Free Software Foundation
22608 gives unlimited permission to copy, distribute and modify it."
22609
22610 ac_pwd='$ac_pwd'
22611 srcdir='$srcdir'
22612 AWK='$AWK'
22613 test -n "\$AWK" || AWK=awk
22614 _ACEOF
22615
22616 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22617 # The default lists apply if the user does not specify any file.
22618 ac_need_defaults=:
22619 while test $# != 0
22620 do
22621   case $1 in
22622   --*=?*)
22623     ac_option=`expr "X$1" : 'X\([^=]*\)='`
22624     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
22625     ac_shift=:
22626     ;;
22627   --*=)
22628     ac_option=`expr "X$1" : 'X\([^=]*\)='`
22629     ac_optarg=
22630     ac_shift=:
22631     ;;
22632   *)
22633     ac_option=$1
22634     ac_optarg=$2
22635     ac_shift=shift
22636     ;;
22637   esac
22638
22639   case $ac_option in
22640   # Handling of the options.
22641   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22642     ac_cs_recheck=: ;;
22643   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
22644     $as_echo "$ac_cs_version"; exit ;;
22645   --config | --confi | --conf | --con | --co | --c )
22646     $as_echo "$ac_cs_config"; exit ;;
22647   --debug | --debu | --deb | --de | --d | -d )
22648     debug=: ;;
22649   --file | --fil | --fi | --f )
22650     $ac_shift
22651     case $ac_optarg in
22652     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22653     '') as_fn_error $? "missing file argument" ;;
22654     esac
22655     as_fn_append CONFIG_FILES " '$ac_optarg'"
22656     ac_need_defaults=false;;
22657   --header | --heade | --head | --hea )
22658     $ac_shift
22659     case $ac_optarg in
22660     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22661     esac
22662     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
22663     ac_need_defaults=false;;
22664   --he | --h)
22665     # Conflict between --help and --header
22666     as_fn_error $? "ambiguous option: \`$1'
22667 Try \`$0 --help' for more information.";;
22668   --help | --hel | -h )
22669     $as_echo "$ac_cs_usage"; exit ;;
22670   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22671   | -silent | --silent | --silen | --sile | --sil | --si | --s)
22672     ac_cs_silent=: ;;
22673
22674   # This is an error.
22675   -*) as_fn_error $? "unrecognized option: \`$1'
22676 Try \`$0 --help' for more information." ;;
22677
22678   *) as_fn_append ac_config_targets " $1"
22679      ac_need_defaults=false ;;
22680
22681   esac
22682   shift
22683 done
22684
22685 ac_configure_extra_args=
22686
22687 if $ac_cs_silent; then
22688   exec 6>/dev/null
22689   ac_configure_extra_args="$ac_configure_extra_args --silent"
22690 fi
22691
22692 _ACEOF
22693 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22694 if \$ac_cs_recheck; then
22695   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22696   shift
22697   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
22698   CONFIG_SHELL='$SHELL'
22699   export CONFIG_SHELL
22700   exec "\$@"
22701 fi
22702
22703 _ACEOF
22704 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22705 exec 5>>config.log
22706 {
22707   echo
22708   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22709 ## Running $as_me. ##
22710 _ASBOX
22711   $as_echo "$ac_log"
22712 } >&5
22713
22714 _ACEOF
22715 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22716 #
22717 # INIT-COMMANDS
22718 #
22719
22720
22721 # The HP-UX ksh and POSIX shell print the target directory to stdout
22722 # if CDPATH is set.
22723 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22724
22725 sed_quote_subst='$sed_quote_subst'
22726 double_quote_subst='$double_quote_subst'
22727 delay_variable_subst='$delay_variable_subst'
22728 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
22729 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
22730 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
22731 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
22732 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
22733 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
22734 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
22735 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
22736 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
22737 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
22738 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
22739 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
22740 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
22741 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
22742 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
22743 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
22744 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
22745 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
22746 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
22747 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
22748 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
22749 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
22750 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
22751 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
22752 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
22753 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
22754 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
22755 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
22756 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
22757 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
22758 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
22759 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
22760 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
22761 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
22762 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
22763 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
22764 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
22765 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
22766 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
22767 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
22768 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
22769 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
22770 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
22771 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
22772 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
22773 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
22774 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22775 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22776 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
22777 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
22778 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
22779 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
22780 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
22781 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
22782 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
22783 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
22784 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
22785 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
22786 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"`'
22787 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
22788 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
22789 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
22790 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
22791 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
22792 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
22793 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
22794 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
22795 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
22796 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
22797 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
22798 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
22799 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
22800 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
22801 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
22802 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
22803 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
22804 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
22805 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
22806 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
22807 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22808 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
22809 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
22810 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
22811 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
22812 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
22813 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
22814 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22815 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
22816 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22817 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
22818 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22819 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
22820 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
22821 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
22822 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
22823 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
22824 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
22825 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
22826 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
22827 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
22828 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
22829 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
22830 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
22831 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
22832 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
22833 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
22834 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
22835 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
22836 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
22837 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
22838 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
22839 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
22840 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
22841 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
22842 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
22843 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
22844 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
22845 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
22846 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
22847 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
22848 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
22849 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22850 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22851 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
22852 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
22853 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
22854 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
22855 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
22856 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
22857 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
22858 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
22859 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
22860 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
22861 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
22862 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
22863
22864 LTCC='$LTCC'
22865 LTCFLAGS='$LTCFLAGS'
22866 compiler='$compiler_DEFAULT'
22867
22868 # A function that is used when there is no print builtin or printf.
22869 func_fallback_echo ()
22870 {
22871   eval 'cat <<_LTECHO_EOF
22872 \$1
22873 _LTECHO_EOF'
22874 }
22875
22876 # Quote evaled strings.
22877 for var in SHELL \
22878 ECHO \
22879 PATH_SEPARATOR \
22880 SED \
22881 GREP \
22882 EGREP \
22883 FGREP \
22884 LD \
22885 NM \
22886 LN_S \
22887 lt_SP2NL \
22888 lt_NL2SP \
22889 reload_flag \
22890 OBJDUMP \
22891 deplibs_check_method \
22892 file_magic_cmd \
22893 file_magic_glob \
22894 want_nocaseglob \
22895 DLLTOOL \
22896 sharedlib_from_linklib_cmd \
22897 AR \
22898 AR_FLAGS \
22899 archiver_list_spec \
22900 STRIP \
22901 RANLIB \
22902 CC \
22903 CFLAGS \
22904 compiler \
22905 lt_cv_sys_global_symbol_pipe \
22906 lt_cv_sys_global_symbol_to_cdecl \
22907 lt_cv_sys_global_symbol_to_import \
22908 lt_cv_sys_global_symbol_to_c_name_address \
22909 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
22910 lt_cv_nm_interface \
22911 nm_file_list_spec \
22912 lt_cv_truncate_bin \
22913 lt_prog_compiler_no_builtin_flag \
22914 lt_prog_compiler_pic \
22915 lt_prog_compiler_wl \
22916 lt_prog_compiler_static \
22917 lt_cv_prog_compiler_c_o \
22918 need_locks \
22919 MANIFEST_TOOL \
22920 DSYMUTIL \
22921 NMEDIT \
22922 LIPO \
22923 OTOOL \
22924 OTOOL64 \
22925 shrext_cmds \
22926 export_dynamic_flag_spec \
22927 whole_archive_flag_spec \
22928 compiler_needs_object \
22929 with_gnu_ld \
22930 allow_undefined_flag \
22931 no_undefined_flag \
22932 hardcode_libdir_flag_spec \
22933 hardcode_libdir_separator \
22934 exclude_expsyms \
22935 include_expsyms \
22936 file_list_spec \
22937 variables_saved_for_relink \
22938 libname_spec \
22939 library_names_spec \
22940 soname_spec \
22941 install_override_mode \
22942 finish_eval \
22943 old_striplib \
22944 striplib; do
22945     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
22946     *[\\\\\\\`\\"\\\$]*)
22947       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
22948       ;;
22949     *)
22950       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
22951       ;;
22952     esac
22953 done
22954
22955 # Double-quote double-evaled strings.
22956 for var in reload_cmds \
22957 old_postinstall_cmds \
22958 old_postuninstall_cmds \
22959 old_archive_cmds \
22960 extract_expsyms_cmds \
22961 old_archive_from_new_cmds \
22962 old_archive_from_expsyms_cmds \
22963 archive_cmds \
22964 archive_expsym_cmds \
22965 module_cmds \
22966 module_expsym_cmds \
22967 export_symbols_cmds \
22968 prelink_cmds \
22969 postlink_cmds \
22970 postinstall_cmds \
22971 postuninstall_cmds \
22972 finish_cmds \
22973 sys_lib_search_path_spec \
22974 configure_time_dlsearch_path \
22975 configure_time_lt_sys_library_path; do
22976     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
22977     *[\\\\\\\`\\"\\\$]*)
22978       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
22979       ;;
22980     *)
22981       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
22982       ;;
22983     esac
22984 done
22985
22986 ac_aux_dir='$ac_aux_dir'
22987
22988 # See if we are running on zsh, and set the options that allow our
22989 # commands through without removal of \ escapes INIT.
22990 if test -n "\${ZSH_VERSION+set}"; then
22991    setopt NO_GLOB_SUBST
22992 fi
22993
22994
22995     PACKAGE='$PACKAGE'
22996     VERSION='$VERSION'
22997     RM='$RM'
22998     ofile='$ofile'
22999
23000
23001
23002
23003 _ACEOF
23004
23005 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23006
23007 # Handling of arguments.
23008 for ac_config_target in $ac_config_targets
23009 do
23010   case $ac_config_target in
23011     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
23012     "disable-rpath") CONFIG_COMMANDS="$CONFIG_COMMANDS disable-rpath" ;;
23013     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23014     "doc/example.conf") CONFIG_FILES="$CONFIG_FILES doc/example.conf" ;;
23015     "doc/libunbound.3") CONFIG_FILES="$CONFIG_FILES doc/libunbound.3" ;;
23016     "doc/unbound.8") CONFIG_FILES="$CONFIG_FILES doc/unbound.8" ;;
23017     "doc/unbound-anchor.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-anchor.8" ;;
23018     "doc/unbound-checkconf.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-checkconf.8" ;;
23019     "doc/unbound.conf.5") CONFIG_FILES="$CONFIG_FILES doc/unbound.conf.5" ;;
23020     "doc/unbound-control.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-control.8" ;;
23021     "doc/unbound-host.1") CONFIG_FILES="$CONFIG_FILES doc/unbound-host.1" ;;
23022     "smallapp/unbound-control-setup.sh") CONFIG_FILES="$CONFIG_FILES smallapp/unbound-control-setup.sh" ;;
23023     "dnstap/dnstap_config.h") CONFIG_FILES="$CONFIG_FILES dnstap/dnstap_config.h" ;;
23024     "dnscrypt/dnscrypt_config.h") CONFIG_FILES="$CONFIG_FILES dnscrypt/dnscrypt_config.h" ;;
23025     "contrib/libunbound.pc") CONFIG_FILES="$CONFIG_FILES contrib/libunbound.pc" ;;
23026     "contrib/unbound.socket") CONFIG_FILES="$CONFIG_FILES contrib/unbound.socket" ;;
23027     "contrib/unbound.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound.service" ;;
23028     "contrib/unbound_portable.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound_portable.service" ;;
23029     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
23030
23031   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
23032   esac
23033 done
23034
23035
23036 # If the user did not use the arguments to specify the items to instantiate,
23037 # then the envvar interface is used.  Set only those that are not.
23038 # We use the long form for the default assignment because of an extremely
23039 # bizarre bug on SunOS 4.1.3.
23040 if $ac_need_defaults; then
23041   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23042   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23043   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23044 fi
23045
23046 # Have a temporary directory for convenience.  Make it in the build tree
23047 # simply because there is no reason against having it here, and in addition,
23048 # creating and moving files from /tmp can sometimes cause problems.
23049 # Hook for its removal unless debugging.
23050 # Note that there is a small window in which the directory will not be cleaned:
23051 # after its creation but before its name has been assigned to `$tmp'.
23052 $debug ||
23053 {
23054   tmp= ac_tmp=
23055   trap 'exit_status=$?
23056   : "${ac_tmp:=$tmp}"
23057   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
23058 ' 0
23059   trap 'as_fn_exit 1' 1 2 13 15
23060 }
23061 # Create a (secure) tmp directory for tmp files.
23062
23063 {
23064   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
23065   test -d "$tmp"
23066 }  ||
23067 {
23068   tmp=./conf$$-$RANDOM
23069   (umask 077 && mkdir "$tmp")
23070 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
23071 ac_tmp=$tmp
23072
23073 # Set up the scripts for CONFIG_FILES section.
23074 # No need to generate them if there are no CONFIG_FILES.
23075 # This happens for instance with `./config.status config.h'.
23076 if test -n "$CONFIG_FILES"; then
23077
23078
23079 ac_cr=`echo X | tr X '\015'`
23080 # On cygwin, bash can eat \r inside `` if the user requested igncr.
23081 # But we know of no other shell where ac_cr would be empty at this
23082 # point, so we can use a bashism as a fallback.
23083 if test "x$ac_cr" = x; then
23084   eval ac_cr=\$\'\\r\'
23085 fi
23086 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
23087 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
23088   ac_cs_awk_cr='\\r'
23089 else
23090   ac_cs_awk_cr=$ac_cr
23091 fi
23092
23093 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
23094 _ACEOF
23095
23096
23097 {
23098   echo "cat >conf$$subs.awk <<_ACEOF" &&
23099   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
23100   echo "_ACEOF"
23101 } >conf$$subs.sh ||
23102   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23103 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
23104 ac_delim='%!_!# '
23105 for ac_last_try in false false false false false :; do
23106   . ./conf$$subs.sh ||
23107     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23108
23109   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
23110   if test $ac_delim_n = $ac_delim_num; then
23111     break
23112   elif $ac_last_try; then
23113     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
23114   else
23115     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23116   fi
23117 done
23118 rm -f conf$$subs.sh
23119
23120 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23121 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
23122 _ACEOF
23123 sed -n '
23124 h
23125 s/^/S["/; s/!.*/"]=/
23126 p
23127 g
23128 s/^[^!]*!//
23129 :repl
23130 t repl
23131 s/'"$ac_delim"'$//
23132 t delim
23133 :nl
23134 h
23135 s/\(.\{148\}\)..*/\1/
23136 t more1
23137 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
23138 p
23139 n
23140 b repl
23141 :more1
23142 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23143 p
23144 g
23145 s/.\{148\}//
23146 t nl
23147 :delim
23148 h
23149 s/\(.\{148\}\)..*/\1/
23150 t more2
23151 s/["\\]/\\&/g; s/^/"/; s/$/"/
23152 p
23153 b
23154 :more2
23155 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23156 p
23157 g
23158 s/.\{148\}//
23159 t delim
23160 ' <conf$$subs.awk | sed '
23161 /^[^""]/{
23162   N
23163   s/\n//
23164 }
23165 ' >>$CONFIG_STATUS || ac_write_fail=1
23166 rm -f conf$$subs.awk
23167 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23168 _ACAWK
23169 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
23170   for (key in S) S_is_set[key] = 1
23171   FS = "\a"
23172
23173 }
23174 {
23175   line = $ 0
23176   nfields = split(line, field, "@")
23177   substed = 0
23178   len = length(field[1])
23179   for (i = 2; i < nfields; i++) {
23180     key = field[i]
23181     keylen = length(key)
23182     if (S_is_set[key]) {
23183       value = S[key]
23184       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
23185       len += length(value) + length(field[++i])
23186       substed = 1
23187     } else
23188       len += 1 + keylen
23189   }
23190
23191   print line
23192 }
23193
23194 _ACAWK
23195 _ACEOF
23196 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23197 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
23198   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
23199 else
23200   cat
23201 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
23202   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
23203 _ACEOF
23204
23205 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
23206 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
23207 # trailing colons and then remove the whole line if VPATH becomes empty
23208 # (actually we leave an empty line to preserve line numbers).
23209 if test "x$srcdir" = x.; then
23210   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
23211 h
23212 s///
23213 s/^/:/
23214 s/[      ]*$/:/
23215 s/:\$(srcdir):/:/g
23216 s/:\${srcdir}:/:/g
23217 s/:@srcdir@:/:/g
23218 s/^:*//
23219 s/:*$//
23220 x
23221 s/\(=[   ]*\).*/\1/
23222 G
23223 s/\n//
23224 s/^[^=]*=[       ]*$//
23225 }'
23226 fi
23227
23228 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23229 fi # test -n "$CONFIG_FILES"
23230
23231 # Set up the scripts for CONFIG_HEADERS section.
23232 # No need to generate them if there are no CONFIG_HEADERS.
23233 # This happens for instance with `./config.status Makefile'.
23234 if test -n "$CONFIG_HEADERS"; then
23235 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
23236 BEGIN {
23237 _ACEOF
23238
23239 # Transform confdefs.h into an awk script `defines.awk', embedded as
23240 # here-document in config.status, that substitutes the proper values into
23241 # config.h.in to produce config.h.
23242
23243 # Create a delimiter string that does not exist in confdefs.h, to ease
23244 # handling of long lines.
23245 ac_delim='%!_!# '
23246 for ac_last_try in false false :; do
23247   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
23248   if test -z "$ac_tt"; then
23249     break
23250   elif $ac_last_try; then
23251     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
23252   else
23253     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23254   fi
23255 done
23256
23257 # For the awk script, D is an array of macro values keyed by name,
23258 # likewise P contains macro parameters if any.  Preserve backslash
23259 # newline sequences.
23260
23261 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
23262 sed -n '
23263 s/.\{148\}/&'"$ac_delim"'/g
23264 t rset
23265 :rset
23266 s/^[     ]*#[    ]*define[       ][      ]*/ /
23267 t def
23268 d
23269 :def
23270 s/\\$//
23271 t bsnl
23272 s/["\\]/\\&/g
23273 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
23274 D["\1"]=" \3"/p
23275 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
23276 d
23277 :bsnl
23278 s/["\\]/\\&/g
23279 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
23280 D["\1"]=" \3\\\\\\n"\\/p
23281 t cont
23282 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
23283 t cont
23284 d
23285 :cont
23286 n
23287 s/.\{148\}/&'"$ac_delim"'/g
23288 t clear
23289 :clear
23290 s/\\$//
23291 t bsnlc
23292 s/["\\]/\\&/g; s/^/"/; s/$/"/p
23293 d
23294 :bsnlc
23295 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
23296 b cont
23297 ' <confdefs.h | sed '
23298 s/'"$ac_delim"'/"\\\
23299 "/g' >>$CONFIG_STATUS || ac_write_fail=1
23300
23301 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23302   for (key in D) D_is_set[key] = 1
23303   FS = "\a"
23304 }
23305 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
23306   line = \$ 0
23307   split(line, arg, " ")
23308   if (arg[1] == "#") {
23309     defundef = arg[2]
23310     mac1 = arg[3]
23311   } else {
23312     defundef = substr(arg[1], 2)
23313     mac1 = arg[2]
23314   }
23315   split(mac1, mac2, "(") #)
23316   macro = mac2[1]
23317   prefix = substr(line, 1, index(line, defundef) - 1)
23318   if (D_is_set[macro]) {
23319     # Preserve the white space surrounding the "#".
23320     print prefix "define", macro P[macro] D[macro]
23321     next
23322   } else {
23323     # Replace #undef with comments.  This is necessary, for example,
23324     # in the case of _POSIX_SOURCE, which is predefined and required
23325     # on some systems where configure will not decide to define it.
23326     if (defundef == "undef") {
23327       print "/*", prefix defundef, macro, "*/"
23328       next
23329     }
23330   }
23331 }
23332 { print }
23333 _ACAWK
23334 _ACEOF
23335 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23336   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
23337 fi # test -n "$CONFIG_HEADERS"
23338
23339
23340 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
23341 shift
23342 for ac_tag
23343 do
23344   case $ac_tag in
23345   :[FHLC]) ac_mode=$ac_tag; continue;;
23346   esac
23347   case $ac_mode$ac_tag in
23348   :[FHL]*:*);;
23349   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
23350   :[FH]-) ac_tag=-:-;;
23351   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
23352   esac
23353   ac_save_IFS=$IFS
23354   IFS=:
23355   set x $ac_tag
23356   IFS=$ac_save_IFS
23357   shift
23358   ac_file=$1
23359   shift
23360
23361   case $ac_mode in
23362   :L) ac_source=$1;;
23363   :[FH])
23364     ac_file_inputs=
23365     for ac_f
23366     do
23367       case $ac_f in
23368       -) ac_f="$ac_tmp/stdin";;
23369       *) # Look for the file first in the build tree, then in the source tree
23370          # (if the path is not absolute).  The absolute path cannot be DOS-style,
23371          # because $ac_f cannot contain `:'.
23372          test -f "$ac_f" ||
23373            case $ac_f in
23374            [\\/$]*) false;;
23375            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
23376            esac ||
23377            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
23378       esac
23379       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
23380       as_fn_append ac_file_inputs " '$ac_f'"
23381     done
23382
23383     # Let's still pretend it is `configure' which instantiates (i.e., don't
23384     # use $as_me), people would be surprised to read:
23385     #    /* config.h.  Generated by config.status.  */
23386     configure_input='Generated from '`
23387           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
23388         `' by configure.'
23389     if test x"$ac_file" != x-; then
23390       configure_input="$ac_file.  $configure_input"
23391       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
23392 $as_echo "$as_me: creating $ac_file" >&6;}
23393     fi
23394     # Neutralize special characters interpreted by sed in replacement strings.
23395     case $configure_input in #(
23396     *\&* | *\|* | *\\* )
23397        ac_sed_conf_input=`$as_echo "$configure_input" |
23398        sed 's/[\\\\&|]/\\\\&/g'`;; #(
23399     *) ac_sed_conf_input=$configure_input;;
23400     esac
23401
23402     case $ac_tag in
23403     *:-:* | *:-) cat >"$ac_tmp/stdin" \
23404       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
23405     esac
23406     ;;
23407   esac
23408
23409   ac_dir=`$as_dirname -- "$ac_file" ||
23410 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23411          X"$ac_file" : 'X\(//\)[^/]' \| \
23412          X"$ac_file" : 'X\(//\)$' \| \
23413          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
23414 $as_echo X"$ac_file" |
23415     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23416             s//\1/
23417             q
23418           }
23419           /^X\(\/\/\)[^/].*/{
23420             s//\1/
23421             q
23422           }
23423           /^X\(\/\/\)$/{
23424             s//\1/
23425             q
23426           }
23427           /^X\(\/\).*/{
23428             s//\1/
23429             q
23430           }
23431           s/.*/./; q'`
23432   as_dir="$ac_dir"; as_fn_mkdir_p
23433   ac_builddir=.
23434
23435 case "$ac_dir" in
23436 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
23437 *)
23438   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
23439   # A ".." for each directory in $ac_dir_suffix.
23440   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
23441   case $ac_top_builddir_sub in
23442   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
23443   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
23444   esac ;;
23445 esac
23446 ac_abs_top_builddir=$ac_pwd
23447 ac_abs_builddir=$ac_pwd$ac_dir_suffix
23448 # for backward compatibility:
23449 ac_top_builddir=$ac_top_build_prefix
23450
23451 case $srcdir in
23452   .)  # We are building in place.
23453     ac_srcdir=.
23454     ac_top_srcdir=$ac_top_builddir_sub
23455     ac_abs_top_srcdir=$ac_pwd ;;
23456   [\\/]* | ?:[\\/]* )  # Absolute name.
23457     ac_srcdir=$srcdir$ac_dir_suffix;
23458     ac_top_srcdir=$srcdir
23459     ac_abs_top_srcdir=$srcdir ;;
23460   *) # Relative name.
23461     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
23462     ac_top_srcdir=$ac_top_build_prefix$srcdir
23463     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
23464 esac
23465 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
23466
23467
23468   case $ac_mode in
23469   :F)
23470   #
23471   # CONFIG_FILE
23472   #
23473
23474 _ACEOF
23475
23476 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23477 # If the template does not know about datarootdir, expand it.
23478 # FIXME: This hack should be removed a few years after 2.60.
23479 ac_datarootdir_hack=; ac_datarootdir_seen=
23480 ac_sed_dataroot='
23481 /datarootdir/ {
23482   p
23483   q
23484 }
23485 /@datadir@/p
23486 /@docdir@/p
23487 /@infodir@/p
23488 /@localedir@/p
23489 /@mandir@/p'
23490 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
23491 *datarootdir*) ac_datarootdir_seen=yes;;
23492 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
23493   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
23494 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
23495 _ACEOF
23496 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23497   ac_datarootdir_hack='
23498   s&@datadir@&$datadir&g
23499   s&@docdir@&$docdir&g
23500   s&@infodir@&$infodir&g
23501   s&@localedir@&$localedir&g
23502   s&@mandir@&$mandir&g
23503   s&\\\${datarootdir}&$datarootdir&g' ;;
23504 esac
23505 _ACEOF
23506
23507 # Neutralize VPATH when `$srcdir' = `.'.
23508 # Shell code in configure.ac might set extrasub.
23509 # FIXME: do we really want to maintain this feature?
23510 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23511 ac_sed_extra="$ac_vpsub
23512 $extrasub
23513 _ACEOF
23514 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23515 :t
23516 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23517 s|@configure_input@|$ac_sed_conf_input|;t t
23518 s&@top_builddir@&$ac_top_builddir_sub&;t t
23519 s&@top_build_prefix@&$ac_top_build_prefix&;t t
23520 s&@srcdir@&$ac_srcdir&;t t
23521 s&@abs_srcdir@&$ac_abs_srcdir&;t t
23522 s&@top_srcdir@&$ac_top_srcdir&;t t
23523 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
23524 s&@builddir@&$ac_builddir&;t t
23525 s&@abs_builddir@&$ac_abs_builddir&;t t
23526 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
23527 $ac_datarootdir_hack
23528 "
23529 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
23530   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23531
23532 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
23533   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
23534   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
23535       "$ac_tmp/out"`; test -z "$ac_out"; } &&
23536   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23537 which seems to be undefined.  Please make sure it is defined" >&5
23538 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23539 which seems to be undefined.  Please make sure it is defined" >&2;}
23540
23541   rm -f "$ac_tmp/stdin"
23542   case $ac_file in
23543   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
23544   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
23545   esac \
23546   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23547  ;;
23548   :H)
23549   #
23550   # CONFIG_HEADER
23551   #
23552   if test x"$ac_file" != x-; then
23553     {
23554       $as_echo "/* $configure_input  */" \
23555       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
23556     } >"$ac_tmp/config.h" \
23557       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23558     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
23559       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
23560 $as_echo "$as_me: $ac_file is unchanged" >&6;}
23561     else
23562       rm -f "$ac_file"
23563       mv "$ac_tmp/config.h" "$ac_file" \
23564         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23565     fi
23566   else
23567     $as_echo "/* $configure_input  */" \
23568       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
23569       || as_fn_error $? "could not create -" "$LINENO" 5
23570   fi
23571  ;;
23572
23573   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
23574 $as_echo "$as_me: executing $ac_file commands" >&6;}
23575  ;;
23576   esac
23577
23578
23579   case $ac_file$ac_mode in
23580     "libtool":C)
23581
23582     # See if we are running on zsh, and set the options that allow our
23583     # commands through without removal of \ escapes.
23584     if test -n "${ZSH_VERSION+set}"; then
23585       setopt NO_GLOB_SUBST
23586     fi
23587
23588     cfgfile=${ofile}T
23589     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
23590     $RM "$cfgfile"
23591
23592     cat <<_LT_EOF >> "$cfgfile"
23593 #! $SHELL
23594 # Generated automatically by $as_me ($PACKAGE) $VERSION
23595 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
23596 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
23597
23598 # Provide generalized library-building support services.
23599 # Written by Gordon Matzigkeit, 1996
23600
23601 # Copyright (C) 2014 Free Software Foundation, Inc.
23602 # This is free software; see the source for copying conditions.  There is NO
23603 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
23604
23605 # GNU Libtool is free software; you can redistribute it and/or modify
23606 # it under the terms of the GNU General Public License as published by
23607 # the Free Software Foundation; either version 2 of of the License, or
23608 # (at your option) any later version.
23609 #
23610 # As a special exception to the GNU General Public License, if you
23611 # distribute this file as part of a program or library that is built
23612 # using GNU Libtool, you may include this file under the  same
23613 # distribution terms that you use for the rest of that program.
23614 #
23615 # GNU Libtool is distributed in the hope that it will be useful, but
23616 # WITHOUT ANY WARRANTY; without even the implied warranty of
23617 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23618 # GNU General Public License for more details.
23619 #
23620 # You should have received a copy of the GNU General Public License
23621 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
23622
23623
23624 # The names of the tagged configurations supported by this script.
23625 available_tags=''
23626
23627 # Configured defaults for sys_lib_dlsearch_path munging.
23628 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
23629
23630 # ### BEGIN LIBTOOL CONFIG
23631
23632 # Which release of libtool.m4 was used?
23633 macro_version=$macro_version
23634 macro_revision=$macro_revision
23635
23636 # Whether or not to build shared libraries.
23637 build_libtool_libs=$enable_shared
23638
23639 # Whether or not to build static libraries.
23640 build_old_libs=$enable_static
23641
23642 # What type of objects to build.
23643 pic_mode=$pic_mode
23644
23645 # Whether or not to optimize for fast installation.
23646 fast_install=$enable_fast_install
23647
23648 # Shared archive member basename,for filename based shared library versioning on AIX.
23649 shared_archive_member_spec=$shared_archive_member_spec
23650
23651 # Shell to use when invoking shell scripts.
23652 SHELL=$lt_SHELL
23653
23654 # An echo program that protects backslashes.
23655 ECHO=$lt_ECHO
23656
23657 # The PATH separator for the build system.
23658 PATH_SEPARATOR=$lt_PATH_SEPARATOR
23659
23660 # The host system.
23661 host_alias=$host_alias
23662 host=$host
23663 host_os=$host_os
23664
23665 # The build system.
23666 build_alias=$build_alias
23667 build=$build
23668 build_os=$build_os
23669
23670 # A sed program that does not truncate output.
23671 SED=$lt_SED
23672
23673 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
23674 Xsed="\$SED -e 1s/^X//"
23675
23676 # A grep program that handles long lines.
23677 GREP=$lt_GREP
23678
23679 # An ERE matcher.
23680 EGREP=$lt_EGREP
23681
23682 # A literal string matcher.
23683 FGREP=$lt_FGREP
23684
23685 # A BSD- or MS-compatible name lister.
23686 NM=$lt_NM
23687
23688 # Whether we need soft or hard links.
23689 LN_S=$lt_LN_S
23690
23691 # What is the maximum length of a command?
23692 max_cmd_len=$max_cmd_len
23693
23694 # Object file suffix (normally "o").
23695 objext=$ac_objext
23696
23697 # Executable file suffix (normally "").
23698 exeext=$exeext
23699
23700 # whether the shell understands "unset".
23701 lt_unset=$lt_unset
23702
23703 # turn spaces into newlines.
23704 SP2NL=$lt_lt_SP2NL
23705
23706 # turn newlines into spaces.
23707 NL2SP=$lt_lt_NL2SP
23708
23709 # convert \$build file names to \$host format.
23710 to_host_file_cmd=$lt_cv_to_host_file_cmd
23711
23712 # convert \$build files to toolchain format.
23713 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
23714
23715 # An object symbol dumper.
23716 OBJDUMP=$lt_OBJDUMP
23717
23718 # Method to check whether dependent libraries are shared objects.
23719 deplibs_check_method=$lt_deplibs_check_method
23720
23721 # Command to use when deplibs_check_method = "file_magic".
23722 file_magic_cmd=$lt_file_magic_cmd
23723
23724 # How to find potential files when deplibs_check_method = "file_magic".
23725 file_magic_glob=$lt_file_magic_glob
23726
23727 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
23728 want_nocaseglob=$lt_want_nocaseglob
23729
23730 # DLL creation program.
23731 DLLTOOL=$lt_DLLTOOL
23732
23733 # Command to associate shared and link libraries.
23734 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
23735
23736 # The archiver.
23737 AR=$lt_AR
23738
23739 # Flags to create an archive.
23740 AR_FLAGS=$lt_AR_FLAGS
23741
23742 # How to feed a file listing to the archiver.
23743 archiver_list_spec=$lt_archiver_list_spec
23744
23745 # A symbol stripping program.
23746 STRIP=$lt_STRIP
23747
23748 # Commands used to install an old-style archive.
23749 RANLIB=$lt_RANLIB
23750 old_postinstall_cmds=$lt_old_postinstall_cmds
23751 old_postuninstall_cmds=$lt_old_postuninstall_cmds
23752
23753 # Whether to use a lock for old archive extraction.
23754 lock_old_archive_extraction=$lock_old_archive_extraction
23755
23756 # A C compiler.
23757 LTCC=$lt_CC
23758
23759 # LTCC compiler flags.
23760 LTCFLAGS=$lt_CFLAGS
23761
23762 # Take the output of nm and produce a listing of raw symbols and C names.
23763 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
23764
23765 # Transform the output of nm in a proper C declaration.
23766 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
23767
23768 # Transform the output of nm into a list of symbols to manually relocate.
23769 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
23770
23771 # Transform the output of nm in a C name address pair.
23772 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
23773
23774 # Transform the output of nm in a C name address pair when lib prefix is needed.
23775 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
23776
23777 # The name lister interface.
23778 nm_interface=$lt_lt_cv_nm_interface
23779
23780 # Specify filename containing input files for \$NM.
23781 nm_file_list_spec=$lt_nm_file_list_spec
23782
23783 # The root where to search for dependent libraries,and where our libraries should be installed.
23784 lt_sysroot=$lt_sysroot
23785
23786 # Command to truncate a binary pipe.
23787 lt_truncate_bin=$lt_lt_cv_truncate_bin
23788
23789 # The name of the directory that contains temporary libtool files.
23790 objdir=$objdir
23791
23792 # Used to examine libraries when file_magic_cmd begins with "file".
23793 MAGIC_CMD=$MAGIC_CMD
23794
23795 # Must we lock files when doing compilation?
23796 need_locks=$lt_need_locks
23797
23798 # Manifest tool.
23799 MANIFEST_TOOL=$lt_MANIFEST_TOOL
23800
23801 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
23802 DSYMUTIL=$lt_DSYMUTIL
23803
23804 # Tool to change global to local symbols on Mac OS X.
23805 NMEDIT=$lt_NMEDIT
23806
23807 # Tool to manipulate fat objects and archives on Mac OS X.
23808 LIPO=$lt_LIPO
23809
23810 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
23811 OTOOL=$lt_OTOOL
23812
23813 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
23814 OTOOL64=$lt_OTOOL64
23815
23816 # Old archive suffix (normally "a").
23817 libext=$libext
23818
23819 # Shared library suffix (normally ".so").
23820 shrext_cmds=$lt_shrext_cmds
23821
23822 # The commands to extract the exported symbol list from a shared archive.
23823 extract_expsyms_cmds=$lt_extract_expsyms_cmds
23824
23825 # Variables whose values should be saved in libtool wrapper scripts and
23826 # restored at link time.
23827 variables_saved_for_relink=$lt_variables_saved_for_relink
23828
23829 # Do we need the "lib" prefix for modules?
23830 need_lib_prefix=$need_lib_prefix
23831
23832 # Do we need a version for libraries?
23833 need_version=$need_version
23834
23835 # Library versioning type.
23836 version_type=$version_type
23837
23838 # Shared library runtime path variable.
23839 runpath_var=$runpath_var
23840
23841 # Shared library path variable.
23842 shlibpath_var=$shlibpath_var
23843
23844 # Is shlibpath searched before the hard-coded library search path?
23845 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
23846
23847 # Format of library name prefix.
23848 libname_spec=$lt_libname_spec
23849
23850 # List of archive names.  First name is the real one, the rest are links.
23851 # The last name is the one that the linker finds with -lNAME
23852 library_names_spec=$lt_library_names_spec
23853
23854 # The coded name of the library, if different from the real name.
23855 soname_spec=$lt_soname_spec
23856
23857 # Permission mode override for installation of shared libraries.
23858 install_override_mode=$lt_install_override_mode
23859
23860 # Command to use after installation of a shared archive.
23861 postinstall_cmds=$lt_postinstall_cmds
23862
23863 # Command to use after uninstallation of a shared archive.
23864 postuninstall_cmds=$lt_postuninstall_cmds
23865
23866 # Commands used to finish a libtool library installation in a directory.
23867 finish_cmds=$lt_finish_cmds
23868
23869 # As "finish_cmds", except a single script fragment to be evaled but
23870 # not shown.
23871 finish_eval=$lt_finish_eval
23872
23873 # Whether we should hardcode library paths into libraries.
23874 hardcode_into_libs=$hardcode_into_libs
23875
23876 # Compile-time system search path for libraries.
23877 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
23878
23879 # Detected run-time system search path for libraries.
23880 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
23881
23882 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
23883 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
23884
23885 # Whether dlopen is supported.
23886 dlopen_support=$enable_dlopen
23887
23888 # Whether dlopen of programs is supported.
23889 dlopen_self=$enable_dlopen_self
23890
23891 # Whether dlopen of statically linked programs is supported.
23892 dlopen_self_static=$enable_dlopen_self_static
23893
23894 # Commands to strip libraries.
23895 old_striplib=$lt_old_striplib
23896 striplib=$lt_striplib
23897
23898
23899 # The linker used to build libraries.
23900 LD=$lt_LD
23901
23902 # How to create reloadable object files.
23903 reload_flag=$lt_reload_flag
23904 reload_cmds=$lt_reload_cmds
23905
23906 # Commands used to build an old-style archive.
23907 old_archive_cmds=$lt_old_archive_cmds
23908
23909 # A language specific compiler.
23910 CC=$lt_compiler
23911
23912 # Is the compiler the GNU compiler?
23913 with_gcc=$GCC
23914
23915 # Compiler flag to turn off builtin functions.
23916 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
23917
23918 # Additional compiler flags for building library objects.
23919 pic_flag=$lt_lt_prog_compiler_pic
23920
23921 # How to pass a linker flag through the compiler.
23922 wl=$lt_lt_prog_compiler_wl
23923
23924 # Compiler flag to prevent dynamic linking.
23925 link_static_flag=$lt_lt_prog_compiler_static
23926
23927 # Does compiler simultaneously support -c and -o options?
23928 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
23929
23930 # Whether or not to add -lc for building shared libraries.
23931 build_libtool_need_lc=$archive_cmds_need_lc
23932
23933 # Whether or not to disallow shared libs when runtime libs are static.
23934 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
23935
23936 # Compiler flag to allow reflexive dlopens.
23937 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
23938
23939 # Compiler flag to generate shared objects directly from archives.
23940 whole_archive_flag_spec=$lt_whole_archive_flag_spec
23941
23942 # Whether the compiler copes with passing no objects directly.
23943 compiler_needs_object=$lt_compiler_needs_object
23944
23945 # Create an old-style archive from a shared archive.
23946 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
23947
23948 # Create a temporary old-style archive to link instead of a shared archive.
23949 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
23950
23951 # Commands used to build a shared archive.
23952 archive_cmds=$lt_archive_cmds
23953 archive_expsym_cmds=$lt_archive_expsym_cmds
23954
23955 # Commands used to build a loadable module if different from building
23956 # a shared archive.
23957 module_cmds=$lt_module_cmds
23958 module_expsym_cmds=$lt_module_expsym_cmds
23959
23960 # Whether we are building with GNU ld or not.
23961 with_gnu_ld=$lt_with_gnu_ld
23962
23963 # Flag that allows shared libraries with undefined symbols to be built.
23964 allow_undefined_flag=$lt_allow_undefined_flag
23965
23966 # Flag that enforces no undefined symbols.
23967 no_undefined_flag=$lt_no_undefined_flag
23968
23969 # Flag to hardcode \$libdir into a binary during linking.
23970 # This must work even if \$libdir does not exist
23971 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
23972
23973 # Whether we need a single "-rpath" flag with a separated argument.
23974 hardcode_libdir_separator=$lt_hardcode_libdir_separator
23975
23976 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
23977 # DIR into the resulting binary.
23978 hardcode_direct=$hardcode_direct
23979
23980 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
23981 # DIR into the resulting binary and the resulting library dependency is
23982 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
23983 # library is relocated.
23984 hardcode_direct_absolute=$hardcode_direct_absolute
23985
23986 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
23987 # into the resulting binary.
23988 hardcode_minus_L=$hardcode_minus_L
23989
23990 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
23991 # into the resulting binary.
23992 hardcode_shlibpath_var=$hardcode_shlibpath_var
23993
23994 # Set to "yes" if building a shared library automatically hardcodes DIR
23995 # into the library and all subsequent libraries and executables linked
23996 # against it.
23997 hardcode_automatic=$hardcode_automatic
23998
23999 # Set to yes if linker adds runtime paths of dependent libraries
24000 # to runtime path list.
24001 inherit_rpath=$inherit_rpath
24002
24003 # Whether libtool must link a program against all its dependency libraries.
24004 link_all_deplibs=$link_all_deplibs
24005
24006 # Set to "yes" if exported symbols are required.
24007 always_export_symbols=$always_export_symbols
24008
24009 # The commands to list exported symbols.
24010 export_symbols_cmds=$lt_export_symbols_cmds
24011
24012 # Symbols that should not be listed in the preloaded symbols.
24013 exclude_expsyms=$lt_exclude_expsyms
24014
24015 # Symbols that must always be exported.
24016 include_expsyms=$lt_include_expsyms
24017
24018 # Commands necessary for linking programs (against libraries) with templates.
24019 prelink_cmds=$lt_prelink_cmds
24020
24021 # Commands necessary for finishing linking programs.
24022 postlink_cmds=$lt_postlink_cmds
24023
24024 # Specify filename containing input files.
24025 file_list_spec=$lt_file_list_spec
24026
24027 # How to hardcode a shared library path into an executable.
24028 hardcode_action=$hardcode_action
24029
24030 # ### END LIBTOOL CONFIG
24031
24032 _LT_EOF
24033
24034     cat <<'_LT_EOF' >> "$cfgfile"
24035
24036 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
24037
24038 # func_munge_path_list VARIABLE PATH
24039 # -----------------------------------
24040 # VARIABLE is name of variable containing _space_ separated list of
24041 # directories to be munged by the contents of PATH, which is string
24042 # having a format:
24043 # "DIR[:DIR]:"
24044 #       string "DIR[ DIR]" will be prepended to VARIABLE
24045 # ":DIR[:DIR]"
24046 #       string "DIR[ DIR]" will be appended to VARIABLE
24047 # "DIRP[:DIRP]::[DIRA:]DIRA"
24048 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
24049 #       "DIRA[ DIRA]" will be appended to VARIABLE
24050 # "DIR[:DIR]"
24051 #       VARIABLE will be replaced by "DIR[ DIR]"
24052 func_munge_path_list ()
24053 {
24054     case x$2 in
24055     x)
24056         ;;
24057     *:)
24058         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
24059         ;;
24060     x:*)
24061         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
24062         ;;
24063     *::*)
24064         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
24065         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
24066         ;;
24067     *)
24068         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
24069         ;;
24070     esac
24071 }
24072
24073
24074 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
24075 func_cc_basename ()
24076 {
24077     for cc_temp in $*""; do
24078       case $cc_temp in
24079         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
24080         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
24081         \-*) ;;
24082         *) break;;
24083       esac
24084     done
24085     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
24086 }
24087
24088
24089 # ### END FUNCTIONS SHARED WITH CONFIGURE
24090
24091 _LT_EOF
24092
24093   case $host_os in
24094   aix3*)
24095     cat <<\_LT_EOF >> "$cfgfile"
24096 # AIX sometimes has problems with the GCC collect2 program.  For some
24097 # reason, if we set the COLLECT_NAMES environment variable, the problems
24098 # vanish in a puff of smoke.
24099 if test set != "${COLLECT_NAMES+set}"; then
24100   COLLECT_NAMES=
24101   export COLLECT_NAMES
24102 fi
24103 _LT_EOF
24104     ;;
24105   esac
24106
24107
24108 ltmain=$ac_aux_dir/ltmain.sh
24109
24110
24111   # We use sed instead of cat because bash on DJGPP gets confused if
24112   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
24113   # text mode, it properly converts lines to CR/LF.  This bash problem
24114   # is reportedly fixed, but why not run on old versions too?
24115   sed '$q' "$ltmain" >> "$cfgfile" \
24116      || (rm -f "$cfgfile"; exit 1)
24117
24118    mv -f "$cfgfile" "$ofile" ||
24119     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
24120   chmod +x "$ofile"
24121
24122  ;;
24123     "disable-rpath":C)
24124         sed < libtool > libtool-2 \
24125         's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_RPATH_SED__ "/'
24126         mv libtool-2 libtool
24127         chmod 755 libtool
24128         libtool="./libtool"
24129          ;;
24130
24131   esac
24132 done # for ac_tag
24133
24134
24135 as_fn_exit 0
24136 _ACEOF
24137 ac_clean_files=$ac_clean_files_save
24138
24139 test $ac_write_fail = 0 ||
24140   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
24141
24142
24143 # configure is writing to config.log, and then calls config.status.
24144 # config.status does its own redirection, appending to config.log.
24145 # Unfortunately, on DOS this fails, as config.log is still kept open
24146 # by configure, so config.status won't be able to write to it; its
24147 # output is simply discarded.  So we exec the FD to /dev/null,
24148 # effectively closing config.log, so it can be properly (re)opened and
24149 # appended to by config.status.  When coming back to configure, we
24150 # need to make the FD available again.
24151 if test "$no_create" != yes; then
24152   ac_cs_success=:
24153   ac_config_status_args=
24154   test "$silent" = yes &&
24155     ac_config_status_args="$ac_config_status_args --quiet"
24156   exec 5>/dev/null
24157   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24158   exec 5>>config.log
24159   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24160   # would make configure fail if this is the last instruction.
24161   $ac_cs_success || as_fn_exit 1
24162 fi
24163 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24164   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24165 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
24166 fi
24167