]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/unbound/configure
Upgrade Unbound to 1.6.3. More to follow.
[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.6.3.
4 #
5 # Report bugs to <unbound-bugs@nlnetlabs.nl>.
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 about your system, including
279 $0: any error possibly output before this message. Then
280 $0: install a modern shell, or manually run the script
281 $0: under such a shell if you do have one."
282   fi
283   exit 1
284 fi
285 fi
286 fi
287 SHELL=${CONFIG_SHELL-/bin/sh}
288 export SHELL
289 # Unset more variables known to interfere with behavior of common tools.
290 CLICOLOR_FORCE= GREP_OPTIONS=
291 unset CLICOLOR_FORCE GREP_OPTIONS
292
293 ## --------------------- ##
294 ## M4sh Shell Functions. ##
295 ## --------------------- ##
296 # as_fn_unset VAR
297 # ---------------
298 # Portably unset VAR.
299 as_fn_unset ()
300 {
301   { eval $1=; unset $1;}
302 }
303 as_unset=as_fn_unset
304
305 # as_fn_set_status STATUS
306 # -----------------------
307 # Set $? to STATUS, without forking.
308 as_fn_set_status ()
309 {
310   return $1
311 } # as_fn_set_status
312
313 # as_fn_exit STATUS
314 # -----------------
315 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
316 as_fn_exit ()
317 {
318   set +e
319   as_fn_set_status $1
320   exit $1
321 } # as_fn_exit
322
323 # as_fn_mkdir_p
324 # -------------
325 # Create "$as_dir" as a directory, including parents if necessary.
326 as_fn_mkdir_p ()
327 {
328
329   case $as_dir in #(
330   -*) as_dir=./$as_dir;;
331   esac
332   test -d "$as_dir" || eval $as_mkdir_p || {
333     as_dirs=
334     while :; do
335       case $as_dir in #(
336       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
337       *) as_qdir=$as_dir;;
338       esac
339       as_dirs="'$as_qdir' $as_dirs"
340       as_dir=`$as_dirname -- "$as_dir" ||
341 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
342          X"$as_dir" : 'X\(//\)[^/]' \| \
343          X"$as_dir" : 'X\(//\)$' \| \
344          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
345 $as_echo X"$as_dir" |
346     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
347             s//\1/
348             q
349           }
350           /^X\(\/\/\)[^/].*/{
351             s//\1/
352             q
353           }
354           /^X\(\/\/\)$/{
355             s//\1/
356             q
357           }
358           /^X\(\/\).*/{
359             s//\1/
360             q
361           }
362           s/.*/./; q'`
363       test -d "$as_dir" && break
364     done
365     test -z "$as_dirs" || eval "mkdir $as_dirs"
366   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
367
368
369 } # as_fn_mkdir_p
370
371 # as_fn_executable_p FILE
372 # -----------------------
373 # Test if FILE is an executable regular file.
374 as_fn_executable_p ()
375 {
376   test -f "$1" && test -x "$1"
377 } # as_fn_executable_p
378 # as_fn_append VAR VALUE
379 # ----------------------
380 # Append the text in VALUE to the end of the definition contained in VAR. Take
381 # advantage of any shell optimizations that allow amortized linear growth over
382 # repeated appends, instead of the typical quadratic growth present in naive
383 # implementations.
384 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
385   eval 'as_fn_append ()
386   {
387     eval $1+=\$2
388   }'
389 else
390   as_fn_append ()
391   {
392     eval $1=\$$1\$2
393   }
394 fi # as_fn_append
395
396 # as_fn_arith ARG...
397 # ------------------
398 # Perform arithmetic evaluation on the ARGs, and store the result in the
399 # global $as_val. Take advantage of shells that can avoid forks. The arguments
400 # must be portable across $(()) and expr.
401 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
402   eval 'as_fn_arith ()
403   {
404     as_val=$(( $* ))
405   }'
406 else
407   as_fn_arith ()
408   {
409     as_val=`expr "$@" || test $? -eq 1`
410   }
411 fi # as_fn_arith
412
413
414 # as_fn_error STATUS ERROR [LINENO LOG_FD]
415 # ----------------------------------------
416 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
417 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
418 # script with STATUS, using 1 if that was 0.
419 as_fn_error ()
420 {
421   as_status=$1; test $as_status -eq 0 && as_status=1
422   if test "$4"; then
423     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
424     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
425   fi
426   $as_echo "$as_me: error: $2" >&2
427   as_fn_exit $as_status
428 } # as_fn_error
429
430 if expr a : '\(a\)' >/dev/null 2>&1 &&
431    test "X`expr 00001 : '.*\(...\)'`" = X001; then
432   as_expr=expr
433 else
434   as_expr=false
435 fi
436
437 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
438   as_basename=basename
439 else
440   as_basename=false
441 fi
442
443 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
444   as_dirname=dirname
445 else
446   as_dirname=false
447 fi
448
449 as_me=`$as_basename -- "$0" ||
450 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
451          X"$0" : 'X\(//\)$' \| \
452          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
453 $as_echo X/"$0" |
454     sed '/^.*\/\([^/][^/]*\)\/*$/{
455             s//\1/
456             q
457           }
458           /^X\/\(\/\/\)$/{
459             s//\1/
460             q
461           }
462           /^X\/\(\/\).*/{
463             s//\1/
464             q
465           }
466           s/.*/./; q'`
467
468 # Avoid depending upon Character Ranges.
469 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
470 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
471 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
472 as_cr_digits='0123456789'
473 as_cr_alnum=$as_cr_Letters$as_cr_digits
474
475
476   as_lineno_1=$LINENO as_lineno_1a=$LINENO
477   as_lineno_2=$LINENO as_lineno_2a=$LINENO
478   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
479   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
480   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
481   sed -n '
482     p
483     /[$]LINENO/=
484   ' <$as_myself |
485     sed '
486       s/[$]LINENO.*/&-/
487       t lineno
488       b
489       :lineno
490       N
491       :loop
492       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
493       t loop
494       s/-\n.*//
495     ' >$as_me.lineno &&
496   chmod +x "$as_me.lineno" ||
497     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
498
499   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
500   # already done that, so ensure we don't try to do so again and fall
501   # in an infinite loop.  This has already happened in practice.
502   _as_can_reexec=no; export _as_can_reexec
503   # Don't try to exec as it changes $[0], causing all sort of problems
504   # (the dirname of $[0] is not the place where we might find the
505   # original and so on.  Autoconf is especially sensitive to this).
506   . "./$as_me.lineno"
507   # Exit status is that of the last command.
508   exit
509 }
510
511 ECHO_C= ECHO_N= ECHO_T=
512 case `echo -n x` in #(((((
513 -n*)
514   case `echo 'xy\c'` in
515   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
516   xy)  ECHO_C='\c';;
517   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
518        ECHO_T=' ';;
519   esac;;
520 *)
521   ECHO_N='-n';;
522 esac
523
524 rm -f conf$$ conf$$.exe conf$$.file
525 if test -d conf$$.dir; then
526   rm -f conf$$.dir/conf$$.file
527 else
528   rm -f conf$$.dir
529   mkdir conf$$.dir 2>/dev/null
530 fi
531 if (echo >conf$$.file) 2>/dev/null; then
532   if ln -s conf$$.file conf$$ 2>/dev/null; then
533     as_ln_s='ln -s'
534     # ... but there are two gotchas:
535     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
536     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
537     # In both cases, we have to default to `cp -pR'.
538     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
539       as_ln_s='cp -pR'
540   elif ln conf$$.file conf$$ 2>/dev/null; then
541     as_ln_s=ln
542   else
543     as_ln_s='cp -pR'
544   fi
545 else
546   as_ln_s='cp -pR'
547 fi
548 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
549 rmdir conf$$.dir 2>/dev/null
550
551 if mkdir -p . 2>/dev/null; then
552   as_mkdir_p='mkdir -p "$as_dir"'
553 else
554   test -d ./-p && rmdir ./-p
555   as_mkdir_p=false
556 fi
557
558 as_test_x='test -x'
559 as_executable_p=as_fn_executable_p
560
561 # Sed expression to map a string onto a valid CPP name.
562 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
563
564 # Sed expression to map a string onto a valid variable name.
565 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
566
567 SHELL=${CONFIG_SHELL-/bin/sh}
568
569
570 test -n "$DJDIR" || exec 7<&0 </dev/null
571 exec 6>&1
572
573 # Name of the host.
574 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
575 # so uname gets run too.
576 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
577
578 #
579 # Initializations.
580 #
581 ac_default_prefix=/usr/local
582 ac_clean_files=
583 ac_config_libobj_dir=.
584 LIBOBJS=
585 cross_compiling=no
586 subdirs=
587 MFLAGS=
588 MAKEFLAGS=
589
590 # Identity of this package.
591 PACKAGE_NAME='unbound'
592 PACKAGE_TARNAME='unbound'
593 PACKAGE_VERSION='1.6.3'
594 PACKAGE_STRING='unbound 1.6.3'
595 PACKAGE_BUGREPORT='unbound-bugs@nlnetlabs.nl'
596 PACKAGE_URL=''
597
598 # Factoring default headers for most tests.
599 ac_includes_default="\
600 #include <stdio.h>
601 #ifdef HAVE_SYS_TYPES_H
602 # include <sys/types.h>
603 #endif
604 #ifdef HAVE_SYS_STAT_H
605 # include <sys/stat.h>
606 #endif
607 #ifdef STDC_HEADERS
608 # include <stdlib.h>
609 # include <stddef.h>
610 #else
611 # ifdef HAVE_STDLIB_H
612 #  include <stdlib.h>
613 # endif
614 #endif
615 #ifdef HAVE_STRING_H
616 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
617 #  include <memory.h>
618 # endif
619 # include <string.h>
620 #endif
621 #ifdef HAVE_STRINGS_H
622 # include <strings.h>
623 #endif
624 #ifdef HAVE_INTTYPES_H
625 # include <inttypes.h>
626 #endif
627 #ifdef HAVE_STDINT_H
628 # include <stdint.h>
629 #endif
630 #ifdef HAVE_UNISTD_H
631 # include <unistd.h>
632 #endif"
633
634 ac_subst_vars='LTLIBOBJS
635 date
636 version
637 INSTALLTARGET
638 ALLTARGET
639 SOURCEFILE
640 SOURCEDETERMINE
641 DNSCRYPT_OBJ
642 DNSCRYPT_SRC
643 ENABLE_DNSCRYPT
644 DNSTAP_OBJ
645 DNSTAP_SRC
646 opt_dnstap_socket_path
647 ENABLE_DNSTAP
648 PROTOC_C
649 UBSYMS
650 EXTRALINK
651 COMMON_OBJ_ALL_SYMBOLS
652 LIBOBJ_WITHOUT_CTIME
653 LIBOBJ_WITHOUT_CTIMEARC4
654 WIN_CHECKCONF_OBJ_LINK
655 WIN_CONTROL_OBJ_LINK
656 WIN_UBANCHOR_OBJ_LINK
657 WIN_HOST_OBJ_LINK
658 WIN_DAEMON_OBJ_LINK
659 WIN_DAEMON_OBJ
660 WIN_DAEMON_SRC
661 WINAPPS
662 WINDRES
663 CHECKLOCK_OBJ
664 USE_SYSTEMD_FALSE
665 USE_SYSTEMD_TRUE
666 SYSTEMD_DAEMON_LIBS
667 SYSTEMD_DAEMON_CFLAGS
668 SYSTEMD_LIBS
669 SYSTEMD_CFLAGS
670 PKG_CONFIG_LIBDIR
671 PKG_CONFIG_PATH
672 PKG_CONFIG
673 staticexe
674 PC_LIBEVENT_DEPENDENCY
675 UNBOUND_EVENT_UNINSTALL
676 UNBOUND_EVENT_INSTALL
677 SUBNET_HEADER
678 SUBNET_OBJ
679 SSLLIB
680 HAVE_SSL
681 CONFIG_DATE
682 NETBSD_LINTFLAGS
683 PYUNBOUND_UNINSTALL
684 PYUNBOUND_INSTALL
685 PYUNBOUND_TARGET
686 PYUNBOUND_OBJ
687 WITH_PYUNBOUND
688 PYTHONMOD_UNINSTALL
689 PYTHONMOD_INSTALL
690 PYTHONMOD_HEADER
691 PYTHONMOD_OBJ
692 WITH_PYTHONMODULE
693 swig
694 SWIG_LIB
695 SWIG
696 PC_PY_DEPENDENCY
697 PY_MAJOR_VERSION
698 PYTHON_SITE_PKG
699 PYTHON_LDFLAGS
700 PYTHON_CPPFLAGS
701 PYTHON
702 PYTHON_VERSION
703 PTHREAD_CFLAGS_ONLY
704 PTHREAD_CFLAGS
705 PTHREAD_LIBS
706 PTHREAD_CC
707 ax_pthread_config
708 RUNTIME_PATH
709 LIBOBJS
710 LT_SYS_LIBRARY_PATH
711 OTOOL64
712 OTOOL
713 LIPO
714 NMEDIT
715 DSYMUTIL
716 MANIFEST_TOOL
717 AWK
718 RANLIB
719 ac_ct_AR
720 DLLTOOL
721 OBJDUMP
722 LN_S
723 NM
724 ac_ct_DUMPBIN
725 DUMPBIN
726 LD
727 FGREP
728 SED
729 LIBTOOL
730 AR
731 host_os
732 host_vendor
733 host_cpu
734 host
735 build_os
736 build_vendor
737 build_cpu
738 build
739 libtool
740 STRIP
741 doxygen
742 YFLAGS
743 YACC
744 LEXLIB
745 LEX_OUTPUT_ROOT
746 LEX
747 debug_enabled
748 DEPFLAG
749 UNBOUND_USERNAME
750 UNBOUND_ROOTCERT_FILE
751 UNBOUND_ROOTKEY_FILE
752 UNBOUND_PIDFILE
753 UNBOUND_SHARE_DIR
754 UNBOUND_CHROOT_DIR
755 UNBOUND_RUN_DIR
756 ub_conf_dir
757 ub_conf_file
758 EGREP
759 GREP
760 CPP
761 OBJEXT
762 EXEEXT
763 ac_ct_CC
764 CPPFLAGS
765 LDFLAGS
766 CFLAGS
767 CC
768 LIBUNBOUND_AGE
769 LIBUNBOUND_REVISION
770 LIBUNBOUND_CURRENT
771 UNBOUND_VERSION_MICRO
772 UNBOUND_VERSION_MINOR
773 UNBOUND_VERSION_MAJOR
774 target_alias
775 host_alias
776 build_alias
777 LIBS
778 ECHO_T
779 ECHO_N
780 ECHO_C
781 DEFS
782 mandir
783 localedir
784 libdir
785 psdir
786 pdfdir
787 dvidir
788 htmldir
789 infodir
790 docdir
791 oldincludedir
792 includedir
793 localstatedir
794 sharedstatedir
795 sysconfdir
796 datadir
797 datarootdir
798 libexecdir
799 sbindir
800 bindir
801 program_transform_name
802 prefix
803 exec_prefix
804 PACKAGE_URL
805 PACKAGE_BUGREPORT
806 PACKAGE_STRING
807 PACKAGE_VERSION
808 PACKAGE_TARNAME
809 PACKAGE_NAME
810 PATH_SEPARATOR
811 SHELL'
812 ac_subst_files=''
813 ac_user_opts='
814 enable_option_checking
815 with_conf_file
816 with_run_dir
817 with_chroot_dir
818 with_share_dir
819 with_pidfile
820 with_rootkey_file
821 with_rootcert_file
822 with_username
823 enable_checking
824 enable_debug
825 enable_flto
826 enable_pie
827 enable_relro_now
828 enable_shared
829 enable_static
830 with_pic
831 enable_fast_install
832 with_aix_soname
833 with_gnu_ld
834 with_sysroot
835 enable_libtool_lock
836 enable_rpath
837 enable_largefile
838 enable_alloc_checks
839 enable_alloc_lite
840 enable_alloc_nonregional
841 with_pthreads
842 with_solaris_threads
843 with_pyunbound
844 with_pythonmodule
845 with_nss
846 with_nettle
847 with_ssl
848 enable_sha1
849 enable_sha2
850 enable_subnet
851 enable_gost
852 enable_ecdsa
853 enable_dsa
854 enable_event_api
855 enable_tfo_client
856 enable_tfo_server
857 with_libevent
858 with_libexpat
859 enable_static_exe
860 enable_systemd
861 enable_lock_checks
862 enable_allsymbols
863 enable_dnstap
864 with_dnstap_socket_path
865 with_protobuf_c
866 with_libfstrm
867 enable_dnscrypt
868 with_libsodium
869 enable_cachedb
870 with_libunbound_only
871 '
872       ac_precious_vars='build_alias
873 host_alias
874 target_alias
875 CC
876 CFLAGS
877 LDFLAGS
878 LIBS
879 CPPFLAGS
880 CPP
881 YACC
882 YFLAGS
883 LT_SYS_LIBRARY_PATH
884 PYTHON_VERSION
885 PKG_CONFIG
886 PKG_CONFIG_PATH
887 PKG_CONFIG_LIBDIR
888 SYSTEMD_CFLAGS
889 SYSTEMD_LIBS
890 SYSTEMD_DAEMON_CFLAGS
891 SYSTEMD_DAEMON_LIBS'
892
893
894 # Initialize some variables set by options.
895 ac_init_help=
896 ac_init_version=false
897 ac_unrecognized_opts=
898 ac_unrecognized_sep=
899 # The variables have the same names as the options, with
900 # dashes changed to underlines.
901 cache_file=/dev/null
902 exec_prefix=NONE
903 no_create=
904 no_recursion=
905 prefix=NONE
906 program_prefix=NONE
907 program_suffix=NONE
908 program_transform_name=s,x,x,
909 silent=
910 site=
911 srcdir=
912 verbose=
913 x_includes=NONE
914 x_libraries=NONE
915
916 # Installation directory options.
917 # These are left unexpanded so users can "make install exec_prefix=/foo"
918 # and all the variables that are supposed to be based on exec_prefix
919 # by default will actually change.
920 # Use braces instead of parens because sh, perl, etc. also accept them.
921 # (The list follows the same order as the GNU Coding Standards.)
922 bindir='${exec_prefix}/bin'
923 sbindir='${exec_prefix}/sbin'
924 libexecdir='${exec_prefix}/libexec'
925 datarootdir='${prefix}/share'
926 datadir='${datarootdir}'
927 sysconfdir='${prefix}/etc'
928 sharedstatedir='${prefix}/com'
929 localstatedir='${prefix}/var'
930 includedir='${prefix}/include'
931 oldincludedir='/usr/include'
932 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
933 infodir='${datarootdir}/info'
934 htmldir='${docdir}'
935 dvidir='${docdir}'
936 pdfdir='${docdir}'
937 psdir='${docdir}'
938 libdir='${exec_prefix}/lib'
939 localedir='${datarootdir}/locale'
940 mandir='${datarootdir}/man'
941
942 ac_prev=
943 ac_dashdash=
944 for ac_option
945 do
946   # If the previous option needs an argument, assign it.
947   if test -n "$ac_prev"; then
948     eval $ac_prev=\$ac_option
949     ac_prev=
950     continue
951   fi
952
953   case $ac_option in
954   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
955   *=)   ac_optarg= ;;
956   *)    ac_optarg=yes ;;
957   esac
958
959   # Accept the important Cygnus configure options, so we can diagnose typos.
960
961   case $ac_dashdash$ac_option in
962   --)
963     ac_dashdash=yes ;;
964
965   -bindir | --bindir | --bindi | --bind | --bin | --bi)
966     ac_prev=bindir ;;
967   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
968     bindir=$ac_optarg ;;
969
970   -build | --build | --buil | --bui | --bu)
971     ac_prev=build_alias ;;
972   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
973     build_alias=$ac_optarg ;;
974
975   -cache-file | --cache-file | --cache-fil | --cache-fi \
976   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
977     ac_prev=cache_file ;;
978   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
979   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
980     cache_file=$ac_optarg ;;
981
982   --config-cache | -C)
983     cache_file=config.cache ;;
984
985   -datadir | --datadir | --datadi | --datad)
986     ac_prev=datadir ;;
987   -datadir=* | --datadir=* | --datadi=* | --datad=*)
988     datadir=$ac_optarg ;;
989
990   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
991   | --dataroo | --dataro | --datar)
992     ac_prev=datarootdir ;;
993   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
994   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
995     datarootdir=$ac_optarg ;;
996
997   -disable-* | --disable-*)
998     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
999     # Reject names that are not valid shell variable names.
1000     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1001       as_fn_error $? "invalid feature name: $ac_useropt"
1002     ac_useropt_orig=$ac_useropt
1003     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1004     case $ac_user_opts in
1005       *"
1006 "enable_$ac_useropt"
1007 "*) ;;
1008       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1009          ac_unrecognized_sep=', ';;
1010     esac
1011     eval enable_$ac_useropt=no ;;
1012
1013   -docdir | --docdir | --docdi | --doc | --do)
1014     ac_prev=docdir ;;
1015   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1016     docdir=$ac_optarg ;;
1017
1018   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1019     ac_prev=dvidir ;;
1020   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1021     dvidir=$ac_optarg ;;
1022
1023   -enable-* | --enable-*)
1024     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1025     # Reject names that are not valid shell variable names.
1026     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1027       as_fn_error $? "invalid feature name: $ac_useropt"
1028     ac_useropt_orig=$ac_useropt
1029     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1030     case $ac_user_opts in
1031       *"
1032 "enable_$ac_useropt"
1033 "*) ;;
1034       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1035          ac_unrecognized_sep=', ';;
1036     esac
1037     eval enable_$ac_useropt=\$ac_optarg ;;
1038
1039   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1040   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1041   | --exec | --exe | --ex)
1042     ac_prev=exec_prefix ;;
1043   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1044   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1045   | --exec=* | --exe=* | --ex=*)
1046     exec_prefix=$ac_optarg ;;
1047
1048   -gas | --gas | --ga | --g)
1049     # Obsolete; use --with-gas.
1050     with_gas=yes ;;
1051
1052   -help | --help | --hel | --he | -h)
1053     ac_init_help=long ;;
1054   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1055     ac_init_help=recursive ;;
1056   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1057     ac_init_help=short ;;
1058
1059   -host | --host | --hos | --ho)
1060     ac_prev=host_alias ;;
1061   -host=* | --host=* | --hos=* | --ho=*)
1062     host_alias=$ac_optarg ;;
1063
1064   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1065     ac_prev=htmldir ;;
1066   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1067   | --ht=*)
1068     htmldir=$ac_optarg ;;
1069
1070   -includedir | --includedir | --includedi | --included | --include \
1071   | --includ | --inclu | --incl | --inc)
1072     ac_prev=includedir ;;
1073   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1074   | --includ=* | --inclu=* | --incl=* | --inc=*)
1075     includedir=$ac_optarg ;;
1076
1077   -infodir | --infodir | --infodi | --infod | --info | --inf)
1078     ac_prev=infodir ;;
1079   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1080     infodir=$ac_optarg ;;
1081
1082   -libdir | --libdir | --libdi | --libd)
1083     ac_prev=libdir ;;
1084   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1085     libdir=$ac_optarg ;;
1086
1087   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1088   | --libexe | --libex | --libe)
1089     ac_prev=libexecdir ;;
1090   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1091   | --libexe=* | --libex=* | --libe=*)
1092     libexecdir=$ac_optarg ;;
1093
1094   -localedir | --localedir | --localedi | --localed | --locale)
1095     ac_prev=localedir ;;
1096   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1097     localedir=$ac_optarg ;;
1098
1099   -localstatedir | --localstatedir | --localstatedi | --localstated \
1100   | --localstate | --localstat | --localsta | --localst | --locals)
1101     ac_prev=localstatedir ;;
1102   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1103   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1104     localstatedir=$ac_optarg ;;
1105
1106   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1107     ac_prev=mandir ;;
1108   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1109     mandir=$ac_optarg ;;
1110
1111   -nfp | --nfp | --nf)
1112     # Obsolete; use --without-fp.
1113     with_fp=no ;;
1114
1115   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1116   | --no-cr | --no-c | -n)
1117     no_create=yes ;;
1118
1119   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1120   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1121     no_recursion=yes ;;
1122
1123   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1124   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1125   | --oldin | --oldi | --old | --ol | --o)
1126     ac_prev=oldincludedir ;;
1127   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1128   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1129   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1130     oldincludedir=$ac_optarg ;;
1131
1132   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1133     ac_prev=prefix ;;
1134   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1135     prefix=$ac_optarg ;;
1136
1137   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1138   | --program-pre | --program-pr | --program-p)
1139     ac_prev=program_prefix ;;
1140   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1141   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1142     program_prefix=$ac_optarg ;;
1143
1144   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1145   | --program-suf | --program-su | --program-s)
1146     ac_prev=program_suffix ;;
1147   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1148   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1149     program_suffix=$ac_optarg ;;
1150
1151   -program-transform-name | --program-transform-name \
1152   | --program-transform-nam | --program-transform-na \
1153   | --program-transform-n | --program-transform- \
1154   | --program-transform | --program-transfor \
1155   | --program-transfo | --program-transf \
1156   | --program-trans | --program-tran \
1157   | --progr-tra | --program-tr | --program-t)
1158     ac_prev=program_transform_name ;;
1159   -program-transform-name=* | --program-transform-name=* \
1160   | --program-transform-nam=* | --program-transform-na=* \
1161   | --program-transform-n=* | --program-transform-=* \
1162   | --program-transform=* | --program-transfor=* \
1163   | --program-transfo=* | --program-transf=* \
1164   | --program-trans=* | --program-tran=* \
1165   | --progr-tra=* | --program-tr=* | --program-t=*)
1166     program_transform_name=$ac_optarg ;;
1167
1168   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1169     ac_prev=pdfdir ;;
1170   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1171     pdfdir=$ac_optarg ;;
1172
1173   -psdir | --psdir | --psdi | --psd | --ps)
1174     ac_prev=psdir ;;
1175   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1176     psdir=$ac_optarg ;;
1177
1178   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1179   | -silent | --silent | --silen | --sile | --sil)
1180     silent=yes ;;
1181
1182   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1183     ac_prev=sbindir ;;
1184   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1185   | --sbi=* | --sb=*)
1186     sbindir=$ac_optarg ;;
1187
1188   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1189   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1190   | --sharedst | --shareds | --shared | --share | --shar \
1191   | --sha | --sh)
1192     ac_prev=sharedstatedir ;;
1193   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1194   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1195   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1196   | --sha=* | --sh=*)
1197     sharedstatedir=$ac_optarg ;;
1198
1199   -site | --site | --sit)
1200     ac_prev=site ;;
1201   -site=* | --site=* | --sit=*)
1202     site=$ac_optarg ;;
1203
1204   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1205     ac_prev=srcdir ;;
1206   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1207     srcdir=$ac_optarg ;;
1208
1209   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1210   | --syscon | --sysco | --sysc | --sys | --sy)
1211     ac_prev=sysconfdir ;;
1212   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1213   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1214     sysconfdir=$ac_optarg ;;
1215
1216   -target | --target | --targe | --targ | --tar | --ta | --t)
1217     ac_prev=target_alias ;;
1218   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1219     target_alias=$ac_optarg ;;
1220
1221   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1222     verbose=yes ;;
1223
1224   -version | --version | --versio | --versi | --vers | -V)
1225     ac_init_version=: ;;
1226
1227   -with-* | --with-*)
1228     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1229     # Reject names that are not valid shell variable names.
1230     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1231       as_fn_error $? "invalid package name: $ac_useropt"
1232     ac_useropt_orig=$ac_useropt
1233     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1234     case $ac_user_opts in
1235       *"
1236 "with_$ac_useropt"
1237 "*) ;;
1238       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1239          ac_unrecognized_sep=', ';;
1240     esac
1241     eval with_$ac_useropt=\$ac_optarg ;;
1242
1243   -without-* | --without-*)
1244     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1245     # Reject names that are not valid shell variable names.
1246     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1247       as_fn_error $? "invalid package name: $ac_useropt"
1248     ac_useropt_orig=$ac_useropt
1249     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1250     case $ac_user_opts in
1251       *"
1252 "with_$ac_useropt"
1253 "*) ;;
1254       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1255          ac_unrecognized_sep=', ';;
1256     esac
1257     eval with_$ac_useropt=no ;;
1258
1259   --x)
1260     # Obsolete; use --with-x.
1261     with_x=yes ;;
1262
1263   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1264   | --x-incl | --x-inc | --x-in | --x-i)
1265     ac_prev=x_includes ;;
1266   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1267   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1268     x_includes=$ac_optarg ;;
1269
1270   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1271   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1272     ac_prev=x_libraries ;;
1273   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1274   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1275     x_libraries=$ac_optarg ;;
1276
1277   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1278 Try \`$0 --help' for more information"
1279     ;;
1280
1281   *=*)
1282     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1283     # Reject names that are not valid shell variable names.
1284     case $ac_envvar in #(
1285       '' | [0-9]* | *[!_$as_cr_alnum]* )
1286       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1287     esac
1288     eval $ac_envvar=\$ac_optarg
1289     export $ac_envvar ;;
1290
1291   *)
1292     # FIXME: should be removed in autoconf 3.0.
1293     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1294     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1295       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1296     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1297     ;;
1298
1299   esac
1300 done
1301
1302 if test -n "$ac_prev"; then
1303   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1304   as_fn_error $? "missing argument to $ac_option"
1305 fi
1306
1307 if test -n "$ac_unrecognized_opts"; then
1308   case $enable_option_checking in
1309     no) ;;
1310     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1311     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1312   esac
1313 fi
1314
1315 # Check all directory arguments for consistency.
1316 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1317                 datadir sysconfdir sharedstatedir localstatedir includedir \
1318                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1319                 libdir localedir mandir
1320 do
1321   eval ac_val=\$$ac_var
1322   # Remove trailing slashes.
1323   case $ac_val in
1324     */ )
1325       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1326       eval $ac_var=\$ac_val;;
1327   esac
1328   # Be sure to have absolute directory names.
1329   case $ac_val in
1330     [\\/$]* | ?:[\\/]* )  continue;;
1331     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1332   esac
1333   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1334 done
1335
1336 # There might be people who depend on the old broken behavior: `$host'
1337 # used to hold the argument of --host etc.
1338 # FIXME: To remove some day.
1339 build=$build_alias
1340 host=$host_alias
1341 target=$target_alias
1342
1343 # FIXME: To remove some day.
1344 if test "x$host_alias" != x; then
1345   if test "x$build_alias" = x; then
1346     cross_compiling=maybe
1347   elif test "x$build_alias" != "x$host_alias"; then
1348     cross_compiling=yes
1349   fi
1350 fi
1351
1352 ac_tool_prefix=
1353 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1354
1355 test "$silent" = yes && exec 6>/dev/null
1356
1357
1358 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1359 ac_ls_di=`ls -di .` &&
1360 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1361   as_fn_error $? "working directory cannot be determined"
1362 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1363   as_fn_error $? "pwd does not report name of working directory"
1364
1365
1366 # Find the source files, if location was not specified.
1367 if test -z "$srcdir"; then
1368   ac_srcdir_defaulted=yes
1369   # Try the directory containing this script, then the parent directory.
1370   ac_confdir=`$as_dirname -- "$as_myself" ||
1371 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1372          X"$as_myself" : 'X\(//\)[^/]' \| \
1373          X"$as_myself" : 'X\(//\)$' \| \
1374          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1375 $as_echo X"$as_myself" |
1376     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1377             s//\1/
1378             q
1379           }
1380           /^X\(\/\/\)[^/].*/{
1381             s//\1/
1382             q
1383           }
1384           /^X\(\/\/\)$/{
1385             s//\1/
1386             q
1387           }
1388           /^X\(\/\).*/{
1389             s//\1/
1390             q
1391           }
1392           s/.*/./; q'`
1393   srcdir=$ac_confdir
1394   if test ! -r "$srcdir/$ac_unique_file"; then
1395     srcdir=..
1396   fi
1397 else
1398   ac_srcdir_defaulted=no
1399 fi
1400 if test ! -r "$srcdir/$ac_unique_file"; then
1401   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1402   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1403 fi
1404 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1405 ac_abs_confdir=`(
1406         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1407         pwd)`
1408 # When building in place, set srcdir=.
1409 if test "$ac_abs_confdir" = "$ac_pwd"; then
1410   srcdir=.
1411 fi
1412 # Remove unnecessary trailing slashes from srcdir.
1413 # Double slashes in file names in object file debugging info
1414 # mess up M-x gdb in Emacs.
1415 case $srcdir in
1416 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1417 esac
1418 for ac_var in $ac_precious_vars; do
1419   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1420   eval ac_env_${ac_var}_value=\$${ac_var}
1421   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1422   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1423 done
1424
1425 #
1426 # Report the --help message.
1427 #
1428 if test "$ac_init_help" = "long"; then
1429   # Omit some internal or obsolete options to make the list less imposing.
1430   # This message is too long to be a string in the A/UX 3.1 sh.
1431   cat <<_ACEOF
1432 \`configure' configures unbound 1.6.3 to adapt to many kinds of systems.
1433
1434 Usage: $0 [OPTION]... [VAR=VALUE]...
1435
1436 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1437 VAR=VALUE.  See below for descriptions of some of the useful variables.
1438
1439 Defaults for the options are specified in brackets.
1440
1441 Configuration:
1442   -h, --help              display this help and exit
1443       --help=short        display options specific to this package
1444       --help=recursive    display the short help of all the included packages
1445   -V, --version           display version information and exit
1446   -q, --quiet, --silent   do not print \`checking ...' messages
1447       --cache-file=FILE   cache test results in FILE [disabled]
1448   -C, --config-cache      alias for \`--cache-file=config.cache'
1449   -n, --no-create         do not create output files
1450       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1451
1452 Installation directories:
1453   --prefix=PREFIX         install architecture-independent files in PREFIX
1454                           [$ac_default_prefix]
1455   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1456                           [PREFIX]
1457
1458 By default, \`make install' will install all the files in
1459 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1460 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1461 for instance \`--prefix=\$HOME'.
1462
1463 For better control, use the options below.
1464
1465 Fine tuning of the installation directories:
1466   --bindir=DIR            user executables [EPREFIX/bin]
1467   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1468   --libexecdir=DIR        program executables [EPREFIX/libexec]
1469   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1470   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1471   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1472   --libdir=DIR            object code libraries [EPREFIX/lib]
1473   --includedir=DIR        C header files [PREFIX/include]
1474   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1475   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1476   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1477   --infodir=DIR           info documentation [DATAROOTDIR/info]
1478   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1479   --mandir=DIR            man documentation [DATAROOTDIR/man]
1480   --docdir=DIR            documentation root [DATAROOTDIR/doc/unbound]
1481   --htmldir=DIR           html documentation [DOCDIR]
1482   --dvidir=DIR            dvi documentation [DOCDIR]
1483   --pdfdir=DIR            pdf documentation [DOCDIR]
1484   --psdir=DIR             ps documentation [DOCDIR]
1485 _ACEOF
1486
1487   cat <<\_ACEOF
1488
1489 System types:
1490   --build=BUILD     configure for building on BUILD [guessed]
1491   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1492 _ACEOF
1493 fi
1494
1495 if test -n "$ac_init_help"; then
1496   case $ac_init_help in
1497      short | recursive ) echo "Configuration of unbound 1.6.3:";;
1498    esac
1499   cat <<\_ACEOF
1500
1501 Optional Features:
1502   --disable-option-checking  ignore unrecognized --enable/--with options
1503   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1504   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1505   --enable-checking       Enable warnings, asserts, makefile-dependencies
1506   --enable-debug          same as enable-checking
1507   --disable-flto          Disable link-time optimization (gcc specific option)
1508   --enable-pie            Enable Position-Independent Executable (eg. to fully
1509                           benefit from ASLR, small performance penalty)
1510   --enable-relro-now      Enable full relocation binding at load-time (RELRO
1511                           NOW, to protect GOT and .dtor areas)
1512   --enable-shared[=PKGS]  build shared libraries [default=yes]
1513   --enable-static[=PKGS]  build static libraries [default=yes]
1514   --enable-fast-install[=PKGS]
1515                           optimize for fast installation [default=yes]
1516   --disable-libtool-lock  avoid locking (might break parallel builds)
1517   --disable-rpath         disable hardcoded rpath (default=enabled)
1518   --disable-largefile     omit support for large files
1519   --enable-alloc-checks   enable to memory allocation statistics, for debug
1520                           purposes
1521   --enable-alloc-lite     enable for lightweight alloc assertions, for debug
1522                           purposes
1523   --enable-alloc-nonregional
1524                           enable nonregional allocs, slow but exposes regional
1525                           allocations to other memory purifiers, for debug
1526                           purposes
1527   --disable-sha1          Disable SHA1 RRSIG support, does not disable nsec3
1528                           support
1529   --disable-sha2          Disable SHA256 and SHA512 RRSIG support
1530   --enable-subnet         Enable client subnet
1531   --disable-gost          Disable GOST support
1532   --disable-ecdsa         Disable ECDSA support
1533   --disable-dsa           Disable DSA support
1534   --enable-event-api      Enable (experimental) pluggable event base
1535                           libunbound API installed to unbound-event.h
1536   --enable-tfo-client     Enable TCP Fast Open for client mode
1537   --enable-tfo-server     Enable TCP Fast Open for server mode
1538   --enable-static-exe     enable to compile executables statically against
1539                           (event) libs, for debug purposes
1540   --enable-systemd        compile with systemd support
1541   --enable-lock-checks    enable to check lock and unlock calls, for debug
1542                           purposes
1543   --enable-allsymbols     export all symbols from libunbound and link binaries
1544                           to it, smaller install size but libunbound export
1545                           table is polluted by internal symbols
1546   --enable-dnstap         Enable dnstap support (requires fstrm, protobuf-c)
1547   --enable-dnscrypt       Enable dnscrypt support (requires libsodium)
1548   --enable-cachedb        enable cachedb module that can use external cache
1549                           storage
1550
1551 Optional Packages:
1552   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1553   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1554   --with-conf-file=path   Pathname to the Unbound configuration file
1555   --with-run-dir=path     set default directory to chdir to (by default dir
1556                           part of cfg file)
1557   --with-chroot-dir=path  set default directory to chroot to (by default same
1558                           as run-dir)
1559   --with-share-dir=path   set default directory with shared data (by default
1560                           same as share/unbound)
1561   --with-pidfile=filename set default pathname to unbound pidfile (default
1562                           run-dir/unbound.pid)
1563   --with-rootkey-file=filename
1564                           set default pathname to root key file (default
1565                           run-dir/root.key). This file is read and written.
1566   --with-rootcert-file=filename
1567                           set default pathname to root update certificate file
1568                           (default run-dir/icannbundle.pem). This file need
1569                           not exist if you are content with the builtin.
1570   --with-username=user    set default user that unbound changes to (default
1571                           user is unbound)
1572   --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
1573                           both]
1574   --with-aix-soname=aix|svr4|both
1575                           shared library versioning (aka "SONAME") variant to
1576                           provide on AIX, [default=aix].
1577   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1578   --with-sysroot[=DIR]    Search for dependent libraries within DIR (or the
1579                           compiler's sysroot if not specified).
1580   --with-pthreads         use pthreads library, or --without-pthreads to
1581                           disable threading support.
1582   --with-solaris-threads  use solaris native thread library.
1583   --with-pyunbound        build PyUnbound, or --without-pyunbound to skip it.
1584                           (default=no)
1585   --with-pythonmodule     build Python module, or --without-pythonmodule to
1586                           disable script engine. (default=no)
1587   --with-nss=path         use libnss instead of openssl, installed at path.
1588   --with-nettle=path      use libnettle as crypto library, installed at path.
1589   --with-ssl=pathname     enable SSL (will check /usr/local/ssl /usr/lib/ssl
1590                           /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw
1591                           /usr)
1592   --with-libevent=pathname
1593                           use libevent (will check /usr/local /opt/local
1594                           /usr/lib /usr/pkg /usr/sfw /usr or you can specify
1595                           an explicit path). Slower, but allows use of large
1596                           outgoing port ranges.
1597   --with-libexpat=path    specify explicit path for libexpat.
1598   --with-dnstap-socket-path=pathname
1599                           set default dnstap socket path
1600   --with-protobuf-c=path  Path where protobuf-c is installed, for dnstap
1601   --with-libfstrm=path    Path where libfstrm is installed, for dnstap
1602   --with-libsodium=path   Path where libsodium is installed, for dnscrypt
1603   --with-libunbound-only  do not build daemon and tool programs
1604
1605 Some influential environment variables:
1606   CC          C compiler command
1607   CFLAGS      C compiler flags
1608   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1609               nonstandard directory <lib dir>
1610   LIBS        libraries to pass to the linker, e.g. -l<library>
1611   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1612               you have headers in a nonstandard directory <include dir>
1613   CPP         C preprocessor
1614   YACC        The `Yet Another Compiler Compiler' implementation to use.
1615               Defaults to the first program found out of: `bison -y', `byacc',
1616               `yacc'.
1617   YFLAGS      The list of arguments that will be passed by default to $YACC.
1618               This script will default YFLAGS to the empty string to avoid a
1619               default value of `-d' given by some make applications.
1620   LT_SYS_LIBRARY_PATH
1621               User-defined run-time library search path.
1622   PYTHON_VERSION
1623               The installed Python version to use, for example '2.3'. This
1624               string will be appended to the Python interpreter canonical
1625               name.
1626   PKG_CONFIG  path to pkg-config utility
1627   PKG_CONFIG_PATH
1628               directories to add to pkg-config's search path
1629   PKG_CONFIG_LIBDIR
1630               path overriding pkg-config's built-in search path
1631   SYSTEMD_CFLAGS
1632               C compiler flags for SYSTEMD, overriding pkg-config
1633   SYSTEMD_LIBS
1634               linker flags for SYSTEMD, overriding pkg-config
1635   SYSTEMD_DAEMON_CFLAGS
1636               C compiler flags for SYSTEMD_DAEMON, overriding pkg-config
1637   SYSTEMD_DAEMON_LIBS
1638               linker flags for SYSTEMD_DAEMON, overriding pkg-config
1639
1640 Use these variables to override the choices made by `configure' or to help
1641 it to find libraries and programs with nonstandard names/locations.
1642
1643 Report bugs to <unbound-bugs@nlnetlabs.nl>.
1644 _ACEOF
1645 ac_status=$?
1646 fi
1647
1648 if test "$ac_init_help" = "recursive"; then
1649   # If there are subdirs, report their specific --help.
1650   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1651     test -d "$ac_dir" ||
1652       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1653       continue
1654     ac_builddir=.
1655
1656 case "$ac_dir" in
1657 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1658 *)
1659   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1660   # A ".." for each directory in $ac_dir_suffix.
1661   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1662   case $ac_top_builddir_sub in
1663   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1664   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1665   esac ;;
1666 esac
1667 ac_abs_top_builddir=$ac_pwd
1668 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1669 # for backward compatibility:
1670 ac_top_builddir=$ac_top_build_prefix
1671
1672 case $srcdir in
1673   .)  # We are building in place.
1674     ac_srcdir=.
1675     ac_top_srcdir=$ac_top_builddir_sub
1676     ac_abs_top_srcdir=$ac_pwd ;;
1677   [\\/]* | ?:[\\/]* )  # Absolute name.
1678     ac_srcdir=$srcdir$ac_dir_suffix;
1679     ac_top_srcdir=$srcdir
1680     ac_abs_top_srcdir=$srcdir ;;
1681   *) # Relative name.
1682     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1683     ac_top_srcdir=$ac_top_build_prefix$srcdir
1684     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1685 esac
1686 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1687
1688     cd "$ac_dir" || { ac_status=$?; continue; }
1689     # Check for guested configure.
1690     if test -f "$ac_srcdir/configure.gnu"; then
1691       echo &&
1692       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1693     elif test -f "$ac_srcdir/configure"; then
1694       echo &&
1695       $SHELL "$ac_srcdir/configure" --help=recursive
1696     else
1697       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1698     fi || ac_status=$?
1699     cd "$ac_pwd" || { ac_status=$?; break; }
1700   done
1701 fi
1702
1703 test -n "$ac_init_help" && exit $ac_status
1704 if $ac_init_version; then
1705   cat <<\_ACEOF
1706 unbound configure 1.6.3
1707 generated by GNU Autoconf 2.69
1708
1709 Copyright (C) 2012 Free Software Foundation, Inc.
1710 This configure script is free software; the Free Software Foundation
1711 gives unlimited permission to copy, distribute and modify it.
1712 _ACEOF
1713   exit
1714 fi
1715
1716 ## ------------------------ ##
1717 ## Autoconf initialization. ##
1718 ## ------------------------ ##
1719
1720 # ac_fn_c_try_compile LINENO
1721 # --------------------------
1722 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1723 ac_fn_c_try_compile ()
1724 {
1725   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1726   rm -f conftest.$ac_objext
1727   if { { ac_try="$ac_compile"
1728 case "(($ac_try" in
1729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1730   *) ac_try_echo=$ac_try;;
1731 esac
1732 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1733 $as_echo "$ac_try_echo"; } >&5
1734   (eval "$ac_compile") 2>conftest.err
1735   ac_status=$?
1736   if test -s conftest.err; then
1737     grep -v '^ *+' conftest.err >conftest.er1
1738     cat conftest.er1 >&5
1739     mv -f conftest.er1 conftest.err
1740   fi
1741   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1742   test $ac_status = 0; } && {
1743          test -z "$ac_c_werror_flag" ||
1744          test ! -s conftest.err
1745        } && test -s conftest.$ac_objext; then :
1746   ac_retval=0
1747 else
1748   $as_echo "$as_me: failed program was:" >&5
1749 sed 's/^/| /' conftest.$ac_ext >&5
1750
1751         ac_retval=1
1752 fi
1753   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1754   as_fn_set_status $ac_retval
1755
1756 } # ac_fn_c_try_compile
1757
1758 # ac_fn_c_try_cpp LINENO
1759 # ----------------------
1760 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1761 ac_fn_c_try_cpp ()
1762 {
1763   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1764   if { { ac_try="$ac_cpp conftest.$ac_ext"
1765 case "(($ac_try" in
1766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1767   *) ac_try_echo=$ac_try;;
1768 esac
1769 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1770 $as_echo "$ac_try_echo"; } >&5
1771   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1772   ac_status=$?
1773   if test -s conftest.err; then
1774     grep -v '^ *+' conftest.err >conftest.er1
1775     cat conftest.er1 >&5
1776     mv -f conftest.er1 conftest.err
1777   fi
1778   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1779   test $ac_status = 0; } > conftest.i && {
1780          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1781          test ! -s conftest.err
1782        }; then :
1783   ac_retval=0
1784 else
1785   $as_echo "$as_me: failed program was:" >&5
1786 sed 's/^/| /' conftest.$ac_ext >&5
1787
1788     ac_retval=1
1789 fi
1790   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1791   as_fn_set_status $ac_retval
1792
1793 } # ac_fn_c_try_cpp
1794
1795 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1796 # -------------------------------------------------------
1797 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1798 # the include files in INCLUDES and setting the cache variable VAR
1799 # accordingly.
1800 ac_fn_c_check_header_mongrel ()
1801 {
1802   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1803   if eval \${$3+:} false; then :
1804   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1805 $as_echo_n "checking for $2... " >&6; }
1806 if eval \${$3+:} false; then :
1807   $as_echo_n "(cached) " >&6
1808 fi
1809 eval ac_res=\$$3
1810                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1811 $as_echo "$ac_res" >&6; }
1812 else
1813   # Is the header compilable?
1814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1815 $as_echo_n "checking $2 usability... " >&6; }
1816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1817 /* end confdefs.h.  */
1818 $4
1819 #include <$2>
1820 _ACEOF
1821 if ac_fn_c_try_compile "$LINENO"; then :
1822   ac_header_compiler=yes
1823 else
1824   ac_header_compiler=no
1825 fi
1826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1828 $as_echo "$ac_header_compiler" >&6; }
1829
1830 # Is the header present?
1831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1832 $as_echo_n "checking $2 presence... " >&6; }
1833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1834 /* end confdefs.h.  */
1835 #include <$2>
1836 _ACEOF
1837 if ac_fn_c_try_cpp "$LINENO"; then :
1838   ac_header_preproc=yes
1839 else
1840   ac_header_preproc=no
1841 fi
1842 rm -f conftest.err conftest.i conftest.$ac_ext
1843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1844 $as_echo "$ac_header_preproc" >&6; }
1845
1846 # So?  What about this header?
1847 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1848   yes:no: )
1849     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1850 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1851     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1852 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1853     ;;
1854   no:yes:* )
1855     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1856 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1857     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1858 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1859     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1860 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1861     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1862 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1863     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1864 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1865 ( $as_echo "## ---------------------------------------- ##
1866 ## Report this to unbound-bugs@nlnetlabs.nl ##
1867 ## ---------------------------------------- ##"
1868      ) | sed "s/^/$as_me: WARNING:     /" >&2
1869     ;;
1870 esac
1871   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1872 $as_echo_n "checking for $2... " >&6; }
1873 if eval \${$3+:} false; then :
1874   $as_echo_n "(cached) " >&6
1875 else
1876   eval "$3=\$ac_header_compiler"
1877 fi
1878 eval ac_res=\$$3
1879                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1880 $as_echo "$ac_res" >&6; }
1881 fi
1882   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1883
1884 } # ac_fn_c_check_header_mongrel
1885
1886 # ac_fn_c_try_run LINENO
1887 # ----------------------
1888 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1889 # that executables *can* be run.
1890 ac_fn_c_try_run ()
1891 {
1892   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1893   if { { ac_try="$ac_link"
1894 case "(($ac_try" in
1895   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1896   *) ac_try_echo=$ac_try;;
1897 esac
1898 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1899 $as_echo "$ac_try_echo"; } >&5
1900   (eval "$ac_link") 2>&5
1901   ac_status=$?
1902   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1903   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1904   { { case "(($ac_try" in
1905   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1906   *) ac_try_echo=$ac_try;;
1907 esac
1908 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1909 $as_echo "$ac_try_echo"; } >&5
1910   (eval "$ac_try") 2>&5
1911   ac_status=$?
1912   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1913   test $ac_status = 0; }; }; then :
1914   ac_retval=0
1915 else
1916   $as_echo "$as_me: program exited with status $ac_status" >&5
1917        $as_echo "$as_me: failed program was:" >&5
1918 sed 's/^/| /' conftest.$ac_ext >&5
1919
1920        ac_retval=$ac_status
1921 fi
1922   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1923   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1924   as_fn_set_status $ac_retval
1925
1926 } # ac_fn_c_try_run
1927
1928 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1929 # -------------------------------------------------------
1930 # Tests whether HEADER exists and can be compiled using the include files in
1931 # INCLUDES, setting the cache variable VAR accordingly.
1932 ac_fn_c_check_header_compile ()
1933 {
1934   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1935   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1936 $as_echo_n "checking for $2... " >&6; }
1937 if eval \${$3+:} false; then :
1938   $as_echo_n "(cached) " >&6
1939 else
1940   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1941 /* end confdefs.h.  */
1942 $4
1943 #include <$2>
1944 _ACEOF
1945 if ac_fn_c_try_compile "$LINENO"; then :
1946   eval "$3=yes"
1947 else
1948   eval "$3=no"
1949 fi
1950 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1951 fi
1952 eval ac_res=\$$3
1953                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1954 $as_echo "$ac_res" >&6; }
1955   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1956
1957 } # ac_fn_c_check_header_compile
1958
1959 # ac_fn_c_try_link LINENO
1960 # -----------------------
1961 # Try to link conftest.$ac_ext, and return whether this succeeded.
1962 ac_fn_c_try_link ()
1963 {
1964   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1965   rm -f conftest.$ac_objext conftest$ac_exeext
1966   if { { ac_try="$ac_link"
1967 case "(($ac_try" in
1968   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1969   *) ac_try_echo=$ac_try;;
1970 esac
1971 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1972 $as_echo "$ac_try_echo"; } >&5
1973   (eval "$ac_link") 2>conftest.err
1974   ac_status=$?
1975   if test -s conftest.err; then
1976     grep -v '^ *+' conftest.err >conftest.er1
1977     cat conftest.er1 >&5
1978     mv -f conftest.er1 conftest.err
1979   fi
1980   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1981   test $ac_status = 0; } && {
1982          test -z "$ac_c_werror_flag" ||
1983          test ! -s conftest.err
1984        } && test -s conftest$ac_exeext && {
1985          test "$cross_compiling" = yes ||
1986          test -x conftest$ac_exeext
1987        }; then :
1988   ac_retval=0
1989 else
1990   $as_echo "$as_me: failed program was:" >&5
1991 sed 's/^/| /' conftest.$ac_ext >&5
1992
1993         ac_retval=1
1994 fi
1995   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1996   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1997   # interfere with the next link command; also delete a directory that is
1998   # left behind by Apple's compiler.  We do this before executing the actions.
1999   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2000   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2001   as_fn_set_status $ac_retval
2002
2003 } # ac_fn_c_try_link
2004
2005 # ac_fn_c_check_func LINENO FUNC VAR
2006 # ----------------------------------
2007 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2008 ac_fn_c_check_func ()
2009 {
2010   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2011   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2012 $as_echo_n "checking for $2... " >&6; }
2013 if eval \${$3+:} false; then :
2014   $as_echo_n "(cached) " >&6
2015 else
2016   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2017 /* end confdefs.h.  */
2018 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2019    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2020 #define $2 innocuous_$2
2021
2022 /* System header to define __stub macros and hopefully few prototypes,
2023     which can conflict with char $2 (); below.
2024     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2025     <limits.h> exists even on freestanding compilers.  */
2026
2027 #ifdef __STDC__
2028 # include <limits.h>
2029 #else
2030 # include <assert.h>
2031 #endif
2032
2033 #undef $2
2034
2035 /* Override any GCC internal prototype to avoid an error.
2036    Use char because int might match the return type of a GCC
2037    builtin and then its argument prototype would still apply.  */
2038 #ifdef __cplusplus
2039 extern "C"
2040 #endif
2041 char $2 ();
2042 /* The GNU C library defines this for functions which it implements
2043     to always fail with ENOSYS.  Some functions are actually named
2044     something starting with __ and the normal name is an alias.  */
2045 #if defined __stub_$2 || defined __stub___$2
2046 choke me
2047 #endif
2048
2049 int
2050 main ()
2051 {
2052 return $2 ();
2053   ;
2054   return 0;
2055 }
2056 _ACEOF
2057 if ac_fn_c_try_link "$LINENO"; then :
2058   eval "$3=yes"
2059 else
2060   eval "$3=no"
2061 fi
2062 rm -f core conftest.err conftest.$ac_objext \
2063     conftest$ac_exeext conftest.$ac_ext
2064 fi
2065 eval ac_res=\$$3
2066                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2067 $as_echo "$ac_res" >&6; }
2068   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2069
2070 } # ac_fn_c_check_func
2071
2072 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2073 # -------------------------------------------
2074 # Tests whether TYPE exists after having included INCLUDES, setting cache
2075 # variable VAR accordingly.
2076 ac_fn_c_check_type ()
2077 {
2078   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2079   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2080 $as_echo_n "checking for $2... " >&6; }
2081 if eval \${$3+:} false; then :
2082   $as_echo_n "(cached) " >&6
2083 else
2084   eval "$3=no"
2085   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2086 /* end confdefs.h.  */
2087 $4
2088 int
2089 main ()
2090 {
2091 if (sizeof ($2))
2092          return 0;
2093   ;
2094   return 0;
2095 }
2096 _ACEOF
2097 if ac_fn_c_try_compile "$LINENO"; then :
2098   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2099 /* end confdefs.h.  */
2100 $4
2101 int
2102 main ()
2103 {
2104 if (sizeof (($2)))
2105             return 0;
2106   ;
2107   return 0;
2108 }
2109 _ACEOF
2110 if ac_fn_c_try_compile "$LINENO"; then :
2111
2112 else
2113   eval "$3=yes"
2114 fi
2115 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2116 fi
2117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2118 fi
2119 eval ac_res=\$$3
2120                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2121 $as_echo "$ac_res" >&6; }
2122   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2123
2124 } # ac_fn_c_check_type
2125
2126 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2127 # --------------------------------------------
2128 # Tries to find the compile-time value of EXPR in a program that includes
2129 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2130 # computed
2131 ac_fn_c_compute_int ()
2132 {
2133   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2134   if test "$cross_compiling" = yes; then
2135     # Depending upon the size, compute the lo and hi bounds.
2136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2137 /* end confdefs.h.  */
2138 $4
2139 int
2140 main ()
2141 {
2142 static int test_array [1 - 2 * !(($2) >= 0)];
2143 test_array [0] = 0;
2144 return test_array [0];
2145
2146   ;
2147   return 0;
2148 }
2149 _ACEOF
2150 if ac_fn_c_try_compile "$LINENO"; then :
2151   ac_lo=0 ac_mid=0
2152   while :; do
2153     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2154 /* end confdefs.h.  */
2155 $4
2156 int
2157 main ()
2158 {
2159 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2160 test_array [0] = 0;
2161 return test_array [0];
2162
2163   ;
2164   return 0;
2165 }
2166 _ACEOF
2167 if ac_fn_c_try_compile "$LINENO"; then :
2168   ac_hi=$ac_mid; break
2169 else
2170   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2171                         if test $ac_lo -le $ac_mid; then
2172                           ac_lo= ac_hi=
2173                           break
2174                         fi
2175                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2176 fi
2177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2178   done
2179 else
2180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2181 /* end confdefs.h.  */
2182 $4
2183 int
2184 main ()
2185 {
2186 static int test_array [1 - 2 * !(($2) < 0)];
2187 test_array [0] = 0;
2188 return test_array [0];
2189
2190   ;
2191   return 0;
2192 }
2193 _ACEOF
2194 if ac_fn_c_try_compile "$LINENO"; then :
2195   ac_hi=-1 ac_mid=-1
2196   while :; do
2197     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2198 /* end confdefs.h.  */
2199 $4
2200 int
2201 main ()
2202 {
2203 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2204 test_array [0] = 0;
2205 return test_array [0];
2206
2207   ;
2208   return 0;
2209 }
2210 _ACEOF
2211 if ac_fn_c_try_compile "$LINENO"; then :
2212   ac_lo=$ac_mid; break
2213 else
2214   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2215                         if test $ac_mid -le $ac_hi; then
2216                           ac_lo= ac_hi=
2217                           break
2218                         fi
2219                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2220 fi
2221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2222   done
2223 else
2224   ac_lo= ac_hi=
2225 fi
2226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2227 fi
2228 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2229 # Binary search between lo and hi bounds.
2230 while test "x$ac_lo" != "x$ac_hi"; do
2231   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2232   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2233 /* end confdefs.h.  */
2234 $4
2235 int
2236 main ()
2237 {
2238 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2239 test_array [0] = 0;
2240 return test_array [0];
2241
2242   ;
2243   return 0;
2244 }
2245 _ACEOF
2246 if ac_fn_c_try_compile "$LINENO"; then :
2247   ac_hi=$ac_mid
2248 else
2249   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2250 fi
2251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2252 done
2253 case $ac_lo in #((
2254 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2255 '') ac_retval=1 ;;
2256 esac
2257   else
2258     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2259 /* end confdefs.h.  */
2260 $4
2261 static long int longval () { return $2; }
2262 static unsigned long int ulongval () { return $2; }
2263 #include <stdio.h>
2264 #include <stdlib.h>
2265 int
2266 main ()
2267 {
2268
2269   FILE *f = fopen ("conftest.val", "w");
2270   if (! f)
2271     return 1;
2272   if (($2) < 0)
2273     {
2274       long int i = longval ();
2275       if (i != ($2))
2276         return 1;
2277       fprintf (f, "%ld", i);
2278     }
2279   else
2280     {
2281       unsigned long int i = ulongval ();
2282       if (i != ($2))
2283         return 1;
2284       fprintf (f, "%lu", i);
2285     }
2286   /* Do not output a trailing newline, as this causes \r\n confusion
2287      on some platforms.  */
2288   return ferror (f) || fclose (f) != 0;
2289
2290   ;
2291   return 0;
2292 }
2293 _ACEOF
2294 if ac_fn_c_try_run "$LINENO"; then :
2295   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2296 else
2297   ac_retval=1
2298 fi
2299 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2300   conftest.$ac_objext conftest.beam conftest.$ac_ext
2301 rm -f conftest.val
2302
2303   fi
2304   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2305   as_fn_set_status $ac_retval
2306
2307 } # ac_fn_c_compute_int
2308
2309 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2310 # ---------------------------------------------
2311 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2312 # accordingly.
2313 ac_fn_c_check_decl ()
2314 {
2315   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2316   as_decl_name=`echo $2|sed 's/ *(.*//'`
2317   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2318   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2319 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2320 if eval \${$3+:} false; then :
2321   $as_echo_n "(cached) " >&6
2322 else
2323   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2324 /* end confdefs.h.  */
2325 $4
2326 int
2327 main ()
2328 {
2329 #ifndef $as_decl_name
2330 #ifdef __cplusplus
2331   (void) $as_decl_use;
2332 #else
2333   (void) $as_decl_name;
2334 #endif
2335 #endif
2336
2337   ;
2338   return 0;
2339 }
2340 _ACEOF
2341 if ac_fn_c_try_compile "$LINENO"; then :
2342   eval "$3=yes"
2343 else
2344   eval "$3=no"
2345 fi
2346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2347 fi
2348 eval ac_res=\$$3
2349                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2350 $as_echo "$ac_res" >&6; }
2351   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2352
2353 } # ac_fn_c_check_decl
2354
2355 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2356 # ----------------------------------------------------
2357 # Tries to find if the field MEMBER exists in type AGGR, after including
2358 # INCLUDES, setting cache variable VAR accordingly.
2359 ac_fn_c_check_member ()
2360 {
2361   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2362   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2363 $as_echo_n "checking for $2.$3... " >&6; }
2364 if eval \${$4+:} false; then :
2365   $as_echo_n "(cached) " >&6
2366 else
2367   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2368 /* end confdefs.h.  */
2369 $5
2370 int
2371 main ()
2372 {
2373 static $2 ac_aggr;
2374 if (ac_aggr.$3)
2375 return 0;
2376   ;
2377   return 0;
2378 }
2379 _ACEOF
2380 if ac_fn_c_try_compile "$LINENO"; then :
2381   eval "$4=yes"
2382 else
2383   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2384 /* end confdefs.h.  */
2385 $5
2386 int
2387 main ()
2388 {
2389 static $2 ac_aggr;
2390 if (sizeof ac_aggr.$3)
2391 return 0;
2392   ;
2393   return 0;
2394 }
2395 _ACEOF
2396 if ac_fn_c_try_compile "$LINENO"; then :
2397   eval "$4=yes"
2398 else
2399   eval "$4=no"
2400 fi
2401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2402 fi
2403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2404 fi
2405 eval ac_res=\$$4
2406                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2407 $as_echo "$ac_res" >&6; }
2408   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2409
2410 } # ac_fn_c_check_member
2411 cat >config.log <<_ACEOF
2412 This file contains any messages produced by compilers while
2413 running configure, to aid debugging if configure makes a mistake.
2414
2415 It was created by unbound $as_me 1.6.3, which was
2416 generated by GNU Autoconf 2.69.  Invocation command line was
2417
2418   $ $0 $@
2419
2420 _ACEOF
2421 exec 5>>config.log
2422 {
2423 cat <<_ASUNAME
2424 ## --------- ##
2425 ## Platform. ##
2426 ## --------- ##
2427
2428 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2429 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2430 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2431 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2432 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2433
2434 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2435 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2436
2437 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2438 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2439 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2440 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2441 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2442 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2443 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2444
2445 _ASUNAME
2446
2447 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2448 for as_dir in $PATH
2449 do
2450   IFS=$as_save_IFS
2451   test -z "$as_dir" && as_dir=.
2452     $as_echo "PATH: $as_dir"
2453   done
2454 IFS=$as_save_IFS
2455
2456 } >&5
2457
2458 cat >&5 <<_ACEOF
2459
2460
2461 ## ----------- ##
2462 ## Core tests. ##
2463 ## ----------- ##
2464
2465 _ACEOF
2466
2467
2468 # Keep a trace of the command line.
2469 # Strip out --no-create and --no-recursion so they do not pile up.
2470 # Strip out --silent because we don't want to record it for future runs.
2471 # Also quote any args containing shell meta-characters.
2472 # Make two passes to allow for proper duplicate-argument suppression.
2473 ac_configure_args=
2474 ac_configure_args0=
2475 ac_configure_args1=
2476 ac_must_keep_next=false
2477 for ac_pass in 1 2
2478 do
2479   for ac_arg
2480   do
2481     case $ac_arg in
2482     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2483     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2484     | -silent | --silent | --silen | --sile | --sil)
2485       continue ;;
2486     *\'*)
2487       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2488     esac
2489     case $ac_pass in
2490     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2491     2)
2492       as_fn_append ac_configure_args1 " '$ac_arg'"
2493       if test $ac_must_keep_next = true; then
2494         ac_must_keep_next=false # Got value, back to normal.
2495       else
2496         case $ac_arg in
2497           *=* | --config-cache | -C | -disable-* | --disable-* \
2498           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2499           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2500           | -with-* | --with-* | -without-* | --without-* | --x)
2501             case "$ac_configure_args0 " in
2502               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2503             esac
2504             ;;
2505           -* ) ac_must_keep_next=true ;;
2506         esac
2507       fi
2508       as_fn_append ac_configure_args " '$ac_arg'"
2509       ;;
2510     esac
2511   done
2512 done
2513 { ac_configure_args0=; unset ac_configure_args0;}
2514 { ac_configure_args1=; unset ac_configure_args1;}
2515
2516 # When interrupted or exit'd, cleanup temporary files, and complete
2517 # config.log.  We remove comments because anyway the quotes in there
2518 # would cause problems or look ugly.
2519 # WARNING: Use '\'' to represent an apostrophe within the trap.
2520 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2521 trap 'exit_status=$?
2522   # Save into config.log some information that might help in debugging.
2523   {
2524     echo
2525
2526     $as_echo "## ---------------- ##
2527 ## Cache variables. ##
2528 ## ---------------- ##"
2529     echo
2530     # The following way of writing the cache mishandles newlines in values,
2531 (
2532   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2533     eval ac_val=\$$ac_var
2534     case $ac_val in #(
2535     *${as_nl}*)
2536       case $ac_var in #(
2537       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2538 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2539       esac
2540       case $ac_var in #(
2541       _ | IFS | as_nl) ;; #(
2542       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2543       *) { eval $ac_var=; unset $ac_var;} ;;
2544       esac ;;
2545     esac
2546   done
2547   (set) 2>&1 |
2548     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2549     *${as_nl}ac_space=\ *)
2550       sed -n \
2551         "s/'\''/'\''\\\\'\'''\''/g;
2552           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2553       ;; #(
2554     *)
2555       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2556       ;;
2557     esac |
2558     sort
2559 )
2560     echo
2561
2562     $as_echo "## ----------------- ##
2563 ## Output variables. ##
2564 ## ----------------- ##"
2565     echo
2566     for ac_var in $ac_subst_vars
2567     do
2568       eval ac_val=\$$ac_var
2569       case $ac_val in
2570       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2571       esac
2572       $as_echo "$ac_var='\''$ac_val'\''"
2573     done | sort
2574     echo
2575
2576     if test -n "$ac_subst_files"; then
2577       $as_echo "## ------------------- ##
2578 ## File substitutions. ##
2579 ## ------------------- ##"
2580       echo
2581       for ac_var in $ac_subst_files
2582       do
2583         eval ac_val=\$$ac_var
2584         case $ac_val in
2585         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2586         esac
2587         $as_echo "$ac_var='\''$ac_val'\''"
2588       done | sort
2589       echo
2590     fi
2591
2592     if test -s confdefs.h; then
2593       $as_echo "## ----------- ##
2594 ## confdefs.h. ##
2595 ## ----------- ##"
2596       echo
2597       cat confdefs.h
2598       echo
2599     fi
2600     test "$ac_signal" != 0 &&
2601       $as_echo "$as_me: caught signal $ac_signal"
2602     $as_echo "$as_me: exit $exit_status"
2603   } >&5
2604   rm -f core *.core core.conftest.* &&
2605     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2606     exit $exit_status
2607 ' 0
2608 for ac_signal in 1 2 13 15; do
2609   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2610 done
2611 ac_signal=0
2612
2613 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2614 rm -f -r conftest* confdefs.h
2615
2616 $as_echo "/* confdefs.h */" > confdefs.h
2617
2618 # Predefined preprocessor variables.
2619
2620 cat >>confdefs.h <<_ACEOF
2621 #define PACKAGE_NAME "$PACKAGE_NAME"
2622 _ACEOF
2623
2624 cat >>confdefs.h <<_ACEOF
2625 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2626 _ACEOF
2627
2628 cat >>confdefs.h <<_ACEOF
2629 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2630 _ACEOF
2631
2632 cat >>confdefs.h <<_ACEOF
2633 #define PACKAGE_STRING "$PACKAGE_STRING"
2634 _ACEOF
2635
2636 cat >>confdefs.h <<_ACEOF
2637 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2638 _ACEOF
2639
2640 cat >>confdefs.h <<_ACEOF
2641 #define PACKAGE_URL "$PACKAGE_URL"
2642 _ACEOF
2643
2644
2645 # Let the site file select an alternate cache file if it wants to.
2646 # Prefer an explicitly selected file to automatically selected ones.
2647 ac_site_file1=NONE
2648 ac_site_file2=NONE
2649 if test -n "$CONFIG_SITE"; then
2650   # We do not want a PATH search for config.site.
2651   case $CONFIG_SITE in #((
2652     -*)  ac_site_file1=./$CONFIG_SITE;;
2653     */*) ac_site_file1=$CONFIG_SITE;;
2654     *)   ac_site_file1=./$CONFIG_SITE;;
2655   esac
2656 elif test "x$prefix" != xNONE; then
2657   ac_site_file1=$prefix/share/config.site
2658   ac_site_file2=$prefix/etc/config.site
2659 else
2660   ac_site_file1=$ac_default_prefix/share/config.site
2661   ac_site_file2=$ac_default_prefix/etc/config.site
2662 fi
2663 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2664 do
2665   test "x$ac_site_file" = xNONE && continue
2666   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2667     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2668 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2669     sed 's/^/| /' "$ac_site_file" >&5
2670     . "$ac_site_file" \
2671       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2672 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2673 as_fn_error $? "failed to load site script $ac_site_file
2674 See \`config.log' for more details" "$LINENO" 5; }
2675   fi
2676 done
2677
2678 if test -r "$cache_file"; then
2679   # Some versions of bash will fail to source /dev/null (special files
2680   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2681   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2682     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2683 $as_echo "$as_me: loading cache $cache_file" >&6;}
2684     case $cache_file in
2685       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2686       *)                      . "./$cache_file";;
2687     esac
2688   fi
2689 else
2690   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2691 $as_echo "$as_me: creating cache $cache_file" >&6;}
2692   >$cache_file
2693 fi
2694
2695 # Check that the precious variables saved in the cache have kept the same
2696 # value.
2697 ac_cache_corrupted=false
2698 for ac_var in $ac_precious_vars; do
2699   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2700   eval ac_new_set=\$ac_env_${ac_var}_set
2701   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2702   eval ac_new_val=\$ac_env_${ac_var}_value
2703   case $ac_old_set,$ac_new_set in
2704     set,)
2705       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2706 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2707       ac_cache_corrupted=: ;;
2708     ,set)
2709       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2710 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2711       ac_cache_corrupted=: ;;
2712     ,);;
2713     *)
2714       if test "x$ac_old_val" != "x$ac_new_val"; then
2715         # differences in whitespace do not lead to failure.
2716         ac_old_val_w=`echo x $ac_old_val`
2717         ac_new_val_w=`echo x $ac_new_val`
2718         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2719           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2720 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2721           ac_cache_corrupted=:
2722         else
2723           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2724 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2725           eval $ac_var=\$ac_old_val
2726         fi
2727         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2728 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2729         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2730 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2731       fi;;
2732   esac
2733   # Pass precious variables to config.status.
2734   if test "$ac_new_set" = set; then
2735     case $ac_new_val in
2736     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2737     *) ac_arg=$ac_var=$ac_new_val ;;
2738     esac
2739     case " $ac_configure_args " in
2740       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2741       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2742     esac
2743   fi
2744 done
2745 if $ac_cache_corrupted; then
2746   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2747 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2748   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2749 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2750   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2751 fi
2752 ## -------------------- ##
2753 ## Main body of script. ##
2754 ## -------------------- ##
2755
2756 ac_ext=c
2757 ac_cpp='$CPP $CPPFLAGS'
2758 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2759 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2760 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2761
2762
2763 UNBOUND_VERSION_MAJOR=1
2764
2765 UNBOUND_VERSION_MINOR=6
2766
2767 UNBOUND_VERSION_MICRO=3
2768
2769
2770 LIBUNBOUND_CURRENT=7
2771 LIBUNBOUND_REVISION=2
2772 LIBUNBOUND_AGE=5
2773 # 1.0.0 had 0:12:0
2774 # 1.0.1 had 0:13:0
2775 # 1.0.2 had 0:14:0
2776 # 1.1.0 had 0:15:0
2777 # 1.1.1 had 0:16:0
2778 # 1.2.0 had 0:17:0
2779 # 1.2.1 had 0:18:0
2780 # 1.3.0 had 1:0:0   # ub_cancel and -export-symbols.
2781 # 1.3.1 had 1:1:0
2782 # 1.3.2 had 1:2:0
2783 # 1.3.3 had 1:3:0
2784 # 1.3.4 had 1:4:0
2785 # 1.4.0-snapshots had 1:5:0
2786 # 1.4.0 had 1:5:0 (not 2:0:0)   # ub_result.why_bogus
2787 # 1.4.1 had 2:1:0
2788 # 1.4.2 had 2:2:0
2789 # 1.4.3 had 2:3:0
2790 # 1.4.4 had 2:4:0
2791 # 1.4.5 had 2:5:0
2792 # 1.4.6 had 2:6:0
2793 # 1.4.7 had 2:7:0
2794 # 1.4.8 had 2:8:0
2795 # 1.4.9 had 2:9:0
2796 # 1.4.10 had 2:10:0
2797 # 1.4.11 had 2:11:0
2798 # 1.4.12 had 2:12:0
2799 # 1.4.13 had 2:13:0
2800 # and 1.4.13p1 and 1.4.13.p2
2801 # 1.4.14 had 2:14:0
2802 # 1.4.15 had 3:0:1 # adds ub_version()
2803 # 1.4.16 had 3:1:1
2804 # 1.4.17 had 3:2:1
2805 # 1.4.18 had 3:3:1
2806 # 1.4.19 had 3:4:1
2807 # 1.4.20 had 4:0:2 # adds libunbound.ttl # but shipped 3:5:1
2808 # 1.4.21 had 4:1:2
2809 # 1.4.22 had 4:1:2
2810 # 1.5.0 had 5:3:3 # adds ub_ctx_add_ta_autr
2811 # 1.5.1 had 5:3:3
2812 # 1.5.2 had 5:5:3
2813 # 1.5.3 had 5:6:3
2814 # 1.5.4 had 5:7:3
2815 # 1.5.5 had 5:8:3
2816 # 1.5.6 had 5:9:3
2817 # 1.5.7 had 5:10:3
2818 # 1.5.8 had 6:0:4 # adds ub_ctx_set_stub
2819 # 1.5.9 had 6:1:4
2820 # 1.5.10 had 6:2:4
2821 # 1.6.0 had 6:3:4
2822 # 1.6.1 had 7:0:5 # ub_callback_t typedef renamed to ub_callback_type
2823 # 1.6.2 had 7:1:5
2824 # 1.6.3 had 7:2:5
2825
2826 #   Current  -- the number of the binary API that we're implementing
2827 #   Revision -- which iteration of the implementation of the binary
2828 #               API are we supplying?
2829 #   Age      -- How many previous binary API versions do we also
2830 #               support?
2831 #
2832 # If we release a new version that does not change the binary API,
2833 # increment Revision.
2834 #
2835 # If we release a new version that changes the binary API, but does
2836 # not break programs compiled against the old binary API, increment
2837 # Current and Age.  Set Revision to 0, since this is the first
2838 # implementation of the new API.
2839 #
2840 # Otherwise, we're changing the binary API and breaking bakward
2841 # compatibility with old binaries.  Increment Current.  Set Age to 0,
2842 # since we're backward compatible with no previous APIs.  Set Revision
2843 # to 0 too.
2844
2845
2846
2847
2848 CFLAGS="$CFLAGS"
2849 ac_ext=c
2850 ac_cpp='$CPP $CPPFLAGS'
2851 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2852 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2853 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2854 if test -n "$ac_tool_prefix"; then
2855   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2856 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2858 $as_echo_n "checking for $ac_word... " >&6; }
2859 if ${ac_cv_prog_CC+:} false; then :
2860   $as_echo_n "(cached) " >&6
2861 else
2862   if test -n "$CC"; then
2863   ac_cv_prog_CC="$CC" # Let the user override the test.
2864 else
2865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2866 for as_dir in $PATH
2867 do
2868   IFS=$as_save_IFS
2869   test -z "$as_dir" && as_dir=.
2870     for ac_exec_ext in '' $ac_executable_extensions; do
2871   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2872     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2873     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2874     break 2
2875   fi
2876 done
2877   done
2878 IFS=$as_save_IFS
2879
2880 fi
2881 fi
2882 CC=$ac_cv_prog_CC
2883 if test -n "$CC"; then
2884   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2885 $as_echo "$CC" >&6; }
2886 else
2887   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2888 $as_echo "no" >&6; }
2889 fi
2890
2891
2892 fi
2893 if test -z "$ac_cv_prog_CC"; then
2894   ac_ct_CC=$CC
2895   # Extract the first word of "gcc", so it can be a program name with args.
2896 set dummy gcc; ac_word=$2
2897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2898 $as_echo_n "checking for $ac_word... " >&6; }
2899 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2900   $as_echo_n "(cached) " >&6
2901 else
2902   if test -n "$ac_ct_CC"; then
2903   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2904 else
2905 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2906 for as_dir in $PATH
2907 do
2908   IFS=$as_save_IFS
2909   test -z "$as_dir" && as_dir=.
2910     for ac_exec_ext in '' $ac_executable_extensions; do
2911   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2912     ac_cv_prog_ac_ct_CC="gcc"
2913     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2914     break 2
2915   fi
2916 done
2917   done
2918 IFS=$as_save_IFS
2919
2920 fi
2921 fi
2922 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2923 if test -n "$ac_ct_CC"; then
2924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2925 $as_echo "$ac_ct_CC" >&6; }
2926 else
2927   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2928 $as_echo "no" >&6; }
2929 fi
2930
2931   if test "x$ac_ct_CC" = x; then
2932     CC=""
2933   else
2934     case $cross_compiling:$ac_tool_warned in
2935 yes:)
2936 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2937 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2938 ac_tool_warned=yes ;;
2939 esac
2940     CC=$ac_ct_CC
2941   fi
2942 else
2943   CC="$ac_cv_prog_CC"
2944 fi
2945
2946 if test -z "$CC"; then
2947           if test -n "$ac_tool_prefix"; then
2948     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2949 set dummy ${ac_tool_prefix}cc; ac_word=$2
2950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2951 $as_echo_n "checking for $ac_word... " >&6; }
2952 if ${ac_cv_prog_CC+:} false; then :
2953   $as_echo_n "(cached) " >&6
2954 else
2955   if test -n "$CC"; then
2956   ac_cv_prog_CC="$CC" # Let the user override the test.
2957 else
2958 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2959 for as_dir in $PATH
2960 do
2961   IFS=$as_save_IFS
2962   test -z "$as_dir" && as_dir=.
2963     for ac_exec_ext in '' $ac_executable_extensions; do
2964   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2965     ac_cv_prog_CC="${ac_tool_prefix}cc"
2966     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2967     break 2
2968   fi
2969 done
2970   done
2971 IFS=$as_save_IFS
2972
2973 fi
2974 fi
2975 CC=$ac_cv_prog_CC
2976 if test -n "$CC"; then
2977   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2978 $as_echo "$CC" >&6; }
2979 else
2980   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2981 $as_echo "no" >&6; }
2982 fi
2983
2984
2985   fi
2986 fi
2987 if test -z "$CC"; then
2988   # Extract the first word of "cc", so it can be a program name with args.
2989 set dummy cc; ac_word=$2
2990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2991 $as_echo_n "checking for $ac_word... " >&6; }
2992 if ${ac_cv_prog_CC+:} false; then :
2993   $as_echo_n "(cached) " >&6
2994 else
2995   if test -n "$CC"; then
2996   ac_cv_prog_CC="$CC" # Let the user override the test.
2997 else
2998   ac_prog_rejected=no
2999 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3000 for as_dir in $PATH
3001 do
3002   IFS=$as_save_IFS
3003   test -z "$as_dir" && as_dir=.
3004     for ac_exec_ext in '' $ac_executable_extensions; do
3005   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3006     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3007        ac_prog_rejected=yes
3008        continue
3009      fi
3010     ac_cv_prog_CC="cc"
3011     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3012     break 2
3013   fi
3014 done
3015   done
3016 IFS=$as_save_IFS
3017
3018 if test $ac_prog_rejected = yes; then
3019   # We found a bogon in the path, so make sure we never use it.
3020   set dummy $ac_cv_prog_CC
3021   shift
3022   if test $# != 0; then
3023     # We chose a different compiler from the bogus one.
3024     # However, it has the same basename, so the bogon will be chosen
3025     # first if we set CC to just the basename; use the full file name.
3026     shift
3027     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3028   fi
3029 fi
3030 fi
3031 fi
3032 CC=$ac_cv_prog_CC
3033 if test -n "$CC"; then
3034   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3035 $as_echo "$CC" >&6; }
3036 else
3037   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3038 $as_echo "no" >&6; }
3039 fi
3040
3041
3042 fi
3043 if test -z "$CC"; then
3044   if test -n "$ac_tool_prefix"; then
3045   for ac_prog in cl.exe
3046   do
3047     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3048 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3050 $as_echo_n "checking for $ac_word... " >&6; }
3051 if ${ac_cv_prog_CC+:} false; then :
3052   $as_echo_n "(cached) " >&6
3053 else
3054   if test -n "$CC"; then
3055   ac_cv_prog_CC="$CC" # Let the user override the test.
3056 else
3057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3058 for as_dir in $PATH
3059 do
3060   IFS=$as_save_IFS
3061   test -z "$as_dir" && as_dir=.
3062     for ac_exec_ext in '' $ac_executable_extensions; do
3063   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3064     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3065     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3066     break 2
3067   fi
3068 done
3069   done
3070 IFS=$as_save_IFS
3071
3072 fi
3073 fi
3074 CC=$ac_cv_prog_CC
3075 if test -n "$CC"; then
3076   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3077 $as_echo "$CC" >&6; }
3078 else
3079   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3080 $as_echo "no" >&6; }
3081 fi
3082
3083
3084     test -n "$CC" && break
3085   done
3086 fi
3087 if test -z "$CC"; then
3088   ac_ct_CC=$CC
3089   for ac_prog in cl.exe
3090 do
3091   # Extract the first word of "$ac_prog", so it can be a program name with args.
3092 set dummy $ac_prog; ac_word=$2
3093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3094 $as_echo_n "checking for $ac_word... " >&6; }
3095 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3096   $as_echo_n "(cached) " >&6
3097 else
3098   if test -n "$ac_ct_CC"; then
3099   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3100 else
3101 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3102 for as_dir in $PATH
3103 do
3104   IFS=$as_save_IFS
3105   test -z "$as_dir" && as_dir=.
3106     for ac_exec_ext in '' $ac_executable_extensions; do
3107   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3108     ac_cv_prog_ac_ct_CC="$ac_prog"
3109     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3110     break 2
3111   fi
3112 done
3113   done
3114 IFS=$as_save_IFS
3115
3116 fi
3117 fi
3118 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3119 if test -n "$ac_ct_CC"; then
3120   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3121 $as_echo "$ac_ct_CC" >&6; }
3122 else
3123   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3124 $as_echo "no" >&6; }
3125 fi
3126
3127
3128   test -n "$ac_ct_CC" && break
3129 done
3130
3131   if test "x$ac_ct_CC" = x; then
3132     CC=""
3133   else
3134     case $cross_compiling:$ac_tool_warned in
3135 yes:)
3136 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3137 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3138 ac_tool_warned=yes ;;
3139 esac
3140     CC=$ac_ct_CC
3141   fi
3142 fi
3143
3144 fi
3145
3146
3147 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3148 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3149 as_fn_error $? "no acceptable C compiler found in \$PATH
3150 See \`config.log' for more details" "$LINENO" 5; }
3151
3152 # Provide some information about the compiler.
3153 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3154 set X $ac_compile
3155 ac_compiler=$2
3156 for ac_option in --version -v -V -qversion; do
3157   { { ac_try="$ac_compiler $ac_option >&5"
3158 case "(($ac_try" in
3159   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3160   *) ac_try_echo=$ac_try;;
3161 esac
3162 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3163 $as_echo "$ac_try_echo"; } >&5
3164   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3165   ac_status=$?
3166   if test -s conftest.err; then
3167     sed '10a\
3168 ... rest of stderr output deleted ...
3169          10q' conftest.err >conftest.er1
3170     cat conftest.er1 >&5
3171   fi
3172   rm -f conftest.er1 conftest.err
3173   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3174   test $ac_status = 0; }
3175 done
3176
3177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3178 /* end confdefs.h.  */
3179
3180 int
3181 main ()
3182 {
3183
3184   ;
3185   return 0;
3186 }
3187 _ACEOF
3188 ac_clean_files_save=$ac_clean_files
3189 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3190 # Try to create an executable without -o first, disregard a.out.
3191 # It will help us diagnose broken compilers, and finding out an intuition
3192 # of exeext.
3193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3194 $as_echo_n "checking whether the C compiler works... " >&6; }
3195 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3196
3197 # The possible output files:
3198 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3199
3200 ac_rmfiles=
3201 for ac_file in $ac_files
3202 do
3203   case $ac_file in
3204     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3205     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3206   esac
3207 done
3208 rm -f $ac_rmfiles
3209
3210 if { { ac_try="$ac_link_default"
3211 case "(($ac_try" in
3212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3213   *) ac_try_echo=$ac_try;;
3214 esac
3215 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3216 $as_echo "$ac_try_echo"; } >&5
3217   (eval "$ac_link_default") 2>&5
3218   ac_status=$?
3219   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3220   test $ac_status = 0; }; then :
3221   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3222 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3223 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3224 # so that the user can short-circuit this test for compilers unknown to
3225 # Autoconf.
3226 for ac_file in $ac_files ''
3227 do
3228   test -f "$ac_file" || continue
3229   case $ac_file in
3230     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3231         ;;
3232     [ab].out )
3233         # We found the default executable, but exeext='' is most
3234         # certainly right.
3235         break;;
3236     *.* )
3237         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3238         then :; else
3239            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3240         fi
3241         # We set ac_cv_exeext here because the later test for it is not
3242         # safe: cross compilers may not add the suffix if given an `-o'
3243         # argument, so we may need to know it at that point already.
3244         # Even if this section looks crufty: it has the advantage of
3245         # actually working.
3246         break;;
3247     * )
3248         break;;
3249   esac
3250 done
3251 test "$ac_cv_exeext" = no && ac_cv_exeext=
3252
3253 else
3254   ac_file=''
3255 fi
3256 if test -z "$ac_file"; then :
3257   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3258 $as_echo "no" >&6; }
3259 $as_echo "$as_me: failed program was:" >&5
3260 sed 's/^/| /' conftest.$ac_ext >&5
3261
3262 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3263 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3264 as_fn_error 77 "C compiler cannot create executables
3265 See \`config.log' for more details" "$LINENO" 5; }
3266 else
3267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3268 $as_echo "yes" >&6; }
3269 fi
3270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3271 $as_echo_n "checking for C compiler default output file name... " >&6; }
3272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3273 $as_echo "$ac_file" >&6; }
3274 ac_exeext=$ac_cv_exeext
3275
3276 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3277 ac_clean_files=$ac_clean_files_save
3278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3279 $as_echo_n "checking for suffix of executables... " >&6; }
3280 if { { ac_try="$ac_link"
3281 case "(($ac_try" in
3282   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3283   *) ac_try_echo=$ac_try;;
3284 esac
3285 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3286 $as_echo "$ac_try_echo"; } >&5
3287   (eval "$ac_link") 2>&5
3288   ac_status=$?
3289   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3290   test $ac_status = 0; }; then :
3291   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3292 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3293 # work properly (i.e., refer to `conftest.exe'), while it won't with
3294 # `rm'.
3295 for ac_file in conftest.exe conftest conftest.*; do
3296   test -f "$ac_file" || continue
3297   case $ac_file in
3298     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3299     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3300           break;;
3301     * ) break;;
3302   esac
3303 done
3304 else
3305   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3306 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3307 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3308 See \`config.log' for more details" "$LINENO" 5; }
3309 fi
3310 rm -f conftest conftest$ac_cv_exeext
3311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3312 $as_echo "$ac_cv_exeext" >&6; }
3313
3314 rm -f conftest.$ac_ext
3315 EXEEXT=$ac_cv_exeext
3316 ac_exeext=$EXEEXT
3317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3318 /* end confdefs.h.  */
3319 #include <stdio.h>
3320 int
3321 main ()
3322 {
3323 FILE *f = fopen ("conftest.out", "w");
3324  return ferror (f) || fclose (f) != 0;
3325
3326   ;
3327   return 0;
3328 }
3329 _ACEOF
3330 ac_clean_files="$ac_clean_files conftest.out"
3331 # Check that the compiler produces executables we can run.  If not, either
3332 # the compiler is broken, or we cross compile.
3333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3334 $as_echo_n "checking whether we are cross compiling... " >&6; }
3335 if test "$cross_compiling" != yes; then
3336   { { ac_try="$ac_link"
3337 case "(($ac_try" in
3338   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3339   *) ac_try_echo=$ac_try;;
3340 esac
3341 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3342 $as_echo "$ac_try_echo"; } >&5
3343   (eval "$ac_link") 2>&5
3344   ac_status=$?
3345   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3346   test $ac_status = 0; }
3347   if { ac_try='./conftest$ac_cv_exeext'
3348   { { case "(($ac_try" in
3349   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3350   *) ac_try_echo=$ac_try;;
3351 esac
3352 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3353 $as_echo "$ac_try_echo"; } >&5
3354   (eval "$ac_try") 2>&5
3355   ac_status=$?
3356   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3357   test $ac_status = 0; }; }; then
3358     cross_compiling=no
3359   else
3360     if test "$cross_compiling" = maybe; then
3361         cross_compiling=yes
3362     else
3363         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3364 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3365 as_fn_error $? "cannot run C compiled programs.
3366 If you meant to cross compile, use \`--host'.
3367 See \`config.log' for more details" "$LINENO" 5; }
3368     fi
3369   fi
3370 fi
3371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3372 $as_echo "$cross_compiling" >&6; }
3373
3374 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3375 ac_clean_files=$ac_clean_files_save
3376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3377 $as_echo_n "checking for suffix of object files... " >&6; }
3378 if ${ac_cv_objext+:} false; then :
3379   $as_echo_n "(cached) " >&6
3380 else
3381   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3382 /* end confdefs.h.  */
3383
3384 int
3385 main ()
3386 {
3387
3388   ;
3389   return 0;
3390 }
3391 _ACEOF
3392 rm -f conftest.o conftest.obj
3393 if { { ac_try="$ac_compile"
3394 case "(($ac_try" in
3395   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3396   *) ac_try_echo=$ac_try;;
3397 esac
3398 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3399 $as_echo "$ac_try_echo"; } >&5
3400   (eval "$ac_compile") 2>&5
3401   ac_status=$?
3402   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3403   test $ac_status = 0; }; then :
3404   for ac_file in conftest.o conftest.obj conftest.*; do
3405   test -f "$ac_file" || continue;
3406   case $ac_file in
3407     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3408     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3409        break;;
3410   esac
3411 done
3412 else
3413   $as_echo "$as_me: failed program was:" >&5
3414 sed 's/^/| /' conftest.$ac_ext >&5
3415
3416 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3417 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3418 as_fn_error $? "cannot compute suffix of object files: cannot compile
3419 See \`config.log' for more details" "$LINENO" 5; }
3420 fi
3421 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3422 fi
3423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3424 $as_echo "$ac_cv_objext" >&6; }
3425 OBJEXT=$ac_cv_objext
3426 ac_objext=$OBJEXT
3427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3428 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3429 if ${ac_cv_c_compiler_gnu+:} false; then :
3430   $as_echo_n "(cached) " >&6
3431 else
3432   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3433 /* end confdefs.h.  */
3434
3435 int
3436 main ()
3437 {
3438 #ifndef __GNUC__
3439        choke me
3440 #endif
3441
3442   ;
3443   return 0;
3444 }
3445 _ACEOF
3446 if ac_fn_c_try_compile "$LINENO"; then :
3447   ac_compiler_gnu=yes
3448 else
3449   ac_compiler_gnu=no
3450 fi
3451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3452 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3453
3454 fi
3455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3456 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3457 if test $ac_compiler_gnu = yes; then
3458   GCC=yes
3459 else
3460   GCC=
3461 fi
3462 ac_test_CFLAGS=${CFLAGS+set}
3463 ac_save_CFLAGS=$CFLAGS
3464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3465 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3466 if ${ac_cv_prog_cc_g+:} false; then :
3467   $as_echo_n "(cached) " >&6
3468 else
3469   ac_save_c_werror_flag=$ac_c_werror_flag
3470    ac_c_werror_flag=yes
3471    ac_cv_prog_cc_g=no
3472    CFLAGS="-g"
3473    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3474 /* end confdefs.h.  */
3475
3476 int
3477 main ()
3478 {
3479
3480   ;
3481   return 0;
3482 }
3483 _ACEOF
3484 if ac_fn_c_try_compile "$LINENO"; then :
3485   ac_cv_prog_cc_g=yes
3486 else
3487   CFLAGS=""
3488       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3489 /* end confdefs.h.  */
3490
3491 int
3492 main ()
3493 {
3494
3495   ;
3496   return 0;
3497 }
3498 _ACEOF
3499 if ac_fn_c_try_compile "$LINENO"; then :
3500
3501 else
3502   ac_c_werror_flag=$ac_save_c_werror_flag
3503          CFLAGS="-g"
3504          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3505 /* end confdefs.h.  */
3506
3507 int
3508 main ()
3509 {
3510
3511   ;
3512   return 0;
3513 }
3514 _ACEOF
3515 if ac_fn_c_try_compile "$LINENO"; then :
3516   ac_cv_prog_cc_g=yes
3517 fi
3518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3519 fi
3520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3521 fi
3522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3523    ac_c_werror_flag=$ac_save_c_werror_flag
3524 fi
3525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3526 $as_echo "$ac_cv_prog_cc_g" >&6; }
3527 if test "$ac_test_CFLAGS" = set; then
3528   CFLAGS=$ac_save_CFLAGS
3529 elif test $ac_cv_prog_cc_g = yes; then
3530   if test "$GCC" = yes; then
3531     CFLAGS="-g -O2"
3532   else
3533     CFLAGS="-g"
3534   fi
3535 else
3536   if test "$GCC" = yes; then
3537     CFLAGS="-O2"
3538   else
3539     CFLAGS=
3540   fi
3541 fi
3542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3543 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3544 if ${ac_cv_prog_cc_c89+:} false; then :
3545   $as_echo_n "(cached) " >&6
3546 else
3547   ac_cv_prog_cc_c89=no
3548 ac_save_CC=$CC
3549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3550 /* end confdefs.h.  */
3551 #include <stdarg.h>
3552 #include <stdio.h>
3553 struct stat;
3554 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3555 struct buf { int x; };
3556 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3557 static char *e (p, i)
3558      char **p;
3559      int i;
3560 {
3561   return p[i];
3562 }
3563 static char *f (char * (*g) (char **, int), char **p, ...)
3564 {
3565   char *s;
3566   va_list v;
3567   va_start (v,p);
3568   s = g (p, va_arg (v,int));
3569   va_end (v);
3570   return s;
3571 }
3572
3573 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3574    function prototypes and stuff, but not '\xHH' hex character constants.
3575    These don't provoke an error unfortunately, instead are silently treated
3576    as 'x'.  The following induces an error, until -std is added to get
3577    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3578    array size at least.  It's necessary to write '\x00'==0 to get something
3579    that's true only with -std.  */
3580 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3581
3582 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3583    inside strings and character constants.  */
3584 #define FOO(x) 'x'
3585 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3586
3587 int test (int i, double x);
3588 struct s1 {int (*f) (int a);};
3589 struct s2 {int (*f) (double a);};
3590 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3591 int argc;
3592 char **argv;
3593 int
3594 main ()
3595 {
3596 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3597   ;
3598   return 0;
3599 }
3600 _ACEOF
3601 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3602         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3603 do
3604   CC="$ac_save_CC $ac_arg"
3605   if ac_fn_c_try_compile "$LINENO"; then :
3606   ac_cv_prog_cc_c89=$ac_arg
3607 fi
3608 rm -f core conftest.err conftest.$ac_objext
3609   test "x$ac_cv_prog_cc_c89" != "xno" && break
3610 done
3611 rm -f conftest.$ac_ext
3612 CC=$ac_save_CC
3613
3614 fi
3615 # AC_CACHE_VAL
3616 case "x$ac_cv_prog_cc_c89" in
3617   x)
3618     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3619 $as_echo "none needed" >&6; } ;;
3620   xno)
3621     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3622 $as_echo "unsupported" >&6; } ;;
3623   *)
3624     CC="$CC $ac_cv_prog_cc_c89"
3625     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3626 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3627 esac
3628 if test "x$ac_cv_prog_cc_c89" != xno; then :
3629
3630 fi
3631
3632 ac_ext=c
3633 ac_cpp='$CPP $CPPFLAGS'
3634 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3635 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3636 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3637
3638
3639 ac_ext=c
3640 ac_cpp='$CPP $CPPFLAGS'
3641 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3642 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3643 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3645 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3646 # On Suns, sometimes $CPP names a directory.
3647 if test -n "$CPP" && test -d "$CPP"; then
3648   CPP=
3649 fi
3650 if test -z "$CPP"; then
3651   if ${ac_cv_prog_CPP+:} false; then :
3652   $as_echo_n "(cached) " >&6
3653 else
3654       # Double quotes because CPP needs to be expanded
3655     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3656     do
3657       ac_preproc_ok=false
3658 for ac_c_preproc_warn_flag in '' yes
3659 do
3660   # Use a header file that comes with gcc, so configuring glibc
3661   # with a fresh cross-compiler works.
3662   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3663   # <limits.h> exists even on freestanding compilers.
3664   # On the NeXT, cc -E runs the code through the compiler's parser,
3665   # not just through cpp. "Syntax error" is here to catch this case.
3666   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3667 /* end confdefs.h.  */
3668 #ifdef __STDC__
3669 # include <limits.h>
3670 #else
3671 # include <assert.h>
3672 #endif
3673                      Syntax error
3674 _ACEOF
3675 if ac_fn_c_try_cpp "$LINENO"; then :
3676
3677 else
3678   # Broken: fails on valid input.
3679 continue
3680 fi
3681 rm -f conftest.err conftest.i conftest.$ac_ext
3682
3683   # OK, works on sane cases.  Now check whether nonexistent headers
3684   # can be detected and how.
3685   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3686 /* end confdefs.h.  */
3687 #include <ac_nonexistent.h>
3688 _ACEOF
3689 if ac_fn_c_try_cpp "$LINENO"; then :
3690   # Broken: success on invalid input.
3691 continue
3692 else
3693   # Passes both tests.
3694 ac_preproc_ok=:
3695 break
3696 fi
3697 rm -f conftest.err conftest.i conftest.$ac_ext
3698
3699 done
3700 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3701 rm -f conftest.i conftest.err conftest.$ac_ext
3702 if $ac_preproc_ok; then :
3703   break
3704 fi
3705
3706     done
3707     ac_cv_prog_CPP=$CPP
3708
3709 fi
3710   CPP=$ac_cv_prog_CPP
3711 else
3712   ac_cv_prog_CPP=$CPP
3713 fi
3714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3715 $as_echo "$CPP" >&6; }
3716 ac_preproc_ok=false
3717 for ac_c_preproc_warn_flag in '' yes
3718 do
3719   # Use a header file that comes with gcc, so configuring glibc
3720   # with a fresh cross-compiler works.
3721   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3722   # <limits.h> exists even on freestanding compilers.
3723   # On the NeXT, cc -E runs the code through the compiler's parser,
3724   # not just through cpp. "Syntax error" is here to catch this case.
3725   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3726 /* end confdefs.h.  */
3727 #ifdef __STDC__
3728 # include <limits.h>
3729 #else
3730 # include <assert.h>
3731 #endif
3732                      Syntax error
3733 _ACEOF
3734 if ac_fn_c_try_cpp "$LINENO"; then :
3735
3736 else
3737   # Broken: fails on valid input.
3738 continue
3739 fi
3740 rm -f conftest.err conftest.i conftest.$ac_ext
3741
3742   # OK, works on sane cases.  Now check whether nonexistent headers
3743   # can be detected and how.
3744   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3745 /* end confdefs.h.  */
3746 #include <ac_nonexistent.h>
3747 _ACEOF
3748 if ac_fn_c_try_cpp "$LINENO"; then :
3749   # Broken: success on invalid input.
3750 continue
3751 else
3752   # Passes both tests.
3753 ac_preproc_ok=:
3754 break
3755 fi
3756 rm -f conftest.err conftest.i conftest.$ac_ext
3757
3758 done
3759 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3760 rm -f conftest.i conftest.err conftest.$ac_ext
3761 if $ac_preproc_ok; then :
3762
3763 else
3764   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3765 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3766 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3767 See \`config.log' for more details" "$LINENO" 5; }
3768 fi
3769
3770 ac_ext=c
3771 ac_cpp='$CPP $CPPFLAGS'
3772 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3773 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3774 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3775
3776
3777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3778 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3779 if ${ac_cv_path_GREP+:} false; then :
3780   $as_echo_n "(cached) " >&6
3781 else
3782   if test -z "$GREP"; then
3783   ac_path_GREP_found=false
3784   # Loop through the user's path and test for each of PROGNAME-LIST
3785   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3786 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3787 do
3788   IFS=$as_save_IFS
3789   test -z "$as_dir" && as_dir=.
3790     for ac_prog in grep ggrep; do
3791     for ac_exec_ext in '' $ac_executable_extensions; do
3792       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3793       as_fn_executable_p "$ac_path_GREP" || continue
3794 # Check for GNU ac_path_GREP and select it if it is found.
3795   # Check for GNU $ac_path_GREP
3796 case `"$ac_path_GREP" --version 2>&1` in
3797 *GNU*)
3798   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3799 *)
3800   ac_count=0
3801   $as_echo_n 0123456789 >"conftest.in"
3802   while :
3803   do
3804     cat "conftest.in" "conftest.in" >"conftest.tmp"
3805     mv "conftest.tmp" "conftest.in"
3806     cp "conftest.in" "conftest.nl"
3807     $as_echo 'GREP' >> "conftest.nl"
3808     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3809     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3810     as_fn_arith $ac_count + 1 && ac_count=$as_val
3811     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3812       # Best one so far, save it but keep looking for a better one
3813       ac_cv_path_GREP="$ac_path_GREP"
3814       ac_path_GREP_max=$ac_count
3815     fi
3816     # 10*(2^10) chars as input seems more than enough
3817     test $ac_count -gt 10 && break
3818   done
3819   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3820 esac
3821
3822       $ac_path_GREP_found && break 3
3823     done
3824   done
3825   done
3826 IFS=$as_save_IFS
3827   if test -z "$ac_cv_path_GREP"; then
3828     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3829   fi
3830 else
3831   ac_cv_path_GREP=$GREP
3832 fi
3833
3834 fi
3835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3836 $as_echo "$ac_cv_path_GREP" >&6; }
3837  GREP="$ac_cv_path_GREP"
3838
3839
3840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3841 $as_echo_n "checking for egrep... " >&6; }
3842 if ${ac_cv_path_EGREP+:} false; then :
3843   $as_echo_n "(cached) " >&6
3844 else
3845   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3846    then ac_cv_path_EGREP="$GREP -E"
3847    else
3848      if test -z "$EGREP"; then
3849   ac_path_EGREP_found=false
3850   # Loop through the user's path and test for each of PROGNAME-LIST
3851   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3852 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3853 do
3854   IFS=$as_save_IFS
3855   test -z "$as_dir" && as_dir=.
3856     for ac_prog in egrep; do
3857     for ac_exec_ext in '' $ac_executable_extensions; do
3858       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3859       as_fn_executable_p "$ac_path_EGREP" || continue
3860 # Check for GNU ac_path_EGREP and select it if it is found.
3861   # Check for GNU $ac_path_EGREP
3862 case `"$ac_path_EGREP" --version 2>&1` in
3863 *GNU*)
3864   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3865 *)
3866   ac_count=0
3867   $as_echo_n 0123456789 >"conftest.in"
3868   while :
3869   do
3870     cat "conftest.in" "conftest.in" >"conftest.tmp"
3871     mv "conftest.tmp" "conftest.in"
3872     cp "conftest.in" "conftest.nl"
3873     $as_echo 'EGREP' >> "conftest.nl"
3874     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3875     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3876     as_fn_arith $ac_count + 1 && ac_count=$as_val
3877     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3878       # Best one so far, save it but keep looking for a better one
3879       ac_cv_path_EGREP="$ac_path_EGREP"
3880       ac_path_EGREP_max=$ac_count
3881     fi
3882     # 10*(2^10) chars as input seems more than enough
3883     test $ac_count -gt 10 && break
3884   done
3885   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3886 esac
3887
3888       $ac_path_EGREP_found && break 3
3889     done
3890   done
3891   done
3892 IFS=$as_save_IFS
3893   if test -z "$ac_cv_path_EGREP"; then
3894     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3895   fi
3896 else
3897   ac_cv_path_EGREP=$EGREP
3898 fi
3899
3900    fi
3901 fi
3902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3903 $as_echo "$ac_cv_path_EGREP" >&6; }
3904  EGREP="$ac_cv_path_EGREP"
3905
3906
3907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3908 $as_echo_n "checking for ANSI C header files... " >&6; }
3909 if ${ac_cv_header_stdc+:} false; then :
3910   $as_echo_n "(cached) " >&6
3911 else
3912   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3913 /* end confdefs.h.  */
3914 #include <stdlib.h>
3915 #include <stdarg.h>
3916 #include <string.h>
3917 #include <float.h>
3918
3919 int
3920 main ()
3921 {
3922
3923   ;
3924   return 0;
3925 }
3926 _ACEOF
3927 if ac_fn_c_try_compile "$LINENO"; then :
3928   ac_cv_header_stdc=yes
3929 else
3930   ac_cv_header_stdc=no
3931 fi
3932 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3933
3934 if test $ac_cv_header_stdc = yes; then
3935   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3936   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3937 /* end confdefs.h.  */
3938 #include <string.h>
3939
3940 _ACEOF
3941 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3942   $EGREP "memchr" >/dev/null 2>&1; then :
3943
3944 else
3945   ac_cv_header_stdc=no
3946 fi
3947 rm -f conftest*
3948
3949 fi
3950
3951 if test $ac_cv_header_stdc = yes; then
3952   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3953   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3954 /* end confdefs.h.  */
3955 #include <stdlib.h>
3956
3957 _ACEOF
3958 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3959   $EGREP "free" >/dev/null 2>&1; then :
3960
3961 else
3962   ac_cv_header_stdc=no
3963 fi
3964 rm -f conftest*
3965
3966 fi
3967
3968 if test $ac_cv_header_stdc = yes; then
3969   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3970   if test "$cross_compiling" = yes; then :
3971   :
3972 else
3973   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3974 /* end confdefs.h.  */
3975 #include <ctype.h>
3976 #include <stdlib.h>
3977 #if ((' ' & 0x0FF) == 0x020)
3978 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3979 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3980 #else
3981 # define ISLOWER(c) \
3982                    (('a' <= (c) && (c) <= 'i') \
3983                      || ('j' <= (c) && (c) <= 'r') \
3984                      || ('s' <= (c) && (c) <= 'z'))
3985 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3986 #endif
3987
3988 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3989 int
3990 main ()
3991 {
3992   int i;
3993   for (i = 0; i < 256; i++)
3994     if (XOR (islower (i), ISLOWER (i))
3995         || toupper (i) != TOUPPER (i))
3996       return 2;
3997   return 0;
3998 }
3999 _ACEOF
4000 if ac_fn_c_try_run "$LINENO"; then :
4001
4002 else
4003   ac_cv_header_stdc=no
4004 fi
4005 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4006   conftest.$ac_objext conftest.beam conftest.$ac_ext
4007 fi
4008
4009 fi
4010 fi
4011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4012 $as_echo "$ac_cv_header_stdc" >&6; }
4013 if test $ac_cv_header_stdc = yes; then
4014
4015 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4016
4017 fi
4018
4019 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4020 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4021                   inttypes.h stdint.h unistd.h
4022 do :
4023   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4024 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4025 "
4026 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4027   cat >>confdefs.h <<_ACEOF
4028 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4029 _ACEOF
4030
4031 fi
4032
4033 done
4034
4035
4036
4037   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4038 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4039   MINIX=yes
4040 else
4041   MINIX=
4042 fi
4043
4044
4045   if test "$MINIX" = yes; then
4046
4047 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4048
4049
4050 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4051
4052
4053 $as_echo "#define _MINIX 1" >>confdefs.h
4054
4055   fi
4056
4057
4058   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4059 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4060 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4061   $as_echo_n "(cached) " >&6
4062 else
4063   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4064 /* end confdefs.h.  */
4065
4066 #         define __EXTENSIONS__ 1
4067           $ac_includes_default
4068 int
4069 main ()
4070 {
4071
4072   ;
4073   return 0;
4074 }
4075 _ACEOF
4076 if ac_fn_c_try_compile "$LINENO"; then :
4077   ac_cv_safe_to_define___extensions__=yes
4078 else
4079   ac_cv_safe_to_define___extensions__=no
4080 fi
4081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4082 fi
4083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4084 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4085   test $ac_cv_safe_to_define___extensions__ = yes &&
4086     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4087
4088   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4089
4090   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4091
4092   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4093
4094   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4095
4096
4097
4098 if test "$ac_cv_header_minix_config_h" = "yes"; then
4099
4100 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4101
4102 fi
4103
4104 case "$prefix" in
4105         NONE)
4106                 prefix="/usr/local"
4107         ;;
4108 esac
4109
4110 # are we on MinGW?
4111 if uname -s 2>&1 | grep MINGW32 >/dev/null; then on_mingw="yes"
4112 else
4113         if echo $host $target | grep mingw32 >/dev/null; then on_mingw="yes"
4114         else on_mingw="no"; fi
4115 fi
4116
4117 #
4118 # Determine configuration file
4119 # the eval is to evaluate shell expansion twice
4120 if test $on_mingw = "no"; then
4121   ub_conf_file=`eval echo "${sysconfdir}/unbound/unbound.conf"`
4122 else
4123   ub_conf_file="C:\\Program Files\\Unbound\\service.conf"
4124 fi
4125
4126 # Check whether --with-conf_file was given.
4127 if test "${with_conf_file+set}" = set; then :
4128   withval=$with_conf_file; ub_conf_file="$withval"
4129 fi
4130
4131
4132 hdr_config="`echo $ub_conf_file | sed -e 's/\\\\/\\\\\\\\/g'`"
4133
4134
4135 cat >>confdefs.h <<_ACEOF
4136 #define CONFIGFILE "$hdr_config"
4137 _ACEOF
4138
4139 ub_conf_dir=`$as_dirname -- "$ub_conf_file" ||
4140 $as_expr X"$ub_conf_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4141          X"$ub_conf_file" : 'X\(//\)[^/]' \| \
4142          X"$ub_conf_file" : 'X\(//\)$' \| \
4143          X"$ub_conf_file" : 'X\(/\)' \| . 2>/dev/null ||
4144 $as_echo X"$ub_conf_file" |
4145     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
4146             s//\1/
4147             q
4148           }
4149           /^X\(\/\/\)[^/].*/{
4150             s//\1/
4151             q
4152           }
4153           /^X\(\/\/\)$/{
4154             s//\1/
4155             q
4156           }
4157           /^X\(\/\).*/{
4158             s//\1/
4159             q
4160           }
4161           s/.*/./; q'`
4162
4163
4164 # Determine run, chroot directory and pidfile locations
4165
4166 # Check whether --with-run-dir was given.
4167 if test "${with_run_dir+set}" = set; then :
4168   withval=$with_run_dir; UNBOUND_RUN_DIR="$withval"
4169 else
4170   if test $on_mingw = no; then
4171     UNBOUND_RUN_DIR=`dirname "$ub_conf_file"`
4172 else
4173     UNBOUND_RUN_DIR=""
4174 fi
4175
4176 fi
4177
4178
4179 hdr_run="`echo $UNBOUND_RUN_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4180
4181
4182 cat >>confdefs.h <<_ACEOF
4183 #define RUN_DIR "$hdr_run"
4184 _ACEOF
4185
4186
4187
4188 # Check whether --with-chroot-dir was given.
4189 if test "${with_chroot_dir+set}" = set; then :
4190   withval=$with_chroot_dir; UNBOUND_CHROOT_DIR="$withval"
4191 else
4192   if test $on_mingw = no; then
4193     UNBOUND_CHROOT_DIR="$UNBOUND_RUN_DIR"
4194 else
4195     UNBOUND_CHROOT_DIR=""
4196 fi
4197
4198 fi
4199
4200
4201 hdr_chroot="`echo $UNBOUND_CHROOT_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4202
4203
4204 cat >>confdefs.h <<_ACEOF
4205 #define CHROOT_DIR "$hdr_chroot"
4206 _ACEOF
4207
4208
4209
4210 # Check whether --with-share-dir was given.
4211 if test "${with_share_dir+set}" = set; then :
4212   withval=$with_share_dir; UNBOUND_SHARE_DIR="$withval"
4213 else
4214   UNBOUND_SHARE_DIR="$UNBOUND_RUN_DIR"
4215 fi
4216
4217
4218
4219 cat >>confdefs.h <<_ACEOF
4220 #define SHARE_DIR "$UNBOUND_SHARE_DIR"
4221 _ACEOF
4222
4223
4224
4225 # Check whether --with-pidfile was given.
4226 if test "${with_pidfile+set}" = set; then :
4227   withval=$with_pidfile; UNBOUND_PIDFILE="$withval"
4228 else
4229   if test $on_mingw = no; then
4230     UNBOUND_PIDFILE="$UNBOUND_RUN_DIR/unbound.pid"
4231 else
4232     UNBOUND_PIDFILE=""
4233 fi
4234
4235 fi
4236
4237
4238 hdr_pid="`echo $UNBOUND_PIDFILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4239
4240
4241 cat >>confdefs.h <<_ACEOF
4242 #define PIDFILE "$hdr_pid"
4243 _ACEOF
4244
4245
4246
4247 # Check whether --with-rootkey-file was given.
4248 if test "${with_rootkey_file+set}" = set; then :
4249   withval=$with_rootkey_file; UNBOUND_ROOTKEY_FILE="$withval"
4250 else
4251   if test $on_mingw = no; then
4252     UNBOUND_ROOTKEY_FILE="$UNBOUND_RUN_DIR/root.key"
4253 else
4254     UNBOUND_ROOTKEY_FILE="C:\\Program Files\\Unbound\\root.key"
4255 fi
4256
4257 fi
4258
4259
4260 hdr_rkey="`echo $UNBOUND_ROOTKEY_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4261
4262
4263 cat >>confdefs.h <<_ACEOF
4264 #define ROOT_ANCHOR_FILE "$hdr_rkey"
4265 _ACEOF
4266
4267
4268
4269 # Check whether --with-rootcert-file was given.
4270 if test "${with_rootcert_file+set}" = set; then :
4271   withval=$with_rootcert_file; UNBOUND_ROOTCERT_FILE="$withval"
4272 else
4273   if test $on_mingw = no; then
4274     UNBOUND_ROOTCERT_FILE="$UNBOUND_RUN_DIR/icannbundle.pem"
4275 else
4276     UNBOUND_ROOTCERT_FILE="C:\\Program Files\\Unbound\\icannbundle.pem"
4277 fi
4278
4279 fi
4280
4281
4282 hdr_rpem="`echo $UNBOUND_ROOTCERT_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4283
4284
4285 cat >>confdefs.h <<_ACEOF
4286 #define ROOT_CERT_FILE "$hdr_rpem"
4287 _ACEOF
4288
4289
4290
4291 # Check whether --with-username was given.
4292 if test "${with_username+set}" = set; then :
4293   withval=$with_username; UNBOUND_USERNAME="$withval"
4294 else
4295   UNBOUND_USERNAME="unbound"
4296 fi
4297
4298
4299
4300 cat >>confdefs.h <<_ACEOF
4301 #define UB_USERNAME "$UNBOUND_USERNAME"
4302 _ACEOF
4303
4304
4305
4306 $as_echo "#define WINVER 0x0502" >>confdefs.h
4307
4308 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/' `
4309
4310
4311 cat >>confdefs.h <<_ACEOF
4312 #define RSRC_PACKAGE_VERSION $wnvs
4313 _ACEOF
4314
4315
4316 # Checks for typedefs, structures, and compiler characteristics.
4317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
4318 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
4319 if ${ac_cv_c_const+:} false; then :
4320   $as_echo_n "(cached) " >&6
4321 else
4322   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4323 /* end confdefs.h.  */
4324
4325 int
4326 main ()
4327 {
4328
4329 #ifndef __cplusplus
4330   /* Ultrix mips cc rejects this sort of thing.  */
4331   typedef int charset[2];
4332   const charset cs = { 0, 0 };
4333   /* SunOS 4.1.1 cc rejects this.  */
4334   char const *const *pcpcc;
4335   char **ppc;
4336   /* NEC SVR4.0.2 mips cc rejects this.  */
4337   struct point {int x, y;};
4338   static struct point const zero = {0,0};
4339   /* AIX XL C 1.02.0.0 rejects this.
4340      It does not let you subtract one const X* pointer from another in
4341      an arm of an if-expression whose if-part is not a constant
4342      expression */
4343   const char *g = "string";
4344   pcpcc = &g + (g ? g-g : 0);
4345   /* HPUX 7.0 cc rejects these. */
4346   ++pcpcc;
4347   ppc = (char**) pcpcc;
4348   pcpcc = (char const *const *) ppc;
4349   { /* SCO 3.2v4 cc rejects this sort of thing.  */
4350     char tx;
4351     char *t = &tx;
4352     char const *s = 0 ? (char *) 0 : (char const *) 0;
4353
4354     *t++ = 0;
4355     if (s) return 0;
4356   }
4357   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
4358     int x[] = {25, 17};
4359     const int *foo = &x[0];
4360     ++foo;
4361   }
4362   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4363     typedef const int *iptr;
4364     iptr p = 0;
4365     ++p;
4366   }
4367   { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
4368        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4369     struct s { int j; const int *ap[3]; } bx;
4370     struct s *b = &bx; b->j = 5;
4371   }
4372   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4373     const int foo = 10;
4374     if (!foo) return 0;
4375   }
4376   return !cs[0] && !zero.x;
4377 #endif
4378
4379   ;
4380   return 0;
4381 }
4382 _ACEOF
4383 if ac_fn_c_try_compile "$LINENO"; then :
4384   ac_cv_c_const=yes
4385 else
4386   ac_cv_c_const=no
4387 fi
4388 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4389 fi
4390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
4391 $as_echo "$ac_cv_c_const" >&6; }
4392 if test $ac_cv_c_const = no; then
4393
4394 $as_echo "#define const /**/" >>confdefs.h
4395
4396 fi
4397
4398 ac_ext=c
4399 ac_cpp='$CPP $CPPFLAGS'
4400 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4401 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4402 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4403
4404 # allow user to override the -g -O2 flags.
4405 if test "x$CFLAGS" = "x" ; then
4406
4407
4408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -g" >&5
4409 $as_echo_n "checking whether $CC supports -g... " >&6; }
4410 cache=`echo g | sed 'y%.=/+-%___p_%'`
4411 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4412   $as_echo_n "(cached) " >&6
4413 else
4414
4415 echo 'void f(void){}' >conftest.c
4416 if test -z "`$CC $CPPFLAGS $CFLAGS -g -c conftest.c 2>&1`"; then
4417 eval "cv_prog_cc_flag_$cache=yes"
4418 else
4419 eval "cv_prog_cc_flag_$cache=no"
4420 fi
4421 rm -f conftest conftest.o conftest.c
4422
4423 fi
4424
4425 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4427 $as_echo "yes" >&6; }
4428 :
4429 CFLAGS="$CFLAGS -g"
4430 else
4431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4432 $as_echo "no" >&6; }
4433 :
4434
4435 fi
4436
4437
4438
4439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -O2" >&5
4440 $as_echo_n "checking whether $CC supports -O2... " >&6; }
4441 cache=`echo O2 | sed 'y%.=/+-%___p_%'`
4442 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4443   $as_echo_n "(cached) " >&6
4444 else
4445
4446 echo 'void f(void){}' >conftest.c
4447 if test -z "`$CC $CPPFLAGS $CFLAGS -O2 -c conftest.c 2>&1`"; then
4448 eval "cv_prog_cc_flag_$cache=yes"
4449 else
4450 eval "cv_prog_cc_flag_$cache=no"
4451 fi
4452 rm -f conftest conftest.o conftest.c
4453
4454 fi
4455
4456 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4458 $as_echo "yes" >&6; }
4459 :
4460 CFLAGS="$CFLAGS -O2"
4461 else
4462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4463 $as_echo "no" >&6; }
4464 :
4465
4466 fi
4467
4468 fi
4469 ac_ext=c
4470 ac_cpp='$CPP $CPPFLAGS'
4471 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4472 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4473 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4474 if test -n "$ac_tool_prefix"; then
4475   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4476 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4478 $as_echo_n "checking for $ac_word... " >&6; }
4479 if ${ac_cv_prog_CC+:} false; then :
4480   $as_echo_n "(cached) " >&6
4481 else
4482   if test -n "$CC"; then
4483   ac_cv_prog_CC="$CC" # Let the user override the test.
4484 else
4485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4486 for as_dir in $PATH
4487 do
4488   IFS=$as_save_IFS
4489   test -z "$as_dir" && as_dir=.
4490     for ac_exec_ext in '' $ac_executable_extensions; do
4491   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4492     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4493     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4494     break 2
4495   fi
4496 done
4497   done
4498 IFS=$as_save_IFS
4499
4500 fi
4501 fi
4502 CC=$ac_cv_prog_CC
4503 if test -n "$CC"; then
4504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4505 $as_echo "$CC" >&6; }
4506 else
4507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4508 $as_echo "no" >&6; }
4509 fi
4510
4511
4512 fi
4513 if test -z "$ac_cv_prog_CC"; then
4514   ac_ct_CC=$CC
4515   # Extract the first word of "gcc", so it can be a program name with args.
4516 set dummy gcc; ac_word=$2
4517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4518 $as_echo_n "checking for $ac_word... " >&6; }
4519 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4520   $as_echo_n "(cached) " >&6
4521 else
4522   if test -n "$ac_ct_CC"; then
4523   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4524 else
4525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4526 for as_dir in $PATH
4527 do
4528   IFS=$as_save_IFS
4529   test -z "$as_dir" && as_dir=.
4530     for ac_exec_ext in '' $ac_executable_extensions; do
4531   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4532     ac_cv_prog_ac_ct_CC="gcc"
4533     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4534     break 2
4535   fi
4536 done
4537   done
4538 IFS=$as_save_IFS
4539
4540 fi
4541 fi
4542 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4543 if test -n "$ac_ct_CC"; then
4544   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4545 $as_echo "$ac_ct_CC" >&6; }
4546 else
4547   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4548 $as_echo "no" >&6; }
4549 fi
4550
4551   if test "x$ac_ct_CC" = x; then
4552     CC=""
4553   else
4554     case $cross_compiling:$ac_tool_warned in
4555 yes:)
4556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4557 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4558 ac_tool_warned=yes ;;
4559 esac
4560     CC=$ac_ct_CC
4561   fi
4562 else
4563   CC="$ac_cv_prog_CC"
4564 fi
4565
4566 if test -z "$CC"; then
4567           if test -n "$ac_tool_prefix"; then
4568     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4569 set dummy ${ac_tool_prefix}cc; ac_word=$2
4570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4571 $as_echo_n "checking for $ac_word... " >&6; }
4572 if ${ac_cv_prog_CC+:} false; then :
4573   $as_echo_n "(cached) " >&6
4574 else
4575   if test -n "$CC"; then
4576   ac_cv_prog_CC="$CC" # Let the user override the test.
4577 else
4578 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4579 for as_dir in $PATH
4580 do
4581   IFS=$as_save_IFS
4582   test -z "$as_dir" && as_dir=.
4583     for ac_exec_ext in '' $ac_executable_extensions; do
4584   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4585     ac_cv_prog_CC="${ac_tool_prefix}cc"
4586     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4587     break 2
4588   fi
4589 done
4590   done
4591 IFS=$as_save_IFS
4592
4593 fi
4594 fi
4595 CC=$ac_cv_prog_CC
4596 if test -n "$CC"; then
4597   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4598 $as_echo "$CC" >&6; }
4599 else
4600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4601 $as_echo "no" >&6; }
4602 fi
4603
4604
4605   fi
4606 fi
4607 if test -z "$CC"; then
4608   # Extract the first word of "cc", so it can be a program name with args.
4609 set dummy cc; ac_word=$2
4610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4611 $as_echo_n "checking for $ac_word... " >&6; }
4612 if ${ac_cv_prog_CC+:} false; then :
4613   $as_echo_n "(cached) " >&6
4614 else
4615   if test -n "$CC"; then
4616   ac_cv_prog_CC="$CC" # Let the user override the test.
4617 else
4618   ac_prog_rejected=no
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     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4627        ac_prog_rejected=yes
4628        continue
4629      fi
4630     ac_cv_prog_CC="cc"
4631     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4632     break 2
4633   fi
4634 done
4635   done
4636 IFS=$as_save_IFS
4637
4638 if test $ac_prog_rejected = yes; then
4639   # We found a bogon in the path, so make sure we never use it.
4640   set dummy $ac_cv_prog_CC
4641   shift
4642   if test $# != 0; then
4643     # We chose a different compiler from the bogus one.
4644     # However, it has the same basename, so the bogon will be chosen
4645     # first if we set CC to just the basename; use the full file name.
4646     shift
4647     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4648   fi
4649 fi
4650 fi
4651 fi
4652 CC=$ac_cv_prog_CC
4653 if test -n "$CC"; then
4654   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4655 $as_echo "$CC" >&6; }
4656 else
4657   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4658 $as_echo "no" >&6; }
4659 fi
4660
4661
4662 fi
4663 if test -z "$CC"; then
4664   if test -n "$ac_tool_prefix"; then
4665   for ac_prog in cl.exe
4666   do
4667     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4668 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4670 $as_echo_n "checking for $ac_word... " >&6; }
4671 if ${ac_cv_prog_CC+:} false; then :
4672   $as_echo_n "(cached) " >&6
4673 else
4674   if test -n "$CC"; then
4675   ac_cv_prog_CC="$CC" # Let the user override the test.
4676 else
4677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4678 for as_dir in $PATH
4679 do
4680   IFS=$as_save_IFS
4681   test -z "$as_dir" && as_dir=.
4682     for ac_exec_ext in '' $ac_executable_extensions; do
4683   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4684     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4685     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4686     break 2
4687   fi
4688 done
4689   done
4690 IFS=$as_save_IFS
4691
4692 fi
4693 fi
4694 CC=$ac_cv_prog_CC
4695 if test -n "$CC"; then
4696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4697 $as_echo "$CC" >&6; }
4698 else
4699   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4700 $as_echo "no" >&6; }
4701 fi
4702
4703
4704     test -n "$CC" && break
4705   done
4706 fi
4707 if test -z "$CC"; then
4708   ac_ct_CC=$CC
4709   for ac_prog in cl.exe
4710 do
4711   # Extract the first word of "$ac_prog", so it can be a program name with args.
4712 set dummy $ac_prog; ac_word=$2
4713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4714 $as_echo_n "checking for $ac_word... " >&6; }
4715 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4716   $as_echo_n "(cached) " >&6
4717 else
4718   if test -n "$ac_ct_CC"; then
4719   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4720 else
4721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4722 for as_dir in $PATH
4723 do
4724   IFS=$as_save_IFS
4725   test -z "$as_dir" && as_dir=.
4726     for ac_exec_ext in '' $ac_executable_extensions; do
4727   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4728     ac_cv_prog_ac_ct_CC="$ac_prog"
4729     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4730     break 2
4731   fi
4732 done
4733   done
4734 IFS=$as_save_IFS
4735
4736 fi
4737 fi
4738 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4739 if test -n "$ac_ct_CC"; then
4740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4741 $as_echo "$ac_ct_CC" >&6; }
4742 else
4743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4744 $as_echo "no" >&6; }
4745 fi
4746
4747
4748   test -n "$ac_ct_CC" && break
4749 done
4750
4751   if test "x$ac_ct_CC" = x; then
4752     CC=""
4753   else
4754     case $cross_compiling:$ac_tool_warned in
4755 yes:)
4756 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4757 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4758 ac_tool_warned=yes ;;
4759 esac
4760     CC=$ac_ct_CC
4761   fi
4762 fi
4763
4764 fi
4765
4766
4767 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4768 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4769 as_fn_error $? "no acceptable C compiler found in \$PATH
4770 See \`config.log' for more details" "$LINENO" 5; }
4771
4772 # Provide some information about the compiler.
4773 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4774 set X $ac_compile
4775 ac_compiler=$2
4776 for ac_option in --version -v -V -qversion; do
4777   { { ac_try="$ac_compiler $ac_option >&5"
4778 case "(($ac_try" in
4779   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4780   *) ac_try_echo=$ac_try;;
4781 esac
4782 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4783 $as_echo "$ac_try_echo"; } >&5
4784   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4785   ac_status=$?
4786   if test -s conftest.err; then
4787     sed '10a\
4788 ... rest of stderr output deleted ...
4789          10q' conftest.err >conftest.er1
4790     cat conftest.er1 >&5
4791   fi
4792   rm -f conftest.er1 conftest.err
4793   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4794   test $ac_status = 0; }
4795 done
4796
4797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4798 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4799 if ${ac_cv_c_compiler_gnu+:} false; then :
4800   $as_echo_n "(cached) " >&6
4801 else
4802   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4803 /* end confdefs.h.  */
4804
4805 int
4806 main ()
4807 {
4808 #ifndef __GNUC__
4809        choke me
4810 #endif
4811
4812   ;
4813   return 0;
4814 }
4815 _ACEOF
4816 if ac_fn_c_try_compile "$LINENO"; then :
4817   ac_compiler_gnu=yes
4818 else
4819   ac_compiler_gnu=no
4820 fi
4821 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4822 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4823
4824 fi
4825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4826 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4827 if test $ac_compiler_gnu = yes; then
4828   GCC=yes
4829 else
4830   GCC=
4831 fi
4832 ac_test_CFLAGS=${CFLAGS+set}
4833 ac_save_CFLAGS=$CFLAGS
4834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4835 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4836 if ${ac_cv_prog_cc_g+:} false; then :
4837   $as_echo_n "(cached) " >&6
4838 else
4839   ac_save_c_werror_flag=$ac_c_werror_flag
4840    ac_c_werror_flag=yes
4841    ac_cv_prog_cc_g=no
4842    CFLAGS="-g"
4843    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4844 /* end confdefs.h.  */
4845
4846 int
4847 main ()
4848 {
4849
4850   ;
4851   return 0;
4852 }
4853 _ACEOF
4854 if ac_fn_c_try_compile "$LINENO"; then :
4855   ac_cv_prog_cc_g=yes
4856 else
4857   CFLAGS=""
4858       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4859 /* end confdefs.h.  */
4860
4861 int
4862 main ()
4863 {
4864
4865   ;
4866   return 0;
4867 }
4868 _ACEOF
4869 if ac_fn_c_try_compile "$LINENO"; then :
4870
4871 else
4872   ac_c_werror_flag=$ac_save_c_werror_flag
4873          CFLAGS="-g"
4874          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4875 /* end confdefs.h.  */
4876
4877 int
4878 main ()
4879 {
4880
4881   ;
4882   return 0;
4883 }
4884 _ACEOF
4885 if ac_fn_c_try_compile "$LINENO"; then :
4886   ac_cv_prog_cc_g=yes
4887 fi
4888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4889 fi
4890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4891 fi
4892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4893    ac_c_werror_flag=$ac_save_c_werror_flag
4894 fi
4895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4896 $as_echo "$ac_cv_prog_cc_g" >&6; }
4897 if test "$ac_test_CFLAGS" = set; then
4898   CFLAGS=$ac_save_CFLAGS
4899 elif test $ac_cv_prog_cc_g = yes; then
4900   if test "$GCC" = yes; then
4901     CFLAGS="-g -O2"
4902   else
4903     CFLAGS="-g"
4904   fi
4905 else
4906   if test "$GCC" = yes; then
4907     CFLAGS="-O2"
4908   else
4909     CFLAGS=
4910   fi
4911 fi
4912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4913 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4914 if ${ac_cv_prog_cc_c89+:} false; then :
4915   $as_echo_n "(cached) " >&6
4916 else
4917   ac_cv_prog_cc_c89=no
4918 ac_save_CC=$CC
4919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4920 /* end confdefs.h.  */
4921 #include <stdarg.h>
4922 #include <stdio.h>
4923 struct stat;
4924 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4925 struct buf { int x; };
4926 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4927 static char *e (p, i)
4928      char **p;
4929      int i;
4930 {
4931   return p[i];
4932 }
4933 static char *f (char * (*g) (char **, int), char **p, ...)
4934 {
4935   char *s;
4936   va_list v;
4937   va_start (v,p);
4938   s = g (p, va_arg (v,int));
4939   va_end (v);
4940   return s;
4941 }
4942
4943 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4944    function prototypes and stuff, but not '\xHH' hex character constants.
4945    These don't provoke an error unfortunately, instead are silently treated
4946    as 'x'.  The following induces an error, until -std is added to get
4947    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4948    array size at least.  It's necessary to write '\x00'==0 to get something
4949    that's true only with -std.  */
4950 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4951
4952 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4953    inside strings and character constants.  */
4954 #define FOO(x) 'x'
4955 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4956
4957 int test (int i, double x);
4958 struct s1 {int (*f) (int a);};
4959 struct s2 {int (*f) (double a);};
4960 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4961 int argc;
4962 char **argv;
4963 int
4964 main ()
4965 {
4966 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4967   ;
4968   return 0;
4969 }
4970 _ACEOF
4971 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4972         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4973 do
4974   CC="$ac_save_CC $ac_arg"
4975   if ac_fn_c_try_compile "$LINENO"; then :
4976   ac_cv_prog_cc_c89=$ac_arg
4977 fi
4978 rm -f core conftest.err conftest.$ac_objext
4979   test "x$ac_cv_prog_cc_c89" != "xno" && break
4980 done
4981 rm -f conftest.$ac_ext
4982 CC=$ac_save_CC
4983
4984 fi
4985 # AC_CACHE_VAL
4986 case "x$ac_cv_prog_cc_c89" in
4987   x)
4988     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4989 $as_echo "none needed" >&6; } ;;
4990   xno)
4991     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4992 $as_echo "unsupported" >&6; } ;;
4993   *)
4994     CC="$CC $ac_cv_prog_cc_c89"
4995     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4996 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4997 esac
4998 if test "x$ac_cv_prog_cc_c89" != xno; then :
4999
5000 fi
5001
5002 ac_ext=c
5003 ac_cpp='$CPP $CPPFLAGS'
5004 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5005 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5006 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5007
5008
5009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $CC dependency flag" >&5
5010 $as_echo_n "checking $CC dependency flag... " >&6; }
5011 echo 'void f(){}' >conftest.c
5012 if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5013         DEPFLAG="-MM"
5014 else
5015   if test "`$CC -xM1 conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5016         DEPFLAG="-xM1"
5017   else
5018         DEPFLAG="-MM"  # dunno do something
5019   fi
5020 fi
5021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEPFLAG" >&5
5022 $as_echo "$DEPFLAG" >&6; }
5023 rm -f conftest.c
5024
5025
5026
5027
5028
5029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Werror" >&5
5030 $as_echo_n "checking whether $CC supports -Werror... " >&6; }
5031 cache=`echo Werror | sed 'y%.=/+-%___p_%'`
5032 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5033   $as_echo_n "(cached) " >&6
5034 else
5035
5036 echo 'void f(void){}' >conftest.c
5037 if test -z "`$CC $CPPFLAGS $CFLAGS -Werror -c conftest.c 2>&1`"; then
5038 eval "cv_prog_cc_flag_$cache=yes"
5039 else
5040 eval "cv_prog_cc_flag_$cache=no"
5041 fi
5042 rm -f conftest conftest.o conftest.c
5043
5044 fi
5045
5046 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5048 $as_echo "yes" >&6; }
5049 :
5050 ERRFLAG="-Werror"
5051 else
5052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5053 $as_echo "no" >&6; }
5054 :
5055 ERRFLAG="-errwarn"
5056 fi
5057
5058
5059
5060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5061 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5062 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5063 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5064   $as_echo_n "(cached) " >&6
5065 else
5066
5067 echo 'void f(void){}' >conftest.c
5068 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5069 eval "cv_prog_cc_flag_$cache=yes"
5070 else
5071 eval "cv_prog_cc_flag_$cache=no"
5072 fi
5073 rm -f conftest conftest.o conftest.c
5074
5075 fi
5076
5077 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5079 $as_echo "yes" >&6; }
5080 :
5081 ERRFLAG="$ERRFLAG -Wall"
5082 else
5083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5084 $as_echo "no" >&6; }
5085 :
5086 ERRFLAG="$ERRFLAG -errfmt"
5087 fi
5088
5089
5090
5091
5092
5093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -std=c99" >&5
5094 $as_echo_n "checking whether $CC supports -std=c99... " >&6; }
5095 cache=`echo std=c99 | sed 'y%.=/+-%___p_%'`
5096 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5097   $as_echo_n "(cached) " >&6
5098 else
5099
5100 echo 'void f(void){}' >conftest.c
5101 if test -z "`$CC $CPPFLAGS $CFLAGS -std=c99 -c conftest.c 2>&1`"; then
5102 eval "cv_prog_cc_flag_$cache=yes"
5103 else
5104 eval "cv_prog_cc_flag_$cache=no"
5105 fi
5106 rm -f conftest conftest.o conftest.c
5107
5108 fi
5109
5110 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5112 $as_echo "yes" >&6; }
5113 :
5114 C99FLAG="-std=c99"
5115 else
5116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5117 $as_echo "no" >&6; }
5118 :
5119
5120 fi
5121
5122
5123
5124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -xc99" >&5
5125 $as_echo_n "checking whether $CC supports -xc99... " >&6; }
5126 cache=`echo xc99 | sed 'y%.=/+-%___p_%'`
5127 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5128   $as_echo_n "(cached) " >&6
5129 else
5130
5131 echo 'void f(void){}' >conftest.c
5132 if test -z "`$CC $CPPFLAGS $CFLAGS -xc99 -c conftest.c 2>&1`"; then
5133 eval "cv_prog_cc_flag_$cache=yes"
5134 else
5135 eval "cv_prog_cc_flag_$cache=no"
5136 fi
5137 rm -f conftest conftest.o conftest.c
5138
5139 fi
5140
5141 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5143 $as_echo "yes" >&6; }
5144 :
5145 C99FLAG="-xc99"
5146 else
5147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5148 $as_echo "no" >&6; }
5149 :
5150
5151 fi
5152
5153
5154 for ac_header in getopt.h time.h
5155 do :
5156   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5157 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5158 "
5159 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5160   cat >>confdefs.h <<_ACEOF
5161 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5162 _ACEOF
5163
5164 fi
5165
5166 done
5167
5168
5169
5170
5171
5172 { $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
5173 $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; }
5174 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`
5175 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5176   $as_echo_n "(cached) " >&6
5177 else
5178
5179 echo '
5180 #include "confdefs.h"
5181 #include <stdlib.h>
5182 #include <ctype.h>
5183 #include <sys/time.h>
5184 #ifdef HAVE_TIME_H
5185 #include <time.h>
5186 #endif
5187 #include <unistd.h>
5188 #include <netdb.h>
5189 #ifdef HAVE_GETOPT_H
5190 #include <getopt.h>
5191 #endif
5192
5193 int test() {
5194         int a;
5195         char **opts = NULL;
5196         struct timeval tv;
5197         char *t;
5198         time_t time = 0;
5199         char *buf = NULL;
5200         const char* str = NULL;
5201         struct msghdr msg;
5202         msg.msg_control = 0;
5203         t = ctime_r(&time, buf);
5204         tv.tv_usec = 10;
5205         srandom(32);
5206         a = getopt(2, opts, "a");
5207         a = isascii(32);
5208         str = gai_strerror(0);
5209         if(str && t && tv.tv_usec && msg.msg_control)
5210                 a = 0;
5211         return a;
5212 }
5213 ' > conftest.c
5214 echo 'void f(){}' >>conftest.c
5215 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5216 eval "cv_prog_cc_flag_needed_$cache=no"
5217 else
5218
5219 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
5220 eval "cv_prog_cc_flag_needed_$cache=yes"
5221 else
5222 eval "cv_prog_cc_flag_needed_$cache=fail"
5223 #echo 'Test with flag fails too!'
5224 #cat conftest.c
5225 #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"
5226 #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`
5227 #exit 1
5228 fi
5229
5230 fi
5231 rm -f conftest conftest.c conftest.o
5232
5233 fi
5234
5235 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5237 $as_echo "yes" >&6; }
5238 :
5239 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"
5240 else
5241 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5243 $as_echo "no" >&6; }
5244 #echo 'Test with flag is no!'
5245 #cat conftest.c
5246 #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"
5247 #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`
5248 #exit 1
5249 :
5250
5251 else
5252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5253 $as_echo "failed" >&6; }
5254 :
5255
5256 fi
5257 fi
5258
5259
5260
5261
5262
5263 { $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
5264 $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; }
5265 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`
5266 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5267   $as_echo_n "(cached) " >&6
5268 else
5269
5270 echo '
5271 #include "confdefs.h"
5272 #include <stdlib.h>
5273 #include <ctype.h>
5274 #include <sys/time.h>
5275 #ifdef HAVE_TIME_H
5276 #include <time.h>
5277 #endif
5278 #include <unistd.h>
5279 #include <netdb.h>
5280 #ifdef HAVE_GETOPT_H
5281 #include <getopt.h>
5282 #endif
5283
5284 int test() {
5285         int a;
5286         char **opts = NULL;
5287         struct timeval tv;
5288         char *t;
5289         time_t time = 0;
5290         char *buf = NULL;
5291         const char* str = NULL;
5292         struct msghdr msg;
5293         msg.msg_control = 0;
5294         t = ctime_r(&time, buf);
5295         tv.tv_usec = 10;
5296         srandom(32);
5297         a = getopt(2, opts, "a");
5298         a = isascii(32);
5299         str = gai_strerror(0);
5300         if(str && t && tv.tv_usec && msg.msg_control)
5301                 a = 0;
5302         return a;
5303 }
5304 ' > conftest.c
5305 echo 'void f(){}' >>conftest.c
5306 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5307 eval "cv_prog_cc_flag_needed_$cache=no"
5308 else
5309
5310 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
5311 eval "cv_prog_cc_flag_needed_$cache=yes"
5312 else
5313 eval "cv_prog_cc_flag_needed_$cache=fail"
5314 #echo 'Test with flag fails too!'
5315 #cat conftest.c
5316 #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"
5317 #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`
5318 #exit 1
5319 fi
5320
5321 fi
5322 rm -f conftest conftest.c conftest.o
5323
5324 fi
5325
5326 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5328 $as_echo "yes" >&6; }
5329 :
5330 CFLAGS="$CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE"
5331 else
5332 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5334 $as_echo "no" >&6; }
5335 #echo 'Test with flag is no!'
5336 #cat conftest.c
5337 #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"
5338 #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`
5339 #exit 1
5340 :
5341
5342 else
5343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5344 $as_echo "failed" >&6; }
5345 :
5346
5347 fi
5348 fi
5349
5350
5351
5352
5353
5354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG as a flag for $CC" >&5
5355 $as_echo_n "checking whether we need $C99FLAG as a flag for $CC... " >&6; }
5356 cache=`$as_echo "$C99FLAG" | $as_tr_sh`
5357 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5358   $as_echo_n "(cached) " >&6
5359 else
5360
5361 echo '
5362 #include <stdbool.h>
5363 #include <ctype.h>
5364 int test() {
5365         int a = 0;
5366         return a;
5367 }
5368 ' > conftest.c
5369 echo 'void f(){}' >>conftest.c
5370 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5371 eval "cv_prog_cc_flag_needed_$cache=no"
5372 else
5373
5374 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`"; then
5375 eval "cv_prog_cc_flag_needed_$cache=yes"
5376 else
5377 eval "cv_prog_cc_flag_needed_$cache=fail"
5378 #echo 'Test with flag fails too!'
5379 #cat conftest.c
5380 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5381 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5382 #exit 1
5383 fi
5384
5385 fi
5386 rm -f conftest conftest.c conftest.o
5387
5388 fi
5389
5390 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5392 $as_echo "yes" >&6; }
5393 :
5394 CFLAGS="$CFLAGS $C99FLAG"
5395 else
5396 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5398 $as_echo "no" >&6; }
5399 #echo 'Test with flag is no!'
5400 #cat conftest.c
5401 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5402 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5403 #exit 1
5404 :
5405
5406 else
5407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5408 $as_echo "failed" >&6; }
5409 :
5410
5411 fi
5412 fi
5413
5414
5415
5416
5417
5418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC" >&5
5419 $as_echo_n "checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC... " >&6; }
5420 cache=_D_BSD_SOURCE__D_DEFAULT_SOURCE
5421 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5422   $as_echo_n "(cached) " >&6
5423 else
5424
5425 echo '
5426 #include <ctype.h>
5427
5428 int test() {
5429         int a;
5430         a = isascii(32);
5431         return a;
5432 }
5433 ' > conftest.c
5434 echo 'void f(){}' >>conftest.c
5435 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5436 eval "cv_prog_cc_flag_needed_$cache=no"
5437 else
5438
5439 if test -z "`$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5440 eval "cv_prog_cc_flag_needed_$cache=yes"
5441 else
5442 eval "cv_prog_cc_flag_needed_$cache=fail"
5443 #echo 'Test with flag fails too!'
5444 #cat conftest.c
5445 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5446 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5447 #exit 1
5448 fi
5449
5450 fi
5451 rm -f conftest conftest.c conftest.o
5452
5453 fi
5454
5455 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5457 $as_echo "yes" >&6; }
5458 :
5459 CFLAGS="$CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE"
5460 else
5461 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5463 $as_echo "no" >&6; }
5464 #echo 'Test with flag is no!'
5465 #cat conftest.c
5466 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5467 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5468 #exit 1
5469 :
5470
5471 else
5472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5473 $as_echo "failed" >&6; }
5474 :
5475
5476 fi
5477 fi
5478
5479
5480
5481
5482
5483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE as a flag for $CC" >&5
5484 $as_echo_n "checking whether we need -D_GNU_SOURCE as a flag for $CC... " >&6; }
5485 cache=_D_GNU_SOURCE
5486 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5487   $as_echo_n "(cached) " >&6
5488 else
5489
5490 echo '
5491 #include <netinet/in.h>
5492
5493 int test() {
5494         struct in6_pktinfo inf;
5495         int a = (int)sizeof(inf);
5496         return a;
5497 }
5498 ' > conftest.c
5499 echo 'void f(){}' >>conftest.c
5500 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5501 eval "cv_prog_cc_flag_needed_$cache=no"
5502 else
5503
5504 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5505 eval "cv_prog_cc_flag_needed_$cache=yes"
5506 else
5507 eval "cv_prog_cc_flag_needed_$cache=fail"
5508 #echo 'Test with flag fails too!'
5509 #cat conftest.c
5510 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5511 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5512 #exit 1
5513 fi
5514
5515 fi
5516 rm -f conftest conftest.c conftest.o
5517
5518 fi
5519
5520 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5522 $as_echo "yes" >&6; }
5523 :
5524 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5525 else
5526 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5528 $as_echo "no" >&6; }
5529 #echo 'Test with flag is no!'
5530 #cat conftest.c
5531 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5532 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5533 #exit 1
5534 :
5535
5536 else
5537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5538 $as_echo "failed" >&6; }
5539 :
5540
5541 fi
5542 fi
5543
5544
5545 # check again for GNU_SOURCE for setresgid. May fail if setresgid
5546 # is not available at all. -D_FRSRESGID is to make this check unique.
5547 # otherwise we would get the previous cached result.
5548
5549
5550
5551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC" >&5
5552 $as_echo_n "checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC... " >&6; }
5553 cache=_D_GNU_SOURCE__D_FRSRESGID
5554 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5555   $as_echo_n "(cached) " >&6
5556 else
5557
5558 echo '
5559 #include <unistd.h>
5560
5561 int test() {
5562         int a = setresgid(0,0,0);
5563         a = setresuid(0,0,0);
5564         return a;
5565 }
5566 ' > conftest.c
5567 echo 'void f(){}' >>conftest.c
5568 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5569 eval "cv_prog_cc_flag_needed_$cache=no"
5570 else
5571
5572 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`"; then
5573 eval "cv_prog_cc_flag_needed_$cache=yes"
5574 else
5575 eval "cv_prog_cc_flag_needed_$cache=fail"
5576 #echo 'Test with flag fails too!'
5577 #cat conftest.c
5578 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5579 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5580 #exit 1
5581 fi
5582
5583 fi
5584 rm -f conftest conftest.c conftest.o
5585
5586 fi
5587
5588 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5590 $as_echo "yes" >&6; }
5591 :
5592 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5593 else
5594 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5596 $as_echo "no" >&6; }
5597 #echo 'Test with flag is no!'
5598 #cat conftest.c
5599 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5600 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5601 #exit 1
5602 :
5603
5604 else
5605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5606 $as_echo "failed" >&6; }
5607 :
5608
5609 fi
5610 fi
5611
5612
5613
5614
5615
5616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC" >&5
5617 $as_echo_n "checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC... " >&6; }
5618 cache=_D_POSIX_C_SOURCE_200112
5619 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5620   $as_echo_n "(cached) " >&6
5621 else
5622
5623 echo '
5624 #include "confdefs.h"
5625 #ifdef HAVE_TIME_H
5626 #include <time.h>
5627 #endif
5628 #include <netdb.h>
5629
5630 int test() {
5631         int a = 0;
5632         char *t;
5633         time_t time = 0;
5634         char *buf = NULL;
5635         const char* str = NULL;
5636         t = ctime_r(&time, buf);
5637         str = gai_strerror(0);
5638         if(t && str)
5639                 a = 0;
5640         return a;
5641 }
5642 ' > conftest.c
5643 echo 'void f(){}' >>conftest.c
5644 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5645 eval "cv_prog_cc_flag_needed_$cache=no"
5646 else
5647
5648 if test -z "`$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`"; then
5649 eval "cv_prog_cc_flag_needed_$cache=yes"
5650 else
5651 eval "cv_prog_cc_flag_needed_$cache=fail"
5652 #echo 'Test with flag fails too!'
5653 #cat conftest.c
5654 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5655 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5656 #exit 1
5657 fi
5658
5659 fi
5660 rm -f conftest conftest.c conftest.o
5661
5662 fi
5663
5664 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5666 $as_echo "yes" >&6; }
5667 :
5668 CFLAGS="$CFLAGS -D_POSIX_C_SOURCE=200112"
5669 else
5670 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5672 $as_echo "no" >&6; }
5673 #echo 'Test with flag is no!'
5674 #cat conftest.c
5675 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5676 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5677 #exit 1
5678 :
5679
5680 else
5681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5682 $as_echo "failed" >&6; }
5683 :
5684
5685 fi
5686 fi
5687
5688
5689
5690
5691
5692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D__EXTENSIONS__ as a flag for $CC" >&5
5693 $as_echo_n "checking whether we need -D__EXTENSIONS__ as a flag for $CC... " >&6; }
5694 cache=_D__EXTENSIONS__
5695 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5696   $as_echo_n "(cached) " >&6
5697 else
5698
5699 echo '
5700 #include "confdefs.h"
5701 #include <stdlib.h>
5702 #include <ctype.h>
5703 #include <sys/time.h>
5704 #ifdef HAVE_TIME_H
5705 #include <time.h>
5706 #endif
5707 #include <unistd.h>
5708 #ifdef HAVE_GETOPT_H
5709 #include <getopt.h>
5710 #endif
5711
5712 int test() {
5713         int a;
5714         char **opts = NULL;
5715         struct timeval tv;
5716         tv.tv_usec = 10;
5717         srandom(32);
5718         a = getopt(2, opts, "a");
5719         a = isascii(32);
5720         if(tv.tv_usec)
5721                 a = 0;
5722         return a;
5723 }
5724 ' > conftest.c
5725 echo 'void f(){}' >>conftest.c
5726 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5727 eval "cv_prog_cc_flag_needed_$cache=no"
5728 else
5729
5730 if test -z "`$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`"; then
5731 eval "cv_prog_cc_flag_needed_$cache=yes"
5732 else
5733 eval "cv_prog_cc_flag_needed_$cache=fail"
5734 #echo 'Test with flag fails too!'
5735 #cat conftest.c
5736 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5737 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5738 #exit 1
5739 fi
5740
5741 fi
5742 rm -f conftest conftest.c conftest.o
5743
5744 fi
5745
5746 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5748 $as_echo "yes" >&6; }
5749 :
5750 CFLAGS="$CFLAGS -D__EXTENSIONS__"
5751 else
5752 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5754 $as_echo "no" >&6; }
5755 #echo 'Test with flag is no!'
5756 #cat conftest.c
5757 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5758 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5759 #exit 1
5760 :
5761
5762 else
5763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5764 $as_echo "failed" >&6; }
5765 :
5766
5767 fi
5768 fi
5769
5770
5771
5772
5773 # debug mode flags warnings
5774 # Check whether --enable-checking was given.
5775 if test "${enable_checking+set}" = set; then :
5776   enableval=$enable_checking;
5777 fi
5778
5779 # Check whether --enable-debug was given.
5780 if test "${enable_debug+set}" = set; then :
5781   enableval=$enable_debug;
5782 fi
5783
5784 if test "$enable_debug" = "yes"; then debug_enabled="$enable_debug";
5785 else debug_enabled="$enable_checking"; fi
5786
5787 case "$debug_enabled" in
5788         yes)
5789
5790
5791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -W" >&5
5792 $as_echo_n "checking whether $CC supports -W... " >&6; }
5793 cache=`echo W | sed 'y%.=/+-%___p_%'`
5794 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5795   $as_echo_n "(cached) " >&6
5796 else
5797
5798 echo 'void f(void){}' >conftest.c
5799 if test -z "`$CC $CPPFLAGS $CFLAGS -W -c conftest.c 2>&1`"; then
5800 eval "cv_prog_cc_flag_$cache=yes"
5801 else
5802 eval "cv_prog_cc_flag_$cache=no"
5803 fi
5804 rm -f conftest conftest.o conftest.c
5805
5806 fi
5807
5808 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5810 $as_echo "yes" >&6; }
5811 :
5812 CFLAGS="$CFLAGS -W"
5813 else
5814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5815 $as_echo "no" >&6; }
5816 :
5817
5818 fi
5819
5820
5821
5822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5823 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5824 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5825 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5826   $as_echo_n "(cached) " >&6
5827 else
5828
5829 echo 'void f(void){}' >conftest.c
5830 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5831 eval "cv_prog_cc_flag_$cache=yes"
5832 else
5833 eval "cv_prog_cc_flag_$cache=no"
5834 fi
5835 rm -f conftest conftest.o conftest.c
5836
5837 fi
5838
5839 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5841 $as_echo "yes" >&6; }
5842 :
5843 CFLAGS="$CFLAGS -Wall"
5844 else
5845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5846 $as_echo "no" >&6; }
5847 :
5848
5849 fi
5850
5851
5852
5853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wextra" >&5
5854 $as_echo_n "checking whether $CC supports -Wextra... " >&6; }
5855 cache=`echo Wextra | sed 'y%.=/+-%___p_%'`
5856 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5857   $as_echo_n "(cached) " >&6
5858 else
5859
5860 echo 'void f(void){}' >conftest.c
5861 if test -z "`$CC $CPPFLAGS $CFLAGS -Wextra -c conftest.c 2>&1`"; then
5862 eval "cv_prog_cc_flag_$cache=yes"
5863 else
5864 eval "cv_prog_cc_flag_$cache=no"
5865 fi
5866 rm -f conftest conftest.o conftest.c
5867
5868 fi
5869
5870 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5872 $as_echo "yes" >&6; }
5873 :
5874 CFLAGS="$CFLAGS -Wextra"
5875 else
5876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5877 $as_echo "no" >&6; }
5878 :
5879
5880 fi
5881
5882
5883
5884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wdeclaration-after-statement" >&5
5885 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
5886 cache=`echo Wdeclaration-after-statement | sed 'y%.=/+-%___p_%'`
5887 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5888   $as_echo_n "(cached) " >&6
5889 else
5890
5891 echo 'void f(void){}' >conftest.c
5892 if test -z "`$CC $CPPFLAGS $CFLAGS -Wdeclaration-after-statement -c conftest.c 2>&1`"; then
5893 eval "cv_prog_cc_flag_$cache=yes"
5894 else
5895 eval "cv_prog_cc_flag_$cache=no"
5896 fi
5897 rm -f conftest conftest.o conftest.c
5898
5899 fi
5900
5901 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5903 $as_echo "yes" >&6; }
5904 :
5905 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
5906 else
5907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5908 $as_echo "no" >&6; }
5909 :
5910
5911 fi
5912
5913
5914 $as_echo "#define UNBOUND_DEBUG /**/" >>confdefs.h
5915
5916                 ;;
5917         no|*)
5918                 # nothing to do.
5919                 ;;
5920 esac
5921
5922     # Check whether --enable-flto was given.
5923 if test "${enable_flto+set}" = set; then :
5924   enableval=$enable_flto;
5925 fi
5926
5927     if test "x$enable_flto" != "xno"; then :
5928
5929         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -flto" >&5
5930 $as_echo_n "checking if $CC supports -flto... " >&6; }
5931         BAKCFLAGS="$CFLAGS"
5932         CFLAGS="$CFLAGS -flto"
5933         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5934 /* end confdefs.h.  */
5935
5936 int
5937 main ()
5938 {
5939
5940   ;
5941   return 0;
5942 }
5943 _ACEOF
5944 if ac_fn_c_try_link "$LINENO"; then :
5945
5946             if $CC $CFLAGS -o conftest conftest.c 2>&1 | $GREP -e "warning: no debug symbols in executable" -e "warning: object" >/dev/null; then
5947                 CFLAGS="$BAKCFLAGS"
5948                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5949 $as_echo "no" >&6; }
5950             else
5951                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5952 $as_echo "yes" >&6; }
5953             fi
5954             rm -f conftest conftest.c conftest.o
5955
5956 else
5957   CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5958 $as_echo "no" >&6; }
5959 fi
5960 rm -f core conftest.err conftest.$ac_objext \
5961     conftest$ac_exeext conftest.$ac_ext
5962
5963 fi
5964
5965
5966     # Check whether --enable-pie was given.
5967 if test "${enable_pie+set}" = set; then :
5968   enableval=$enable_pie;
5969 fi
5970
5971     if test "x$enable_pie" = "xyes"; then :
5972
5973         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports PIE" >&5
5974 $as_echo_n "checking if $CC supports PIE... " >&6; }
5975         BAKLDFLAGS="$LDFLAGS"
5976         BAKCFLAGS="$CFLAGS"
5977         LDFLAGS="$LDFLAGS -pie"
5978         CFLAGS="$CFLAGS -fPIE"
5979         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5980 /* end confdefs.h.  */
5981
5982 int
5983 main ()
5984 {
5985
5986   ;
5987   return 0;
5988 }
5989 _ACEOF
5990 if ac_fn_c_try_link "$LINENO"; then :
5991
5992             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
5993                 LDFLAGS="$BAKLDFLAGS"
5994                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5995 $as_echo "no" >&6; }
5996             else
5997                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5998 $as_echo "yes" >&6; }
5999             fi
6000             rm -f conftest conftest.c conftest.o
6001
6002 else
6003   LDFLAGS="$BAKLDFLAGS" ; CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6004 $as_echo "no" >&6; }
6005 fi
6006 rm -f core conftest.err conftest.$ac_objext \
6007     conftest$ac_exeext conftest.$ac_ext
6008
6009 fi
6010
6011
6012     # Check whether --enable-relro_now was given.
6013 if test "${enable_relro_now+set}" = set; then :
6014   enableval=$enable_relro_now;
6015 fi
6016
6017     if test "x$enable_relro_now" = "xyes"; then :
6018
6019         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wl,-z,relro,-z,now" >&5
6020 $as_echo_n "checking if $CC supports -Wl,-z,relro,-z,now... " >&6; }
6021         BAKLDFLAGS="$LDFLAGS"
6022         LDFLAGS="$LDFLAGS -Wl,-z,relro,-z,now"
6023         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6024 /* end confdefs.h.  */
6025
6026 int
6027 main ()
6028 {
6029
6030   ;
6031   return 0;
6032 }
6033 _ACEOF
6034 if ac_fn_c_try_link "$LINENO"; then :
6035
6036             if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6037                 LDFLAGS="$BAKLDFLAGS"
6038                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6039 $as_echo "no" >&6; }
6040             else
6041                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6042 $as_echo "yes" >&6; }
6043             fi
6044             rm -f conftest conftest.c conftest.o
6045
6046 else
6047   LDFLAGS="$BAKLDFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6048 $as_echo "no" >&6; }
6049 fi
6050 rm -f core conftest.err conftest.$ac_objext \
6051     conftest$ac_exeext conftest.$ac_ext
6052
6053 fi
6054
6055
6056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
6057 $as_echo_n "checking for inline... " >&6; }
6058 if ${ac_cv_c_inline+:} false; then :
6059   $as_echo_n "(cached) " >&6
6060 else
6061   ac_cv_c_inline=no
6062 for ac_kw in inline __inline__ __inline; do
6063   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6064 /* end confdefs.h.  */
6065 #ifndef __cplusplus
6066 typedef int foo_t;
6067 static $ac_kw foo_t static_foo () {return 0; }
6068 $ac_kw foo_t foo () {return 0; }
6069 #endif
6070
6071 _ACEOF
6072 if ac_fn_c_try_compile "$LINENO"; then :
6073   ac_cv_c_inline=$ac_kw
6074 fi
6075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6076   test "$ac_cv_c_inline" != no && break
6077 done
6078
6079 fi
6080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
6081 $as_echo "$ac_cv_c_inline" >&6; }
6082
6083 case $ac_cv_c_inline in
6084   inline | yes) ;;
6085   *)
6086     case $ac_cv_c_inline in
6087       no) ac_val=;;
6088       *) ac_val=$ac_cv_c_inline;;
6089     esac
6090     cat >>confdefs.h <<_ACEOF
6091 #ifndef __cplusplus
6092 #define inline $ac_val
6093 #endif
6094 _ACEOF
6095     ;;
6096 esac
6097
6098
6099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute" >&5
6100 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute... " >&6; }
6101 if ${ac_cv_c_format_attribute+:} false; then :
6102   $as_echo_n "(cached) " >&6
6103 else
6104   ac_cv_c_format_attribute=no
6105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6106 /* end confdefs.h.  */
6107 #include <stdio.h>
6108 void f (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6109 void (*pf) (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6110
6111 int
6112 main ()
6113 {
6114
6115    f ("%s", "str");
6116
6117   ;
6118   return 0;
6119 }
6120 _ACEOF
6121 if ac_fn_c_try_compile "$LINENO"; then :
6122   ac_cv_c_format_attribute="yes"
6123 else
6124   ac_cv_c_format_attribute="no"
6125 fi
6126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6127
6128 fi
6129
6130
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_format_attribute" >&5
6132 $as_echo "$ac_cv_c_format_attribute" >&6; }
6133 if test $ac_cv_c_format_attribute = yes; then
6134
6135 $as_echo "#define HAVE_ATTR_FORMAT 1" >>confdefs.h
6136
6137 fi
6138
6139
6140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute" >&5
6141 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute... " >&6; }
6142 if ${ac_cv_c_unused_attribute+:} false; then :
6143   $as_echo_n "(cached) " >&6
6144 else
6145   ac_cv_c_unused_attribute=no
6146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6147 /* end confdefs.h.  */
6148 #include <stdio.h>
6149 void f (char *u __attribute__((unused)));
6150
6151 int
6152 main ()
6153 {
6154
6155    f ("x");
6156
6157   ;
6158   return 0;
6159 }
6160 _ACEOF
6161 if ac_fn_c_try_compile "$LINENO"; then :
6162   ac_cv_c_unused_attribute="yes"
6163 else
6164   ac_cv_c_unused_attribute="no"
6165 fi
6166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6167
6168 fi
6169
6170
6171
6172
6173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_unused_attribute" >&5
6174 $as_echo "$ac_cv_c_unused_attribute" >&6; }
6175 if test $ac_cv_c_unused_attribute = yes; then
6176
6177 $as_echo "#define HAVE_ATTR_UNUSED 1" >>confdefs.h
6178
6179 fi
6180
6181
6182
6183
6184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute" >&5
6185 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute... " >&6; }
6186 if ${ac_cv_c_weak_attribute+:} false; then :
6187   $as_echo_n "(cached) " >&6
6188 else
6189   ac_cv_c_weak_attribute=no
6190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6191 /* end confdefs.h.  */
6192  #include <stdio.h>
6193 __attribute__((weak)) void f(int x) { printf("%d", x); }
6194
6195 int
6196 main ()
6197 {
6198
6199    f(1);
6200
6201   ;
6202   return 0;
6203 }
6204 _ACEOF
6205 if ac_fn_c_try_compile "$LINENO"; then :
6206   ac_cv_c_weak_attribute="yes"
6207 else
6208   ac_cv_c_weak_attribute="no"
6209 fi
6210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6211
6212 fi
6213
6214
6215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_weak_attribute" >&5
6216 $as_echo "$ac_cv_c_weak_attribute" >&6; }
6217 if test $ac_cv_c_weak_attribute = yes; then
6218
6219 $as_echo "#define HAVE_ATTR_WEAK 1" >>confdefs.h
6220
6221 fi
6222
6223
6224 if test "$srcdir" != "."; then
6225         CPPFLAGS="$CPPFLAGS -I$srcdir"
6226 fi
6227
6228
6229
6230 for ac_prog in flex lex
6231 do
6232   # Extract the first word of "$ac_prog", so it can be a program name with args.
6233 set dummy $ac_prog; ac_word=$2
6234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6235 $as_echo_n "checking for $ac_word... " >&6; }
6236 if ${ac_cv_prog_LEX+:} false; then :
6237   $as_echo_n "(cached) " >&6
6238 else
6239   if test -n "$LEX"; then
6240   ac_cv_prog_LEX="$LEX" # Let the user override the test.
6241 else
6242 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6243 for as_dir in $PATH
6244 do
6245   IFS=$as_save_IFS
6246   test -z "$as_dir" && as_dir=.
6247     for ac_exec_ext in '' $ac_executable_extensions; do
6248   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6249     ac_cv_prog_LEX="$ac_prog"
6250     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6251     break 2
6252   fi
6253 done
6254   done
6255 IFS=$as_save_IFS
6256
6257 fi
6258 fi
6259 LEX=$ac_cv_prog_LEX
6260 if test -n "$LEX"; then
6261   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
6262 $as_echo "$LEX" >&6; }
6263 else
6264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6265 $as_echo "no" >&6; }
6266 fi
6267
6268
6269   test -n "$LEX" && break
6270 done
6271 test -n "$LEX" || LEX=":"
6272
6273 if test "x$LEX" != "x:"; then
6274   cat >conftest.l <<_ACEOF
6275 %%
6276 a { ECHO; }
6277 b { REJECT; }
6278 c { yymore (); }
6279 d { yyless (1); }
6280 e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument.  */
6281     yyless ((input () != 0)); }
6282 f { unput (yytext[0]); }
6283 . { BEGIN INITIAL; }
6284 %%
6285 #ifdef YYTEXT_POINTER
6286 extern char *yytext;
6287 #endif
6288 int
6289 main (void)
6290 {
6291   return ! yylex () + ! yywrap ();
6292 }
6293 _ACEOF
6294 { { ac_try="$LEX conftest.l"
6295 case "(($ac_try" in
6296   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6297   *) ac_try_echo=$ac_try;;
6298 esac
6299 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6300 $as_echo "$ac_try_echo"; } >&5
6301   (eval "$LEX conftest.l") 2>&5
6302   ac_status=$?
6303   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6304   test $ac_status = 0; }
6305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
6306 $as_echo_n "checking lex output file root... " >&6; }
6307 if ${ac_cv_prog_lex_root+:} false; then :
6308   $as_echo_n "(cached) " >&6
6309 else
6310
6311 if test -f lex.yy.c; then
6312   ac_cv_prog_lex_root=lex.yy
6313 elif test -f lexyy.c; then
6314   ac_cv_prog_lex_root=lexyy
6315 else
6316   as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
6317 fi
6318 fi
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
6320 $as_echo "$ac_cv_prog_lex_root" >&6; }
6321 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
6322
6323 if test -z "${LEXLIB+set}"; then
6324   { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
6325 $as_echo_n "checking lex library... " >&6; }
6326 if ${ac_cv_lib_lex+:} false; then :
6327   $as_echo_n "(cached) " >&6
6328 else
6329
6330     ac_save_LIBS=$LIBS
6331     ac_cv_lib_lex='none needed'
6332     for ac_lib in '' -lfl -ll; do
6333       LIBS="$ac_lib $ac_save_LIBS"
6334       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6335 /* end confdefs.h.  */
6336 `cat $LEX_OUTPUT_ROOT.c`
6337 _ACEOF
6338 if ac_fn_c_try_link "$LINENO"; then :
6339   ac_cv_lib_lex=$ac_lib
6340 fi
6341 rm -f core conftest.err conftest.$ac_objext \
6342     conftest$ac_exeext conftest.$ac_ext
6343       test "$ac_cv_lib_lex" != 'none needed' && break
6344     done
6345     LIBS=$ac_save_LIBS
6346
6347 fi
6348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
6349 $as_echo "$ac_cv_lib_lex" >&6; }
6350   test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
6351 fi
6352
6353
6354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
6355 $as_echo_n "checking whether yytext is a pointer... " >&6; }
6356 if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
6357   $as_echo_n "(cached) " >&6
6358 else
6359   # POSIX says lex can declare yytext either as a pointer or an array; the
6360 # default is implementation-dependent.  Figure out which it is, since
6361 # not all implementations provide the %pointer and %array declarations.
6362 ac_cv_prog_lex_yytext_pointer=no
6363 ac_save_LIBS=$LIBS
6364 LIBS="$LEXLIB $ac_save_LIBS"
6365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6366 /* end confdefs.h.  */
6367
6368   #define YYTEXT_POINTER 1
6369 `cat $LEX_OUTPUT_ROOT.c`
6370 _ACEOF
6371 if ac_fn_c_try_link "$LINENO"; then :
6372   ac_cv_prog_lex_yytext_pointer=yes
6373 fi
6374 rm -f core conftest.err conftest.$ac_objext \
6375     conftest$ac_exeext conftest.$ac_ext
6376 LIBS=$ac_save_LIBS
6377
6378 fi
6379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
6380 $as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
6381 if test $ac_cv_prog_lex_yytext_pointer = yes; then
6382
6383 $as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
6384
6385 fi
6386 rm -f conftest.l $LEX_OUTPUT_ROOT.c
6387
6388 fi
6389
6390         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yylex_destroy" >&5
6391 $as_echo_n "checking for yylex_destroy... " >&6; }
6392         if echo %% | $LEX -t 2>&1 | grep yylex_destroy >/dev/null 2>&1; then
6393
6394 $as_echo "#define LEX_HAS_YYLEX_DESTROY 1" >>confdefs.h
6395
6396                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6397 $as_echo "yes" >&6; }
6398         else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6399 $as_echo "no" >&6; }; fi
6400
6401 for ac_prog in 'bison -y' byacc
6402 do
6403   # Extract the first word of "$ac_prog", so it can be a program name with args.
6404 set dummy $ac_prog; ac_word=$2
6405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6406 $as_echo_n "checking for $ac_word... " >&6; }
6407 if ${ac_cv_prog_YACC+:} false; then :
6408   $as_echo_n "(cached) " >&6
6409 else
6410   if test -n "$YACC"; then
6411   ac_cv_prog_YACC="$YACC" # Let the user override the test.
6412 else
6413 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6414 for as_dir in $PATH
6415 do
6416   IFS=$as_save_IFS
6417   test -z "$as_dir" && as_dir=.
6418     for ac_exec_ext in '' $ac_executable_extensions; do
6419   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6420     ac_cv_prog_YACC="$ac_prog"
6421     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6422     break 2
6423   fi
6424 done
6425   done
6426 IFS=$as_save_IFS
6427
6428 fi
6429 fi
6430 YACC=$ac_cv_prog_YACC
6431 if test -n "$YACC"; then
6432   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6433 $as_echo "$YACC" >&6; }
6434 else
6435   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6436 $as_echo "no" >&6; }
6437 fi
6438
6439
6440   test -n "$YACC" && break
6441 done
6442 test -n "$YACC" || YACC="yacc"
6443
6444 # Extract the first word of "doxygen", so it can be a program name with args.
6445 set dummy doxygen; ac_word=$2
6446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6447 $as_echo_n "checking for $ac_word... " >&6; }
6448 if ${ac_cv_prog_doxygen+:} false; then :
6449   $as_echo_n "(cached) " >&6
6450 else
6451   if test -n "$doxygen"; then
6452   ac_cv_prog_doxygen="$doxygen" # Let the user override the test.
6453 else
6454 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6455 for as_dir in $PATH
6456 do
6457   IFS=$as_save_IFS
6458   test -z "$as_dir" && as_dir=.
6459     for ac_exec_ext in '' $ac_executable_extensions; do
6460   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6461     ac_cv_prog_doxygen="doxygen"
6462     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6463     break 2
6464   fi
6465 done
6466   done
6467 IFS=$as_save_IFS
6468
6469 fi
6470 fi
6471 doxygen=$ac_cv_prog_doxygen
6472 if test -n "$doxygen"; then
6473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $doxygen" >&5
6474 $as_echo "$doxygen" >&6; }
6475 else
6476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6477 $as_echo "no" >&6; }
6478 fi
6479
6480
6481 if test -n "$ac_tool_prefix"; then
6482   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6483 set dummy ${ac_tool_prefix}strip; ac_word=$2
6484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6485 $as_echo_n "checking for $ac_word... " >&6; }
6486 if ${ac_cv_prog_STRIP+:} false; then :
6487   $as_echo_n "(cached) " >&6
6488 else
6489   if test -n "$STRIP"; then
6490   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6491 else
6492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6493 for as_dir in $PATH
6494 do
6495   IFS=$as_save_IFS
6496   test -z "$as_dir" && as_dir=.
6497     for ac_exec_ext in '' $ac_executable_extensions; do
6498   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6499     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6500     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6501     break 2
6502   fi
6503 done
6504   done
6505 IFS=$as_save_IFS
6506
6507 fi
6508 fi
6509 STRIP=$ac_cv_prog_STRIP
6510 if test -n "$STRIP"; then
6511   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6512 $as_echo "$STRIP" >&6; }
6513 else
6514   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6515 $as_echo "no" >&6; }
6516 fi
6517
6518
6519 fi
6520 if test -z "$ac_cv_prog_STRIP"; then
6521   ac_ct_STRIP=$STRIP
6522   # Extract the first word of "strip", so it can be a program name with args.
6523 set dummy strip; ac_word=$2
6524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6525 $as_echo_n "checking for $ac_word... " >&6; }
6526 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6527   $as_echo_n "(cached) " >&6
6528 else
6529   if test -n "$ac_ct_STRIP"; then
6530   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6531 else
6532 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6533 for as_dir in $PATH
6534 do
6535   IFS=$as_save_IFS
6536   test -z "$as_dir" && as_dir=.
6537     for ac_exec_ext in '' $ac_executable_extensions; do
6538   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6539     ac_cv_prog_ac_ct_STRIP="strip"
6540     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6541     break 2
6542   fi
6543 done
6544   done
6545 IFS=$as_save_IFS
6546
6547 fi
6548 fi
6549 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6550 if test -n "$ac_ct_STRIP"; then
6551   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6552 $as_echo "$ac_ct_STRIP" >&6; }
6553 else
6554   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6555 $as_echo "no" >&6; }
6556 fi
6557
6558   if test "x$ac_ct_STRIP" = x; then
6559     STRIP=""
6560   else
6561     case $cross_compiling:$ac_tool_warned in
6562 yes:)
6563 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6564 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6565 ac_tool_warned=yes ;;
6566 esac
6567     STRIP=$ac_ct_STRIP
6568   fi
6569 else
6570   STRIP="$ac_cv_prog_STRIP"
6571 fi
6572
6573 ac_aux_dir=
6574 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
6575   if test -f "$ac_dir/install-sh"; then
6576     ac_aux_dir=$ac_dir
6577     ac_install_sh="$ac_aux_dir/install-sh -c"
6578     break
6579   elif test -f "$ac_dir/install.sh"; then
6580     ac_aux_dir=$ac_dir
6581     ac_install_sh="$ac_aux_dir/install.sh -c"
6582     break
6583   elif test -f "$ac_dir/shtool"; then
6584     ac_aux_dir=$ac_dir
6585     ac_install_sh="$ac_aux_dir/shtool install -c"
6586     break
6587   fi
6588 done
6589 if test -z "$ac_aux_dir"; then
6590   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
6591 fi
6592
6593 # These three variables are undocumented and unsupported,
6594 # and are intended to be withdrawn in a future Autoconf release.
6595 # They can cause serious problems if a builder's source tree is in a directory
6596 # whose full name contains unusual characters.
6597 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
6598 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
6599 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
6600
6601
6602 # Make sure we can run config.sub.
6603 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
6604   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
6605
6606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
6607 $as_echo_n "checking build system type... " >&6; }
6608 if ${ac_cv_build+:} false; then :
6609   $as_echo_n "(cached) " >&6
6610 else
6611   ac_build_alias=$build_alias
6612 test "x$ac_build_alias" = x &&
6613   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
6614 test "x$ac_build_alias" = x &&
6615   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
6616 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
6617   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
6618
6619 fi
6620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
6621 $as_echo "$ac_cv_build" >&6; }
6622 case $ac_cv_build in
6623 *-*-*) ;;
6624 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
6625 esac
6626 build=$ac_cv_build
6627 ac_save_IFS=$IFS; IFS='-'
6628 set x $ac_cv_build
6629 shift
6630 build_cpu=$1
6631 build_vendor=$2
6632 shift; shift
6633 # Remember, the first character of IFS is used to create $*,
6634 # except with old shells:
6635 build_os=$*
6636 IFS=$ac_save_IFS
6637 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
6638
6639
6640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
6641 $as_echo_n "checking host system type... " >&6; }
6642 if ${ac_cv_host+:} false; then :
6643   $as_echo_n "(cached) " >&6
6644 else
6645   if test "x$host_alias" = x; then
6646   ac_cv_host=$ac_cv_build
6647 else
6648   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
6649     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
6650 fi
6651
6652 fi
6653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
6654 $as_echo "$ac_cv_host" >&6; }
6655 case $ac_cv_host in
6656 *-*-*) ;;
6657 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
6658 esac
6659 host=$ac_cv_host
6660 ac_save_IFS=$IFS; IFS='-'
6661 set x $ac_cv_host
6662 shift
6663 host_cpu=$1
6664 host_vendor=$2
6665 shift; shift
6666 # Remember, the first character of IFS is used to create $*,
6667 # except with old shells:
6668 host_os=$*
6669 IFS=$ac_save_IFS
6670 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
6671
6672
6673
6674 # skip these tests, we do not need them.
6675
6676
6677
6678
6679
6680
6681
6682
6683 # always use ./libtool unless override from commandline (libtool=mylibtool)
6684 if test -z "$libtool"; then
6685         libtool="./libtool"
6686 fi
6687
6688 # avoid libtool max commandline length test on systems that fork slowly.
6689
6690 if echo "$host_os" | grep "sunos4" >/dev/null; then
6691         lt_cv_sys_max_cmd_len=32750;
6692 fi
6693 if test -n "$ac_tool_prefix"; then
6694   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6695 set dummy ${ac_tool_prefix}ar; ac_word=$2
6696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6697 $as_echo_n "checking for $ac_word... " >&6; }
6698 if ${ac_cv_path_AR+:} false; then :
6699   $as_echo_n "(cached) " >&6
6700 else
6701   case $AR in
6702   [\\/]* | ?:[\\/]*)
6703   ac_cv_path_AR="$AR" # Let the user override the test with a path.
6704   ;;
6705   *)
6706   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6707 for as_dir in $PATH
6708 do
6709   IFS=$as_save_IFS
6710   test -z "$as_dir" && as_dir=.
6711     for ac_exec_ext in '' $ac_executable_extensions; do
6712   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6713     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
6714     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6715     break 2
6716   fi
6717 done
6718   done
6719 IFS=$as_save_IFS
6720
6721   ;;
6722 esac
6723 fi
6724 AR=$ac_cv_path_AR
6725 if test -n "$AR"; then
6726   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6727 $as_echo "$AR" >&6; }
6728 else
6729   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6730 $as_echo "no" >&6; }
6731 fi
6732
6733
6734 fi
6735 if test -z "$ac_cv_path_AR"; then
6736   ac_pt_AR=$AR
6737   # Extract the first word of "ar", so it can be a program name with args.
6738 set dummy ar; ac_word=$2
6739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6740 $as_echo_n "checking for $ac_word... " >&6; }
6741 if ${ac_cv_path_ac_pt_AR+:} false; then :
6742   $as_echo_n "(cached) " >&6
6743 else
6744   case $ac_pt_AR in
6745   [\\/]* | ?:[\\/]*)
6746   ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
6747   ;;
6748   *)
6749   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6750 for as_dir in $PATH
6751 do
6752   IFS=$as_save_IFS
6753   test -z "$as_dir" && as_dir=.
6754     for ac_exec_ext in '' $ac_executable_extensions; do
6755   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6756     ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
6757     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6758     break 2
6759   fi
6760 done
6761   done
6762 IFS=$as_save_IFS
6763
6764   ;;
6765 esac
6766 fi
6767 ac_pt_AR=$ac_cv_path_ac_pt_AR
6768 if test -n "$ac_pt_AR"; then
6769   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
6770 $as_echo "$ac_pt_AR" >&6; }
6771 else
6772   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6773 $as_echo "no" >&6; }
6774 fi
6775
6776   if test "x$ac_pt_AR" = x; then
6777     AR="false"
6778   else
6779     case $cross_compiling:$ac_tool_warned in
6780 yes:)
6781 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6782 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6783 ac_tool_warned=yes ;;
6784 esac
6785     AR=$ac_pt_AR
6786   fi
6787 else
6788   AR="$ac_cv_path_AR"
6789 fi
6790
6791 if test $AR = false; then
6792         as_fn_error $? "Cannot find 'ar', please extend PATH to include it" "$LINENO" 5
6793 fi
6794
6795 case `pwd` in
6796   *\ * | *\     *)
6797     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
6798 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
6799 esac
6800
6801
6802
6803 macro_version='2.4.6'
6804 macro_revision='2.4.6'
6805
6806
6807
6808
6809
6810
6811
6812
6813
6814
6815
6816
6817
6818 ltmain=$ac_aux_dir/ltmain.sh
6819
6820 # Backslashify metacharacters that are still active within
6821 # double-quoted strings.
6822 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
6823
6824 # Same as above, but do not quote variable references.
6825 double_quote_subst='s/\(["`\\]\)/\\\1/g'
6826
6827 # Sed substitution to delay expansion of an escaped shell variable in a
6828 # double_quote_subst'ed string.
6829 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
6830
6831 # Sed substitution to delay expansion of an escaped single quote.
6832 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
6833
6834 # Sed substitution to avoid accidental globbing in evaled expressions
6835 no_glob_subst='s/\*/\\\*/g'
6836
6837 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
6838 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
6839 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
6840
6841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
6842 $as_echo_n "checking how to print strings... " >&6; }
6843 # Test print first, because it will be a builtin if present.
6844 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
6845    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
6846   ECHO='print -r --'
6847 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
6848   ECHO='printf %s\n'
6849 else
6850   # Use this function as a fallback that always works.
6851   func_fallback_echo ()
6852   {
6853     eval 'cat <<_LTECHO_EOF
6854 $1
6855 _LTECHO_EOF'
6856   }
6857   ECHO='func_fallback_echo'
6858 fi
6859
6860 # func_echo_all arg...
6861 # Invoke $ECHO with all args, space-separated.
6862 func_echo_all ()
6863 {
6864     $ECHO ""
6865 }
6866
6867 case $ECHO in
6868   printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
6869 $as_echo "printf" >&6; } ;;
6870   print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
6871 $as_echo "print -r" >&6; } ;;
6872   *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
6873 $as_echo "cat" >&6; } ;;
6874 esac
6875
6876
6877
6878
6879
6880
6881
6882
6883
6884
6885
6886
6887
6888
6889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
6890 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
6891 if ${ac_cv_path_SED+:} false; then :
6892   $as_echo_n "(cached) " >&6
6893 else
6894             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
6895      for ac_i in 1 2 3 4 5 6 7; do
6896        ac_script="$ac_script$as_nl$ac_script"
6897      done
6898      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
6899      { ac_script=; unset ac_script;}
6900      if test -z "$SED"; then
6901   ac_path_SED_found=false
6902   # Loop through the user's path and test for each of PROGNAME-LIST
6903   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6904 for as_dir in $PATH
6905 do
6906   IFS=$as_save_IFS
6907   test -z "$as_dir" && as_dir=.
6908     for ac_prog in sed gsed; do
6909     for ac_exec_ext in '' $ac_executable_extensions; do
6910       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
6911       as_fn_executable_p "$ac_path_SED" || continue
6912 # Check for GNU ac_path_SED and select it if it is found.
6913   # Check for GNU $ac_path_SED
6914 case `"$ac_path_SED" --version 2>&1` in
6915 *GNU*)
6916   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
6917 *)
6918   ac_count=0
6919   $as_echo_n 0123456789 >"conftest.in"
6920   while :
6921   do
6922     cat "conftest.in" "conftest.in" >"conftest.tmp"
6923     mv "conftest.tmp" "conftest.in"
6924     cp "conftest.in" "conftest.nl"
6925     $as_echo '' >> "conftest.nl"
6926     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
6927     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6928     as_fn_arith $ac_count + 1 && ac_count=$as_val
6929     if test $ac_count -gt ${ac_path_SED_max-0}; then
6930       # Best one so far, save it but keep looking for a better one
6931       ac_cv_path_SED="$ac_path_SED"
6932       ac_path_SED_max=$ac_count
6933     fi
6934     # 10*(2^10) chars as input seems more than enough
6935     test $ac_count -gt 10 && break
6936   done
6937   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6938 esac
6939
6940       $ac_path_SED_found && break 3
6941     done
6942   done
6943   done
6944 IFS=$as_save_IFS
6945   if test -z "$ac_cv_path_SED"; then
6946     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
6947   fi
6948 else
6949   ac_cv_path_SED=$SED
6950 fi
6951
6952 fi
6953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
6954 $as_echo "$ac_cv_path_SED" >&6; }
6955  SED="$ac_cv_path_SED"
6956   rm -f conftest.sed
6957
6958 test -z "$SED" && SED=sed
6959 Xsed="$SED -e 1s/^X//"
6960
6961
6962
6963
6964
6965
6966
6967
6968
6969
6970
6971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
6972 $as_echo_n "checking for fgrep... " >&6; }
6973 if ${ac_cv_path_FGREP+:} false; then :
6974   $as_echo_n "(cached) " >&6
6975 else
6976   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
6977    then ac_cv_path_FGREP="$GREP -F"
6978    else
6979      if test -z "$FGREP"; then
6980   ac_path_FGREP_found=false
6981   # Loop through the user's path and test for each of PROGNAME-LIST
6982   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6983 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6984 do
6985   IFS=$as_save_IFS
6986   test -z "$as_dir" && as_dir=.
6987     for ac_prog in fgrep; do
6988     for ac_exec_ext in '' $ac_executable_extensions; do
6989       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
6990       as_fn_executable_p "$ac_path_FGREP" || continue
6991 # Check for GNU ac_path_FGREP and select it if it is found.
6992   # Check for GNU $ac_path_FGREP
6993 case `"$ac_path_FGREP" --version 2>&1` in
6994 *GNU*)
6995   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
6996 *)
6997   ac_count=0
6998   $as_echo_n 0123456789 >"conftest.in"
6999   while :
7000   do
7001     cat "conftest.in" "conftest.in" >"conftest.tmp"
7002     mv "conftest.tmp" "conftest.in"
7003     cp "conftest.in" "conftest.nl"
7004     $as_echo 'FGREP' >> "conftest.nl"
7005     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7006     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7007     as_fn_arith $ac_count + 1 && ac_count=$as_val
7008     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7009       # Best one so far, save it but keep looking for a better one
7010       ac_cv_path_FGREP="$ac_path_FGREP"
7011       ac_path_FGREP_max=$ac_count
7012     fi
7013     # 10*(2^10) chars as input seems more than enough
7014     test $ac_count -gt 10 && break
7015   done
7016   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7017 esac
7018
7019       $ac_path_FGREP_found && break 3
7020     done
7021   done
7022   done
7023 IFS=$as_save_IFS
7024   if test -z "$ac_cv_path_FGREP"; then
7025     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7026   fi
7027 else
7028   ac_cv_path_FGREP=$FGREP
7029 fi
7030
7031    fi
7032 fi
7033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7034 $as_echo "$ac_cv_path_FGREP" >&6; }
7035  FGREP="$ac_cv_path_FGREP"
7036
7037
7038 test -z "$GREP" && GREP=grep
7039
7040
7041
7042
7043
7044
7045
7046
7047
7048
7049
7050
7051
7052
7053
7054
7055
7056
7057
7058 # Check whether --with-gnu-ld was given.
7059 if test "${with_gnu_ld+set}" = set; then :
7060   withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7061 else
7062   with_gnu_ld=no
7063 fi
7064
7065 ac_prog=ld
7066 if test yes = "$GCC"; then
7067   # Check if gcc -print-prog-name=ld gives a path.
7068   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7069 $as_echo_n "checking for ld used by $CC... " >&6; }
7070   case $host in
7071   *-*-mingw*)
7072     # gcc leaves a trailing carriage return, which upsets mingw
7073     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7074   *)
7075     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7076   esac
7077   case $ac_prog in
7078     # Accept absolute paths.
7079     [\\/]* | ?:[\\/]*)
7080       re_direlt='/[^/][^/]*/\.\./'
7081       # Canonicalize the pathname of ld
7082       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7083       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7084         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7085       done
7086       test -z "$LD" && LD=$ac_prog
7087       ;;
7088   "")
7089     # If it fails, then pretend we aren't using GCC.
7090     ac_prog=ld
7091     ;;
7092   *)
7093     # If it is relative, then search for the first ld in PATH.
7094     with_gnu_ld=unknown
7095     ;;
7096   esac
7097 elif test yes = "$with_gnu_ld"; then
7098   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7099 $as_echo_n "checking for GNU ld... " >&6; }
7100 else
7101   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7102 $as_echo_n "checking for non-GNU ld... " >&6; }
7103 fi
7104 if ${lt_cv_path_LD+:} false; then :
7105   $as_echo_n "(cached) " >&6
7106 else
7107   if test -z "$LD"; then
7108   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7109   for ac_dir in $PATH; do
7110     IFS=$lt_save_ifs
7111     test -z "$ac_dir" && ac_dir=.
7112     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7113       lt_cv_path_LD=$ac_dir/$ac_prog
7114       # Check to see if the program is GNU ld.  I'd rather use --version,
7115       # but apparently some variants of GNU ld only accept -v.
7116       # Break only if it was the GNU/non-GNU ld that we prefer.
7117       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7118       *GNU* | *'with BFD'*)
7119         test no != "$with_gnu_ld" && break
7120         ;;
7121       *)
7122         test yes != "$with_gnu_ld" && break
7123         ;;
7124       esac
7125     fi
7126   done
7127   IFS=$lt_save_ifs
7128 else
7129   lt_cv_path_LD=$LD # Let the user override the test with a path.
7130 fi
7131 fi
7132
7133 LD=$lt_cv_path_LD
7134 if test -n "$LD"; then
7135   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7136 $as_echo "$LD" >&6; }
7137 else
7138   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7139 $as_echo "no" >&6; }
7140 fi
7141 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7143 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7144 if ${lt_cv_prog_gnu_ld+:} false; then :
7145   $as_echo_n "(cached) " >&6
7146 else
7147   # I'd rather use --version here, but apparently some GNU lds only accept -v.
7148 case `$LD -v 2>&1 </dev/null` in
7149 *GNU* | *'with BFD'*)
7150   lt_cv_prog_gnu_ld=yes
7151   ;;
7152 *)
7153   lt_cv_prog_gnu_ld=no
7154   ;;
7155 esac
7156 fi
7157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7158 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
7159 with_gnu_ld=$lt_cv_prog_gnu_ld
7160
7161
7162
7163
7164
7165
7166
7167
7168
7169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7170 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7171 if ${lt_cv_path_NM+:} false; then :
7172   $as_echo_n "(cached) " >&6
7173 else
7174   if test -n "$NM"; then
7175   # Let the user override the test.
7176   lt_cv_path_NM=$NM
7177 else
7178   lt_nm_to_check=${ac_tool_prefix}nm
7179   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7180     lt_nm_to_check="$lt_nm_to_check nm"
7181   fi
7182   for lt_tmp_nm in $lt_nm_to_check; do
7183     lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7184     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7185       IFS=$lt_save_ifs
7186       test -z "$ac_dir" && ac_dir=.
7187       tmp_nm=$ac_dir/$lt_tmp_nm
7188       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7189         # Check to see if the nm accepts a BSD-compat flag.
7190         # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7191         #   nm: unknown option "B" ignored
7192         # Tru64's nm complains that /dev/null is an invalid object file
7193         # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7194         case $build_os in
7195         mingw*) lt_bad_file=conftest.nm/nofile ;;
7196         *) lt_bad_file=/dev/null ;;
7197         esac
7198         case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7199         *$lt_bad_file* | *'Invalid file or object type'*)
7200           lt_cv_path_NM="$tmp_nm -B"
7201           break 2
7202           ;;
7203         *)
7204           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7205           */dev/null*)
7206             lt_cv_path_NM="$tmp_nm -p"
7207             break 2
7208             ;;
7209           *)
7210             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7211             continue # so that we can try to find one that supports BSD flags
7212             ;;
7213           esac
7214           ;;
7215         esac
7216       fi
7217     done
7218     IFS=$lt_save_ifs
7219   done
7220   : ${lt_cv_path_NM=no}
7221 fi
7222 fi
7223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7224 $as_echo "$lt_cv_path_NM" >&6; }
7225 if test no != "$lt_cv_path_NM"; then
7226   NM=$lt_cv_path_NM
7227 else
7228   # Didn't find any BSD compatible name lister, look for dumpbin.
7229   if test -n "$DUMPBIN"; then :
7230     # Let the user override the test.
7231   else
7232     if test -n "$ac_tool_prefix"; then
7233   for ac_prog in dumpbin "link -dump"
7234   do
7235     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7236 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7238 $as_echo_n "checking for $ac_word... " >&6; }
7239 if ${ac_cv_prog_DUMPBIN+:} false; then :
7240   $as_echo_n "(cached) " >&6
7241 else
7242   if test -n "$DUMPBIN"; then
7243   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7244 else
7245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7246 for as_dir in $PATH
7247 do
7248   IFS=$as_save_IFS
7249   test -z "$as_dir" && as_dir=.
7250     for ac_exec_ext in '' $ac_executable_extensions; do
7251   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7252     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7253     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7254     break 2
7255   fi
7256 done
7257   done
7258 IFS=$as_save_IFS
7259
7260 fi
7261 fi
7262 DUMPBIN=$ac_cv_prog_DUMPBIN
7263 if test -n "$DUMPBIN"; then
7264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7265 $as_echo "$DUMPBIN" >&6; }
7266 else
7267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7268 $as_echo "no" >&6; }
7269 fi
7270
7271
7272     test -n "$DUMPBIN" && break
7273   done
7274 fi
7275 if test -z "$DUMPBIN"; then
7276   ac_ct_DUMPBIN=$DUMPBIN
7277   for ac_prog in dumpbin "link -dump"
7278 do
7279   # Extract the first word of "$ac_prog", so it can be a program name with args.
7280 set dummy $ac_prog; ac_word=$2
7281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7282 $as_echo_n "checking for $ac_word... " >&6; }
7283 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7284   $as_echo_n "(cached) " >&6
7285 else
7286   if test -n "$ac_ct_DUMPBIN"; then
7287   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7288 else
7289 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7290 for as_dir in $PATH
7291 do
7292   IFS=$as_save_IFS
7293   test -z "$as_dir" && as_dir=.
7294     for ac_exec_ext in '' $ac_executable_extensions; do
7295   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7296     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7297     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7298     break 2
7299   fi
7300 done
7301   done
7302 IFS=$as_save_IFS
7303
7304 fi
7305 fi
7306 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7307 if test -n "$ac_ct_DUMPBIN"; then
7308   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7309 $as_echo "$ac_ct_DUMPBIN" >&6; }
7310 else
7311   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7312 $as_echo "no" >&6; }
7313 fi
7314
7315
7316   test -n "$ac_ct_DUMPBIN" && break
7317 done
7318
7319   if test "x$ac_ct_DUMPBIN" = x; then
7320     DUMPBIN=":"
7321   else
7322     case $cross_compiling:$ac_tool_warned in
7323 yes:)
7324 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7325 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7326 ac_tool_warned=yes ;;
7327 esac
7328     DUMPBIN=$ac_ct_DUMPBIN
7329   fi
7330 fi
7331
7332     case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7333     *COFF*)
7334       DUMPBIN="$DUMPBIN -symbols -headers"
7335       ;;
7336     *)
7337       DUMPBIN=:
7338       ;;
7339     esac
7340   fi
7341
7342   if test : != "$DUMPBIN"; then
7343     NM=$DUMPBIN
7344   fi
7345 fi
7346 test -z "$NM" && NM=nm
7347
7348
7349
7350
7351
7352
7353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7354 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
7355 if ${lt_cv_nm_interface+:} false; then :
7356   $as_echo_n "(cached) " >&6
7357 else
7358   lt_cv_nm_interface="BSD nm"
7359   echo "int some_variable = 0;" > conftest.$ac_ext
7360   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7361   (eval "$ac_compile" 2>conftest.err)
7362   cat conftest.err >&5
7363   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7364   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7365   cat conftest.err >&5
7366   (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7367   cat conftest.out >&5
7368   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7369     lt_cv_nm_interface="MS dumpbin"
7370   fi
7371   rm -f conftest*
7372 fi
7373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7374 $as_echo "$lt_cv_nm_interface" >&6; }
7375
7376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7377 $as_echo_n "checking whether ln -s works... " >&6; }
7378 LN_S=$as_ln_s
7379 if test "$LN_S" = "ln -s"; then
7380   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7381 $as_echo "yes" >&6; }
7382 else
7383   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7384 $as_echo "no, using $LN_S" >&6; }
7385 fi
7386
7387 # find the maximum length of command line arguments
7388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7389 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
7390 if ${lt_cv_sys_max_cmd_len+:} false; then :
7391   $as_echo_n "(cached) " >&6
7392 else
7393     i=0
7394   teststring=ABCD
7395
7396   case $build_os in
7397   msdosdjgpp*)
7398     # On DJGPP, this test can blow up pretty badly due to problems in libc
7399     # (any single argument exceeding 2000 bytes causes a buffer overrun
7400     # during glob expansion).  Even if it were fixed, the result of this
7401     # check would be larger than it should be.
7402     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
7403     ;;
7404
7405   gnu*)
7406     # Under GNU Hurd, this test is not required because there is
7407     # no limit to the length of command line arguments.
7408     # Libtool will interpret -1 as no limit whatsoever
7409     lt_cv_sys_max_cmd_len=-1;
7410     ;;
7411
7412   cygwin* | mingw* | cegcc*)
7413     # On Win9x/ME, this test blows up -- it succeeds, but takes
7414     # about 5 minutes as the teststring grows exponentially.
7415     # Worse, since 9x/ME are not pre-emptively multitasking,
7416     # you end up with a "frozen" computer, even though with patience
7417     # the test eventually succeeds (with a max line length of 256k).
7418     # Instead, let's just punt: use the minimum linelength reported by
7419     # all of the supported platforms: 8192 (on NT/2K/XP).
7420     lt_cv_sys_max_cmd_len=8192;
7421     ;;
7422
7423   mint*)
7424     # On MiNT this can take a long time and run out of memory.
7425     lt_cv_sys_max_cmd_len=8192;
7426     ;;
7427
7428   amigaos*)
7429     # On AmigaOS with pdksh, this test takes hours, literally.
7430     # So we just punt and use a minimum line length of 8192.
7431     lt_cv_sys_max_cmd_len=8192;
7432     ;;
7433
7434   bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7435     # This has been around since 386BSD, at least.  Likely further.
7436     if test -x /sbin/sysctl; then
7437       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7438     elif test -x /usr/sbin/sysctl; then
7439       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7440     else
7441       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
7442     fi
7443     # And add a safety zone
7444     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7445     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7446     ;;
7447
7448   interix*)
7449     # We know the value 262144 and hardcode it with a safety zone (like BSD)
7450     lt_cv_sys_max_cmd_len=196608
7451     ;;
7452
7453   os2*)
7454     # The test takes a long time on OS/2.
7455     lt_cv_sys_max_cmd_len=8192
7456     ;;
7457
7458   osf*)
7459     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7460     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7461     # nice to cause kernel panics so lets avoid the loop below.
7462     # First set a reasonable default.
7463     lt_cv_sys_max_cmd_len=16384
7464     #
7465     if test -x /sbin/sysconfig; then
7466       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7467         *1*) lt_cv_sys_max_cmd_len=-1 ;;
7468       esac
7469     fi
7470     ;;
7471   sco3.2v5*)
7472     lt_cv_sys_max_cmd_len=102400
7473     ;;
7474   sysv5* | sco5v6* | sysv4.2uw2*)
7475     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7476     if test -n "$kargmax"; then
7477       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
7478     else
7479       lt_cv_sys_max_cmd_len=32768
7480     fi
7481     ;;
7482   *)
7483     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7484     if test -n "$lt_cv_sys_max_cmd_len" && \
7485        test undefined != "$lt_cv_sys_max_cmd_len"; then
7486       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7487       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7488     else
7489       # Make teststring a little bigger before we do anything with it.
7490       # a 1K string should be a reasonable start.
7491       for i in 1 2 3 4 5 6 7 8; do
7492         teststring=$teststring$teststring
7493       done
7494       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7495       # If test is not a shell built-in, we'll probably end up computing a
7496       # maximum length that is only half of the actual maximum length, but
7497       # we can't tell.
7498       while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7499                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7500               test 17 != "$i" # 1/2 MB should be enough
7501       do
7502         i=`expr $i + 1`
7503         teststring=$teststring$teststring
7504       done
7505       # Only check the string length outside the loop.
7506       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7507       teststring=
7508       # Add a significant safety factor because C++ compilers can tack on
7509       # massive amounts of additional arguments before passing them to the
7510       # linker.  It appears as though 1/2 is a usable value.
7511       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7512     fi
7513     ;;
7514   esac
7515
7516 fi
7517
7518 if test -n "$lt_cv_sys_max_cmd_len"; then
7519   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7520 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7521 else
7522   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7523 $as_echo "none" >&6; }
7524 fi
7525 max_cmd_len=$lt_cv_sys_max_cmd_len
7526
7527
7528
7529
7530
7531
7532 : ${CP="cp -f"}
7533 : ${MV="mv -f"}
7534 : ${RM="rm -f"}
7535
7536 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7537   lt_unset=unset
7538 else
7539   lt_unset=false
7540 fi
7541
7542
7543
7544
7545
7546 # test EBCDIC or ASCII
7547 case `echo X|tr X '\101'` in
7548  A) # ASCII based system
7549     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7550   lt_SP2NL='tr \040 \012'
7551   lt_NL2SP='tr \015\012 \040\040'
7552   ;;
7553  *) # EBCDIC based system
7554   lt_SP2NL='tr \100 \n'
7555   lt_NL2SP='tr \r\n \100\100'
7556   ;;
7557 esac
7558
7559
7560
7561
7562
7563
7564
7565
7566
7567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7568 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7569 if ${lt_cv_to_host_file_cmd+:} false; then :
7570   $as_echo_n "(cached) " >&6
7571 else
7572   case $host in
7573   *-*-mingw* )
7574     case $build in
7575       *-*-mingw* ) # actually msys
7576         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7577         ;;
7578       *-*-cygwin* )
7579         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7580         ;;
7581       * ) # otherwise, assume *nix
7582         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7583         ;;
7584     esac
7585     ;;
7586   *-*-cygwin* )
7587     case $build in
7588       *-*-mingw* ) # actually msys
7589         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7590         ;;
7591       *-*-cygwin* )
7592         lt_cv_to_host_file_cmd=func_convert_file_noop
7593         ;;
7594       * ) # otherwise, assume *nix
7595         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7596         ;;
7597     esac
7598     ;;
7599   * ) # unhandled hosts (and "normal" native builds)
7600     lt_cv_to_host_file_cmd=func_convert_file_noop
7601     ;;
7602 esac
7603
7604 fi
7605
7606 to_host_file_cmd=$lt_cv_to_host_file_cmd
7607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7608 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
7609
7610
7611
7612
7613
7614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7615 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7616 if ${lt_cv_to_tool_file_cmd+:} false; then :
7617   $as_echo_n "(cached) " >&6
7618 else
7619   #assume ordinary cross tools, or native build.
7620 lt_cv_to_tool_file_cmd=func_convert_file_noop
7621 case $host in
7622   *-*-mingw* )
7623     case $build in
7624       *-*-mingw* ) # actually msys
7625         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7626         ;;
7627     esac
7628     ;;
7629 esac
7630
7631 fi
7632
7633 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7635 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7636
7637
7638
7639
7640
7641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7642 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7643 if ${lt_cv_ld_reload_flag+:} false; then :
7644   $as_echo_n "(cached) " >&6
7645 else
7646   lt_cv_ld_reload_flag='-r'
7647 fi
7648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7649 $as_echo "$lt_cv_ld_reload_flag" >&6; }
7650 reload_flag=$lt_cv_ld_reload_flag
7651 case $reload_flag in
7652 "" | " "*) ;;
7653 *) reload_flag=" $reload_flag" ;;
7654 esac
7655 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7656 case $host_os in
7657   cygwin* | mingw* | pw32* | cegcc*)
7658     if test yes != "$GCC"; then
7659       reload_cmds=false
7660     fi
7661     ;;
7662   darwin*)
7663     if test yes = "$GCC"; then
7664       reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
7665     else
7666       reload_cmds='$LD$reload_flag -o $output$reload_objs'
7667     fi
7668     ;;
7669 esac
7670
7671
7672
7673
7674
7675
7676
7677
7678
7679 if test -n "$ac_tool_prefix"; then
7680   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7681 set dummy ${ac_tool_prefix}objdump; ac_word=$2
7682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7683 $as_echo_n "checking for $ac_word... " >&6; }
7684 if ${ac_cv_prog_OBJDUMP+:} false; then :
7685   $as_echo_n "(cached) " >&6
7686 else
7687   if test -n "$OBJDUMP"; then
7688   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7689 else
7690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7691 for as_dir in $PATH
7692 do
7693   IFS=$as_save_IFS
7694   test -z "$as_dir" && as_dir=.
7695     for ac_exec_ext in '' $ac_executable_extensions; do
7696   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7697     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7698     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7699     break 2
7700   fi
7701 done
7702   done
7703 IFS=$as_save_IFS
7704
7705 fi
7706 fi
7707 OBJDUMP=$ac_cv_prog_OBJDUMP
7708 if test -n "$OBJDUMP"; then
7709   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7710 $as_echo "$OBJDUMP" >&6; }
7711 else
7712   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7713 $as_echo "no" >&6; }
7714 fi
7715
7716
7717 fi
7718 if test -z "$ac_cv_prog_OBJDUMP"; then
7719   ac_ct_OBJDUMP=$OBJDUMP
7720   # Extract the first word of "objdump", so it can be a program name with args.
7721 set dummy objdump; ac_word=$2
7722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7723 $as_echo_n "checking for $ac_word... " >&6; }
7724 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7725   $as_echo_n "(cached) " >&6
7726 else
7727   if test -n "$ac_ct_OBJDUMP"; then
7728   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7729 else
7730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7731 for as_dir in $PATH
7732 do
7733   IFS=$as_save_IFS
7734   test -z "$as_dir" && as_dir=.
7735     for ac_exec_ext in '' $ac_executable_extensions; do
7736   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7737     ac_cv_prog_ac_ct_OBJDUMP="objdump"
7738     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7739     break 2
7740   fi
7741 done
7742   done
7743 IFS=$as_save_IFS
7744
7745 fi
7746 fi
7747 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7748 if test -n "$ac_ct_OBJDUMP"; then
7749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7750 $as_echo "$ac_ct_OBJDUMP" >&6; }
7751 else
7752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7753 $as_echo "no" >&6; }
7754 fi
7755
7756   if test "x$ac_ct_OBJDUMP" = x; then
7757     OBJDUMP="false"
7758   else
7759     case $cross_compiling:$ac_tool_warned in
7760 yes:)
7761 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7762 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7763 ac_tool_warned=yes ;;
7764 esac
7765     OBJDUMP=$ac_ct_OBJDUMP
7766   fi
7767 else
7768   OBJDUMP="$ac_cv_prog_OBJDUMP"
7769 fi
7770
7771 test -z "$OBJDUMP" && OBJDUMP=objdump
7772
7773
7774
7775
7776
7777
7778
7779
7780
7781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
7782 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
7783 if ${lt_cv_deplibs_check_method+:} false; then :
7784   $as_echo_n "(cached) " >&6
7785 else
7786   lt_cv_file_magic_cmd='$MAGIC_CMD'
7787 lt_cv_file_magic_test_file=
7788 lt_cv_deplibs_check_method='unknown'
7789 # Need to set the preceding variable on all platforms that support
7790 # interlibrary dependencies.
7791 # 'none' -- dependencies not supported.
7792 # 'unknown' -- same as none, but documents that we really don't know.
7793 # 'pass_all' -- all dependencies passed with no checks.
7794 # 'test_compile' -- check by making test program.
7795 # 'file_magic [[regex]]' -- check by looking for files in library path
7796 # that responds to the $file_magic_cmd with a given extended regex.
7797 # If you have 'file' or equivalent on your system and you're not sure
7798 # whether 'pass_all' will *always* work, you probably want this one.
7799
7800 case $host_os in
7801 aix[4-9]*)
7802   lt_cv_deplibs_check_method=pass_all
7803   ;;
7804
7805 beos*)
7806   lt_cv_deplibs_check_method=pass_all
7807   ;;
7808
7809 bsdi[45]*)
7810   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
7811   lt_cv_file_magic_cmd='/usr/bin/file -L'
7812   lt_cv_file_magic_test_file=/shlib/libc.so
7813   ;;
7814
7815 cygwin*)
7816   # func_win32_libid is a shell function defined in ltmain.sh
7817   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7818   lt_cv_file_magic_cmd='func_win32_libid'
7819   ;;
7820
7821 mingw* | pw32*)
7822   # Base MSYS/MinGW do not provide the 'file' command needed by
7823   # func_win32_libid shell function, so use a weaker test based on 'objdump',
7824   # unless we find 'file', for example because we are cross-compiling.
7825   if ( file / ) >/dev/null 2>&1; then
7826     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7827     lt_cv_file_magic_cmd='func_win32_libid'
7828   else
7829     # Keep this pattern in sync with the one in func_win32_libid.
7830     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
7831     lt_cv_file_magic_cmd='$OBJDUMP -f'
7832   fi
7833   ;;
7834
7835 cegcc*)
7836   # use the weaker test based on 'objdump'. See mingw*.
7837   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
7838   lt_cv_file_magic_cmd='$OBJDUMP -f'
7839   ;;
7840
7841 darwin* | rhapsody*)
7842   lt_cv_deplibs_check_method=pass_all
7843   ;;
7844
7845 freebsd* | dragonfly*)
7846   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
7847     case $host_cpu in
7848     i*86 )
7849       # Not sure whether the presence of OpenBSD here was a mistake.
7850       # Let's accept both of them until this is cleared up.
7851       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
7852       lt_cv_file_magic_cmd=/usr/bin/file
7853       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
7854       ;;
7855     esac
7856   else
7857     lt_cv_deplibs_check_method=pass_all
7858   fi
7859   ;;
7860
7861 haiku*)
7862   lt_cv_deplibs_check_method=pass_all
7863   ;;
7864
7865 hpux10.20* | hpux11*)
7866   lt_cv_file_magic_cmd=/usr/bin/file
7867   case $host_cpu in
7868   ia64*)
7869     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
7870     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
7871     ;;
7872   hppa*64*)
7873     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]'
7874     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
7875     ;;
7876   *)
7877     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
7878     lt_cv_file_magic_test_file=/usr/lib/libc.sl
7879     ;;
7880   esac
7881   ;;
7882
7883 interix[3-9]*)
7884   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
7885   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
7886   ;;
7887
7888 irix5* | irix6* | nonstopux*)
7889   case $LD in
7890   *-32|*"-32 ") libmagic=32-bit;;
7891   *-n32|*"-n32 ") libmagic=N32;;
7892   *-64|*"-64 ") libmagic=64-bit;;
7893   *) libmagic=never-match;;
7894   esac
7895   lt_cv_deplibs_check_method=pass_all
7896   ;;
7897
7898 # This must be glibc/ELF.
7899 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
7900   lt_cv_deplibs_check_method=pass_all
7901   ;;
7902
7903 netbsd*)
7904   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
7905     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
7906   else
7907     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
7908   fi
7909   ;;
7910
7911 newos6*)
7912   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
7913   lt_cv_file_magic_cmd=/usr/bin/file
7914   lt_cv_file_magic_test_file=/usr/lib/libnls.so
7915   ;;
7916
7917 *nto* | *qnx*)
7918   lt_cv_deplibs_check_method=pass_all
7919   ;;
7920
7921 openbsd* | bitrig*)
7922   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
7923     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
7924   else
7925     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
7926   fi
7927   ;;
7928
7929 osf3* | osf4* | osf5*)
7930   lt_cv_deplibs_check_method=pass_all
7931   ;;
7932
7933 rdos*)
7934   lt_cv_deplibs_check_method=pass_all
7935   ;;
7936
7937 solaris*)
7938   lt_cv_deplibs_check_method=pass_all
7939   ;;
7940
7941 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
7942   lt_cv_deplibs_check_method=pass_all
7943   ;;
7944
7945 sysv4 | sysv4.3*)
7946   case $host_vendor in
7947   motorola)
7948     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]'
7949     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
7950     ;;
7951   ncr)
7952     lt_cv_deplibs_check_method=pass_all
7953     ;;
7954   sequent)
7955     lt_cv_file_magic_cmd='/bin/file'
7956     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
7957     ;;
7958   sni)
7959     lt_cv_file_magic_cmd='/bin/file'
7960     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
7961     lt_cv_file_magic_test_file=/lib/libc.so
7962     ;;
7963   siemens)
7964     lt_cv_deplibs_check_method=pass_all
7965     ;;
7966   pc)
7967     lt_cv_deplibs_check_method=pass_all
7968     ;;
7969   esac
7970   ;;
7971
7972 tpf*)
7973   lt_cv_deplibs_check_method=pass_all
7974   ;;
7975 os2*)
7976   lt_cv_deplibs_check_method=pass_all
7977   ;;
7978 esac
7979
7980 fi
7981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
7982 $as_echo "$lt_cv_deplibs_check_method" >&6; }
7983
7984 file_magic_glob=
7985 want_nocaseglob=no
7986 if test "$build" = "$host"; then
7987   case $host_os in
7988   mingw* | pw32*)
7989     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
7990       want_nocaseglob=yes
7991     else
7992       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
7993     fi
7994     ;;
7995   esac
7996 fi
7997
7998 file_magic_cmd=$lt_cv_file_magic_cmd
7999 deplibs_check_method=$lt_cv_deplibs_check_method
8000 test -z "$deplibs_check_method" && deplibs_check_method=unknown
8001
8002
8003
8004
8005
8006
8007
8008
8009
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021
8022
8023 if test -n "$ac_tool_prefix"; then
8024   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8025 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8027 $as_echo_n "checking for $ac_word... " >&6; }
8028 if ${ac_cv_prog_DLLTOOL+:} false; then :
8029   $as_echo_n "(cached) " >&6
8030 else
8031   if test -n "$DLLTOOL"; then
8032   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8033 else
8034 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8035 for as_dir in $PATH
8036 do
8037   IFS=$as_save_IFS
8038   test -z "$as_dir" && as_dir=.
8039     for ac_exec_ext in '' $ac_executable_extensions; do
8040   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8041     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8042     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8043     break 2
8044   fi
8045 done
8046   done
8047 IFS=$as_save_IFS
8048
8049 fi
8050 fi
8051 DLLTOOL=$ac_cv_prog_DLLTOOL
8052 if test -n "$DLLTOOL"; then
8053   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8054 $as_echo "$DLLTOOL" >&6; }
8055 else
8056   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8057 $as_echo "no" >&6; }
8058 fi
8059
8060
8061 fi
8062 if test -z "$ac_cv_prog_DLLTOOL"; then
8063   ac_ct_DLLTOOL=$DLLTOOL
8064   # Extract the first word of "dlltool", so it can be a program name with args.
8065 set dummy dlltool; ac_word=$2
8066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8067 $as_echo_n "checking for $ac_word... " >&6; }
8068 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8069   $as_echo_n "(cached) " >&6
8070 else
8071   if test -n "$ac_ct_DLLTOOL"; then
8072   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8073 else
8074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8075 for as_dir in $PATH
8076 do
8077   IFS=$as_save_IFS
8078   test -z "$as_dir" && as_dir=.
8079     for ac_exec_ext in '' $ac_executable_extensions; do
8080   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8081     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8082     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8083     break 2
8084   fi
8085 done
8086   done
8087 IFS=$as_save_IFS
8088
8089 fi
8090 fi
8091 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8092 if test -n "$ac_ct_DLLTOOL"; then
8093   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8094 $as_echo "$ac_ct_DLLTOOL" >&6; }
8095 else
8096   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8097 $as_echo "no" >&6; }
8098 fi
8099
8100   if test "x$ac_ct_DLLTOOL" = x; then
8101     DLLTOOL="false"
8102   else
8103     case $cross_compiling:$ac_tool_warned in
8104 yes:)
8105 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8106 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8107 ac_tool_warned=yes ;;
8108 esac
8109     DLLTOOL=$ac_ct_DLLTOOL
8110   fi
8111 else
8112   DLLTOOL="$ac_cv_prog_DLLTOOL"
8113 fi
8114
8115 test -z "$DLLTOOL" && DLLTOOL=dlltool
8116
8117
8118
8119
8120
8121
8122
8123
8124
8125
8126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8127 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8128 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8129   $as_echo_n "(cached) " >&6
8130 else
8131   lt_cv_sharedlib_from_linklib_cmd='unknown'
8132
8133 case $host_os in
8134 cygwin* | mingw* | pw32* | cegcc*)
8135   # two different shell functions defined in ltmain.sh;
8136   # decide which one to use based on capabilities of $DLLTOOL
8137   case `$DLLTOOL --help 2>&1` in
8138   *--identify-strict*)
8139     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8140     ;;
8141   *)
8142     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8143     ;;
8144   esac
8145   ;;
8146 *)
8147   # fallback: assume linklib IS sharedlib
8148   lt_cv_sharedlib_from_linklib_cmd=$ECHO
8149   ;;
8150 esac
8151
8152 fi
8153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8154 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8155 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8156 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8157
8158
8159
8160
8161
8162
8163
8164 if test -n "$ac_tool_prefix"; then
8165   for ac_prog in ar
8166   do
8167     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8168 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8170 $as_echo_n "checking for $ac_word... " >&6; }
8171 if ${ac_cv_prog_AR+:} false; then :
8172   $as_echo_n "(cached) " >&6
8173 else
8174   if test -n "$AR"; then
8175   ac_cv_prog_AR="$AR" # Let the user override the test.
8176 else
8177 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8178 for as_dir in $PATH
8179 do
8180   IFS=$as_save_IFS
8181   test -z "$as_dir" && as_dir=.
8182     for ac_exec_ext in '' $ac_executable_extensions; do
8183   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8184     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8185     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8186     break 2
8187   fi
8188 done
8189   done
8190 IFS=$as_save_IFS
8191
8192 fi
8193 fi
8194 AR=$ac_cv_prog_AR
8195 if test -n "$AR"; then
8196   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8197 $as_echo "$AR" >&6; }
8198 else
8199   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8200 $as_echo "no" >&6; }
8201 fi
8202
8203
8204     test -n "$AR" && break
8205   done
8206 fi
8207 if test -z "$AR"; then
8208   ac_ct_AR=$AR
8209   for ac_prog in ar
8210 do
8211   # Extract the first word of "$ac_prog", so it can be a program name with args.
8212 set dummy $ac_prog; ac_word=$2
8213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8214 $as_echo_n "checking for $ac_word... " >&6; }
8215 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8216   $as_echo_n "(cached) " >&6
8217 else
8218   if test -n "$ac_ct_AR"; then
8219   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8220 else
8221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8222 for as_dir in $PATH
8223 do
8224   IFS=$as_save_IFS
8225   test -z "$as_dir" && as_dir=.
8226     for ac_exec_ext in '' $ac_executable_extensions; do
8227   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8228     ac_cv_prog_ac_ct_AR="$ac_prog"
8229     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8230     break 2
8231   fi
8232 done
8233   done
8234 IFS=$as_save_IFS
8235
8236 fi
8237 fi
8238 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8239 if test -n "$ac_ct_AR"; then
8240   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8241 $as_echo "$ac_ct_AR" >&6; }
8242 else
8243   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8244 $as_echo "no" >&6; }
8245 fi
8246
8247
8248   test -n "$ac_ct_AR" && break
8249 done
8250
8251   if test "x$ac_ct_AR" = x; then
8252     AR="false"
8253   else
8254     case $cross_compiling:$ac_tool_warned in
8255 yes:)
8256 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8257 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8258 ac_tool_warned=yes ;;
8259 esac
8260     AR=$ac_ct_AR
8261   fi
8262 fi
8263
8264 : ${AR=ar}
8265 : ${AR_FLAGS=cru}
8266
8267
8268
8269
8270
8271
8272
8273
8274
8275
8276
8277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8278 $as_echo_n "checking for archiver @FILE support... " >&6; }
8279 if ${lt_cv_ar_at_file+:} false; then :
8280   $as_echo_n "(cached) " >&6
8281 else
8282   lt_cv_ar_at_file=no
8283    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8284 /* end confdefs.h.  */
8285
8286 int
8287 main ()
8288 {
8289
8290   ;
8291   return 0;
8292 }
8293 _ACEOF
8294 if ac_fn_c_try_compile "$LINENO"; then :
8295   echo conftest.$ac_objext > conftest.lst
8296       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8297       { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8298   (eval $lt_ar_try) 2>&5
8299   ac_status=$?
8300   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8301   test $ac_status = 0; }
8302       if test 0 -eq "$ac_status"; then
8303         # Ensure the archiver fails upon bogus file names.
8304         rm -f conftest.$ac_objext libconftest.a
8305         { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8306   (eval $lt_ar_try) 2>&5
8307   ac_status=$?
8308   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8309   test $ac_status = 0; }
8310         if test 0 -ne "$ac_status"; then
8311           lt_cv_ar_at_file=@
8312         fi
8313       fi
8314       rm -f conftest.* libconftest.a
8315
8316 fi
8317 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8318
8319 fi
8320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8321 $as_echo "$lt_cv_ar_at_file" >&6; }
8322
8323 if test no = "$lt_cv_ar_at_file"; then
8324   archiver_list_spec=
8325 else
8326   archiver_list_spec=$lt_cv_ar_at_file
8327 fi
8328
8329
8330
8331
8332
8333
8334
8335 if test -n "$ac_tool_prefix"; then
8336   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8337 set dummy ${ac_tool_prefix}strip; ac_word=$2
8338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8339 $as_echo_n "checking for $ac_word... " >&6; }
8340 if ${ac_cv_prog_STRIP+:} false; then :
8341   $as_echo_n "(cached) " >&6
8342 else
8343   if test -n "$STRIP"; then
8344   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8345 else
8346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8347 for as_dir in $PATH
8348 do
8349   IFS=$as_save_IFS
8350   test -z "$as_dir" && as_dir=.
8351     for ac_exec_ext in '' $ac_executable_extensions; do
8352   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8353     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8354     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8355     break 2
8356   fi
8357 done
8358   done
8359 IFS=$as_save_IFS
8360
8361 fi
8362 fi
8363 STRIP=$ac_cv_prog_STRIP
8364 if test -n "$STRIP"; then
8365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8366 $as_echo "$STRIP" >&6; }
8367 else
8368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8369 $as_echo "no" >&6; }
8370 fi
8371
8372
8373 fi
8374 if test -z "$ac_cv_prog_STRIP"; then
8375   ac_ct_STRIP=$STRIP
8376   # Extract the first word of "strip", so it can be a program name with args.
8377 set dummy strip; 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_ac_ct_STRIP+:} false; then :
8381   $as_echo_n "(cached) " >&6
8382 else
8383   if test -n "$ac_ct_STRIP"; then
8384   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # 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_ac_ct_STRIP="strip"
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 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8404 if test -n "$ac_ct_STRIP"; then
8405   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8406 $as_echo "$ac_ct_STRIP" >&6; }
8407 else
8408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8409 $as_echo "no" >&6; }
8410 fi
8411
8412   if test "x$ac_ct_STRIP" = x; then
8413     STRIP=":"
8414   else
8415     case $cross_compiling:$ac_tool_warned in
8416 yes:)
8417 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8418 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8419 ac_tool_warned=yes ;;
8420 esac
8421     STRIP=$ac_ct_STRIP
8422   fi
8423 else
8424   STRIP="$ac_cv_prog_STRIP"
8425 fi
8426
8427 test -z "$STRIP" && STRIP=:
8428
8429
8430
8431
8432
8433
8434 if test -n "$ac_tool_prefix"; then
8435   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8436 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8438 $as_echo_n "checking for $ac_word... " >&6; }
8439 if ${ac_cv_prog_RANLIB+:} false; then :
8440   $as_echo_n "(cached) " >&6
8441 else
8442   if test -n "$RANLIB"; then
8443   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8444 else
8445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8446 for as_dir in $PATH
8447 do
8448   IFS=$as_save_IFS
8449   test -z "$as_dir" && as_dir=.
8450     for ac_exec_ext in '' $ac_executable_extensions; do
8451   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8452     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8453     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8454     break 2
8455   fi
8456 done
8457   done
8458 IFS=$as_save_IFS
8459
8460 fi
8461 fi
8462 RANLIB=$ac_cv_prog_RANLIB
8463 if test -n "$RANLIB"; then
8464   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8465 $as_echo "$RANLIB" >&6; }
8466 else
8467   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8468 $as_echo "no" >&6; }
8469 fi
8470
8471
8472 fi
8473 if test -z "$ac_cv_prog_RANLIB"; then
8474   ac_ct_RANLIB=$RANLIB
8475   # Extract the first word of "ranlib", so it can be a program name with args.
8476 set dummy ranlib; ac_word=$2
8477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8478 $as_echo_n "checking for $ac_word... " >&6; }
8479 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8480   $as_echo_n "(cached) " >&6
8481 else
8482   if test -n "$ac_ct_RANLIB"; then
8483   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8484 else
8485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8486 for as_dir in $PATH
8487 do
8488   IFS=$as_save_IFS
8489   test -z "$as_dir" && as_dir=.
8490     for ac_exec_ext in '' $ac_executable_extensions; do
8491   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8492     ac_cv_prog_ac_ct_RANLIB="ranlib"
8493     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8494     break 2
8495   fi
8496 done
8497   done
8498 IFS=$as_save_IFS
8499
8500 fi
8501 fi
8502 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8503 if test -n "$ac_ct_RANLIB"; then
8504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8505 $as_echo "$ac_ct_RANLIB" >&6; }
8506 else
8507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8508 $as_echo "no" >&6; }
8509 fi
8510
8511   if test "x$ac_ct_RANLIB" = x; then
8512     RANLIB=":"
8513   else
8514     case $cross_compiling:$ac_tool_warned in
8515 yes:)
8516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8517 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8518 ac_tool_warned=yes ;;
8519 esac
8520     RANLIB=$ac_ct_RANLIB
8521   fi
8522 else
8523   RANLIB="$ac_cv_prog_RANLIB"
8524 fi
8525
8526 test -z "$RANLIB" && RANLIB=:
8527
8528
8529
8530
8531
8532
8533 # Determine commands to create old-style static archives.
8534 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8535 old_postinstall_cmds='chmod 644 $oldlib'
8536 old_postuninstall_cmds=
8537
8538 if test -n "$RANLIB"; then
8539   case $host_os in
8540   bitrig* | openbsd*)
8541     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8542     ;;
8543   *)
8544     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8545     ;;
8546   esac
8547   old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8548 fi
8549
8550 case $host_os in
8551   darwin*)
8552     lock_old_archive_extraction=yes ;;
8553   *)
8554     lock_old_archive_extraction=no ;;
8555 esac
8556
8557
8558
8559
8560
8561
8562
8563
8564
8565
8566
8567
8568
8569
8570
8571
8572
8573
8574
8575
8576
8577 for ac_prog in gawk mawk nawk awk
8578 do
8579   # Extract the first word of "$ac_prog", so it can be a program name with args.
8580 set dummy $ac_prog; ac_word=$2
8581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8582 $as_echo_n "checking for $ac_word... " >&6; }
8583 if ${ac_cv_prog_AWK+:} false; then :
8584   $as_echo_n "(cached) " >&6
8585 else
8586   if test -n "$AWK"; then
8587   ac_cv_prog_AWK="$AWK" # Let the user override the test.
8588 else
8589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8590 for as_dir in $PATH
8591 do
8592   IFS=$as_save_IFS
8593   test -z "$as_dir" && as_dir=.
8594     for ac_exec_ext in '' $ac_executable_extensions; do
8595   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8596     ac_cv_prog_AWK="$ac_prog"
8597     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8598     break 2
8599   fi
8600 done
8601   done
8602 IFS=$as_save_IFS
8603
8604 fi
8605 fi
8606 AWK=$ac_cv_prog_AWK
8607 if test -n "$AWK"; then
8608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
8609 $as_echo "$AWK" >&6; }
8610 else
8611   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8612 $as_echo "no" >&6; }
8613 fi
8614
8615
8616   test -n "$AWK" && break
8617 done
8618
8619
8620
8621
8622
8623
8624
8625
8626
8627
8628
8629
8630
8631
8632
8633
8634
8635
8636
8637 # If no C compiler was specified, use CC.
8638 LTCC=${LTCC-"$CC"}
8639
8640 # If no C compiler flags were specified, use CFLAGS.
8641 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8642
8643 # Allow CC to be a program name with arguments.
8644 compiler=$CC
8645
8646
8647 # Check for command to grab the raw symbol name followed by C symbol from nm.
8648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8649 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8650 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8651   $as_echo_n "(cached) " >&6
8652 else
8653
8654 # These are sane defaults that work on at least a few old systems.
8655 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
8656
8657 # Character class describing NM global symbol codes.
8658 symcode='[BCDEGRST]'
8659
8660 # Regexp to match symbols that can be accessed directly from C.
8661 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8662
8663 # Define system-specific variables.
8664 case $host_os in
8665 aix*)
8666   symcode='[BCDT]'
8667   ;;
8668 cygwin* | mingw* | pw32* | cegcc*)
8669   symcode='[ABCDGISTW]'
8670   ;;
8671 hpux*)
8672   if test ia64 = "$host_cpu"; then
8673     symcode='[ABCDEGRST]'
8674   fi
8675   ;;
8676 irix* | nonstopux*)
8677   symcode='[BCDEGRST]'
8678   ;;
8679 osf*)
8680   symcode='[BCDEGQRST]'
8681   ;;
8682 solaris*)
8683   symcode='[BDRT]'
8684   ;;
8685 sco3.2v5*)
8686   symcode='[DT]'
8687   ;;
8688 sysv4.2uw2*)
8689   symcode='[DT]'
8690   ;;
8691 sysv5* | sco5v6* | unixware* | OpenUNIX*)
8692   symcode='[ABDT]'
8693   ;;
8694 sysv4)
8695   symcode='[DFNSTU]'
8696   ;;
8697 esac
8698
8699 # If we're using GNU nm, then use its standard symbol codes.
8700 case `$NM -V 2>&1` in
8701 *GNU* | *'with BFD'*)
8702   symcode='[ABCDGIRSTW]' ;;
8703 esac
8704
8705 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8706   # Gets list of data symbols to import.
8707   lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
8708   # Adjust the below global symbol transforms to fixup imported variables.
8709   lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
8710   lt_c_name_hook=" -e 's/^I .* \(.*\)$/  {\"\1\", (void *) 0},/p'"
8711   lt_c_name_lib_hook="\
8712   -e 's/^I .* \(lib.*\)$/  {\"\1\", (void *) 0},/p'\
8713   -e 's/^I .* \(.*\)$/  {\"lib\1\", (void *) 0},/p'"
8714 else
8715   # Disable hooks by default.
8716   lt_cv_sys_global_symbol_to_import=
8717   lt_cdecl_hook=
8718   lt_c_name_hook=
8719   lt_c_name_lib_hook=
8720 fi
8721
8722 # Transform an extracted symbol line into a proper C declaration.
8723 # Some systems (esp. on ia64) link data and code symbols differently,
8724 # so use this general approach.
8725 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
8726 $lt_cdecl_hook\
8727 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
8728 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
8729
8730 # Transform an extracted symbol line into symbol name and symbol address
8731 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
8732 $lt_c_name_hook\
8733 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8734 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/p'"
8735
8736 # Transform an extracted symbol line into symbol name with lib prefix and
8737 # symbol address.
8738 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
8739 $lt_c_name_lib_hook\
8740 " -e 's/^: \(.*\) .*$/  {\"\1\", (void *) 0},/p'"\
8741 " -e 's/^$symcode$symcode* .* \(lib.*\)$/  {\"\1\", (void *) \&\1},/p'"\
8742 " -e 's/^$symcode$symcode* .* \(.*\)$/  {\"lib\1\", (void *) \&\1},/p'"
8743
8744 # Handle CRLF in mingw tool chain
8745 opt_cr=
8746 case $build_os in
8747 mingw*)
8748   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8749   ;;
8750 esac
8751
8752 # Try without a prefix underscore, then with it.
8753 for ac_symprfx in "" "_"; do
8754
8755   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8756   symxfrm="\\1 $ac_symprfx\\2 \\2"
8757
8758   # Write the raw and C identifiers.
8759   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8760     # Fake it for dumpbin and say T for any non-static function,
8761     # D for any global variable and I for any imported variable.
8762     # Also find C++ and __fastcall symbols from MSVC++,
8763     # which start with @ or ?.
8764     lt_cv_sys_global_symbol_pipe="$AWK '"\
8765 "     {last_section=section; section=\$ 3};"\
8766 "     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8767 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8768 "     /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
8769 "     /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
8770 "     /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
8771 "     \$ 0!~/External *\|/{next};"\
8772 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8773 "     {if(hide[section]) next};"\
8774 "     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
8775 "     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
8776 "     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
8777 "     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
8778 "     ' prfx=^$ac_symprfx"
8779   else
8780     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
8781   fi
8782   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
8783
8784   # Check to see that the pipe works correctly.
8785   pipe_works=no
8786
8787   rm -f conftest*
8788   cat > conftest.$ac_ext <<_LT_EOF
8789 #ifdef __cplusplus
8790 extern "C" {
8791 #endif
8792 char nm_test_var;
8793 void nm_test_func(void);
8794 void nm_test_func(void){}
8795 #ifdef __cplusplus
8796 }
8797 #endif
8798 int main(){nm_test_var='a';nm_test_func();return(0);}
8799 _LT_EOF
8800
8801   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8802   (eval $ac_compile) 2>&5
8803   ac_status=$?
8804   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8805   test $ac_status = 0; }; then
8806     # Now try to grab the symbols.
8807     nlist=conftest.nm
8808     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
8809   (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
8810   ac_status=$?
8811   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8812   test $ac_status = 0; } && test -s "$nlist"; then
8813       # Try sorting and uniquifying the output.
8814       if sort "$nlist" | uniq > "$nlist"T; then
8815         mv -f "$nlist"T "$nlist"
8816       else
8817         rm -f "$nlist"T
8818       fi
8819
8820       # Make sure that we snagged all the symbols we need.
8821       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
8822         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
8823           cat <<_LT_EOF > conftest.$ac_ext
8824 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
8825 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
8826 /* DATA imports from DLLs on WIN32 can't be const, because runtime
8827    relocations are performed -- see ld's documentation on pseudo-relocs.  */
8828 # define LT_DLSYM_CONST
8829 #elif defined __osf__
8830 /* This system does not cope well with relocations in const data.  */
8831 # define LT_DLSYM_CONST
8832 #else
8833 # define LT_DLSYM_CONST const
8834 #endif
8835
8836 #ifdef __cplusplus
8837 extern "C" {
8838 #endif
8839
8840 _LT_EOF
8841           # Now generate the symbol file.
8842           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
8843
8844           cat <<_LT_EOF >> conftest.$ac_ext
8845
8846 /* The mapping between symbol names and symbols.  */
8847 LT_DLSYM_CONST struct {
8848   const char *name;
8849   void       *address;
8850 }
8851 lt__PROGRAM__LTX_preloaded_symbols[] =
8852 {
8853   { "@PROGRAM@", (void *) 0 },
8854 _LT_EOF
8855           $SED "s/^$symcode$symcode* .* \(.*\)$/  {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
8856           cat <<\_LT_EOF >> conftest.$ac_ext
8857   {0, (void *) 0}
8858 };
8859
8860 /* This works around a problem in FreeBSD linker */
8861 #ifdef FREEBSD_WORKAROUND
8862 static const void *lt_preloaded_setup() {
8863   return lt__PROGRAM__LTX_preloaded_symbols;
8864 }
8865 #endif
8866
8867 #ifdef __cplusplus
8868 }
8869 #endif
8870 _LT_EOF
8871           # Now try linking the two files.
8872           mv conftest.$ac_objext conftstm.$ac_objext
8873           lt_globsym_save_LIBS=$LIBS
8874           lt_globsym_save_CFLAGS=$CFLAGS
8875           LIBS=conftstm.$ac_objext
8876           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
8877           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
8878   (eval $ac_link) 2>&5
8879   ac_status=$?
8880   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8881   test $ac_status = 0; } && test -s conftest$ac_exeext; then
8882             pipe_works=yes
8883           fi
8884           LIBS=$lt_globsym_save_LIBS
8885           CFLAGS=$lt_globsym_save_CFLAGS
8886         else
8887           echo "cannot find nm_test_func in $nlist" >&5
8888         fi
8889       else
8890         echo "cannot find nm_test_var in $nlist" >&5
8891       fi
8892     else
8893       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
8894     fi
8895   else
8896     echo "$progname: failed program was:" >&5
8897     cat conftest.$ac_ext >&5
8898   fi
8899   rm -rf conftest* conftst*
8900
8901   # Do not use the global_symbol_pipe unless it works.
8902   if test yes = "$pipe_works"; then
8903     break
8904   else
8905     lt_cv_sys_global_symbol_pipe=
8906   fi
8907 done
8908
8909 fi
8910
8911 if test -z "$lt_cv_sys_global_symbol_pipe"; then
8912   lt_cv_sys_global_symbol_to_cdecl=
8913 fi
8914 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
8915   { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
8916 $as_echo "failed" >&6; }
8917 else
8918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
8919 $as_echo "ok" >&6; }
8920 fi
8921
8922 # Response file support.
8923 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8924   nm_file_list_spec='@'
8925 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
8926   nm_file_list_spec='@'
8927 fi
8928
8929
8930
8931
8932
8933
8934
8935
8936
8937
8938
8939
8940
8941
8942
8943
8944
8945
8946
8947
8948
8949
8950
8951
8952
8953
8954
8955
8956
8957
8958
8959
8960
8961
8962
8963
8964
8965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
8966 $as_echo_n "checking for sysroot... " >&6; }
8967
8968 # Check whether --with-sysroot was given.
8969 if test "${with_sysroot+set}" = set; then :
8970   withval=$with_sysroot;
8971 else
8972   with_sysroot=no
8973 fi
8974
8975
8976 lt_sysroot=
8977 case $with_sysroot in #(
8978  yes)
8979    if test yes = "$GCC"; then
8980      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
8981    fi
8982    ;; #(
8983  /*)
8984    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
8985    ;; #(
8986  no|'')
8987    ;; #(
8988  *)
8989    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
8990 $as_echo "$with_sysroot" >&6; }
8991    as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
8992    ;;
8993 esac
8994
8995  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
8996 $as_echo "${lt_sysroot:-no}" >&6; }
8997
8998
8999
9000
9001
9002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9003 $as_echo_n "checking for a working dd... " >&6; }
9004 if ${ac_cv_path_lt_DD+:} false; then :
9005   $as_echo_n "(cached) " >&6
9006 else
9007   printf 0123456789abcdef0123456789abcdef >conftest.i
9008 cat conftest.i conftest.i >conftest2.i
9009 : ${lt_DD:=$DD}
9010 if test -z "$lt_DD"; then
9011   ac_path_lt_DD_found=false
9012   # Loop through the user's path and test for each of PROGNAME-LIST
9013   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9014 for as_dir in $PATH
9015 do
9016   IFS=$as_save_IFS
9017   test -z "$as_dir" && as_dir=.
9018     for ac_prog in dd; do
9019     for ac_exec_ext in '' $ac_executable_extensions; do
9020       ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9021       as_fn_executable_p "$ac_path_lt_DD" || continue
9022 if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9023   cmp -s conftest.i conftest.out \
9024   && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9025 fi
9026       $ac_path_lt_DD_found && break 3
9027     done
9028   done
9029   done
9030 IFS=$as_save_IFS
9031   if test -z "$ac_cv_path_lt_DD"; then
9032     :
9033   fi
9034 else
9035   ac_cv_path_lt_DD=$lt_DD
9036 fi
9037
9038 rm -f conftest.i conftest2.i conftest.out
9039 fi
9040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9041 $as_echo "$ac_cv_path_lt_DD" >&6; }
9042
9043
9044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9045 $as_echo_n "checking how to truncate binary pipes... " >&6; }
9046 if ${lt_cv_truncate_bin+:} false; then :
9047   $as_echo_n "(cached) " >&6
9048 else
9049   printf 0123456789abcdef0123456789abcdef >conftest.i
9050 cat conftest.i conftest.i >conftest2.i
9051 lt_cv_truncate_bin=
9052 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9053   cmp -s conftest.i conftest.out \
9054   && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9055 fi
9056 rm -f conftest.i conftest2.i conftest.out
9057 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9058 fi
9059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9060 $as_echo "$lt_cv_truncate_bin" >&6; }
9061
9062
9063
9064
9065
9066
9067
9068 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
9069 func_cc_basename ()
9070 {
9071     for cc_temp in $*""; do
9072       case $cc_temp in
9073         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9074         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9075         \-*) ;;
9076         *) break;;
9077       esac
9078     done
9079     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9080 }
9081
9082 # Check whether --enable-libtool-lock was given.
9083 if test "${enable_libtool_lock+set}" = set; then :
9084   enableval=$enable_libtool_lock;
9085 fi
9086
9087 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9088
9089 # Some flags need to be propagated to the compiler or linker for good
9090 # libtool support.
9091 case $host in
9092 ia64-*-hpux*)
9093   # Find out what ABI is being produced by ac_compile, and set mode
9094   # options accordingly.
9095   echo 'int i;' > conftest.$ac_ext
9096   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9097   (eval $ac_compile) 2>&5
9098   ac_status=$?
9099   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9100   test $ac_status = 0; }; then
9101     case `/usr/bin/file conftest.$ac_objext` in
9102       *ELF-32*)
9103         HPUX_IA64_MODE=32
9104         ;;
9105       *ELF-64*)
9106         HPUX_IA64_MODE=64
9107         ;;
9108     esac
9109   fi
9110   rm -rf conftest*
9111   ;;
9112 *-*-irix6*)
9113   # Find out what ABI is being produced by ac_compile, and set linker
9114   # options accordingly.
9115   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9116   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9117   (eval $ac_compile) 2>&5
9118   ac_status=$?
9119   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9120   test $ac_status = 0; }; then
9121     if test yes = "$lt_cv_prog_gnu_ld"; then
9122       case `/usr/bin/file conftest.$ac_objext` in
9123         *32-bit*)
9124           LD="${LD-ld} -melf32bsmip"
9125           ;;
9126         *N32*)
9127           LD="${LD-ld} -melf32bmipn32"
9128           ;;
9129         *64-bit*)
9130           LD="${LD-ld} -melf64bmip"
9131         ;;
9132       esac
9133     else
9134       case `/usr/bin/file conftest.$ac_objext` in
9135         *32-bit*)
9136           LD="${LD-ld} -32"
9137           ;;
9138         *N32*)
9139           LD="${LD-ld} -n32"
9140           ;;
9141         *64-bit*)
9142           LD="${LD-ld} -64"
9143           ;;
9144       esac
9145     fi
9146   fi
9147   rm -rf conftest*
9148   ;;
9149
9150 mips64*-*linux*)
9151   # Find out what ABI is being produced by ac_compile, and set linker
9152   # options accordingly.
9153   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9154   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9155   (eval $ac_compile) 2>&5
9156   ac_status=$?
9157   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9158   test $ac_status = 0; }; then
9159     emul=elf
9160     case `/usr/bin/file conftest.$ac_objext` in
9161       *32-bit*)
9162         emul="${emul}32"
9163         ;;
9164       *64-bit*)
9165         emul="${emul}64"
9166         ;;
9167     esac
9168     case `/usr/bin/file conftest.$ac_objext` in
9169       *MSB*)
9170         emul="${emul}btsmip"
9171         ;;
9172       *LSB*)
9173         emul="${emul}ltsmip"
9174         ;;
9175     esac
9176     case `/usr/bin/file conftest.$ac_objext` in
9177       *N32*)
9178         emul="${emul}n32"
9179         ;;
9180     esac
9181     LD="${LD-ld} -m $emul"
9182   fi
9183   rm -rf conftest*
9184   ;;
9185
9186 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9187 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9188   # Find out what ABI is being produced by ac_compile, and set linker
9189   # options accordingly.  Note that the listed cases only cover the
9190   # situations where additional linker options are needed (such as when
9191   # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9192   # vice versa); the common cases where no linker options are needed do
9193   # not appear in the list.
9194   echo 'int i;' > conftest.$ac_ext
9195   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9196   (eval $ac_compile) 2>&5
9197   ac_status=$?
9198   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9199   test $ac_status = 0; }; then
9200     case `/usr/bin/file conftest.o` in
9201       *32-bit*)
9202         case $host in
9203           x86_64-*kfreebsd*-gnu)
9204             LD="${LD-ld} -m elf_i386_fbsd"
9205             ;;
9206           x86_64-*linux*)
9207             case `/usr/bin/file conftest.o` in
9208               *x86-64*)
9209                 LD="${LD-ld} -m elf32_x86_64"
9210                 ;;
9211               *)
9212                 LD="${LD-ld} -m elf_i386"
9213                 ;;
9214             esac
9215             ;;
9216           powerpc64le-*linux*)
9217             LD="${LD-ld} -m elf32lppclinux"
9218             ;;
9219           powerpc64-*linux*)
9220             LD="${LD-ld} -m elf32ppclinux"
9221             ;;
9222           s390x-*linux*)
9223             LD="${LD-ld} -m elf_s390"
9224             ;;
9225           sparc64-*linux*)
9226             LD="${LD-ld} -m elf32_sparc"
9227             ;;
9228         esac
9229         ;;
9230       *64-bit*)
9231         case $host in
9232           x86_64-*kfreebsd*-gnu)
9233             LD="${LD-ld} -m elf_x86_64_fbsd"
9234             ;;
9235           x86_64-*linux*)
9236             LD="${LD-ld} -m elf_x86_64"
9237             ;;
9238           powerpcle-*linux*)
9239             LD="${LD-ld} -m elf64lppc"
9240             ;;
9241           powerpc-*linux*)
9242             LD="${LD-ld} -m elf64ppc"
9243             ;;
9244           s390*-*linux*|s390*-*tpf*)
9245             LD="${LD-ld} -m elf64_s390"
9246             ;;
9247           sparc*-*linux*)
9248             LD="${LD-ld} -m elf64_sparc"
9249             ;;
9250         esac
9251         ;;
9252     esac
9253   fi
9254   rm -rf conftest*
9255   ;;
9256
9257 *-*-sco3.2v5*)
9258   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9259   SAVE_CFLAGS=$CFLAGS
9260   CFLAGS="$CFLAGS -belf"
9261   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9262 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9263 if ${lt_cv_cc_needs_belf+:} false; then :
9264   $as_echo_n "(cached) " >&6
9265 else
9266   ac_ext=c
9267 ac_cpp='$CPP $CPPFLAGS'
9268 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9269 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9270 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9271
9272      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9273 /* end confdefs.h.  */
9274
9275 int
9276 main ()
9277 {
9278
9279   ;
9280   return 0;
9281 }
9282 _ACEOF
9283 if ac_fn_c_try_link "$LINENO"; then :
9284   lt_cv_cc_needs_belf=yes
9285 else
9286   lt_cv_cc_needs_belf=no
9287 fi
9288 rm -f core conftest.err conftest.$ac_objext \
9289     conftest$ac_exeext conftest.$ac_ext
9290      ac_ext=c
9291 ac_cpp='$CPP $CPPFLAGS'
9292 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9293 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9294 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9295
9296 fi
9297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9298 $as_echo "$lt_cv_cc_needs_belf" >&6; }
9299   if test yes != "$lt_cv_cc_needs_belf"; then
9300     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9301     CFLAGS=$SAVE_CFLAGS
9302   fi
9303   ;;
9304 *-*solaris*)
9305   # Find out what ABI is being produced by ac_compile, and set linker
9306   # options accordingly.
9307   echo 'int i;' > conftest.$ac_ext
9308   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9309   (eval $ac_compile) 2>&5
9310   ac_status=$?
9311   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9312   test $ac_status = 0; }; then
9313     case `/usr/bin/file conftest.o` in
9314     *64-bit*)
9315       case $lt_cv_prog_gnu_ld in
9316       yes*)
9317         case $host in
9318         i?86-*-solaris*|x86_64-*-solaris*)
9319           LD="${LD-ld} -m elf_x86_64"
9320           ;;
9321         sparc*-*-solaris*)
9322           LD="${LD-ld} -m elf64_sparc"
9323           ;;
9324         esac
9325         # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
9326         if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9327           LD=${LD-ld}_sol2
9328         fi
9329         ;;
9330       *)
9331         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9332           LD="${LD-ld} -64"
9333         fi
9334         ;;
9335       esac
9336       ;;
9337     esac
9338   fi
9339   rm -rf conftest*
9340   ;;
9341 esac
9342
9343 need_locks=$enable_libtool_lock
9344
9345 if test -n "$ac_tool_prefix"; then
9346   # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9347 set dummy ${ac_tool_prefix}mt; ac_word=$2
9348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9349 $as_echo_n "checking for $ac_word... " >&6; }
9350 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9351   $as_echo_n "(cached) " >&6
9352 else
9353   if test -n "$MANIFEST_TOOL"; then
9354   ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9355 else
9356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9357 for as_dir in $PATH
9358 do
9359   IFS=$as_save_IFS
9360   test -z "$as_dir" && as_dir=.
9361     for ac_exec_ext in '' $ac_executable_extensions; do
9362   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9363     ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9364     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9365     break 2
9366   fi
9367 done
9368   done
9369 IFS=$as_save_IFS
9370
9371 fi
9372 fi
9373 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9374 if test -n "$MANIFEST_TOOL"; then
9375   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9376 $as_echo "$MANIFEST_TOOL" >&6; }
9377 else
9378   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9379 $as_echo "no" >&6; }
9380 fi
9381
9382
9383 fi
9384 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9385   ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9386   # Extract the first word of "mt", so it can be a program name with args.
9387 set dummy mt; ac_word=$2
9388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9389 $as_echo_n "checking for $ac_word... " >&6; }
9390 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9391   $as_echo_n "(cached) " >&6
9392 else
9393   if test -n "$ac_ct_MANIFEST_TOOL"; then
9394   ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9395 else
9396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9397 for as_dir in $PATH
9398 do
9399   IFS=$as_save_IFS
9400   test -z "$as_dir" && as_dir=.
9401     for ac_exec_ext in '' $ac_executable_extensions; do
9402   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9403     ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9404     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9405     break 2
9406   fi
9407 done
9408   done
9409 IFS=$as_save_IFS
9410
9411 fi
9412 fi
9413 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9414 if test -n "$ac_ct_MANIFEST_TOOL"; then
9415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9416 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9417 else
9418   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9419 $as_echo "no" >&6; }
9420 fi
9421
9422   if test "x$ac_ct_MANIFEST_TOOL" = x; then
9423     MANIFEST_TOOL=":"
9424   else
9425     case $cross_compiling:$ac_tool_warned in
9426 yes:)
9427 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9428 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9429 ac_tool_warned=yes ;;
9430 esac
9431     MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9432   fi
9433 else
9434   MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9435 fi
9436
9437 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9439 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9440 if ${lt_cv_path_mainfest_tool+:} false; then :
9441   $as_echo_n "(cached) " >&6
9442 else
9443   lt_cv_path_mainfest_tool=no
9444   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9445   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9446   cat conftest.err >&5
9447   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9448     lt_cv_path_mainfest_tool=yes
9449   fi
9450   rm -f conftest*
9451 fi
9452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9453 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
9454 if test yes != "$lt_cv_path_mainfest_tool"; then
9455   MANIFEST_TOOL=:
9456 fi
9457
9458
9459
9460
9461
9462
9463   case $host_os in
9464     rhapsody* | darwin*)
9465     if test -n "$ac_tool_prefix"; then
9466   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9467 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9469 $as_echo_n "checking for $ac_word... " >&6; }
9470 if ${ac_cv_prog_DSYMUTIL+:} false; then :
9471   $as_echo_n "(cached) " >&6
9472 else
9473   if test -n "$DSYMUTIL"; then
9474   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9475 else
9476 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9477 for as_dir in $PATH
9478 do
9479   IFS=$as_save_IFS
9480   test -z "$as_dir" && as_dir=.
9481     for ac_exec_ext in '' $ac_executable_extensions; do
9482   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9483     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9484     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9485     break 2
9486   fi
9487 done
9488   done
9489 IFS=$as_save_IFS
9490
9491 fi
9492 fi
9493 DSYMUTIL=$ac_cv_prog_DSYMUTIL
9494 if test -n "$DSYMUTIL"; then
9495   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9496 $as_echo "$DSYMUTIL" >&6; }
9497 else
9498   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9499 $as_echo "no" >&6; }
9500 fi
9501
9502
9503 fi
9504 if test -z "$ac_cv_prog_DSYMUTIL"; then
9505   ac_ct_DSYMUTIL=$DSYMUTIL
9506   # Extract the first word of "dsymutil", so it can be a program name with args.
9507 set dummy dsymutil; ac_word=$2
9508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9509 $as_echo_n "checking for $ac_word... " >&6; }
9510 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9511   $as_echo_n "(cached) " >&6
9512 else
9513   if test -n "$ac_ct_DSYMUTIL"; then
9514   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9515 else
9516 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9517 for as_dir in $PATH
9518 do
9519   IFS=$as_save_IFS
9520   test -z "$as_dir" && as_dir=.
9521     for ac_exec_ext in '' $ac_executable_extensions; do
9522   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9523     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9524     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9525     break 2
9526   fi
9527 done
9528   done
9529 IFS=$as_save_IFS
9530
9531 fi
9532 fi
9533 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9534 if test -n "$ac_ct_DSYMUTIL"; then
9535   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9536 $as_echo "$ac_ct_DSYMUTIL" >&6; }
9537 else
9538   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9539 $as_echo "no" >&6; }
9540 fi
9541
9542   if test "x$ac_ct_DSYMUTIL" = x; then
9543     DSYMUTIL=":"
9544   else
9545     case $cross_compiling:$ac_tool_warned in
9546 yes:)
9547 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9548 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9549 ac_tool_warned=yes ;;
9550 esac
9551     DSYMUTIL=$ac_ct_DSYMUTIL
9552   fi
9553 else
9554   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9555 fi
9556
9557     if test -n "$ac_tool_prefix"; then
9558   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9559 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9561 $as_echo_n "checking for $ac_word... " >&6; }
9562 if ${ac_cv_prog_NMEDIT+:} false; then :
9563   $as_echo_n "(cached) " >&6
9564 else
9565   if test -n "$NMEDIT"; then
9566   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9567 else
9568 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9569 for as_dir in $PATH
9570 do
9571   IFS=$as_save_IFS
9572   test -z "$as_dir" && as_dir=.
9573     for ac_exec_ext in '' $ac_executable_extensions; do
9574   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9575     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9576     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9577     break 2
9578   fi
9579 done
9580   done
9581 IFS=$as_save_IFS
9582
9583 fi
9584 fi
9585 NMEDIT=$ac_cv_prog_NMEDIT
9586 if test -n "$NMEDIT"; then
9587   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9588 $as_echo "$NMEDIT" >&6; }
9589 else
9590   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9591 $as_echo "no" >&6; }
9592 fi
9593
9594
9595 fi
9596 if test -z "$ac_cv_prog_NMEDIT"; then
9597   ac_ct_NMEDIT=$NMEDIT
9598   # Extract the first word of "nmedit", so it can be a program name with args.
9599 set dummy nmedit; ac_word=$2
9600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9601 $as_echo_n "checking for $ac_word... " >&6; }
9602 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9603   $as_echo_n "(cached) " >&6
9604 else
9605   if test -n "$ac_ct_NMEDIT"; then
9606   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9607 else
9608 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9609 for as_dir in $PATH
9610 do
9611   IFS=$as_save_IFS
9612   test -z "$as_dir" && as_dir=.
9613     for ac_exec_ext in '' $ac_executable_extensions; do
9614   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9615     ac_cv_prog_ac_ct_NMEDIT="nmedit"
9616     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9617     break 2
9618   fi
9619 done
9620   done
9621 IFS=$as_save_IFS
9622
9623 fi
9624 fi
9625 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9626 if test -n "$ac_ct_NMEDIT"; then
9627   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9628 $as_echo "$ac_ct_NMEDIT" >&6; }
9629 else
9630   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9631 $as_echo "no" >&6; }
9632 fi
9633
9634   if test "x$ac_ct_NMEDIT" = x; then
9635     NMEDIT=":"
9636   else
9637     case $cross_compiling:$ac_tool_warned in
9638 yes:)
9639 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9640 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9641 ac_tool_warned=yes ;;
9642 esac
9643     NMEDIT=$ac_ct_NMEDIT
9644   fi
9645 else
9646   NMEDIT="$ac_cv_prog_NMEDIT"
9647 fi
9648
9649     if test -n "$ac_tool_prefix"; then
9650   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9651 set dummy ${ac_tool_prefix}lipo; ac_word=$2
9652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9653 $as_echo_n "checking for $ac_word... " >&6; }
9654 if ${ac_cv_prog_LIPO+:} false; then :
9655   $as_echo_n "(cached) " >&6
9656 else
9657   if test -n "$LIPO"; then
9658   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9659 else
9660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9661 for as_dir in $PATH
9662 do
9663   IFS=$as_save_IFS
9664   test -z "$as_dir" && as_dir=.
9665     for ac_exec_ext in '' $ac_executable_extensions; do
9666   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9667     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9668     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9669     break 2
9670   fi
9671 done
9672   done
9673 IFS=$as_save_IFS
9674
9675 fi
9676 fi
9677 LIPO=$ac_cv_prog_LIPO
9678 if test -n "$LIPO"; then
9679   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9680 $as_echo "$LIPO" >&6; }
9681 else
9682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9683 $as_echo "no" >&6; }
9684 fi
9685
9686
9687 fi
9688 if test -z "$ac_cv_prog_LIPO"; then
9689   ac_ct_LIPO=$LIPO
9690   # Extract the first word of "lipo", so it can be a program name with args.
9691 set dummy lipo; ac_word=$2
9692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9693 $as_echo_n "checking for $ac_word... " >&6; }
9694 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9695   $as_echo_n "(cached) " >&6
9696 else
9697   if test -n "$ac_ct_LIPO"; then
9698   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9699 else
9700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9701 for as_dir in $PATH
9702 do
9703   IFS=$as_save_IFS
9704   test -z "$as_dir" && as_dir=.
9705     for ac_exec_ext in '' $ac_executable_extensions; do
9706   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9707     ac_cv_prog_ac_ct_LIPO="lipo"
9708     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9709     break 2
9710   fi
9711 done
9712   done
9713 IFS=$as_save_IFS
9714
9715 fi
9716 fi
9717 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9718 if test -n "$ac_ct_LIPO"; then
9719   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9720 $as_echo "$ac_ct_LIPO" >&6; }
9721 else
9722   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9723 $as_echo "no" >&6; }
9724 fi
9725
9726   if test "x$ac_ct_LIPO" = x; then
9727     LIPO=":"
9728   else
9729     case $cross_compiling:$ac_tool_warned in
9730 yes:)
9731 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9732 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9733 ac_tool_warned=yes ;;
9734 esac
9735     LIPO=$ac_ct_LIPO
9736   fi
9737 else
9738   LIPO="$ac_cv_prog_LIPO"
9739 fi
9740
9741     if test -n "$ac_tool_prefix"; then
9742   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9743 set dummy ${ac_tool_prefix}otool; ac_word=$2
9744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9745 $as_echo_n "checking for $ac_word... " >&6; }
9746 if ${ac_cv_prog_OTOOL+:} false; then :
9747   $as_echo_n "(cached) " >&6
9748 else
9749   if test -n "$OTOOL"; then
9750   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9751 else
9752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9753 for as_dir in $PATH
9754 do
9755   IFS=$as_save_IFS
9756   test -z "$as_dir" && as_dir=.
9757     for ac_exec_ext in '' $ac_executable_extensions; do
9758   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9759     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9760     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9761     break 2
9762   fi
9763 done
9764   done
9765 IFS=$as_save_IFS
9766
9767 fi
9768 fi
9769 OTOOL=$ac_cv_prog_OTOOL
9770 if test -n "$OTOOL"; then
9771   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9772 $as_echo "$OTOOL" >&6; }
9773 else
9774   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9775 $as_echo "no" >&6; }
9776 fi
9777
9778
9779 fi
9780 if test -z "$ac_cv_prog_OTOOL"; then
9781   ac_ct_OTOOL=$OTOOL
9782   # Extract the first word of "otool", so it can be a program name with args.
9783 set dummy otool; ac_word=$2
9784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9785 $as_echo_n "checking for $ac_word... " >&6; }
9786 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
9787   $as_echo_n "(cached) " >&6
9788 else
9789   if test -n "$ac_ct_OTOOL"; then
9790   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
9791 else
9792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9793 for as_dir in $PATH
9794 do
9795   IFS=$as_save_IFS
9796   test -z "$as_dir" && as_dir=.
9797     for ac_exec_ext in '' $ac_executable_extensions; do
9798   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9799     ac_cv_prog_ac_ct_OTOOL="otool"
9800     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9801     break 2
9802   fi
9803 done
9804   done
9805 IFS=$as_save_IFS
9806
9807 fi
9808 fi
9809 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
9810 if test -n "$ac_ct_OTOOL"; then
9811   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
9812 $as_echo "$ac_ct_OTOOL" >&6; }
9813 else
9814   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9815 $as_echo "no" >&6; }
9816 fi
9817
9818   if test "x$ac_ct_OTOOL" = x; then
9819     OTOOL=":"
9820   else
9821     case $cross_compiling:$ac_tool_warned in
9822 yes:)
9823 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9824 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9825 ac_tool_warned=yes ;;
9826 esac
9827     OTOOL=$ac_ct_OTOOL
9828   fi
9829 else
9830   OTOOL="$ac_cv_prog_OTOOL"
9831 fi
9832
9833     if test -n "$ac_tool_prefix"; then
9834   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
9835 set dummy ${ac_tool_prefix}otool64; ac_word=$2
9836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9837 $as_echo_n "checking for $ac_word... " >&6; }
9838 if ${ac_cv_prog_OTOOL64+:} false; then :
9839   $as_echo_n "(cached) " >&6
9840 else
9841   if test -n "$OTOOL64"; then
9842   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
9843 else
9844 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9845 for as_dir in $PATH
9846 do
9847   IFS=$as_save_IFS
9848   test -z "$as_dir" && as_dir=.
9849     for ac_exec_ext in '' $ac_executable_extensions; do
9850   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9851     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
9852     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9853     break 2
9854   fi
9855 done
9856   done
9857 IFS=$as_save_IFS
9858
9859 fi
9860 fi
9861 OTOOL64=$ac_cv_prog_OTOOL64
9862 if test -n "$OTOOL64"; then
9863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
9864 $as_echo "$OTOOL64" >&6; }
9865 else
9866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9867 $as_echo "no" >&6; }
9868 fi
9869
9870
9871 fi
9872 if test -z "$ac_cv_prog_OTOOL64"; then
9873   ac_ct_OTOOL64=$OTOOL64
9874   # Extract the first word of "otool64", so it can be a program name with args.
9875 set dummy otool64; ac_word=$2
9876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9877 $as_echo_n "checking for $ac_word... " >&6; }
9878 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
9879   $as_echo_n "(cached) " >&6
9880 else
9881   if test -n "$ac_ct_OTOOL64"; then
9882   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
9883 else
9884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9885 for as_dir in $PATH
9886 do
9887   IFS=$as_save_IFS
9888   test -z "$as_dir" && as_dir=.
9889     for ac_exec_ext in '' $ac_executable_extensions; do
9890   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9891     ac_cv_prog_ac_ct_OTOOL64="otool64"
9892     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9893     break 2
9894   fi
9895 done
9896   done
9897 IFS=$as_save_IFS
9898
9899 fi
9900 fi
9901 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
9902 if test -n "$ac_ct_OTOOL64"; then
9903   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
9904 $as_echo "$ac_ct_OTOOL64" >&6; }
9905 else
9906   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9907 $as_echo "no" >&6; }
9908 fi
9909
9910   if test "x$ac_ct_OTOOL64" = x; then
9911     OTOOL64=":"
9912   else
9913     case $cross_compiling:$ac_tool_warned in
9914 yes:)
9915 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9916 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9917 ac_tool_warned=yes ;;
9918 esac
9919     OTOOL64=$ac_ct_OTOOL64
9920   fi
9921 else
9922   OTOOL64="$ac_cv_prog_OTOOL64"
9923 fi
9924
9925
9926
9927
9928
9929
9930
9931
9932
9933
9934
9935
9936
9937
9938
9939
9940
9941
9942
9943
9944
9945
9946
9947
9948
9949
9950
9951     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
9952 $as_echo_n "checking for -single_module linker flag... " >&6; }
9953 if ${lt_cv_apple_cc_single_mod+:} false; then :
9954   $as_echo_n "(cached) " >&6
9955 else
9956   lt_cv_apple_cc_single_mod=no
9957       if test -z "$LT_MULTI_MODULE"; then
9958         # By default we will add the -single_module flag. You can override
9959         # by either setting the environment variable LT_MULTI_MODULE
9960         # non-empty at configure time, or by adding -multi_module to the
9961         # link flags.
9962         rm -rf libconftest.dylib*
9963         echo "int foo(void){return 1;}" > conftest.c
9964         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
9965 -dynamiclib -Wl,-single_module conftest.c" >&5
9966         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
9967           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
9968         _lt_result=$?
9969         # If there is a non-empty error log, and "single_module"
9970         # appears in it, assume the flag caused a linker warning
9971         if test -s conftest.err && $GREP single_module conftest.err; then
9972           cat conftest.err >&5
9973         # Otherwise, if the output was created with a 0 exit code from
9974         # the compiler, it worked.
9975         elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
9976           lt_cv_apple_cc_single_mod=yes
9977         else
9978           cat conftest.err >&5
9979         fi
9980         rm -rf libconftest.dylib*
9981         rm -f conftest.*
9982       fi
9983 fi
9984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
9985 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
9986
9987     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
9988 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
9989 if ${lt_cv_ld_exported_symbols_list+:} false; then :
9990   $as_echo_n "(cached) " >&6
9991 else
9992   lt_cv_ld_exported_symbols_list=no
9993       save_LDFLAGS=$LDFLAGS
9994       echo "_main" > conftest.sym
9995       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
9996       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9997 /* end confdefs.h.  */
9998
9999 int
10000 main ()
10001 {
10002
10003   ;
10004   return 0;
10005 }
10006 _ACEOF
10007 if ac_fn_c_try_link "$LINENO"; then :
10008   lt_cv_ld_exported_symbols_list=yes
10009 else
10010   lt_cv_ld_exported_symbols_list=no
10011 fi
10012 rm -f core conftest.err conftest.$ac_objext \
10013     conftest$ac_exeext conftest.$ac_ext
10014         LDFLAGS=$save_LDFLAGS
10015
10016 fi
10017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10018 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10019
10020     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10021 $as_echo_n "checking for -force_load linker flag... " >&6; }
10022 if ${lt_cv_ld_force_load+:} false; then :
10023   $as_echo_n "(cached) " >&6
10024 else
10025   lt_cv_ld_force_load=no
10026       cat > conftest.c << _LT_EOF
10027 int forced_loaded() { return 2;}
10028 _LT_EOF
10029       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10030       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10031       echo "$AR cru libconftest.a conftest.o" >&5
10032       $AR cru libconftest.a conftest.o 2>&5
10033       echo "$RANLIB libconftest.a" >&5
10034       $RANLIB libconftest.a 2>&5
10035       cat > conftest.c << _LT_EOF
10036 int main() { return 0;}
10037 _LT_EOF
10038       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10039       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10040       _lt_result=$?
10041       if test -s conftest.err && $GREP force_load conftest.err; then
10042         cat conftest.err >&5
10043       elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10044         lt_cv_ld_force_load=yes
10045       else
10046         cat conftest.err >&5
10047       fi
10048         rm -f conftest.err libconftest.a conftest conftest.c
10049         rm -rf conftest.dSYM
10050
10051 fi
10052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10053 $as_echo "$lt_cv_ld_force_load" >&6; }
10054     case $host_os in
10055     rhapsody* | darwin1.[012])
10056       _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10057     darwin1.*)
10058       _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10059     darwin*) # darwin 5.x on
10060       # if running on 10.5 or later, the deployment target defaults
10061       # to the OS version, if on x86, and 10.4, the deployment
10062       # target defaults to 10.4. Don't you love it?
10063       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10064         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10065           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10066         10.[012][,.]*)
10067           _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10068         10.*)
10069           _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10070       esac
10071     ;;
10072   esac
10073     if test yes = "$lt_cv_apple_cc_single_mod"; then
10074       _lt_dar_single_mod='$single_module'
10075     fi
10076     if test yes = "$lt_cv_ld_exported_symbols_list"; then
10077       _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10078     else
10079       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10080     fi
10081     if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10082       _lt_dsymutil='~$DSYMUTIL $lib || :'
10083     else
10084       _lt_dsymutil=
10085     fi
10086     ;;
10087   esac
10088
10089 # func_munge_path_list VARIABLE PATH
10090 # -----------------------------------
10091 # VARIABLE is name of variable containing _space_ separated list of
10092 # directories to be munged by the contents of PATH, which is string
10093 # having a format:
10094 # "DIR[:DIR]:"
10095 #       string "DIR[ DIR]" will be prepended to VARIABLE
10096 # ":DIR[:DIR]"
10097 #       string "DIR[ DIR]" will be appended to VARIABLE
10098 # "DIRP[:DIRP]::[DIRA:]DIRA"
10099 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10100 #       "DIRA[ DIRA]" will be appended to VARIABLE
10101 # "DIR[:DIR]"
10102 #       VARIABLE will be replaced by "DIR[ DIR]"
10103 func_munge_path_list ()
10104 {
10105     case x$2 in
10106     x)
10107         ;;
10108     *:)
10109         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10110         ;;
10111     x:*)
10112         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10113         ;;
10114     *::*)
10115         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10116         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10117         ;;
10118     *)
10119         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10120         ;;
10121     esac
10122 }
10123
10124 for ac_header in dlfcn.h
10125 do :
10126   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10127 "
10128 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10129   cat >>confdefs.h <<_ACEOF
10130 #define HAVE_DLFCN_H 1
10131 _ACEOF
10132
10133 fi
10134
10135 done
10136
10137
10138
10139
10140
10141
10142
10143 # Set options
10144
10145
10146
10147         enable_dlopen=no
10148
10149
10150   enable_win32_dll=no
10151
10152
10153             # Check whether --enable-shared was given.
10154 if test "${enable_shared+set}" = set; then :
10155   enableval=$enable_shared; p=${PACKAGE-default}
10156     case $enableval in
10157     yes) enable_shared=yes ;;
10158     no) enable_shared=no ;;
10159     *)
10160       enable_shared=no
10161       # Look at the argument we got.  We use all the common list separators.
10162       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10163       for pkg in $enableval; do
10164         IFS=$lt_save_ifs
10165         if test "X$pkg" = "X$p"; then
10166           enable_shared=yes
10167         fi
10168       done
10169       IFS=$lt_save_ifs
10170       ;;
10171     esac
10172 else
10173   enable_shared=yes
10174 fi
10175
10176
10177
10178
10179
10180
10181
10182
10183
10184   # Check whether --enable-static was given.
10185 if test "${enable_static+set}" = set; then :
10186   enableval=$enable_static; p=${PACKAGE-default}
10187     case $enableval in
10188     yes) enable_static=yes ;;
10189     no) enable_static=no ;;
10190     *)
10191      enable_static=no
10192       # Look at the argument we got.  We use all the common list separators.
10193       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10194       for pkg in $enableval; do
10195         IFS=$lt_save_ifs
10196         if test "X$pkg" = "X$p"; then
10197           enable_static=yes
10198         fi
10199       done
10200       IFS=$lt_save_ifs
10201       ;;
10202     esac
10203 else
10204   enable_static=yes
10205 fi
10206
10207
10208
10209
10210
10211
10212
10213
10214
10215
10216 # Check whether --with-pic was given.
10217 if test "${with_pic+set}" = set; then :
10218   withval=$with_pic; lt_p=${PACKAGE-default}
10219     case $withval in
10220     yes|no) pic_mode=$withval ;;
10221     *)
10222       pic_mode=default
10223       # Look at the argument we got.  We use all the common list separators.
10224       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10225       for lt_pkg in $withval; do
10226         IFS=$lt_save_ifs
10227         if test "X$lt_pkg" = "X$lt_p"; then
10228           pic_mode=yes
10229         fi
10230       done
10231       IFS=$lt_save_ifs
10232       ;;
10233     esac
10234 else
10235   pic_mode=default
10236 fi
10237
10238
10239
10240
10241
10242
10243
10244
10245   # Check whether --enable-fast-install was given.
10246 if test "${enable_fast_install+set}" = set; then :
10247   enableval=$enable_fast_install; p=${PACKAGE-default}
10248     case $enableval in
10249     yes) enable_fast_install=yes ;;
10250     no) enable_fast_install=no ;;
10251     *)
10252       enable_fast_install=no
10253       # Look at the argument we got.  We use all the common list separators.
10254       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10255       for pkg in $enableval; do
10256         IFS=$lt_save_ifs
10257         if test "X$pkg" = "X$p"; then
10258           enable_fast_install=yes
10259         fi
10260       done
10261       IFS=$lt_save_ifs
10262       ;;
10263     esac
10264 else
10265   enable_fast_install=yes
10266 fi
10267
10268
10269
10270
10271
10272
10273
10274
10275   shared_archive_member_spec=
10276 case $host,$enable_shared in
10277 power*-*-aix[5-9]*,yes)
10278   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
10279 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
10280
10281 # Check whether --with-aix-soname was given.
10282 if test "${with_aix_soname+set}" = set; then :
10283   withval=$with_aix_soname; case $withval in
10284     aix|svr4|both)
10285       ;;
10286     *)
10287       as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
10288       ;;
10289     esac
10290     lt_cv_with_aix_soname=$with_aix_soname
10291 else
10292   if ${lt_cv_with_aix_soname+:} false; then :
10293   $as_echo_n "(cached) " >&6
10294 else
10295   lt_cv_with_aix_soname=aix
10296 fi
10297
10298     with_aix_soname=$lt_cv_with_aix_soname
10299 fi
10300
10301   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
10302 $as_echo "$with_aix_soname" >&6; }
10303   if test aix != "$with_aix_soname"; then
10304     # For the AIX way of multilib, we name the shared archive member
10305     # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
10306     # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
10307     # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
10308     # the AIX toolchain works better with OBJECT_MODE set (default 32).
10309     if test 64 = "${OBJECT_MODE-32}"; then
10310       shared_archive_member_spec=shr_64
10311     else
10312       shared_archive_member_spec=shr
10313     fi
10314   fi
10315   ;;
10316 *)
10317   with_aix_soname=aix
10318   ;;
10319 esac
10320
10321
10322
10323
10324
10325
10326
10327
10328
10329
10330 # This can be used to rebuild libtool when needed
10331 LIBTOOL_DEPS=$ltmain
10332
10333 # Always use our own libtool.
10334 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10335
10336
10337
10338
10339
10340
10341
10342
10343
10344
10345
10346
10347
10348
10349
10350
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361
10362
10363
10364
10365 test -z "$LN_S" && LN_S="ln -s"
10366
10367
10368
10369
10370
10371
10372
10373
10374
10375
10376
10377
10378
10379
10380 if test -n "${ZSH_VERSION+set}"; then
10381    setopt NO_GLOB_SUBST
10382 fi
10383
10384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10385 $as_echo_n "checking for objdir... " >&6; }
10386 if ${lt_cv_objdir+:} false; then :
10387   $as_echo_n "(cached) " >&6
10388 else
10389   rm -f .libs 2>/dev/null
10390 mkdir .libs 2>/dev/null
10391 if test -d .libs; then
10392   lt_cv_objdir=.libs
10393 else
10394   # MS-DOS does not allow filenames that begin with a dot.
10395   lt_cv_objdir=_libs
10396 fi
10397 rmdir .libs 2>/dev/null
10398 fi
10399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10400 $as_echo "$lt_cv_objdir" >&6; }
10401 objdir=$lt_cv_objdir
10402
10403
10404
10405
10406
10407 cat >>confdefs.h <<_ACEOF
10408 #define LT_OBJDIR "$lt_cv_objdir/"
10409 _ACEOF
10410
10411
10412
10413
10414 case $host_os in
10415 aix3*)
10416   # AIX sometimes has problems with the GCC collect2 program.  For some
10417   # reason, if we set the COLLECT_NAMES environment variable, the problems
10418   # vanish in a puff of smoke.
10419   if test set != "${COLLECT_NAMES+set}"; then
10420     COLLECT_NAMES=
10421     export COLLECT_NAMES
10422   fi
10423   ;;
10424 esac
10425
10426 # Global variables:
10427 ofile=libtool
10428 can_build_shared=yes
10429
10430 # All known linkers require a '.a' archive for static linking (except MSVC,
10431 # which needs '.lib').
10432 libext=a
10433
10434 with_gnu_ld=$lt_cv_prog_gnu_ld
10435
10436 old_CC=$CC
10437 old_CFLAGS=$CFLAGS
10438
10439 # Set sane defaults for various variables
10440 test -z "$CC" && CC=cc
10441 test -z "$LTCC" && LTCC=$CC
10442 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10443 test -z "$LD" && LD=ld
10444 test -z "$ac_objext" && ac_objext=o
10445
10446 func_cc_basename $compiler
10447 cc_basename=$func_cc_basename_result
10448
10449
10450 # Only perform the check for file, if the check method requires it
10451 test -z "$MAGIC_CMD" && MAGIC_CMD=file
10452 case $deplibs_check_method in
10453 file_magic*)
10454   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10455     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10456 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10457 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10458   $as_echo_n "(cached) " >&6
10459 else
10460   case $MAGIC_CMD in
10461 [\\/*] |  ?:[\\/]*)
10462   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10463   ;;
10464 *)
10465   lt_save_MAGIC_CMD=$MAGIC_CMD
10466   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10467   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10468   for ac_dir in $ac_dummy; do
10469     IFS=$lt_save_ifs
10470     test -z "$ac_dir" && ac_dir=.
10471     if test -f "$ac_dir/${ac_tool_prefix}file"; then
10472       lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
10473       if test -n "$file_magic_test_file"; then
10474         case $deplibs_check_method in
10475         "file_magic "*)
10476           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10477           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10478           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10479             $EGREP "$file_magic_regex" > /dev/null; then
10480             :
10481           else
10482             cat <<_LT_EOF 1>&2
10483
10484 *** Warning: the command libtool uses to detect shared libraries,
10485 *** $file_magic_cmd, produces output that libtool cannot recognize.
10486 *** The result is that libtool may fail to recognize shared libraries
10487 *** as such.  This will affect the creation of libtool libraries that
10488 *** depend on shared libraries, but programs linked with such libtool
10489 *** libraries will work regardless of this problem.  Nevertheless, you
10490 *** may want to report the problem to your system manager and/or to
10491 *** bug-libtool@gnu.org
10492
10493 _LT_EOF
10494           fi ;;
10495         esac
10496       fi
10497       break
10498     fi
10499   done
10500   IFS=$lt_save_ifs
10501   MAGIC_CMD=$lt_save_MAGIC_CMD
10502   ;;
10503 esac
10504 fi
10505
10506 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10507 if test -n "$MAGIC_CMD"; then
10508   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10509 $as_echo "$MAGIC_CMD" >&6; }
10510 else
10511   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10512 $as_echo "no" >&6; }
10513 fi
10514
10515
10516
10517
10518
10519 if test -z "$lt_cv_path_MAGIC_CMD"; then
10520   if test -n "$ac_tool_prefix"; then
10521     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10522 $as_echo_n "checking for file... " >&6; }
10523 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10524   $as_echo_n "(cached) " >&6
10525 else
10526   case $MAGIC_CMD in
10527 [\\/*] |  ?:[\\/]*)
10528   lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10529   ;;
10530 *)
10531   lt_save_MAGIC_CMD=$MAGIC_CMD
10532   lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10533   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10534   for ac_dir in $ac_dummy; do
10535     IFS=$lt_save_ifs
10536     test -z "$ac_dir" && ac_dir=.
10537     if test -f "$ac_dir/file"; then
10538       lt_cv_path_MAGIC_CMD=$ac_dir/"file"
10539       if test -n "$file_magic_test_file"; then
10540         case $deplibs_check_method in
10541         "file_magic "*)
10542           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10543           MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10544           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10545             $EGREP "$file_magic_regex" > /dev/null; then
10546             :
10547           else
10548             cat <<_LT_EOF 1>&2
10549
10550 *** Warning: the command libtool uses to detect shared libraries,
10551 *** $file_magic_cmd, produces output that libtool cannot recognize.
10552 *** The result is that libtool may fail to recognize shared libraries
10553 *** as such.  This will affect the creation of libtool libraries that
10554 *** depend on shared libraries, but programs linked with such libtool
10555 *** libraries will work regardless of this problem.  Nevertheless, you
10556 *** may want to report the problem to your system manager and/or to
10557 *** bug-libtool@gnu.org
10558
10559 _LT_EOF
10560           fi ;;
10561         esac
10562       fi
10563       break
10564     fi
10565   done
10566   IFS=$lt_save_ifs
10567   MAGIC_CMD=$lt_save_MAGIC_CMD
10568   ;;
10569 esac
10570 fi
10571
10572 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10573 if test -n "$MAGIC_CMD"; then
10574   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10575 $as_echo "$MAGIC_CMD" >&6; }
10576 else
10577   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10578 $as_echo "no" >&6; }
10579 fi
10580
10581
10582   else
10583     MAGIC_CMD=:
10584   fi
10585 fi
10586
10587   fi
10588   ;;
10589 esac
10590
10591 # Use C for the default configuration in the libtool script
10592
10593 lt_save_CC=$CC
10594 ac_ext=c
10595 ac_cpp='$CPP $CPPFLAGS'
10596 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10597 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10598 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10599
10600
10601 # Source file extension for C test sources.
10602 ac_ext=c
10603
10604 # Object file extension for compiled C test sources.
10605 objext=o
10606 objext=$objext
10607
10608 # Code to be used in simple compile tests
10609 lt_simple_compile_test_code="int some_variable = 0;"
10610
10611 # Code to be used in simple link tests
10612 lt_simple_link_test_code='int main(){return(0);}'
10613
10614
10615
10616
10617
10618
10619
10620 # If no C compiler was specified, use CC.
10621 LTCC=${LTCC-"$CC"}
10622
10623 # If no C compiler flags were specified, use CFLAGS.
10624 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10625
10626 # Allow CC to be a program name with arguments.
10627 compiler=$CC
10628
10629 # Save the default compiler, since it gets overwritten when the other
10630 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10631 compiler_DEFAULT=$CC
10632
10633 # save warnings/boilerplate of simple test code
10634 ac_outfile=conftest.$ac_objext
10635 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10636 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10637 _lt_compiler_boilerplate=`cat conftest.err`
10638 $RM conftest*
10639
10640 ac_outfile=conftest.$ac_objext
10641 echo "$lt_simple_link_test_code" >conftest.$ac_ext
10642 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10643 _lt_linker_boilerplate=`cat conftest.err`
10644 $RM -r conftest*
10645
10646
10647 if test -n "$compiler"; then
10648
10649 lt_prog_compiler_no_builtin_flag=
10650
10651 if test yes = "$GCC"; then
10652   case $cc_basename in
10653   nvcc*)
10654     lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10655   *)
10656     lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10657   esac
10658
10659   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10660 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10661 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10662   $as_echo_n "(cached) " >&6
10663 else
10664   lt_cv_prog_compiler_rtti_exceptions=no
10665    ac_outfile=conftest.$ac_objext
10666    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10667    lt_compiler_flag="-fno-rtti -fno-exceptions"  ## exclude from sc_useless_quotes_in_assignment
10668    # Insert the option either (1) after the last *FLAGS variable, or
10669    # (2) before a word containing "conftest.", or (3) at the end.
10670    # Note that $ac_compile itself does not contain backslashes and begins
10671    # with a dollar sign (not a hyphen), so the echo should work correctly.
10672    # The option is referenced via a variable to avoid confusing sed.
10673    lt_compile=`echo "$ac_compile" | $SED \
10674    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10675    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10676    -e 's:$: $lt_compiler_flag:'`
10677    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10678    (eval "$lt_compile" 2>conftest.err)
10679    ac_status=$?
10680    cat conftest.err >&5
10681    echo "$as_me:$LINENO: \$? = $ac_status" >&5
10682    if (exit $ac_status) && test -s "$ac_outfile"; then
10683      # The compiler can only warn and ignore the option if not recognized
10684      # So say no if there are warnings other than the usual output.
10685      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10686      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10687      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10688        lt_cv_prog_compiler_rtti_exceptions=yes
10689      fi
10690    fi
10691    $RM conftest*
10692
10693 fi
10694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10695 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10696
10697 if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
10698     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10699 else
10700     :
10701 fi
10702
10703 fi
10704
10705
10706
10707
10708
10709
10710   lt_prog_compiler_wl=
10711 lt_prog_compiler_pic=
10712 lt_prog_compiler_static=
10713
10714
10715   if test yes = "$GCC"; then
10716     lt_prog_compiler_wl='-Wl,'
10717     lt_prog_compiler_static='-static'
10718
10719     case $host_os in
10720       aix*)
10721       # All AIX code is PIC.
10722       if test ia64 = "$host_cpu"; then
10723         # AIX 5 now supports IA64 processor
10724         lt_prog_compiler_static='-Bstatic'
10725       fi
10726       lt_prog_compiler_pic='-fPIC'
10727       ;;
10728
10729     amigaos*)
10730       case $host_cpu in
10731       powerpc)
10732             # see comment about AmigaOS4 .so support
10733             lt_prog_compiler_pic='-fPIC'
10734         ;;
10735       m68k)
10736             # FIXME: we need at least 68020 code to build shared libraries, but
10737             # adding the '-m68020' flag to GCC prevents building anything better,
10738             # like '-m68040'.
10739             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10740         ;;
10741       esac
10742       ;;
10743
10744     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10745       # PIC is the default for these OSes.
10746       ;;
10747
10748     mingw* | cygwin* | pw32* | os2* | cegcc*)
10749       # This hack is so that the source file can tell whether it is being
10750       # built for inclusion in a dll (and should export symbols for example).
10751       # Although the cygwin gcc ignores -fPIC, still need this for old-style
10752       # (--disable-auto-import) libraries
10753       lt_prog_compiler_pic='-DDLL_EXPORT'
10754       case $host_os in
10755       os2*)
10756         lt_prog_compiler_static='$wl-static'
10757         ;;
10758       esac
10759       ;;
10760
10761     darwin* | rhapsody*)
10762       # PIC is the default on this platform
10763       # Common symbols not allowed in MH_DYLIB files
10764       lt_prog_compiler_pic='-fno-common'
10765       ;;
10766
10767     haiku*)
10768       # PIC is the default for Haiku.
10769       # The "-static" flag exists, but is broken.
10770       lt_prog_compiler_static=
10771       ;;
10772
10773     hpux*)
10774       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10775       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
10776       # sets the default TLS model and affects inlining.
10777       case $host_cpu in
10778       hppa*64*)
10779         # +Z the default
10780         ;;
10781       *)
10782         lt_prog_compiler_pic='-fPIC'
10783         ;;
10784       esac
10785       ;;
10786
10787     interix[3-9]*)
10788       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
10789       # Instead, we relocate shared libraries at runtime.
10790       ;;
10791
10792     msdosdjgpp*)
10793       # Just because we use GCC doesn't mean we suddenly get shared libraries
10794       # on systems that don't support them.
10795       lt_prog_compiler_can_build_shared=no
10796       enable_shared=no
10797       ;;
10798
10799     *nto* | *qnx*)
10800       # QNX uses GNU C++, but need to define -shared option too, otherwise
10801       # it will coredump.
10802       lt_prog_compiler_pic='-fPIC -shared'
10803       ;;
10804
10805     sysv4*MP*)
10806       if test -d /usr/nec; then
10807         lt_prog_compiler_pic=-Kconform_pic
10808       fi
10809       ;;
10810
10811     *)
10812       lt_prog_compiler_pic='-fPIC'
10813       ;;
10814     esac
10815
10816     case $cc_basename in
10817     nvcc*) # Cuda Compiler Driver 2.2
10818       lt_prog_compiler_wl='-Xlinker '
10819       if test -n "$lt_prog_compiler_pic"; then
10820         lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
10821       fi
10822       ;;
10823     esac
10824   else
10825     # PORTME Check for flag to pass linker flags through the system compiler.
10826     case $host_os in
10827     aix*)
10828       lt_prog_compiler_wl='-Wl,'
10829       if test ia64 = "$host_cpu"; then
10830         # AIX 5 now supports IA64 processor
10831         lt_prog_compiler_static='-Bstatic'
10832       else
10833         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
10834       fi
10835       ;;
10836
10837     darwin* | rhapsody*)
10838       # PIC is the default on this platform
10839       # Common symbols not allowed in MH_DYLIB files
10840       lt_prog_compiler_pic='-fno-common'
10841       case $cc_basename in
10842       nagfor*)
10843         # NAG Fortran compiler
10844         lt_prog_compiler_wl='-Wl,-Wl,,'
10845         lt_prog_compiler_pic='-PIC'
10846         lt_prog_compiler_static='-Bstatic'
10847         ;;
10848       esac
10849       ;;
10850
10851     mingw* | cygwin* | pw32* | os2* | cegcc*)
10852       # This hack is so that the source file can tell whether it is being
10853       # built for inclusion in a dll (and should export symbols for example).
10854       lt_prog_compiler_pic='-DDLL_EXPORT'
10855       case $host_os in
10856       os2*)
10857         lt_prog_compiler_static='$wl-static'
10858         ;;
10859       esac
10860       ;;
10861
10862     hpux9* | hpux10* | hpux11*)
10863       lt_prog_compiler_wl='-Wl,'
10864       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
10865       # not for PA HP-UX.
10866       case $host_cpu in
10867       hppa*64*|ia64*)
10868         # +Z the default
10869         ;;
10870       *)
10871         lt_prog_compiler_pic='+Z'
10872         ;;
10873       esac
10874       # Is there a better lt_prog_compiler_static that works with the bundled CC?
10875       lt_prog_compiler_static='$wl-a ${wl}archive'
10876       ;;
10877
10878     irix5* | irix6* | nonstopux*)
10879       lt_prog_compiler_wl='-Wl,'
10880       # PIC (with -KPIC) is the default.
10881       lt_prog_compiler_static='-non_shared'
10882       ;;
10883
10884     linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
10885       case $cc_basename in
10886       # old Intel for x86_64, which still supported -KPIC.
10887       ecc*)
10888         lt_prog_compiler_wl='-Wl,'
10889         lt_prog_compiler_pic='-KPIC'
10890         lt_prog_compiler_static='-static'
10891         ;;
10892       # icc used to be incompatible with GCC.
10893       # ICC 10 doesn't accept -KPIC any more.
10894       icc* | ifort*)
10895         lt_prog_compiler_wl='-Wl,'
10896         lt_prog_compiler_pic='-fPIC'
10897         lt_prog_compiler_static='-static'
10898         ;;
10899       # Lahey Fortran 8.1.
10900       lf95*)
10901         lt_prog_compiler_wl='-Wl,'
10902         lt_prog_compiler_pic='--shared'
10903         lt_prog_compiler_static='--static'
10904         ;;
10905       nagfor*)
10906         # NAG Fortran compiler
10907         lt_prog_compiler_wl='-Wl,-Wl,,'
10908         lt_prog_compiler_pic='-PIC'
10909         lt_prog_compiler_static='-Bstatic'
10910         ;;
10911       tcc*)
10912         # Fabrice Bellard et al's Tiny C Compiler
10913         lt_prog_compiler_wl='-Wl,'
10914         lt_prog_compiler_pic='-fPIC'
10915         lt_prog_compiler_static='-static'
10916         ;;
10917       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
10918         # Portland Group compilers (*not* the Pentium gcc compiler,
10919         # which looks to be a dead project)
10920         lt_prog_compiler_wl='-Wl,'
10921         lt_prog_compiler_pic='-fpic'
10922         lt_prog_compiler_static='-Bstatic'
10923         ;;
10924       ccc*)
10925         lt_prog_compiler_wl='-Wl,'
10926         # All Alpha code is PIC.
10927         lt_prog_compiler_static='-non_shared'
10928         ;;
10929       xl* | bgxl* | bgf* | mpixl*)
10930         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
10931         lt_prog_compiler_wl='-Wl,'
10932         lt_prog_compiler_pic='-qpic'
10933         lt_prog_compiler_static='-qstaticlink'
10934         ;;
10935       *)
10936         case `$CC -V 2>&1 | sed 5q` in
10937         *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
10938           # Sun Fortran 8.3 passes all unrecognized flags to the linker
10939           lt_prog_compiler_pic='-KPIC'
10940           lt_prog_compiler_static='-Bstatic'
10941           lt_prog_compiler_wl=''
10942           ;;
10943         *Sun\ F* | *Sun*Fortran*)
10944           lt_prog_compiler_pic='-KPIC'
10945           lt_prog_compiler_static='-Bstatic'
10946           lt_prog_compiler_wl='-Qoption ld '
10947           ;;
10948         *Sun\ C*)
10949           # Sun C 5.9
10950           lt_prog_compiler_pic='-KPIC'
10951           lt_prog_compiler_static='-Bstatic'
10952           lt_prog_compiler_wl='-Wl,'
10953           ;;
10954         *Intel*\ [CF]*Compiler*)
10955           lt_prog_compiler_wl='-Wl,'
10956           lt_prog_compiler_pic='-fPIC'
10957           lt_prog_compiler_static='-static'
10958           ;;
10959         *Portland\ Group*)
10960           lt_prog_compiler_wl='-Wl,'
10961           lt_prog_compiler_pic='-fpic'
10962           lt_prog_compiler_static='-Bstatic'
10963           ;;
10964         esac
10965         ;;
10966       esac
10967       ;;
10968
10969     newsos6)
10970       lt_prog_compiler_pic='-KPIC'
10971       lt_prog_compiler_static='-Bstatic'
10972       ;;
10973
10974     *nto* | *qnx*)
10975       # QNX uses GNU C++, but need to define -shared option too, otherwise
10976       # it will coredump.
10977       lt_prog_compiler_pic='-fPIC -shared'
10978       ;;
10979
10980     osf3* | osf4* | osf5*)
10981       lt_prog_compiler_wl='-Wl,'
10982       # All OSF/1 code is PIC.
10983       lt_prog_compiler_static='-non_shared'
10984       ;;
10985
10986     rdos*)
10987       lt_prog_compiler_static='-non_shared'
10988       ;;
10989
10990     solaris*)
10991       lt_prog_compiler_pic='-KPIC'
10992       lt_prog_compiler_static='-Bstatic'
10993       case $cc_basename in
10994       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
10995         lt_prog_compiler_wl='-Qoption ld ';;
10996       *)
10997         lt_prog_compiler_wl='-Wl,';;
10998       esac
10999       ;;
11000
11001     sunos4*)
11002       lt_prog_compiler_wl='-Qoption ld '
11003       lt_prog_compiler_pic='-PIC'
11004       lt_prog_compiler_static='-Bstatic'
11005       ;;
11006
11007     sysv4 | sysv4.2uw2* | sysv4.3*)
11008       lt_prog_compiler_wl='-Wl,'
11009       lt_prog_compiler_pic='-KPIC'
11010       lt_prog_compiler_static='-Bstatic'
11011       ;;
11012
11013     sysv4*MP*)
11014       if test -d /usr/nec; then
11015         lt_prog_compiler_pic='-Kconform_pic'
11016         lt_prog_compiler_static='-Bstatic'
11017       fi
11018       ;;
11019
11020     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11021       lt_prog_compiler_wl='-Wl,'
11022       lt_prog_compiler_pic='-KPIC'
11023       lt_prog_compiler_static='-Bstatic'
11024       ;;
11025
11026     unicos*)
11027       lt_prog_compiler_wl='-Wl,'
11028       lt_prog_compiler_can_build_shared=no
11029       ;;
11030
11031     uts4*)
11032       lt_prog_compiler_pic='-pic'
11033       lt_prog_compiler_static='-Bstatic'
11034       ;;
11035
11036     *)
11037       lt_prog_compiler_can_build_shared=no
11038       ;;
11039     esac
11040   fi
11041
11042 case $host_os in
11043   # For platforms that do not support PIC, -DPIC is meaningless:
11044   *djgpp*)
11045     lt_prog_compiler_pic=
11046     ;;
11047   *)
11048     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11049     ;;
11050 esac
11051
11052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11053 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11054 if ${lt_cv_prog_compiler_pic+:} false; then :
11055   $as_echo_n "(cached) " >&6
11056 else
11057   lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11058 fi
11059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11060 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
11061 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11062
11063 #
11064 # Check to make sure the PIC flag actually works.
11065 #
11066 if test -n "$lt_prog_compiler_pic"; then
11067   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
11068 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
11069 if ${lt_cv_prog_compiler_pic_works+:} false; then :
11070   $as_echo_n "(cached) " >&6
11071 else
11072   lt_cv_prog_compiler_pic_works=no
11073    ac_outfile=conftest.$ac_objext
11074    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11075    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"  ## exclude from sc_useless_quotes_in_assignment
11076    # Insert the option either (1) after the last *FLAGS variable, or
11077    # (2) before a word containing "conftest.", or (3) at the end.
11078    # Note that $ac_compile itself does not contain backslashes and begins
11079    # with a dollar sign (not a hyphen), so the echo should work correctly.
11080    # The option is referenced via a variable to avoid confusing sed.
11081    lt_compile=`echo "$ac_compile" | $SED \
11082    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11083    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11084    -e 's:$: $lt_compiler_flag:'`
11085    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11086    (eval "$lt_compile" 2>conftest.err)
11087    ac_status=$?
11088    cat conftest.err >&5
11089    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11090    if (exit $ac_status) && test -s "$ac_outfile"; then
11091      # The compiler can only warn and ignore the option if not recognized
11092      # So say no if there are warnings other than the usual output.
11093      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11094      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11095      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11096        lt_cv_prog_compiler_pic_works=yes
11097      fi
11098    fi
11099    $RM conftest*
11100
11101 fi
11102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
11103 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
11104
11105 if test yes = "$lt_cv_prog_compiler_pic_works"; then
11106     case $lt_prog_compiler_pic in
11107      "" | " "*) ;;
11108      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
11109      esac
11110 else
11111     lt_prog_compiler_pic=
11112      lt_prog_compiler_can_build_shared=no
11113 fi
11114
11115 fi
11116
11117
11118
11119
11120
11121
11122
11123
11124
11125
11126
11127 #
11128 # Check to make sure the static flag actually works.
11129 #
11130 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
11131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
11132 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
11133 if ${lt_cv_prog_compiler_static_works+:} false; then :
11134   $as_echo_n "(cached) " >&6
11135 else
11136   lt_cv_prog_compiler_static_works=no
11137    save_LDFLAGS=$LDFLAGS
11138    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
11139    echo "$lt_simple_link_test_code" > conftest.$ac_ext
11140    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11141      # The linker can only warn and ignore the option if not recognized
11142      # So say no if there are warnings
11143      if test -s conftest.err; then
11144        # Append any errors to the config.log.
11145        cat conftest.err 1>&5
11146        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11147        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11148        if diff conftest.exp conftest.er2 >/dev/null; then
11149          lt_cv_prog_compiler_static_works=yes
11150        fi
11151      else
11152        lt_cv_prog_compiler_static_works=yes
11153      fi
11154    fi
11155    $RM -r conftest*
11156    LDFLAGS=$save_LDFLAGS
11157
11158 fi
11159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
11160 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
11161
11162 if test yes = "$lt_cv_prog_compiler_static_works"; then
11163     :
11164 else
11165     lt_prog_compiler_static=
11166 fi
11167
11168
11169
11170
11171
11172
11173
11174   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11175 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11176 if ${lt_cv_prog_compiler_c_o+:} false; then :
11177   $as_echo_n "(cached) " >&6
11178 else
11179   lt_cv_prog_compiler_c_o=no
11180    $RM -r conftest 2>/dev/null
11181    mkdir conftest
11182    cd conftest
11183    mkdir out
11184    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11185
11186    lt_compiler_flag="-o out/conftest2.$ac_objext"
11187    # Insert the option either (1) after the last *FLAGS variable, or
11188    # (2) before a word containing "conftest.", or (3) at the end.
11189    # Note that $ac_compile itself does not contain backslashes and begins
11190    # with a dollar sign (not a hyphen), so the echo should work correctly.
11191    lt_compile=`echo "$ac_compile" | $SED \
11192    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11193    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11194    -e 's:$: $lt_compiler_flag:'`
11195    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11196    (eval "$lt_compile" 2>out/conftest.err)
11197    ac_status=$?
11198    cat out/conftest.err >&5
11199    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11200    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11201    then
11202      # The compiler can only warn and ignore the option if not recognized
11203      # So say no if there are warnings
11204      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11205      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11206      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11207        lt_cv_prog_compiler_c_o=yes
11208      fi
11209    fi
11210    chmod u+w . 2>&5
11211    $RM conftest*
11212    # SGI C++ compiler will create directory out/ii_files/ for
11213    # template instantiation
11214    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11215    $RM out/* && rmdir out
11216    cd ..
11217    $RM -r conftest
11218    $RM conftest*
11219
11220 fi
11221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11222 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11223
11224
11225
11226
11227
11228
11229   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11230 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11231 if ${lt_cv_prog_compiler_c_o+:} false; then :
11232   $as_echo_n "(cached) " >&6
11233 else
11234   lt_cv_prog_compiler_c_o=no
11235    $RM -r conftest 2>/dev/null
11236    mkdir conftest
11237    cd conftest
11238    mkdir out
11239    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11240
11241    lt_compiler_flag="-o out/conftest2.$ac_objext"
11242    # Insert the option either (1) after the last *FLAGS variable, or
11243    # (2) before a word containing "conftest.", or (3) at the end.
11244    # Note that $ac_compile itself does not contain backslashes and begins
11245    # with a dollar sign (not a hyphen), so the echo should work correctly.
11246    lt_compile=`echo "$ac_compile" | $SED \
11247    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11248    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11249    -e 's:$: $lt_compiler_flag:'`
11250    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11251    (eval "$lt_compile" 2>out/conftest.err)
11252    ac_status=$?
11253    cat out/conftest.err >&5
11254    echo "$as_me:$LINENO: \$? = $ac_status" >&5
11255    if (exit $ac_status) && test -s out/conftest2.$ac_objext
11256    then
11257      # The compiler can only warn and ignore the option if not recognized
11258      # So say no if there are warnings
11259      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11260      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11261      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11262        lt_cv_prog_compiler_c_o=yes
11263      fi
11264    fi
11265    chmod u+w . 2>&5
11266    $RM conftest*
11267    # SGI C++ compiler will create directory out/ii_files/ for
11268    # template instantiation
11269    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11270    $RM out/* && rmdir out
11271    cd ..
11272    $RM -r conftest
11273    $RM conftest*
11274
11275 fi
11276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11277 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11278
11279
11280
11281
11282 hard_links=nottested
11283 if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
11284   # do not overwrite the value of need_locks provided by the user
11285   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11286 $as_echo_n "checking if we can lock with hard links... " >&6; }
11287   hard_links=yes
11288   $RM conftest*
11289   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11290   touch conftest.a
11291   ln conftest.a conftest.b 2>&5 || hard_links=no
11292   ln conftest.a conftest.b 2>/dev/null && hard_links=no
11293   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11294 $as_echo "$hard_links" >&6; }
11295   if test no = "$hard_links"; then
11296     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
11297 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
11298     need_locks=warn
11299   fi
11300 else
11301   need_locks=no
11302 fi
11303
11304
11305
11306
11307
11308
11309   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11310 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11311
11312   runpath_var=
11313   allow_undefined_flag=
11314   always_export_symbols=no
11315   archive_cmds=
11316   archive_expsym_cmds=
11317   compiler_needs_object=no
11318   enable_shared_with_static_runtimes=no
11319   export_dynamic_flag_spec=
11320   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11321   hardcode_automatic=no
11322   hardcode_direct=no
11323   hardcode_direct_absolute=no
11324   hardcode_libdir_flag_spec=
11325   hardcode_libdir_separator=
11326   hardcode_minus_L=no
11327   hardcode_shlibpath_var=unsupported
11328   inherit_rpath=no
11329   link_all_deplibs=unknown
11330   module_cmds=
11331   module_expsym_cmds=
11332   old_archive_from_new_cmds=
11333   old_archive_from_expsyms_cmds=
11334   thread_safe_flag_spec=
11335   whole_archive_flag_spec=
11336   # include_expsyms should be a list of space-separated symbols to be *always*
11337   # included in the symbol list
11338   include_expsyms=
11339   # exclude_expsyms can be an extended regexp of symbols to exclude
11340   # it will be wrapped by ' (' and ')$', so one must not match beginning or
11341   # end of line.  Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
11342   # as well as any symbol that contains 'd'.
11343   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11344   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11345   # platforms (ab)use it in PIC code, but their linkers get confused if
11346   # the symbol is explicitly referenced.  Since portable code cannot
11347   # rely on this symbol name, it's probably fine to never include it in
11348   # preloaded symbol tables.
11349   # Exclude shared library initialization/finalization symbols.
11350   extract_expsyms_cmds=
11351
11352   case $host_os in
11353   cygwin* | mingw* | pw32* | cegcc*)
11354     # FIXME: the MSVC++ port hasn't been tested in a loooong time
11355     # When not using gcc, we currently assume that we are using
11356     # Microsoft Visual C++.
11357     if test yes != "$GCC"; then
11358       with_gnu_ld=no
11359     fi
11360     ;;
11361   interix*)
11362     # we just hope/assume this is gcc and not c89 (= MSVC++)
11363     with_gnu_ld=yes
11364     ;;
11365   openbsd* | bitrig*)
11366     with_gnu_ld=no
11367     ;;
11368   esac
11369
11370   ld_shlibs=yes
11371
11372   # On some targets, GNU ld is compatible enough with the native linker
11373   # that we're better off using the native interface for both.
11374   lt_use_gnu_ld_interface=no
11375   if test yes = "$with_gnu_ld"; then
11376     case $host_os in
11377       aix*)
11378         # The AIX port of GNU ld has always aspired to compatibility
11379         # with the native linker.  However, as the warning in the GNU ld
11380         # block says, versions before 2.19.5* couldn't really create working
11381         # shared libraries, regardless of the interface used.
11382         case `$LD -v 2>&1` in
11383           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11384           *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11385           *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11386           *)
11387             lt_use_gnu_ld_interface=yes
11388             ;;
11389         esac
11390         ;;
11391       *)
11392         lt_use_gnu_ld_interface=yes
11393         ;;
11394     esac
11395   fi
11396
11397   if test yes = "$lt_use_gnu_ld_interface"; then
11398     # If archive_cmds runs LD, not CC, wlarc should be empty
11399     wlarc='$wl'
11400
11401     # Set some defaults for GNU ld with shared library support. These
11402     # are reset later if shared libraries are not supported. Putting them
11403     # here allows them to be overridden if necessary.
11404     runpath_var=LD_RUN_PATH
11405     hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11406     export_dynamic_flag_spec='$wl--export-dynamic'
11407     # ancient GNU ld didn't support --whole-archive et. al.
11408     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11409       whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
11410     else
11411       whole_archive_flag_spec=
11412     fi
11413     supports_anon_versioning=no
11414     case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
11415       *GNU\ gold*) supports_anon_versioning=yes ;;
11416       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11417       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11418       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11419       *\ 2.11.*) ;; # other 2.11 versions
11420       *) supports_anon_versioning=yes ;;
11421     esac
11422
11423     # See if GNU ld supports shared libraries.
11424     case $host_os in
11425     aix[3-9]*)
11426       # On AIX/PPC, the GNU linker is very broken
11427       if test ia64 != "$host_cpu"; then
11428         ld_shlibs=no
11429         cat <<_LT_EOF 1>&2
11430
11431 *** Warning: the GNU linker, at least up to release 2.19, is reported
11432 *** to be unable to reliably create shared libraries on AIX.
11433 *** Therefore, libtool is disabling shared libraries support.  If you
11434 *** really care for shared libraries, you may want to install binutils
11435 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11436 *** You will then need to restart the configuration process.
11437
11438 _LT_EOF
11439       fi
11440       ;;
11441
11442     amigaos*)
11443       case $host_cpu in
11444       powerpc)
11445             # see comment about AmigaOS4 .so support
11446             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11447             archive_expsym_cmds=''
11448         ;;
11449       m68k)
11450             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)'
11451             hardcode_libdir_flag_spec='-L$libdir'
11452             hardcode_minus_L=yes
11453         ;;
11454       esac
11455       ;;
11456
11457     beos*)
11458       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11459         allow_undefined_flag=unsupported
11460         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
11461         # support --undefined.  This deserves some investigation.  FIXME
11462         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11463       else
11464         ld_shlibs=no
11465       fi
11466       ;;
11467
11468     cygwin* | mingw* | pw32* | cegcc*)
11469       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11470       # as there is no search path for DLLs.
11471       hardcode_libdir_flag_spec='-L$libdir'
11472       export_dynamic_flag_spec='$wl--export-all-symbols'
11473       allow_undefined_flag=unsupported
11474       always_export_symbols=no
11475       enable_shared_with_static_runtimes=yes
11476       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'
11477       exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11478
11479       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11480         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11481         # If the export-symbols file already is a .def file, use it as
11482         # is; otherwise, prepend EXPORTS...
11483         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
11484           cp $export_symbols $output_objdir/$soname.def;
11485         else
11486           echo EXPORTS > $output_objdir/$soname.def;
11487           cat $export_symbols >> $output_objdir/$soname.def;
11488         fi~
11489         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11490       else
11491         ld_shlibs=no
11492       fi
11493       ;;
11494
11495     haiku*)
11496       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11497       link_all_deplibs=yes
11498       ;;
11499
11500     os2*)
11501       hardcode_libdir_flag_spec='-L$libdir'
11502       hardcode_minus_L=yes
11503       allow_undefined_flag=unsupported
11504       shrext_cmds=.dll
11505       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11506         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11507         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11508         $ECHO EXPORTS >> $output_objdir/$libname.def~
11509         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
11510         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11511         emximp -o $lib $output_objdir/$libname.def'
11512       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11513         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11514         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11515         $ECHO EXPORTS >> $output_objdir/$libname.def~
11516         prefix_cmds="$SED"~
11517         if test EXPORTS = "`$SED 1q $export_symbols`"; then
11518           prefix_cmds="$prefix_cmds -e 1d";
11519         fi~
11520         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
11521         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
11522         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11523         emximp -o $lib $output_objdir/$libname.def'
11524       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
11525       enable_shared_with_static_runtimes=yes
11526       ;;
11527
11528     interix[3-9]*)
11529       hardcode_direct=no
11530       hardcode_shlibpath_var=no
11531       hardcode_libdir_flag_spec='$wl-rpath,$libdir'
11532       export_dynamic_flag_spec='$wl-E'
11533       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11534       # Instead, shared libraries are loaded at an image base (0x10000000 by
11535       # default) and relocated if they conflict, which is a slow very memory
11536       # consuming and fragmenting process.  To avoid this, we pick a random,
11537       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11538       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
11539       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11540       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'
11541       ;;
11542
11543     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11544       tmp_diet=no
11545       if test linux-dietlibc = "$host_os"; then
11546         case $cc_basename in
11547           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
11548         esac
11549       fi
11550       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11551          && test no = "$tmp_diet"
11552       then
11553         tmp_addflag=' $pic_flag'
11554         tmp_sharedflag='-shared'
11555         case $cc_basename,$host_cpu in
11556         pgcc*)                          # Portland Group C compiler
11557           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'
11558           tmp_addflag=' $pic_flag'
11559           ;;
11560         pgf77* | pgf90* | pgf95* | pgfortran*)
11561                                         # Portland Group f77 and f90 compilers
11562           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'
11563           tmp_addflag=' $pic_flag -Mnomain' ;;
11564         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
11565           tmp_addflag=' -i_dynamic' ;;
11566         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
11567           tmp_addflag=' -i_dynamic -nofor_main' ;;
11568         ifc* | ifort*)                  # Intel Fortran compiler
11569           tmp_addflag=' -nofor_main' ;;
11570         lf95*)                          # Lahey Fortran 8.1
11571           whole_archive_flag_spec=
11572           tmp_sharedflag='--shared' ;;
11573         nagfor*)                        # NAGFOR 5.3
11574           tmp_sharedflag='-Wl,-shared' ;;
11575         xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11576           tmp_sharedflag='-qmkshrobj'
11577           tmp_addflag= ;;
11578         nvcc*)  # Cuda Compiler Driver 2.2
11579           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'
11580           compiler_needs_object=yes
11581           ;;
11582         esac
11583         case `$CC -V 2>&1 | sed 5q` in
11584         *Sun\ C*)                       # Sun C 5.9
11585           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'
11586           compiler_needs_object=yes
11587           tmp_sharedflag='-G' ;;
11588         *Sun\ F*)                       # Sun Fortran 8.3
11589           tmp_sharedflag='-G' ;;
11590         esac
11591         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11592
11593         if test yes = "$supports_anon_versioning"; then
11594           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11595             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11596             echo "local: *; };" >> $output_objdir/$libname.ver~
11597             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
11598         fi
11599
11600         case $cc_basename in
11601         tcc*)
11602           export_dynamic_flag_spec='-rdynamic'
11603           ;;
11604         xlf* | bgf* | bgxlf* | mpixlf*)
11605           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11606           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11607           hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11608           archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11609           if test yes = "$supports_anon_versioning"; then
11610             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11611               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11612               echo "local: *; };" >> $output_objdir/$libname.ver~
11613               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11614           fi
11615           ;;
11616         esac
11617       else
11618         ld_shlibs=no
11619       fi
11620       ;;
11621
11622     netbsd*)
11623       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11624         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11625         wlarc=
11626       else
11627         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11628         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11629       fi
11630       ;;
11631
11632     solaris*)
11633       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11634         ld_shlibs=no
11635         cat <<_LT_EOF 1>&2
11636
11637 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
11638 *** create shared libraries on Solaris systems.  Therefore, libtool
11639 *** is disabling shared libraries support.  We urge you to upgrade GNU
11640 *** binutils to release 2.9.1 or newer.  Another option is to modify
11641 *** your PATH or compiler configuration so that the native linker is
11642 *** used, and then restart.
11643
11644 _LT_EOF
11645       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11646         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11647         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11648       else
11649         ld_shlibs=no
11650       fi
11651       ;;
11652
11653     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11654       case `$LD -v 2>&1` in
11655         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11656         ld_shlibs=no
11657         cat <<_LT_EOF 1>&2
11658
11659 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
11660 *** reliably create shared libraries on SCO systems.  Therefore, libtool
11661 *** is disabling shared libraries support.  We urge you to upgrade GNU
11662 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
11663 *** your PATH or compiler configuration so that the native linker is
11664 *** used, and then restart.
11665
11666 _LT_EOF
11667         ;;
11668         *)
11669           # For security reasons, it is highly recommended that you always
11670           # use absolute paths for naming shared libraries, and exclude the
11671           # DT_RUNPATH tag from executables and libraries.  But doing so
11672           # requires that you compile everything twice, which is a pain.
11673           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11674             hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11675             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11676             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11677           else
11678             ld_shlibs=no
11679           fi
11680         ;;
11681       esac
11682       ;;
11683
11684     sunos4*)
11685       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11686       wlarc=
11687       hardcode_direct=yes
11688       hardcode_shlibpath_var=no
11689       ;;
11690
11691     *)
11692       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11693         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11694         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11695       else
11696         ld_shlibs=no
11697       fi
11698       ;;
11699     esac
11700
11701     if test no = "$ld_shlibs"; then
11702       runpath_var=
11703       hardcode_libdir_flag_spec=
11704       export_dynamic_flag_spec=
11705       whole_archive_flag_spec=
11706     fi
11707   else
11708     # PORTME fill in a description of your system's linker (not GNU ld)
11709     case $host_os in
11710     aix3*)
11711       allow_undefined_flag=unsupported
11712       always_export_symbols=yes
11713       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'
11714       # Note: this linker hardcodes the directories in LIBPATH if there
11715       # are no directories specified by -L.
11716       hardcode_minus_L=yes
11717       if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
11718         # Neither direct hardcoding nor static linking is supported with a
11719         # broken collect2.
11720         hardcode_direct=unsupported
11721       fi
11722       ;;
11723
11724     aix[4-9]*)
11725       if test ia64 = "$host_cpu"; then
11726         # On IA64, the linker does run time linking by default, so we don't
11727         # have to do anything special.
11728         aix_use_runtimelinking=no
11729         exp_sym_flag='-Bexport'
11730         no_entry_flag=
11731       else
11732         # If we're using GNU nm, then we don't want the "-C" option.
11733         # -C means demangle to GNU nm, but means don't demangle to AIX nm.
11734         # Without the "-l" option, or with the "-B" option, AIX nm treats
11735         # weak defined symbols like other global defined symbols, whereas
11736         # GNU nm marks them as "W".
11737         # While the 'weak' keyword is ignored in the Export File, we need
11738         # it in the Import File for the 'aix-soname' feature, so we have
11739         # to replace the "-B" option with "-P" for AIX nm.
11740         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11741           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'
11742         else
11743           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'
11744         fi
11745         aix_use_runtimelinking=no
11746
11747         # Test if we are trying to use run time linking or normal
11748         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
11749         # have runtime linking enabled, and use it for executables.
11750         # For shared libraries, we enable/disable runtime linking
11751         # depending on the kind of the shared library created -
11752         # when "with_aix_soname,aix_use_runtimelinking" is:
11753         # "aix,no"   lib.a(lib.so.V) shared, rtl:no,  for executables
11754         # "aix,yes"  lib.so          shared, rtl:yes, for executables
11755         #            lib.a           static archive
11756         # "both,no"  lib.so.V(shr.o) shared, rtl:yes
11757         #            lib.a(lib.so.V) shared, rtl:no,  for executables
11758         # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
11759         #            lib.a(lib.so.V) shared, rtl:no
11760         # "svr4,*"   lib.so.V(shr.o) shared, rtl:yes, for executables
11761         #            lib.a           static archive
11762         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11763           for ld_flag in $LDFLAGS; do
11764           if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
11765             aix_use_runtimelinking=yes
11766             break
11767           fi
11768           done
11769           if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
11770             # With aix-soname=svr4, we create the lib.so.V shared archives only,
11771             # so we don't have lib.a shared libs to link our executables.
11772             # We have to force runtime linking in this case.
11773             aix_use_runtimelinking=yes
11774             LDFLAGS="$LDFLAGS -Wl,-brtl"
11775           fi
11776           ;;
11777         esac
11778
11779         exp_sym_flag='-bexport'
11780         no_entry_flag='-bnoentry'
11781       fi
11782
11783       # When large executables or shared objects are built, AIX ld can
11784       # have problems creating the table of contents.  If linking a library
11785       # or program results in "error TOC overflow" add -mminimal-toc to
11786       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
11787       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
11788
11789       archive_cmds=''
11790       hardcode_direct=yes
11791       hardcode_direct_absolute=yes
11792       hardcode_libdir_separator=':'
11793       link_all_deplibs=yes
11794       file_list_spec='$wl-f,'
11795       case $with_aix_soname,$aix_use_runtimelinking in
11796       aix,*) ;; # traditional, no import file
11797       svr4,* | *,yes) # use import file
11798         # The Import File defines what to hardcode.
11799         hardcode_direct=no
11800         hardcode_direct_absolute=no
11801         ;;
11802       esac
11803
11804       if test yes = "$GCC"; then
11805         case $host_os in aix4.[012]|aix4.[012].*)
11806         # We only want to do this on AIX 4.2 and lower, the check
11807         # below for broken collect2 doesn't work under 4.3+
11808           collect2name=`$CC -print-prog-name=collect2`
11809           if test -f "$collect2name" &&
11810            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
11811           then
11812           # We have reworked collect2
11813           :
11814           else
11815           # We have old collect2
11816           hardcode_direct=unsupported
11817           # It fails to find uninstalled libraries when the uninstalled
11818           # path is not listed in the libpath.  Setting hardcode_minus_L
11819           # to unsupported forces relinking
11820           hardcode_minus_L=yes
11821           hardcode_libdir_flag_spec='-L$libdir'
11822           hardcode_libdir_separator=
11823           fi
11824           ;;
11825         esac
11826         shared_flag='-shared'
11827         if test yes = "$aix_use_runtimelinking"; then
11828           shared_flag="$shared_flag "'$wl-G'
11829         fi
11830         # Need to ensure runtime linking is disabled for the traditional
11831         # shared library, or the linker may eventually find shared libraries
11832         # /with/ Import File - we do not want to mix them.
11833         shared_flag_aix='-shared'
11834         shared_flag_svr4='-shared $wl-G'
11835       else
11836         # not using gcc
11837         if test ia64 = "$host_cpu"; then
11838         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
11839         # chokes on -Wl,-G. The following line is correct:
11840           shared_flag='-G'
11841         else
11842           if test yes = "$aix_use_runtimelinking"; then
11843             shared_flag='$wl-G'
11844           else
11845             shared_flag='$wl-bM:SRE'
11846           fi
11847           shared_flag_aix='$wl-bM:SRE'
11848           shared_flag_svr4='$wl-G'
11849         fi
11850       fi
11851
11852       export_dynamic_flag_spec='$wl-bexpall'
11853       # It seems that -bexpall does not export symbols beginning with
11854       # underscore (_), so it is better to generate a list of symbols to export.
11855       always_export_symbols=yes
11856       if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
11857         # Warning - without using the other runtime loading flags (-brtl),
11858         # -berok will link without error, but may produce a broken library.
11859         allow_undefined_flag='-berok'
11860         # Determine the default libpath from the value encoded in an
11861         # empty executable.
11862         if test set = "${lt_cv_aix_libpath+set}"; then
11863   aix_libpath=$lt_cv_aix_libpath
11864 else
11865   if ${lt_cv_aix_libpath_+:} false; then :
11866   $as_echo_n "(cached) " >&6
11867 else
11868   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11869 /* end confdefs.h.  */
11870
11871 int
11872 main ()
11873 {
11874
11875   ;
11876   return 0;
11877 }
11878 _ACEOF
11879 if ac_fn_c_try_link "$LINENO"; then :
11880
11881   lt_aix_libpath_sed='
11882       /Import File Strings/,/^$/ {
11883           /^0/ {
11884               s/^0  *\([^ ]*\) *$/\1/
11885               p
11886           }
11887       }'
11888   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11889   # Check for a 64-bit object if we didn't find anything.
11890   if test -z "$lt_cv_aix_libpath_"; then
11891     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11892   fi
11893 fi
11894 rm -f core conftest.err conftest.$ac_objext \
11895     conftest$ac_exeext conftest.$ac_ext
11896   if test -z "$lt_cv_aix_libpath_"; then
11897     lt_cv_aix_libpath_=/usr/lib:/lib
11898   fi
11899
11900 fi
11901
11902   aix_libpath=$lt_cv_aix_libpath_
11903 fi
11904
11905         hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
11906         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
11907       else
11908         if test ia64 = "$host_cpu"; then
11909           hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
11910           allow_undefined_flag="-z nodefs"
11911           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"
11912         else
11913          # Determine the default libpath from the value encoded in an
11914          # empty executable.
11915          if test set = "${lt_cv_aix_libpath+set}"; then
11916   aix_libpath=$lt_cv_aix_libpath
11917 else
11918   if ${lt_cv_aix_libpath_+:} false; then :
11919   $as_echo_n "(cached) " >&6
11920 else
11921   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11922 /* end confdefs.h.  */
11923
11924 int
11925 main ()
11926 {
11927
11928   ;
11929   return 0;
11930 }
11931 _ACEOF
11932 if ac_fn_c_try_link "$LINENO"; then :
11933
11934   lt_aix_libpath_sed='
11935       /Import File Strings/,/^$/ {
11936           /^0/ {
11937               s/^0  *\([^ ]*\) *$/\1/
11938               p
11939           }
11940       }'
11941   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11942   # Check for a 64-bit object if we didn't find anything.
11943   if test -z "$lt_cv_aix_libpath_"; then
11944     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11945   fi
11946 fi
11947 rm -f core conftest.err conftest.$ac_objext \
11948     conftest$ac_exeext conftest.$ac_ext
11949   if test -z "$lt_cv_aix_libpath_"; then
11950     lt_cv_aix_libpath_=/usr/lib:/lib
11951   fi
11952
11953 fi
11954
11955   aix_libpath=$lt_cv_aix_libpath_
11956 fi
11957
11958          hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
11959           # Warning - without using the other run time loading flags,
11960           # -berok will link without error, but may produce a broken library.
11961           no_undefined_flag=' $wl-bernotok'
11962           allow_undefined_flag=' $wl-berok'
11963           if test yes = "$with_gnu_ld"; then
11964             # We only use this code for GNU lds that support --whole-archive.
11965             whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
11966           else
11967             # Exported symbols can be pulled into shared objects from archives
11968             whole_archive_flag_spec='$convenience'
11969           fi
11970           archive_cmds_need_lc=yes
11971           archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
11972           # -brtl affects multiple linker settings, -berok does not and is overridden later
11973           compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
11974           if test svr4 != "$with_aix_soname"; then
11975             # This is similar to how AIX traditionally builds its shared libraries.
11976             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'
11977           fi
11978           if test aix != "$with_aix_soname"; then
11979             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'
11980           else
11981             # used by -dlpreopen to get the symbols
11982             archive_expsym_cmds="$archive_expsym_cmds"'~$MV  $output_objdir/$realname.d/$soname $output_objdir'
11983           fi
11984           archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
11985         fi
11986       fi
11987       ;;
11988
11989     amigaos*)
11990       case $host_cpu in
11991       powerpc)
11992             # see comment about AmigaOS4 .so support
11993             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11994             archive_expsym_cmds=''
11995         ;;
11996       m68k)
11997             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)'
11998             hardcode_libdir_flag_spec='-L$libdir'
11999             hardcode_minus_L=yes
12000         ;;
12001       esac
12002       ;;
12003
12004     bsdi[45]*)
12005       export_dynamic_flag_spec=-rdynamic
12006       ;;
12007
12008     cygwin* | mingw* | pw32* | cegcc*)
12009       # When not using gcc, we currently assume that we are using
12010       # Microsoft Visual C++.
12011       # hardcode_libdir_flag_spec is actually meaningless, as there is
12012       # no search path for DLLs.
12013       case $cc_basename in
12014       cl*)
12015         # Native MSVC
12016         hardcode_libdir_flag_spec=' '
12017         allow_undefined_flag=unsupported
12018         always_export_symbols=yes
12019         file_list_spec='@'
12020         # Tell ltmain to make .lib files, not .a files.
12021         libext=lib
12022         # Tell ltmain to make .dll files, not .so files.
12023         shrext_cmds=.dll
12024         # FIXME: Setting linknames here is a bad hack.
12025         archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12026         archive_expsym_cmds='if   test DEF = "`$SED -n     -e '\''s/^[   ]*//'\''     -e '\''/^\(;.*\)*$/d'\''     -e '\''s/^\(EXPORTS\|LIBRARY\)\([     ].*\)*$/DEF/p'\''     -e q     $export_symbols`" ; then
12027             cp "$export_symbols" "$output_objdir/$soname.def";
12028             echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12029           else
12030             $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12031           fi~
12032           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12033           linknames='
12034         # The linker will not automatically build a static lib if we build a DLL.
12035         # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12036         enable_shared_with_static_runtimes=yes
12037         exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12038         export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12039         # Don't use ranlib
12040         old_postinstall_cmds='chmod 644 $oldlib'
12041         postlink_cmds='lt_outputfile="@OUTPUT@"~
12042           lt_tool_outputfile="@TOOL_OUTPUT@"~
12043           case $lt_outputfile in
12044             *.exe|*.EXE) ;;
12045             *)
12046               lt_outputfile=$lt_outputfile.exe
12047               lt_tool_outputfile=$lt_tool_outputfile.exe
12048               ;;
12049           esac~
12050           if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
12051             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12052             $RM "$lt_outputfile.manifest";
12053           fi'
12054         ;;
12055       *)
12056         # Assume MSVC wrapper
12057         hardcode_libdir_flag_spec=' '
12058         allow_undefined_flag=unsupported
12059         # Tell ltmain to make .lib files, not .a files.
12060         libext=lib
12061         # Tell ltmain to make .dll files, not .so files.
12062         shrext_cmds=.dll
12063         # FIXME: Setting linknames here is a bad hack.
12064         archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12065         # The linker will automatically build a .lib file if we build a DLL.
12066         old_archive_from_new_cmds='true'
12067         # FIXME: Should let the user specify the lib program.
12068         old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12069         enable_shared_with_static_runtimes=yes
12070         ;;
12071       esac
12072       ;;
12073
12074     darwin* | rhapsody*)
12075
12076
12077   archive_cmds_need_lc=no
12078   hardcode_direct=no
12079   hardcode_automatic=yes
12080   hardcode_shlibpath_var=unsupported
12081   if test yes = "$lt_cv_ld_force_load"; then
12082     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\"`'
12083
12084   else
12085     whole_archive_flag_spec=''
12086   fi
12087   link_all_deplibs=yes
12088   allow_undefined_flag=$_lt_dar_allow_undefined
12089   case $cc_basename in
12090      ifort*|nagfor*) _lt_dar_can_shared=yes ;;
12091      *) _lt_dar_can_shared=$GCC ;;
12092   esac
12093   if test yes = "$_lt_dar_can_shared"; then
12094     output_verbose_link_cmd=func_echo_all
12095     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
12096     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
12097     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"
12098     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"
12099
12100   else
12101   ld_shlibs=no
12102   fi
12103
12104       ;;
12105
12106     dgux*)
12107       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12108       hardcode_libdir_flag_spec='-L$libdir'
12109       hardcode_shlibpath_var=no
12110       ;;
12111
12112     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
12113     # support.  Future versions do this automatically, but an explicit c++rt0.o
12114     # does not break anything, and helps significantly (at the cost of a little
12115     # extra space).
12116     freebsd2.2*)
12117       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
12118       hardcode_libdir_flag_spec='-R$libdir'
12119       hardcode_direct=yes
12120       hardcode_shlibpath_var=no
12121       ;;
12122
12123     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
12124     freebsd2.*)
12125       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12126       hardcode_direct=yes
12127       hardcode_minus_L=yes
12128       hardcode_shlibpath_var=no
12129       ;;
12130
12131     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12132     freebsd* | dragonfly*)
12133       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12134       hardcode_libdir_flag_spec='-R$libdir'
12135       hardcode_direct=yes
12136       hardcode_shlibpath_var=no
12137       ;;
12138
12139     hpux9*)
12140       if test yes = "$GCC"; then
12141         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'
12142       else
12143         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'
12144       fi
12145       hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12146       hardcode_libdir_separator=:
12147       hardcode_direct=yes
12148
12149       # hardcode_minus_L: Not really in the search PATH,
12150       # but as the default location of the library.
12151       hardcode_minus_L=yes
12152       export_dynamic_flag_spec='$wl-E'
12153       ;;
12154
12155     hpux10*)
12156       if test yes,no = "$GCC,$with_gnu_ld"; then
12157         archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12158       else
12159         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12160       fi
12161       if test no = "$with_gnu_ld"; then
12162         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12163         hardcode_libdir_separator=:
12164         hardcode_direct=yes
12165         hardcode_direct_absolute=yes
12166         export_dynamic_flag_spec='$wl-E'
12167         # hardcode_minus_L: Not really in the search PATH,
12168         # but as the default location of the library.
12169         hardcode_minus_L=yes
12170       fi
12171       ;;
12172
12173     hpux11*)
12174       if test yes,no = "$GCC,$with_gnu_ld"; then
12175         case $host_cpu in
12176         hppa*64*)
12177           archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12178           ;;
12179         ia64*)
12180           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12181           ;;
12182         *)
12183           archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12184           ;;
12185         esac
12186       else
12187         case $host_cpu in
12188         hppa*64*)
12189           archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12190           ;;
12191         ia64*)
12192           archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12193           ;;
12194         *)
12195
12196           # Older versions of the 11.00 compiler do not understand -b yet
12197           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
12198           { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
12199 $as_echo_n "checking if $CC understands -b... " >&6; }
12200 if ${lt_cv_prog_compiler__b+:} false; then :
12201   $as_echo_n "(cached) " >&6
12202 else
12203   lt_cv_prog_compiler__b=no
12204    save_LDFLAGS=$LDFLAGS
12205    LDFLAGS="$LDFLAGS -b"
12206    echo "$lt_simple_link_test_code" > conftest.$ac_ext
12207    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12208      # The linker can only warn and ignore the option if not recognized
12209      # So say no if there are warnings
12210      if test -s conftest.err; then
12211        # Append any errors to the config.log.
12212        cat conftest.err 1>&5
12213        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12214        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12215        if diff conftest.exp conftest.er2 >/dev/null; then
12216          lt_cv_prog_compiler__b=yes
12217        fi
12218      else
12219        lt_cv_prog_compiler__b=yes
12220      fi
12221    fi
12222    $RM -r conftest*
12223    LDFLAGS=$save_LDFLAGS
12224
12225 fi
12226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
12227 $as_echo "$lt_cv_prog_compiler__b" >&6; }
12228
12229 if test yes = "$lt_cv_prog_compiler__b"; then
12230     archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12231 else
12232     archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12233 fi
12234
12235           ;;
12236         esac
12237       fi
12238       if test no = "$with_gnu_ld"; then
12239         hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12240         hardcode_libdir_separator=:
12241
12242         case $host_cpu in
12243         hppa*64*|ia64*)
12244           hardcode_direct=no
12245           hardcode_shlibpath_var=no
12246           ;;
12247         *)
12248           hardcode_direct=yes
12249           hardcode_direct_absolute=yes
12250           export_dynamic_flag_spec='$wl-E'
12251
12252           # hardcode_minus_L: Not really in the search PATH,
12253           # but as the default location of the library.
12254           hardcode_minus_L=yes
12255           ;;
12256         esac
12257       fi
12258       ;;
12259
12260     irix5* | irix6* | nonstopux*)
12261       if test yes = "$GCC"; then
12262         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'
12263         # Try to use the -exported_symbol ld option, if it does not
12264         # work, assume that -exports_file does not work either and
12265         # implicitly export all symbols.
12266         # This should be the same for all languages, so no per-tag cache variable.
12267         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12268 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12269 if ${lt_cv_irix_exported_symbol+:} false; then :
12270   $as_echo_n "(cached) " >&6
12271 else
12272   save_LDFLAGS=$LDFLAGS
12273            LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
12274            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12275 /* end confdefs.h.  */
12276 int foo (void) { return 0; }
12277 _ACEOF
12278 if ac_fn_c_try_link "$LINENO"; then :
12279   lt_cv_irix_exported_symbol=yes
12280 else
12281   lt_cv_irix_exported_symbol=no
12282 fi
12283 rm -f core conftest.err conftest.$ac_objext \
12284     conftest$ac_exeext conftest.$ac_ext
12285            LDFLAGS=$save_LDFLAGS
12286 fi
12287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12288 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
12289         if test yes = "$lt_cv_irix_exported_symbol"; then
12290           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'
12291         fi
12292       else
12293         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'
12294         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'
12295       fi
12296       archive_cmds_need_lc='no'
12297       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12298       hardcode_libdir_separator=:
12299       inherit_rpath=yes
12300       link_all_deplibs=yes
12301       ;;
12302
12303     linux*)
12304       case $cc_basename in
12305       tcc*)
12306         # Fabrice Bellard et al's Tiny C Compiler
12307         ld_shlibs=yes
12308         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12309         ;;
12310       esac
12311       ;;
12312
12313     netbsd*)
12314       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12315         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
12316       else
12317         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
12318       fi
12319       hardcode_libdir_flag_spec='-R$libdir'
12320       hardcode_direct=yes
12321       hardcode_shlibpath_var=no
12322       ;;
12323
12324     newsos6)
12325       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12326       hardcode_direct=yes
12327       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12328       hardcode_libdir_separator=:
12329       hardcode_shlibpath_var=no
12330       ;;
12331
12332     *nto* | *qnx*)
12333       ;;
12334
12335     openbsd* | bitrig*)
12336       if test -f /usr/libexec/ld.so; then
12337         hardcode_direct=yes
12338         hardcode_shlibpath_var=no
12339         hardcode_direct_absolute=yes
12340         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
12341           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12342           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
12343           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12344           export_dynamic_flag_spec='$wl-E'
12345         else
12346           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12347           hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12348         fi
12349       else
12350         ld_shlibs=no
12351       fi
12352       ;;
12353
12354     os2*)
12355       hardcode_libdir_flag_spec='-L$libdir'
12356       hardcode_minus_L=yes
12357       allow_undefined_flag=unsupported
12358       shrext_cmds=.dll
12359       archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12360         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12361         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12362         $ECHO EXPORTS >> $output_objdir/$libname.def~
12363         emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12364         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12365         emximp -o $lib $output_objdir/$libname.def'
12366       archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12367         $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12368         $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12369         $ECHO EXPORTS >> $output_objdir/$libname.def~
12370         prefix_cmds="$SED"~
12371         if test EXPORTS = "`$SED 1q $export_symbols`"; then
12372           prefix_cmds="$prefix_cmds -e 1d";
12373         fi~
12374         prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12375         cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12376         $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12377         emximp -o $lib $output_objdir/$libname.def'
12378       old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12379       enable_shared_with_static_runtimes=yes
12380       ;;
12381
12382     osf3*)
12383       if test yes = "$GCC"; then
12384         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12385         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'
12386       else
12387         allow_undefined_flag=' -expect_unresolved \*'
12388         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'
12389       fi
12390       archive_cmds_need_lc='no'
12391       hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12392       hardcode_libdir_separator=:
12393       ;;
12394
12395     osf4* | osf5*)      # as osf3* with the addition of -msym flag
12396       if test yes = "$GCC"; then
12397         allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12398         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'
12399         hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12400       else
12401         allow_undefined_flag=' -expect_unresolved \*'
12402         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'
12403         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~
12404           $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'
12405
12406         # Both c and cxx compiler support -rpath directly
12407         hardcode_libdir_flag_spec='-rpath $libdir'
12408       fi
12409       archive_cmds_need_lc='no'
12410       hardcode_libdir_separator=:
12411       ;;
12412
12413     solaris*)
12414       no_undefined_flag=' -z defs'
12415       if test yes = "$GCC"; then
12416         wlarc='$wl'
12417         archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12418         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12419           $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'
12420       else
12421         case `$CC -V 2>&1` in
12422         *"Compilers 5.0"*)
12423           wlarc=''
12424           archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
12425           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12426             $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12427           ;;
12428         *)
12429           wlarc='$wl'
12430           archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12431           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12432             $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12433           ;;
12434         esac
12435       fi
12436       hardcode_libdir_flag_spec='-R$libdir'
12437       hardcode_shlibpath_var=no
12438       case $host_os in
12439       solaris2.[0-5] | solaris2.[0-5].*) ;;
12440       *)
12441         # The compiler driver will combine and reorder linker options,
12442         # but understands '-z linker_flag'.  GCC discards it without '$wl',
12443         # but is careful enough not to reorder.
12444         # Supported since Solaris 2.6 (maybe 2.5.1?)
12445         if test yes = "$GCC"; then
12446           whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
12447         else
12448           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12449         fi
12450         ;;
12451       esac
12452       link_all_deplibs=yes
12453       ;;
12454
12455     sunos4*)
12456       if test sequent = "$host_vendor"; then
12457         # Use $CC to link under sequent, because it throws in some extra .o
12458         # files that make .init and .fini sections work.
12459         archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12460       else
12461         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12462       fi
12463       hardcode_libdir_flag_spec='-L$libdir'
12464       hardcode_direct=yes
12465       hardcode_minus_L=yes
12466       hardcode_shlibpath_var=no
12467       ;;
12468
12469     sysv4)
12470       case $host_vendor in
12471         sni)
12472           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12473           hardcode_direct=yes # is this really true???
12474         ;;
12475         siemens)
12476           ## LD is ld it makes a PLAMLIB
12477           ## CC just makes a GrossModule.
12478           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12479           reload_cmds='$CC -r -o $output$reload_objs'
12480           hardcode_direct=no
12481         ;;
12482         motorola)
12483           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12484           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12485         ;;
12486       esac
12487       runpath_var='LD_RUN_PATH'
12488       hardcode_shlibpath_var=no
12489       ;;
12490
12491     sysv4.3*)
12492       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12493       hardcode_shlibpath_var=no
12494       export_dynamic_flag_spec='-Bexport'
12495       ;;
12496
12497     sysv4*MP*)
12498       if test -d /usr/nec; then
12499         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12500         hardcode_shlibpath_var=no
12501         runpath_var=LD_RUN_PATH
12502         hardcode_runpath_var=yes
12503         ld_shlibs=yes
12504       fi
12505       ;;
12506
12507     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12508       no_undefined_flag='$wl-z,text'
12509       archive_cmds_need_lc=no
12510       hardcode_shlibpath_var=no
12511       runpath_var='LD_RUN_PATH'
12512
12513       if test yes = "$GCC"; then
12514         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12515         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12516       else
12517         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12518         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12519       fi
12520       ;;
12521
12522     sysv5* | sco3.2v5* | sco5v6*)
12523       # Note: We CANNOT use -z defs as we might desire, because we do not
12524       # link with -lc, and that would cause any symbols used from libc to
12525       # always be unresolved, which means just about no library would
12526       # ever link correctly.  If we're not using GNU ld we use -z text
12527       # though, which does catch some bad symbols but isn't as heavy-handed
12528       # as -z defs.
12529       no_undefined_flag='$wl-z,text'
12530       allow_undefined_flag='$wl-z,nodefs'
12531       archive_cmds_need_lc=no
12532       hardcode_shlibpath_var=no
12533       hardcode_libdir_flag_spec='$wl-R,$libdir'
12534       hardcode_libdir_separator=':'
12535       link_all_deplibs=yes
12536       export_dynamic_flag_spec='$wl-Bexport'
12537       runpath_var='LD_RUN_PATH'
12538
12539       if test yes = "$GCC"; then
12540         archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12541         archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12542       else
12543         archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12544         archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12545       fi
12546       ;;
12547
12548     uts4*)
12549       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12550       hardcode_libdir_flag_spec='-L$libdir'
12551       hardcode_shlibpath_var=no
12552       ;;
12553
12554     *)
12555       ld_shlibs=no
12556       ;;
12557     esac
12558
12559     if test sni = "$host_vendor"; then
12560       case $host in
12561       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12562         export_dynamic_flag_spec='$wl-Blargedynsym'
12563         ;;
12564       esac
12565     fi
12566   fi
12567
12568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12569 $as_echo "$ld_shlibs" >&6; }
12570 test no = "$ld_shlibs" && can_build_shared=no
12571
12572 with_gnu_ld=$with_gnu_ld
12573
12574
12575
12576
12577
12578
12579
12580
12581
12582
12583
12584
12585
12586
12587
12588 #
12589 # Do we need to explicitly link libc?
12590 #
12591 case "x$archive_cmds_need_lc" in
12592 x|xyes)
12593   # Assume -lc should be added
12594   archive_cmds_need_lc=yes
12595
12596   if test yes,yes = "$GCC,$enable_shared"; then
12597     case $archive_cmds in
12598     *'~'*)
12599       # FIXME: we may have to deal with multi-command sequences.
12600       ;;
12601     '$CC '*)
12602       # Test whether the compiler implicitly links with -lc since on some
12603       # systems, -lgcc has to come before -lc. If gcc already passes -lc
12604       # to ld, don't add -lc before -lgcc.
12605       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12606 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12607 if ${lt_cv_archive_cmds_need_lc+:} false; then :
12608   $as_echo_n "(cached) " >&6
12609 else
12610   $RM conftest*
12611         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12612
12613         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12614   (eval $ac_compile) 2>&5
12615   ac_status=$?
12616   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12617   test $ac_status = 0; } 2>conftest.err; then
12618           soname=conftest
12619           lib=conftest
12620           libobjs=conftest.$ac_objext
12621           deplibs=
12622           wl=$lt_prog_compiler_wl
12623           pic_flag=$lt_prog_compiler_pic
12624           compiler_flags=-v
12625           linker_flags=-v
12626           verstring=
12627           output_objdir=.
12628           libname=conftest
12629           lt_save_allow_undefined_flag=$allow_undefined_flag
12630           allow_undefined_flag=
12631           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12632   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12633   ac_status=$?
12634   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12635   test $ac_status = 0; }
12636           then
12637             lt_cv_archive_cmds_need_lc=no
12638           else
12639             lt_cv_archive_cmds_need_lc=yes
12640           fi
12641           allow_undefined_flag=$lt_save_allow_undefined_flag
12642         else
12643           cat conftest.err 1>&5
12644         fi
12645         $RM conftest*
12646
12647 fi
12648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12649 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12650       archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12651       ;;
12652     esac
12653   fi
12654   ;;
12655 esac
12656
12657
12658
12659
12660
12661
12662
12663
12664
12665
12666
12667
12668
12669
12670
12671
12672
12673
12674
12675
12676
12677
12678
12679
12680
12681
12682
12683
12684
12685
12686
12687
12688
12689
12690
12691
12692
12693
12694
12695
12696
12697
12698
12699
12700
12701
12702
12703
12704
12705
12706
12707
12708
12709
12710
12711
12712
12713
12714
12715
12716
12717
12718
12719
12720
12721
12722
12723
12724
12725
12726
12727
12728
12729
12730
12731
12732
12733
12734
12735
12736
12737
12738
12739
12740
12741
12742
12743
12744
12745
12746
12747
12748
12749
12750
12751
12752
12753
12754
12755
12756
12757
12758
12759
12760
12761
12762
12763
12764
12765
12766
12767
12768
12769
12770
12771
12772
12773
12774
12775
12776
12777
12778
12779
12780
12781
12782
12783
12784
12785
12786
12787
12788
12789
12790
12791
12792
12793
12794
12795
12796
12797
12798
12799
12800
12801
12802
12803
12804
12805
12806
12807
12808   { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
12809 $as_echo_n "checking dynamic linker characteristics... " >&6; }
12810
12811 if test yes = "$GCC"; then
12812   case $host_os in
12813     darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
12814     *) lt_awk_arg='/^libraries:/' ;;
12815   esac
12816   case $host_os in
12817     mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
12818     *) lt_sed_strip_eq='s|=/|/|g' ;;
12819   esac
12820   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
12821   case $lt_search_path_spec in
12822   *\;*)
12823     # if the path contains ";" then we assume it to be the separator
12824     # otherwise default to the standard path separator (i.e. ":") - it is
12825     # assumed that no part of a normal pathname contains ";" but that should
12826     # okay in the real world where ";" in dirpaths is itself problematic.
12827     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
12828     ;;
12829   *)
12830     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
12831     ;;
12832   esac
12833   # Ok, now we have the path, separated by spaces, we can step through it
12834   # and add multilib dir if necessary...
12835   lt_tmp_lt_search_path_spec=
12836   lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
12837   # ...but if some path component already ends with the multilib dir we assume
12838   # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
12839   case "$lt_multi_os_dir; $lt_search_path_spec " in
12840   "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
12841     lt_multi_os_dir=
12842     ;;
12843   esac
12844   for lt_sys_path in $lt_search_path_spec; do
12845     if test -d "$lt_sys_path$lt_multi_os_dir"; then
12846       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
12847     elif test -n "$lt_multi_os_dir"; then
12848       test -d "$lt_sys_path" && \
12849         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
12850     fi
12851   done
12852   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
12853 BEGIN {RS = " "; FS = "/|\n";} {
12854   lt_foo = "";
12855   lt_count = 0;
12856   for (lt_i = NF; lt_i > 0; lt_i--) {
12857     if ($lt_i != "" && $lt_i != ".") {
12858       if ($lt_i == "..") {
12859         lt_count++;
12860       } else {
12861         if (lt_count == 0) {
12862           lt_foo = "/" $lt_i lt_foo;
12863         } else {
12864           lt_count--;
12865         }
12866       }
12867     }
12868   }
12869   if (lt_foo != "") { lt_freq[lt_foo]++; }
12870   if (lt_freq[lt_foo] == 1) { print lt_foo; }
12871 }'`
12872   # AWK program above erroneously prepends '/' to C:/dos/paths
12873   # for these hosts.
12874   case $host_os in
12875     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
12876       $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
12877   esac
12878   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
12879 else
12880   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
12881 fi
12882 library_names_spec=
12883 libname_spec='lib$name'
12884 soname_spec=
12885 shrext_cmds=.so
12886 postinstall_cmds=
12887 postuninstall_cmds=
12888 finish_cmds=
12889 finish_eval=
12890 shlibpath_var=
12891 shlibpath_overrides_runpath=unknown
12892 version_type=none
12893 dynamic_linker="$host_os ld.so"
12894 sys_lib_dlsearch_path_spec="/lib /usr/lib"
12895 need_lib_prefix=unknown
12896 hardcode_into_libs=no
12897
12898 # when you set need_version to no, make sure it does not cause -set_version
12899 # flags to be left without arguments
12900 need_version=unknown
12901
12902
12903
12904 case $host_os in
12905 aix3*)
12906   version_type=linux # correct to gnu/linux during the next big refactor
12907   library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
12908   shlibpath_var=LIBPATH
12909
12910   # AIX 3 has no versioning support, so we append a major version to the name.
12911   soname_spec='$libname$release$shared_ext$major'
12912   ;;
12913
12914 aix[4-9]*)
12915   version_type=linux # correct to gnu/linux during the next big refactor
12916   need_lib_prefix=no
12917   need_version=no
12918   hardcode_into_libs=yes
12919   if test ia64 = "$host_cpu"; then
12920     # AIX 5 supports IA64
12921     library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
12922     shlibpath_var=LD_LIBRARY_PATH
12923   else
12924     # With GCC up to 2.95.x, collect2 would create an import file
12925     # for dependence libraries.  The import file would start with
12926     # the line '#! .'.  This would cause the generated library to
12927     # depend on '.', always an invalid library.  This was fixed in
12928     # development snapshots of GCC prior to 3.0.
12929     case $host_os in
12930       aix4 | aix4.[01] | aix4.[01].*)
12931       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
12932            echo ' yes '
12933            echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
12934         :
12935       else
12936         can_build_shared=no
12937       fi
12938       ;;
12939     esac
12940     # Using Import Files as archive members, it is possible to support
12941     # filename-based versioning of shared library archives on AIX. While
12942     # this would work for both with and without runtime linking, it will
12943     # prevent static linking of such archives. So we do filename-based
12944     # shared library versioning with .so extension only, which is used
12945     # when both runtime linking and shared linking is enabled.
12946     # Unfortunately, runtime linking may impact performance, so we do
12947     # not want this to be the default eventually. Also, we use the
12948     # versioned .so libs for executables only if there is the -brtl
12949     # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
12950     # To allow for filename-based versioning support, we need to create
12951     # libNAME.so.V as an archive file, containing:
12952     # *) an Import File, referring to the versioned filename of the
12953     #    archive as well as the shared archive member, telling the
12954     #    bitwidth (32 or 64) of that shared object, and providing the
12955     #    list of exported symbols of that shared object, eventually
12956     #    decorated with the 'weak' keyword
12957     # *) the shared object with the F_LOADONLY flag set, to really avoid
12958     #    it being seen by the linker.
12959     # At run time we better use the real file rather than another symlink,
12960     # but for link time we create the symlink libNAME.so -> libNAME.so.V
12961
12962     case $with_aix_soname,$aix_use_runtimelinking in
12963     # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
12964     # soname into executable. Probably we can add versioning support to
12965     # collect2, so additional links can be useful in future.
12966     aix,yes) # traditional libtool
12967       dynamic_linker='AIX unversionable lib.so'
12968       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
12969       # instead of lib<name>.a to let people know that these are not
12970       # typical AIX shared libraries.
12971       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
12972       ;;
12973     aix,no) # traditional AIX only
12974       dynamic_linker='AIX lib.a(lib.so.V)'
12975       # We preserve .a as extension for shared libraries through AIX4.2
12976       # and later when we are not doing run time linking.
12977       library_names_spec='$libname$release.a $libname.a'
12978       soname_spec='$libname$release$shared_ext$major'
12979       ;;
12980     svr4,*) # full svr4 only
12981       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
12982       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
12983       # We do not specify a path in Import Files, so LIBPATH fires.
12984       shlibpath_overrides_runpath=yes
12985       ;;
12986     *,yes) # both, prefer svr4
12987       dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
12988       library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
12989       # unpreferred sharedlib libNAME.a needs extra handling
12990       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"'
12991       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"'
12992       # We do not specify a path in Import Files, so LIBPATH fires.
12993       shlibpath_overrides_runpath=yes
12994       ;;
12995     *,no) # both, prefer aix
12996       dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
12997       library_names_spec='$libname$release.a $libname.a'
12998       soname_spec='$libname$release$shared_ext$major'
12999       # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13000       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)'
13001       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"'
13002       ;;
13003     esac
13004     shlibpath_var=LIBPATH
13005   fi
13006   ;;
13007
13008 amigaos*)
13009   case $host_cpu in
13010   powerpc)
13011     # Since July 2007 AmigaOS4 officially supports .so libraries.
13012     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13013     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13014     ;;
13015   m68k)
13016     library_names_spec='$libname.ixlibrary $libname.a'
13017     # Create ${libname}_ixlibrary.a entries in /sys/libs.
13018     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'
13019     ;;
13020   esac
13021   ;;
13022
13023 beos*)
13024   library_names_spec='$libname$shared_ext'
13025   dynamic_linker="$host_os ld.so"
13026   shlibpath_var=LIBRARY_PATH
13027   ;;
13028
13029 bsdi[45]*)
13030   version_type=linux # correct to gnu/linux during the next big refactor
13031   need_version=no
13032   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13033   soname_spec='$libname$release$shared_ext$major'
13034   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13035   shlibpath_var=LD_LIBRARY_PATH
13036   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13037   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13038   # the default ld.so.conf also contains /usr/contrib/lib and
13039   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13040   # libtool to hard-code these into programs
13041   ;;
13042
13043 cygwin* | mingw* | pw32* | cegcc*)
13044   version_type=windows
13045   shrext_cmds=.dll
13046   need_version=no
13047   need_lib_prefix=no
13048
13049   case $GCC,$cc_basename in
13050   yes,*)
13051     # gcc
13052     library_names_spec='$libname.dll.a'
13053     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13054     postinstall_cmds='base_file=`basename \$file`~
13055       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13056       dldir=$destdir/`dirname \$dlpath`~
13057       test -d \$dldir || mkdir -p \$dldir~
13058       $install_prog $dir/$dlname \$dldir/$dlname~
13059       chmod a+x \$dldir/$dlname~
13060       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13061         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13062       fi'
13063     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13064       dlpath=$dir/\$dldll~
13065        $RM \$dlpath'
13066     shlibpath_overrides_runpath=yes
13067
13068     case $host_os in
13069     cygwin*)
13070       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
13071       soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13072
13073       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
13074       ;;
13075     mingw* | cegcc*)
13076       # MinGW DLLs use traditional 'lib' prefix
13077       soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13078       ;;
13079     pw32*)
13080       # pw32 DLLs use 'pw' prefix rather than 'lib'
13081       library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13082       ;;
13083     esac
13084     dynamic_linker='Win32 ld.exe'
13085     ;;
13086
13087   *,cl*)
13088     # Native MSVC
13089     libname_spec='$name'
13090     soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13091     library_names_spec='$libname.dll.lib'
13092
13093     case $build_os in
13094     mingw*)
13095       sys_lib_search_path_spec=
13096       lt_save_ifs=$IFS
13097       IFS=';'
13098       for lt_path in $LIB
13099       do
13100         IFS=$lt_save_ifs
13101         # Let DOS variable expansion print the short 8.3 style file name.
13102         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
13103         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
13104       done
13105       IFS=$lt_save_ifs
13106       # Convert to MSYS style.
13107       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
13108       ;;
13109     cygwin*)
13110       # Convert to unix form, then to dos form, then back to unix form
13111       # but this time dos style (no spaces!) so that the unix form looks
13112       # like /cygdrive/c/PROGRA~1:/cygdr...
13113       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
13114       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
13115       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13116       ;;
13117     *)
13118       sys_lib_search_path_spec=$LIB
13119       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
13120         # It is most probably a Windows format PATH.
13121         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
13122       else
13123         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13124       fi
13125       # FIXME: find the short name or the path components, as spaces are
13126       # common. (e.g. "Program Files" -> "PROGRA~1")
13127       ;;
13128     esac
13129
13130     # DLL is installed to $(libdir)/../bin by postinstall_cmds
13131     postinstall_cmds='base_file=`basename \$file`~
13132       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13133       dldir=$destdir/`dirname \$dlpath`~
13134       test -d \$dldir || mkdir -p \$dldir~
13135       $install_prog $dir/$dlname \$dldir/$dlname'
13136     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13137       dlpath=$dir/\$dldll~
13138        $RM \$dlpath'
13139     shlibpath_overrides_runpath=yes
13140     dynamic_linker='Win32 link.exe'
13141     ;;
13142
13143   *)
13144     # Assume MSVC wrapper
13145     library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
13146     dynamic_linker='Win32 ld.exe'
13147     ;;
13148   esac
13149   # FIXME: first we should search . and the directory the executable is in
13150   shlibpath_var=PATH
13151   ;;
13152
13153 darwin* | rhapsody*)
13154   dynamic_linker="$host_os dyld"
13155   version_type=darwin
13156   need_lib_prefix=no
13157   need_version=no
13158   library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
13159   soname_spec='$libname$release$major$shared_ext'
13160   shlibpath_overrides_runpath=yes
13161   shlibpath_var=DYLD_LIBRARY_PATH
13162   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
13163
13164   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
13165   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
13166   ;;
13167
13168 dgux*)
13169   version_type=linux # correct to gnu/linux during the next big refactor
13170   need_lib_prefix=no
13171   need_version=no
13172   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13173   soname_spec='$libname$release$shared_ext$major'
13174   shlibpath_var=LD_LIBRARY_PATH
13175   ;;
13176
13177 freebsd* | dragonfly*)
13178   # DragonFly does not have aout.  When/if they implement a new
13179   # versioning mechanism, adjust this.
13180   if test -x /usr/bin/objformat; then
13181     objformat=`/usr/bin/objformat`
13182   else
13183     case $host_os in
13184     freebsd[23].*) objformat=aout ;;
13185     *) objformat=elf ;;
13186     esac
13187   fi
13188   version_type=freebsd-$objformat
13189   case $version_type in
13190     freebsd-elf*)
13191       library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13192       soname_spec='$libname$release$shared_ext$major'
13193       need_version=no
13194       need_lib_prefix=no
13195       ;;
13196     freebsd-*)
13197       library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13198       need_version=yes
13199       ;;
13200   esac
13201   shlibpath_var=LD_LIBRARY_PATH
13202   case $host_os in
13203   freebsd2.*)
13204     shlibpath_overrides_runpath=yes
13205     ;;
13206   freebsd3.[01]* | freebsdelf3.[01]*)
13207     shlibpath_overrides_runpath=yes
13208     hardcode_into_libs=yes
13209     ;;
13210   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
13211   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
13212     shlibpath_overrides_runpath=no
13213     hardcode_into_libs=yes
13214     ;;
13215   *) # from 4.6 on, and DragonFly
13216     shlibpath_overrides_runpath=yes
13217     hardcode_into_libs=yes
13218     ;;
13219   esac
13220   ;;
13221
13222 haiku*)
13223   version_type=linux # correct to gnu/linux during the next big refactor
13224   need_lib_prefix=no
13225   need_version=no
13226   dynamic_linker="$host_os runtime_loader"
13227   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13228   soname_spec='$libname$release$shared_ext$major'
13229   shlibpath_var=LIBRARY_PATH
13230   shlibpath_overrides_runpath=no
13231   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
13232   hardcode_into_libs=yes
13233   ;;
13234
13235 hpux9* | hpux10* | hpux11*)
13236   # Give a soname corresponding to the major version so that dld.sl refuses to
13237   # link against other versions.
13238   version_type=sunos
13239   need_lib_prefix=no
13240   need_version=no
13241   case $host_cpu in
13242   ia64*)
13243     shrext_cmds='.so'
13244     hardcode_into_libs=yes
13245     dynamic_linker="$host_os dld.so"
13246     shlibpath_var=LD_LIBRARY_PATH
13247     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13248     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13249     soname_spec='$libname$release$shared_ext$major'
13250     if test 32 = "$HPUX_IA64_MODE"; then
13251       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
13252       sys_lib_dlsearch_path_spec=/usr/lib/hpux32
13253     else
13254       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
13255       sys_lib_dlsearch_path_spec=/usr/lib/hpux64
13256     fi
13257     ;;
13258   hppa*64*)
13259     shrext_cmds='.sl'
13260     hardcode_into_libs=yes
13261     dynamic_linker="$host_os dld.sl"
13262     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
13263     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13264     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13265     soname_spec='$libname$release$shared_ext$major'
13266     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
13267     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13268     ;;
13269   *)
13270     shrext_cmds='.sl'
13271     dynamic_linker="$host_os dld.sl"
13272     shlibpath_var=SHLIB_PATH
13273     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
13274     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13275     soname_spec='$libname$release$shared_ext$major'
13276     ;;
13277   esac
13278   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
13279   postinstall_cmds='chmod 555 $lib'
13280   # or fails outright, so override atomically:
13281   install_override_mode=555
13282   ;;
13283
13284 interix[3-9]*)
13285   version_type=linux # correct to gnu/linux during the next big refactor
13286   need_lib_prefix=no
13287   need_version=no
13288   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13289   soname_spec='$libname$release$shared_ext$major'
13290   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
13291   shlibpath_var=LD_LIBRARY_PATH
13292   shlibpath_overrides_runpath=no
13293   hardcode_into_libs=yes
13294   ;;
13295
13296 irix5* | irix6* | nonstopux*)
13297   case $host_os in
13298     nonstopux*) version_type=nonstopux ;;
13299     *)
13300         if test yes = "$lt_cv_prog_gnu_ld"; then
13301                 version_type=linux # correct to gnu/linux during the next big refactor
13302         else
13303                 version_type=irix
13304         fi ;;
13305   esac
13306   need_lib_prefix=no
13307   need_version=no
13308   soname_spec='$libname$release$shared_ext$major'
13309   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
13310   case $host_os in
13311   irix5* | nonstopux*)
13312     libsuff= shlibsuff=
13313     ;;
13314   *)
13315     case $LD in # libtool.m4 will add one of these switches to LD
13316     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
13317       libsuff= shlibsuff= libmagic=32-bit;;
13318     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
13319       libsuff=32 shlibsuff=N32 libmagic=N32;;
13320     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
13321       libsuff=64 shlibsuff=64 libmagic=64-bit;;
13322     *) libsuff= shlibsuff= libmagic=never-match;;
13323     esac
13324     ;;
13325   esac
13326   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
13327   shlibpath_overrides_runpath=no
13328   sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
13329   sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
13330   hardcode_into_libs=yes
13331   ;;
13332
13333 # No shared lib support for Linux oldld, aout, or coff.
13334 linux*oldld* | linux*aout* | linux*coff*)
13335   dynamic_linker=no
13336   ;;
13337
13338 linux*android*)
13339   version_type=none # Android doesn't support versioned libraries.
13340   need_lib_prefix=no
13341   need_version=no
13342   library_names_spec='$libname$release$shared_ext'
13343   soname_spec='$libname$release$shared_ext'
13344   finish_cmds=
13345   shlibpath_var=LD_LIBRARY_PATH
13346   shlibpath_overrides_runpath=yes
13347
13348   # This implies no fast_install, which is unacceptable.
13349   # Some rework will be needed to allow for fast_install
13350   # before this can be enabled.
13351   hardcode_into_libs=yes
13352
13353   dynamic_linker='Android linker'
13354   # Don't embed -rpath directories since the linker doesn't support them.
13355   hardcode_libdir_flag_spec='-L$libdir'
13356   ;;
13357
13358 # This must be glibc/ELF.
13359 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
13360   version_type=linux # correct to gnu/linux during the next big refactor
13361   need_lib_prefix=no
13362   need_version=no
13363   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13364   soname_spec='$libname$release$shared_ext$major'
13365   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
13366   shlibpath_var=LD_LIBRARY_PATH
13367   shlibpath_overrides_runpath=no
13368
13369   # Some binutils ld are patched to set DT_RUNPATH
13370   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
13371   $as_echo_n "(cached) " >&6
13372 else
13373   lt_cv_shlibpath_overrides_runpath=no
13374     save_LDFLAGS=$LDFLAGS
13375     save_libdir=$libdir
13376     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
13377          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
13378     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13379 /* end confdefs.h.  */
13380
13381 int
13382 main ()
13383 {
13384
13385   ;
13386   return 0;
13387 }
13388 _ACEOF
13389 if ac_fn_c_try_link "$LINENO"; then :
13390   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
13391   lt_cv_shlibpath_overrides_runpath=yes
13392 fi
13393 fi
13394 rm -f core conftest.err conftest.$ac_objext \
13395     conftest$ac_exeext conftest.$ac_ext
13396     LDFLAGS=$save_LDFLAGS
13397     libdir=$save_libdir
13398
13399 fi
13400
13401   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
13402
13403   # This implies no fast_install, which is unacceptable.
13404   # Some rework will be needed to allow for fast_install
13405   # before this can be enabled.
13406   hardcode_into_libs=yes
13407
13408   # Add ABI-specific directories to the system library path.
13409   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
13410
13411   # Ideally, we could use ldconfig to report *all* directores which are
13412   # searched for libraries, however this is still not possible.  Aside from not
13413   # being certain /sbin/ldconfig is available, command
13414   # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
13415   # even though it is searched at run-time.  Try to do the best guess by
13416   # appending ld.so.conf contents (and includes) to the search path.
13417   if test -f /etc/ld.so.conf; then
13418     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' ' '`
13419     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
13420   fi
13421
13422   # We used to test for /lib/ld.so.1 and disable shared libraries on
13423   # powerpc, because MkLinux only supported shared libraries with the
13424   # GNU dynamic linker.  Since this was broken with cross compilers,
13425   # most powerpc-linux boxes support dynamic linking these days and
13426   # people can always --disable-shared, the test was removed, and we
13427   # assume the GNU/Linux dynamic linker is in use.
13428   dynamic_linker='GNU/Linux ld.so'
13429   ;;
13430
13431 netbsd*)
13432   version_type=sunos
13433   need_lib_prefix=no
13434   need_version=no
13435   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13436     library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13437     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13438     dynamic_linker='NetBSD (a.out) ld.so'
13439   else
13440     library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13441     soname_spec='$libname$release$shared_ext$major'
13442     dynamic_linker='NetBSD ld.elf_so'
13443   fi
13444   shlibpath_var=LD_LIBRARY_PATH
13445   shlibpath_overrides_runpath=yes
13446   hardcode_into_libs=yes
13447   ;;
13448
13449 newsos6)
13450   version_type=linux # correct to gnu/linux during the next big refactor
13451   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13452   shlibpath_var=LD_LIBRARY_PATH
13453   shlibpath_overrides_runpath=yes
13454   ;;
13455
13456 *nto* | *qnx*)
13457   version_type=qnx
13458   need_lib_prefix=no
13459   need_version=no
13460   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13461   soname_spec='$libname$release$shared_ext$major'
13462   shlibpath_var=LD_LIBRARY_PATH
13463   shlibpath_overrides_runpath=no
13464   hardcode_into_libs=yes
13465   dynamic_linker='ldqnx.so'
13466   ;;
13467
13468 openbsd* | bitrig*)
13469   version_type=sunos
13470   sys_lib_dlsearch_path_spec=/usr/lib
13471   need_lib_prefix=no
13472   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13473     need_version=no
13474   else
13475     need_version=yes
13476   fi
13477   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13478   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13479   shlibpath_var=LD_LIBRARY_PATH
13480   shlibpath_overrides_runpath=yes
13481   ;;
13482
13483 os2*)
13484   libname_spec='$name'
13485   version_type=windows
13486   shrext_cmds=.dll
13487   need_version=no
13488   need_lib_prefix=no
13489   # OS/2 can only load a DLL with a base name of 8 characters or less.
13490   soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
13491     v=$($ECHO $release$versuffix | tr -d .-);
13492     n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
13493     $ECHO $n$v`$shared_ext'
13494   library_names_spec='${libname}_dll.$libext'
13495   dynamic_linker='OS/2 ld.exe'
13496   shlibpath_var=BEGINLIBPATH
13497   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13498   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13499   postinstall_cmds='base_file=`basename \$file`~
13500     dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
13501     dldir=$destdir/`dirname \$dlpath`~
13502     test -d \$dldir || mkdir -p \$dldir~
13503     $install_prog $dir/$dlname \$dldir/$dlname~
13504     chmod a+x \$dldir/$dlname~
13505     if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13506       eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13507     fi'
13508   postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
13509     dlpath=$dir/\$dldll~
13510     $RM \$dlpath'
13511   ;;
13512
13513 osf3* | osf4* | osf5*)
13514   version_type=osf
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$shared_ext'
13519   shlibpath_var=LD_LIBRARY_PATH
13520   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13521   sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13522   ;;
13523
13524 rdos*)
13525   dynamic_linker=no
13526   ;;
13527
13528 solaris*)
13529   version_type=linux # correct to gnu/linux during the next big refactor
13530   need_lib_prefix=no
13531   need_version=no
13532   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13533   soname_spec='$libname$release$shared_ext$major'
13534   shlibpath_var=LD_LIBRARY_PATH
13535   shlibpath_overrides_runpath=yes
13536   hardcode_into_libs=yes
13537   # ldd complains unless libraries are executable
13538   postinstall_cmds='chmod +x $lib'
13539   ;;
13540
13541 sunos4*)
13542   version_type=sunos
13543   library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13544   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13545   shlibpath_var=LD_LIBRARY_PATH
13546   shlibpath_overrides_runpath=yes
13547   if test yes = "$with_gnu_ld"; then
13548     need_lib_prefix=no
13549   fi
13550   need_version=yes
13551   ;;
13552
13553 sysv4 | sysv4.3*)
13554   version_type=linux # correct to gnu/linux during the next big refactor
13555   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13556   soname_spec='$libname$release$shared_ext$major'
13557   shlibpath_var=LD_LIBRARY_PATH
13558   case $host_vendor in
13559     sni)
13560       shlibpath_overrides_runpath=no
13561       need_lib_prefix=no
13562       runpath_var=LD_RUN_PATH
13563       ;;
13564     siemens)
13565       need_lib_prefix=no
13566       ;;
13567     motorola)
13568       need_lib_prefix=no
13569       need_version=no
13570       shlibpath_overrides_runpath=no
13571       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13572       ;;
13573   esac
13574   ;;
13575
13576 sysv4*MP*)
13577   if test -d /usr/nec; then
13578     version_type=linux # correct to gnu/linux during the next big refactor
13579     library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
13580     soname_spec='$libname$shared_ext.$major'
13581     shlibpath_var=LD_LIBRARY_PATH
13582   fi
13583   ;;
13584
13585 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13586   version_type=sco
13587   need_lib_prefix=no
13588   need_version=no
13589   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
13590   soname_spec='$libname$release$shared_ext$major'
13591   shlibpath_var=LD_LIBRARY_PATH
13592   shlibpath_overrides_runpath=yes
13593   hardcode_into_libs=yes
13594   if test yes = "$with_gnu_ld"; then
13595     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13596   else
13597     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13598     case $host_os in
13599       sco3.2v5*)
13600         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13601         ;;
13602     esac
13603   fi
13604   sys_lib_dlsearch_path_spec='/usr/lib'
13605   ;;
13606
13607 tpf*)
13608   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
13609   version_type=linux # correct to gnu/linux during the next big refactor
13610   need_lib_prefix=no
13611   need_version=no
13612   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13613   shlibpath_var=LD_LIBRARY_PATH
13614   shlibpath_overrides_runpath=no
13615   hardcode_into_libs=yes
13616   ;;
13617
13618 uts4*)
13619   version_type=linux # correct to gnu/linux during the next big refactor
13620   library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13621   soname_spec='$libname$release$shared_ext$major'
13622   shlibpath_var=LD_LIBRARY_PATH
13623   ;;
13624
13625 *)
13626   dynamic_linker=no
13627   ;;
13628 esac
13629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13630 $as_echo "$dynamic_linker" >&6; }
13631 test no = "$dynamic_linker" && can_build_shared=no
13632
13633 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13634 if test yes = "$GCC"; then
13635   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13636 fi
13637
13638 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
13639   sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
13640 fi
13641
13642 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
13643   sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
13644 fi
13645
13646 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
13647 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
13648
13649 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
13650 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
13651
13652 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
13653 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
13654
13655
13656
13657
13658
13659
13660
13661
13662
13663
13664
13665
13666
13667
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679
13680
13681
13682
13683
13684
13685
13686
13687
13688
13689
13690
13691
13692
13693
13694
13695
13696
13697
13698
13699
13700
13701
13702
13703
13704
13705
13706
13707
13708
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721
13722
13723
13724
13725
13726
13727
13728
13729
13730
13731
13732
13733
13734
13735
13736
13737
13738
13739
13740
13741
13742
13743
13744
13745
13746
13747
13748
13749
13750
13751   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13752 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13753 hardcode_action=
13754 if test -n "$hardcode_libdir_flag_spec" ||
13755    test -n "$runpath_var" ||
13756    test yes = "$hardcode_automatic"; then
13757
13758   # We can hardcode non-existent directories.
13759   if test no != "$hardcode_direct" &&
13760      # If the only mechanism to avoid hardcoding is shlibpath_var, we
13761      # have to relink, otherwise we might link with an installed library
13762      # when we should be linking with a yet-to-be-installed one
13763      ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
13764      test no != "$hardcode_minus_L"; then
13765     # Linking always hardcodes the temporary library directory.
13766     hardcode_action=relink
13767   else
13768     # We can link without hardcoding, and we can hardcode nonexisting dirs.
13769     hardcode_action=immediate
13770   fi
13771 else
13772   # We cannot hardcode anything, or else we can only hardcode existing
13773   # directories.
13774   hardcode_action=unsupported
13775 fi
13776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
13777 $as_echo "$hardcode_action" >&6; }
13778
13779 if test relink = "$hardcode_action" ||
13780    test yes = "$inherit_rpath"; then
13781   # Fast installation is not supported
13782   enable_fast_install=no
13783 elif test yes = "$shlibpath_overrides_runpath" ||
13784      test no = "$enable_shared"; then
13785   # Fast installation is not necessary
13786   enable_fast_install=needless
13787 fi
13788
13789
13790
13791
13792
13793
13794   if test yes != "$enable_dlopen"; then
13795   enable_dlopen=unknown
13796   enable_dlopen_self=unknown
13797   enable_dlopen_self_static=unknown
13798 else
13799   lt_cv_dlopen=no
13800   lt_cv_dlopen_libs=
13801
13802   case $host_os in
13803   beos*)
13804     lt_cv_dlopen=load_add_on
13805     lt_cv_dlopen_libs=
13806     lt_cv_dlopen_self=yes
13807     ;;
13808
13809   mingw* | pw32* | cegcc*)
13810     lt_cv_dlopen=LoadLibrary
13811     lt_cv_dlopen_libs=
13812     ;;
13813
13814   cygwin*)
13815     lt_cv_dlopen=dlopen
13816     lt_cv_dlopen_libs=
13817     ;;
13818
13819   darwin*)
13820     # if libdl is installed we need to link against it
13821     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13822 $as_echo_n "checking for dlopen in -ldl... " >&6; }
13823 if ${ac_cv_lib_dl_dlopen+:} false; then :
13824   $as_echo_n "(cached) " >&6
13825 else
13826   ac_check_lib_save_LIBS=$LIBS
13827 LIBS="-ldl  $LIBS"
13828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13829 /* end confdefs.h.  */
13830
13831 /* Override any GCC internal prototype to avoid an error.
13832    Use char because int might match the return type of a GCC
13833    builtin and then its argument prototype would still apply.  */
13834 #ifdef __cplusplus
13835 extern "C"
13836 #endif
13837 char dlopen ();
13838 int
13839 main ()
13840 {
13841 return dlopen ();
13842   ;
13843   return 0;
13844 }
13845 _ACEOF
13846 if ac_fn_c_try_link "$LINENO"; then :
13847   ac_cv_lib_dl_dlopen=yes
13848 else
13849   ac_cv_lib_dl_dlopen=no
13850 fi
13851 rm -f core conftest.err conftest.$ac_objext \
13852     conftest$ac_exeext conftest.$ac_ext
13853 LIBS=$ac_check_lib_save_LIBS
13854 fi
13855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
13856 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
13857 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
13858   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
13859 else
13860
13861     lt_cv_dlopen=dyld
13862     lt_cv_dlopen_libs=
13863     lt_cv_dlopen_self=yes
13864
13865 fi
13866
13867     ;;
13868
13869   tpf*)
13870     # Don't try to run any link tests for TPF.  We know it's impossible
13871     # because TPF is a cross-compiler, and we know how we open DSOs.
13872     lt_cv_dlopen=dlopen
13873     lt_cv_dlopen_libs=
13874     lt_cv_dlopen_self=no
13875     ;;
13876
13877   *)
13878     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
13879 if test "x$ac_cv_func_shl_load" = xyes; then :
13880   lt_cv_dlopen=shl_load
13881 else
13882   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
13883 $as_echo_n "checking for shl_load in -ldld... " >&6; }
13884 if ${ac_cv_lib_dld_shl_load+:} false; then :
13885   $as_echo_n "(cached) " >&6
13886 else
13887   ac_check_lib_save_LIBS=$LIBS
13888 LIBS="-ldld  $LIBS"
13889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13890 /* end confdefs.h.  */
13891
13892 /* Override any GCC internal prototype to avoid an error.
13893    Use char because int might match the return type of a GCC
13894    builtin and then its argument prototype would still apply.  */
13895 #ifdef __cplusplus
13896 extern "C"
13897 #endif
13898 char shl_load ();
13899 int
13900 main ()
13901 {
13902 return shl_load ();
13903   ;
13904   return 0;
13905 }
13906 _ACEOF
13907 if ac_fn_c_try_link "$LINENO"; then :
13908   ac_cv_lib_dld_shl_load=yes
13909 else
13910   ac_cv_lib_dld_shl_load=no
13911 fi
13912 rm -f core conftest.err conftest.$ac_objext \
13913     conftest$ac_exeext conftest.$ac_ext
13914 LIBS=$ac_check_lib_save_LIBS
13915 fi
13916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
13917 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
13918 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
13919   lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
13920 else
13921   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
13922 if test "x$ac_cv_func_dlopen" = xyes; then :
13923   lt_cv_dlopen=dlopen
13924 else
13925   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13926 $as_echo_n "checking for dlopen in -ldl... " >&6; }
13927 if ${ac_cv_lib_dl_dlopen+:} false; then :
13928   $as_echo_n "(cached) " >&6
13929 else
13930   ac_check_lib_save_LIBS=$LIBS
13931 LIBS="-ldl  $LIBS"
13932 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13933 /* end confdefs.h.  */
13934
13935 /* Override any GCC internal prototype to avoid an error.
13936    Use char because int might match the return type of a GCC
13937    builtin and then its argument prototype would still apply.  */
13938 #ifdef __cplusplus
13939 extern "C"
13940 #endif
13941 char dlopen ();
13942 int
13943 main ()
13944 {
13945 return dlopen ();
13946   ;
13947   return 0;
13948 }
13949 _ACEOF
13950 if ac_fn_c_try_link "$LINENO"; then :
13951   ac_cv_lib_dl_dlopen=yes
13952 else
13953   ac_cv_lib_dl_dlopen=no
13954 fi
13955 rm -f core conftest.err conftest.$ac_objext \
13956     conftest$ac_exeext conftest.$ac_ext
13957 LIBS=$ac_check_lib_save_LIBS
13958 fi
13959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
13960 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
13961 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
13962   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
13963 else
13964   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
13965 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
13966 if ${ac_cv_lib_svld_dlopen+:} false; then :
13967   $as_echo_n "(cached) " >&6
13968 else
13969   ac_check_lib_save_LIBS=$LIBS
13970 LIBS="-lsvld  $LIBS"
13971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13972 /* end confdefs.h.  */
13973
13974 /* Override any GCC internal prototype to avoid an error.
13975    Use char because int might match the return type of a GCC
13976    builtin and then its argument prototype would still apply.  */
13977 #ifdef __cplusplus
13978 extern "C"
13979 #endif
13980 char dlopen ();
13981 int
13982 main ()
13983 {
13984 return dlopen ();
13985   ;
13986   return 0;
13987 }
13988 _ACEOF
13989 if ac_fn_c_try_link "$LINENO"; then :
13990   ac_cv_lib_svld_dlopen=yes
13991 else
13992   ac_cv_lib_svld_dlopen=no
13993 fi
13994 rm -f core conftest.err conftest.$ac_objext \
13995     conftest$ac_exeext conftest.$ac_ext
13996 LIBS=$ac_check_lib_save_LIBS
13997 fi
13998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
13999 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14000 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14001   lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14002 else
14003   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14004 $as_echo_n "checking for dld_link in -ldld... " >&6; }
14005 if ${ac_cv_lib_dld_dld_link+:} false; then :
14006   $as_echo_n "(cached) " >&6
14007 else
14008   ac_check_lib_save_LIBS=$LIBS
14009 LIBS="-ldld  $LIBS"
14010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14011 /* end confdefs.h.  */
14012
14013 /* Override any GCC internal prototype to avoid an error.
14014    Use char because int might match the return type of a GCC
14015    builtin and then its argument prototype would still apply.  */
14016 #ifdef __cplusplus
14017 extern "C"
14018 #endif
14019 char dld_link ();
14020 int
14021 main ()
14022 {
14023 return dld_link ();
14024   ;
14025   return 0;
14026 }
14027 _ACEOF
14028 if ac_fn_c_try_link "$LINENO"; then :
14029   ac_cv_lib_dld_dld_link=yes
14030 else
14031   ac_cv_lib_dld_dld_link=no
14032 fi
14033 rm -f core conftest.err conftest.$ac_objext \
14034     conftest$ac_exeext conftest.$ac_ext
14035 LIBS=$ac_check_lib_save_LIBS
14036 fi
14037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14038 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14039 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14040   lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14041 fi
14042
14043
14044 fi
14045
14046
14047 fi
14048
14049
14050 fi
14051
14052
14053 fi
14054
14055
14056 fi
14057
14058     ;;
14059   esac
14060
14061   if test no = "$lt_cv_dlopen"; then
14062     enable_dlopen=no
14063   else
14064     enable_dlopen=yes
14065   fi
14066
14067   case $lt_cv_dlopen in
14068   dlopen)
14069     save_CPPFLAGS=$CPPFLAGS
14070     test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
14071
14072     save_LDFLAGS=$LDFLAGS
14073     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
14074
14075     save_LIBS=$LIBS
14076     LIBS="$lt_cv_dlopen_libs $LIBS"
14077
14078     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
14079 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
14080 if ${lt_cv_dlopen_self+:} false; then :
14081   $as_echo_n "(cached) " >&6
14082 else
14083           if test yes = "$cross_compiling"; then :
14084   lt_cv_dlopen_self=cross
14085 else
14086   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14087   lt_status=$lt_dlunknown
14088   cat > conftest.$ac_ext <<_LT_EOF
14089 #line $LINENO "configure"
14090 #include "confdefs.h"
14091
14092 #if HAVE_DLFCN_H
14093 #include <dlfcn.h>
14094 #endif
14095
14096 #include <stdio.h>
14097
14098 #ifdef RTLD_GLOBAL
14099 #  define LT_DLGLOBAL           RTLD_GLOBAL
14100 #else
14101 #  ifdef DL_GLOBAL
14102 #    define LT_DLGLOBAL         DL_GLOBAL
14103 #  else
14104 #    define LT_DLGLOBAL         0
14105 #  endif
14106 #endif
14107
14108 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14109    find out it does not work in some platform. */
14110 #ifndef LT_DLLAZY_OR_NOW
14111 #  ifdef RTLD_LAZY
14112 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14113 #  else
14114 #    ifdef DL_LAZY
14115 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14116 #    else
14117 #      ifdef RTLD_NOW
14118 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14119 #      else
14120 #        ifdef DL_NOW
14121 #          define LT_DLLAZY_OR_NOW      DL_NOW
14122 #        else
14123 #          define LT_DLLAZY_OR_NOW      0
14124 #        endif
14125 #      endif
14126 #    endif
14127 #  endif
14128 #endif
14129
14130 /* When -fvisibility=hidden is used, assume the code has been annotated
14131    correspondingly for the symbols needed.  */
14132 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14133 int fnord () __attribute__((visibility("default")));
14134 #endif
14135
14136 int fnord () { return 42; }
14137 int main ()
14138 {
14139   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14140   int status = $lt_dlunknown;
14141
14142   if (self)
14143     {
14144       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14145       else
14146         {
14147           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14148           else puts (dlerror ());
14149         }
14150       /* dlclose (self); */
14151     }
14152   else
14153     puts (dlerror ());
14154
14155   return status;
14156 }
14157 _LT_EOF
14158   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14159   (eval $ac_link) 2>&5
14160   ac_status=$?
14161   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14162   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14163     (./conftest; exit; ) >&5 2>/dev/null
14164     lt_status=$?
14165     case x$lt_status in
14166       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
14167       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
14168       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
14169     esac
14170   else :
14171     # compilation failed
14172     lt_cv_dlopen_self=no
14173   fi
14174 fi
14175 rm -fr conftest*
14176
14177
14178 fi
14179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
14180 $as_echo "$lt_cv_dlopen_self" >&6; }
14181
14182     if test yes = "$lt_cv_dlopen_self"; then
14183       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
14184       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
14185 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
14186 if ${lt_cv_dlopen_self_static+:} false; then :
14187   $as_echo_n "(cached) " >&6
14188 else
14189           if test yes = "$cross_compiling"; then :
14190   lt_cv_dlopen_self_static=cross
14191 else
14192   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14193   lt_status=$lt_dlunknown
14194   cat > conftest.$ac_ext <<_LT_EOF
14195 #line $LINENO "configure"
14196 #include "confdefs.h"
14197
14198 #if HAVE_DLFCN_H
14199 #include <dlfcn.h>
14200 #endif
14201
14202 #include <stdio.h>
14203
14204 #ifdef RTLD_GLOBAL
14205 #  define LT_DLGLOBAL           RTLD_GLOBAL
14206 #else
14207 #  ifdef DL_GLOBAL
14208 #    define LT_DLGLOBAL         DL_GLOBAL
14209 #  else
14210 #    define LT_DLGLOBAL         0
14211 #  endif
14212 #endif
14213
14214 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14215    find out it does not work in some platform. */
14216 #ifndef LT_DLLAZY_OR_NOW
14217 #  ifdef RTLD_LAZY
14218 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
14219 #  else
14220 #    ifdef DL_LAZY
14221 #      define LT_DLLAZY_OR_NOW          DL_LAZY
14222 #    else
14223 #      ifdef RTLD_NOW
14224 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
14225 #      else
14226 #        ifdef DL_NOW
14227 #          define LT_DLLAZY_OR_NOW      DL_NOW
14228 #        else
14229 #          define LT_DLLAZY_OR_NOW      0
14230 #        endif
14231 #      endif
14232 #    endif
14233 #  endif
14234 #endif
14235
14236 /* When -fvisibility=hidden is used, assume the code has been annotated
14237    correspondingly for the symbols needed.  */
14238 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14239 int fnord () __attribute__((visibility("default")));
14240 #endif
14241
14242 int fnord () { return 42; }
14243 int main ()
14244 {
14245   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14246   int status = $lt_dlunknown;
14247
14248   if (self)
14249     {
14250       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
14251       else
14252         {
14253           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
14254           else puts (dlerror ());
14255         }
14256       /* dlclose (self); */
14257     }
14258   else
14259     puts (dlerror ());
14260
14261   return status;
14262 }
14263 _LT_EOF
14264   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14265   (eval $ac_link) 2>&5
14266   ac_status=$?
14267   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14268   test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14269     (./conftest; exit; ) >&5 2>/dev/null
14270     lt_status=$?
14271     case x$lt_status in
14272       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
14273       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
14274       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
14275     esac
14276   else :
14277     # compilation failed
14278     lt_cv_dlopen_self_static=no
14279   fi
14280 fi
14281 rm -fr conftest*
14282
14283
14284 fi
14285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
14286 $as_echo "$lt_cv_dlopen_self_static" >&6; }
14287     fi
14288
14289     CPPFLAGS=$save_CPPFLAGS
14290     LDFLAGS=$save_LDFLAGS
14291     LIBS=$save_LIBS
14292     ;;
14293   esac
14294
14295   case $lt_cv_dlopen_self in
14296   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
14297   *) enable_dlopen_self=unknown ;;
14298   esac
14299
14300   case $lt_cv_dlopen_self_static in
14301   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
14302   *) enable_dlopen_self_static=unknown ;;
14303   esac
14304 fi
14305
14306
14307
14308
14309
14310
14311
14312
14313
14314
14315
14316
14317
14318
14319
14320
14321
14322 striplib=
14323 old_striplib=
14324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
14325 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
14326 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
14327   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
14328   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
14329   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14330 $as_echo "yes" >&6; }
14331 else
14332 # FIXME - insert some real tests, host_os isn't really good enough
14333   case $host_os in
14334   darwin*)
14335     if test -n "$STRIP"; then
14336       striplib="$STRIP -x"
14337       old_striplib="$STRIP -S"
14338       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14339 $as_echo "yes" >&6; }
14340     else
14341       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14342 $as_echo "no" >&6; }
14343     fi
14344     ;;
14345   *)
14346     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14347 $as_echo "no" >&6; }
14348     ;;
14349   esac
14350 fi
14351
14352
14353
14354
14355
14356
14357
14358
14359
14360
14361
14362
14363   # Report what library types will actually be built
14364   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
14365 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
14366   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
14367 $as_echo "$can_build_shared" >&6; }
14368
14369   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
14370 $as_echo_n "checking whether to build shared libraries... " >&6; }
14371   test no = "$can_build_shared" && enable_shared=no
14372
14373   # On AIX, shared libraries and static libraries use the same namespace, and
14374   # are all built from PIC.
14375   case $host_os in
14376   aix3*)
14377     test yes = "$enable_shared" && enable_static=no
14378     if test -n "$RANLIB"; then
14379       archive_cmds="$archive_cmds~\$RANLIB \$lib"
14380       postinstall_cmds='$RANLIB $lib'
14381     fi
14382     ;;
14383
14384   aix[4-9]*)
14385     if test ia64 != "$host_cpu"; then
14386       case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
14387       yes,aix,yes) ;;                   # shared object as lib.so file only
14388       yes,svr4,*) ;;                    # shared object as lib.so archive member only
14389       yes,*) enable_static=no ;;        # shared object in lib.a archive as well
14390       esac
14391     fi
14392     ;;
14393   esac
14394   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
14395 $as_echo "$enable_shared" >&6; }
14396
14397   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
14398 $as_echo_n "checking whether to build static libraries... " >&6; }
14399   # Make sure either enable_shared or enable_static is yes.
14400   test yes = "$enable_shared" || enable_static=yes
14401   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
14402 $as_echo "$enable_static" >&6; }
14403
14404
14405
14406
14407 fi
14408 ac_ext=c
14409 ac_cpp='$CPP $CPPFLAGS'
14410 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14411 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14412 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14413
14414 CC=$lt_save_CC
14415
14416
14417
14418
14419
14420
14421
14422
14423
14424
14425
14426
14427
14428
14429
14430         ac_config_commands="$ac_config_commands libtool"
14431
14432
14433
14434
14435 # Only expand once:
14436
14437
14438
14439
14440 # Checks for header files.
14441 for ac_header in stdarg.h stdbool.h netinet/in.h netinet/tcp.h sys/param.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/ipc.h sys/shm.h
14442 do :
14443   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14444 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
14445 "
14446 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14447   cat >>confdefs.h <<_ACEOF
14448 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14449 _ACEOF
14450
14451 fi
14452
14453 done
14454
14455
14456 # check for types.
14457 # Using own tests for int64* because autoconf builtin only give 32bit.
14458 ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
14459 if test "x$ac_cv_type_int8_t" = xyes; then :
14460
14461 else
14462
14463 cat >>confdefs.h <<_ACEOF
14464 #define int8_t signed char
14465 _ACEOF
14466
14467 fi
14468
14469 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
14470 if test "x$ac_cv_type_int16_t" = xyes; then :
14471
14472 else
14473
14474 cat >>confdefs.h <<_ACEOF
14475 #define int16_t short
14476 _ACEOF
14477
14478 fi
14479
14480 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
14481 if test "x$ac_cv_type_int32_t" = xyes; then :
14482
14483 else
14484
14485 cat >>confdefs.h <<_ACEOF
14486 #define int32_t int
14487 _ACEOF
14488
14489 fi
14490
14491 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
14492 if test "x$ac_cv_type_int64_t" = xyes; then :
14493
14494 else
14495
14496 cat >>confdefs.h <<_ACEOF
14497 #define int64_t long long
14498 _ACEOF
14499
14500 fi
14501
14502 ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
14503 if test "x$ac_cv_type_uint8_t" = xyes; then :
14504
14505 else
14506
14507 cat >>confdefs.h <<_ACEOF
14508 #define uint8_t unsigned char
14509 _ACEOF
14510
14511 fi
14512
14513 ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
14514 if test "x$ac_cv_type_uint16_t" = xyes; then :
14515
14516 else
14517
14518 cat >>confdefs.h <<_ACEOF
14519 #define uint16_t unsigned short
14520 _ACEOF
14521
14522 fi
14523
14524 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
14525 if test "x$ac_cv_type_uint32_t" = xyes; then :
14526
14527 else
14528
14529 cat >>confdefs.h <<_ACEOF
14530 #define uint32_t unsigned int
14531 _ACEOF
14532
14533 fi
14534
14535 ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
14536 if test "x$ac_cv_type_uint64_t" = xyes; then :
14537
14538 else
14539
14540 cat >>confdefs.h <<_ACEOF
14541 #define uint64_t unsigned long long
14542 _ACEOF
14543
14544 fi
14545
14546 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
14547 if test "x$ac_cv_type_size_t" = xyes; then :
14548
14549 else
14550
14551 cat >>confdefs.h <<_ACEOF
14552 #define size_t unsigned int
14553 _ACEOF
14554
14555 fi
14556
14557 ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
14558 if test "x$ac_cv_type_ssize_t" = xyes; then :
14559
14560 else
14561
14562 cat >>confdefs.h <<_ACEOF
14563 #define ssize_t int
14564 _ACEOF
14565
14566 fi
14567
14568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
14569 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
14570 if ${ac_cv_type_uid_t+:} false; then :
14571   $as_echo_n "(cached) " >&6
14572 else
14573   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14574 /* end confdefs.h.  */
14575 #include <sys/types.h>
14576
14577 _ACEOF
14578 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14579   $EGREP "uid_t" >/dev/null 2>&1; then :
14580   ac_cv_type_uid_t=yes
14581 else
14582   ac_cv_type_uid_t=no
14583 fi
14584 rm -f conftest*
14585
14586 fi
14587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
14588 $as_echo "$ac_cv_type_uid_t" >&6; }
14589 if test $ac_cv_type_uid_t = no; then
14590
14591 $as_echo "#define uid_t int" >>confdefs.h
14592
14593
14594 $as_echo "#define gid_t int" >>confdefs.h
14595
14596 fi
14597
14598 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14599 if test "x$ac_cv_type_pid_t" = xyes; then :
14600
14601 else
14602
14603 cat >>confdefs.h <<_ACEOF
14604 #define pid_t int
14605 _ACEOF
14606
14607 fi
14608
14609 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
14610 if test "x$ac_cv_type_off_t" = xyes; then :
14611
14612 else
14613
14614 cat >>confdefs.h <<_ACEOF
14615 #define off_t long int
14616 _ACEOF
14617
14618 fi
14619
14620 ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "
14621 $ac_includes_default
14622 #ifdef HAVE_WINSOCK2_H
14623 #  include <winsock2.h>
14624 #endif
14625
14626 "
14627 if test "x$ac_cv_type_u_char" = xyes; then :
14628
14629 else
14630
14631 $as_echo "#define u_char unsigned char" >>confdefs.h
14632
14633 fi
14634
14635 ac_fn_c_check_type "$LINENO" "rlim_t" "ac_cv_type_rlim_t" "
14636 $ac_includes_default
14637 #ifdef HAVE_SYS_RESOURCE_H
14638 #  include <sys/resource.h>
14639 #endif
14640
14641 "
14642 if test "x$ac_cv_type_rlim_t" = xyes; then :
14643
14644 else
14645
14646 $as_echo "#define rlim_t unsigned long" >>confdefs.h
14647
14648 fi
14649
14650
14651 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
14652 $ac_includes_default
14653 #ifdef HAVE_SYS_SOCKET_H
14654 #  include <sys/socket.h>
14655 #endif
14656 #ifdef HAVE_WS2TCPIP_H
14657 #  include <ws2tcpip.h>
14658 #endif
14659
14660 "
14661 if test "x$ac_cv_type_socklen_t" = xyes; then :
14662
14663 else
14664
14665 $as_echo "#define socklen_t int" >>confdefs.h
14666
14667 fi
14668
14669  ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
14670 $ac_includes_default
14671 #ifdef HAVE_SYS_TYPES_H
14672 # include <sys/types.h>
14673 #endif
14674 #ifdef HAVE_NETINET_IN_H
14675 # include <netinet/in.h>
14676 #endif
14677
14678 "
14679 if test "x$ac_cv_type_in_addr_t" = xyes; then :
14680
14681 else
14682
14683 $as_echo "#define in_addr_t uint32_t" >>confdefs.h
14684
14685 fi
14686
14687  ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "
14688 $ac_includes_default
14689 #ifdef HAVE_SYS_TYPES_H
14690 # include <sys/types.h>
14691 #endif
14692 #ifdef HAVE_NETINET_IN_H
14693 # include <netinet/in.h>
14694 #endif
14695
14696 "
14697 if test "x$ac_cv_type_in_port_t" = xyes; then :
14698
14699 else
14700
14701 $as_echo "#define in_port_t uint16_t" >>confdefs.h
14702
14703 fi
14704
14705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memcmp compares unsigned" >&5
14706 $as_echo_n "checking if memcmp compares unsigned... " >&6; }
14707 if test "$cross_compiling" = yes; then :
14708    { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile no" >&5
14709 $as_echo "cross-compile no" >&6; }
14710
14711 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
14712
14713   case " $LIBOBJS " in
14714   *" memcmp.$ac_objext "* ) ;;
14715   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
14716  ;;
14717 esac
14718
14719
14720 else
14721   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14722 /* end confdefs.h.  */
14723
14724 #include <stdio.h>
14725 #include <stdlib.h>
14726 #include <string.h>
14727 int main(void)
14728 {
14729         char a = 255, b = 0;
14730         if(memcmp(&a, &b, 1) < 0)
14731                 return 1;
14732         return 0;
14733 }
14734
14735 _ACEOF
14736 if ac_fn_c_try_run "$LINENO"; then :
14737   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14738 $as_echo "yes" >&6; }
14739 else
14740    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14741 $as_echo "no" >&6; }
14742
14743 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
14744
14745   case " $LIBOBJS " in
14746   *" memcmp.$ac_objext "* ) ;;
14747   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
14748  ;;
14749 esac
14750
14751
14752 fi
14753 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14754   conftest.$ac_objext conftest.beam conftest.$ac_ext
14755 fi
14756
14757
14758 # The cast to long int works around a bug in the HP C Compiler
14759 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14760 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14761 # This bug is HP SR number 8606223364.
14762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
14763 $as_echo_n "checking size of time_t... " >&6; }
14764 if ${ac_cv_sizeof_time_t+:} false; then :
14765   $as_echo_n "(cached) " >&6
14766 else
14767   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "
14768 $ac_includes_default
14769 #ifdef TIME_WITH_SYS_TIME
14770 # include <sys/time.h>
14771 # include <time.h>
14772 #else
14773 # ifdef HAVE_SYS_TIME_H
14774 #  include <sys/time.h>
14775 # else
14776 #  include <time.h>
14777 # endif
14778 #endif
14779
14780 "; then :
14781
14782 else
14783   if test "$ac_cv_type_time_t" = yes; then
14784      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14785 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14786 as_fn_error 77 "cannot compute sizeof (time_t)
14787 See \`config.log' for more details" "$LINENO" 5; }
14788    else
14789      ac_cv_sizeof_time_t=0
14790    fi
14791 fi
14792
14793 fi
14794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
14795 $as_echo "$ac_cv_sizeof_time_t" >&6; }
14796
14797
14798
14799 cat >>confdefs.h <<_ACEOF
14800 #define SIZEOF_TIME_T $ac_cv_sizeof_time_t
14801 _ACEOF
14802
14803
14804
14805 # add option to disable the evil rpath
14806
14807 # Check whether --enable-rpath was given.
14808 if test "${enable_rpath+set}" = set; then :
14809   enableval=$enable_rpath; enable_rpath=$enableval
14810 else
14811   enable_rpath=yes
14812 fi
14813
14814 if test "x$enable_rpath" = xno; then
14815                 ac_config_commands="$ac_config_commands disable-rpath"
14816
14817 fi
14818
14819
14820
14821 # check to see if libraries are needed for these functions.
14822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
14823 $as_echo_n "checking for library containing inet_pton... " >&6; }
14824 if ${ac_cv_search_inet_pton+:} false; then :
14825   $as_echo_n "(cached) " >&6
14826 else
14827   ac_func_search_save_LIBS=$LIBS
14828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14829 /* end confdefs.h.  */
14830
14831 /* Override any GCC internal prototype to avoid an error.
14832    Use char because int might match the return type of a GCC
14833    builtin and then its argument prototype would still apply.  */
14834 #ifdef __cplusplus
14835 extern "C"
14836 #endif
14837 char inet_pton ();
14838 int
14839 main ()
14840 {
14841 return inet_pton ();
14842   ;
14843   return 0;
14844 }
14845 _ACEOF
14846 for ac_lib in '' nsl; do
14847   if test -z "$ac_lib"; then
14848     ac_res="none required"
14849   else
14850     ac_res=-l$ac_lib
14851     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14852   fi
14853   if ac_fn_c_try_link "$LINENO"; then :
14854   ac_cv_search_inet_pton=$ac_res
14855 fi
14856 rm -f core conftest.err conftest.$ac_objext \
14857     conftest$ac_exeext
14858   if ${ac_cv_search_inet_pton+:} false; then :
14859   break
14860 fi
14861 done
14862 if ${ac_cv_search_inet_pton+:} false; then :
14863
14864 else
14865   ac_cv_search_inet_pton=no
14866 fi
14867 rm conftest.$ac_ext
14868 LIBS=$ac_func_search_save_LIBS
14869 fi
14870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
14871 $as_echo "$ac_cv_search_inet_pton" >&6; }
14872 ac_res=$ac_cv_search_inet_pton
14873 if test "$ac_res" != no; then :
14874   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14875
14876 fi
14877
14878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
14879 $as_echo_n "checking for library containing socket... " >&6; }
14880 if ${ac_cv_search_socket+:} false; then :
14881   $as_echo_n "(cached) " >&6
14882 else
14883   ac_func_search_save_LIBS=$LIBS
14884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14885 /* end confdefs.h.  */
14886
14887 /* Override any GCC internal prototype to avoid an error.
14888    Use char because int might match the return type of a GCC
14889    builtin and then its argument prototype would still apply.  */
14890 #ifdef __cplusplus
14891 extern "C"
14892 #endif
14893 char socket ();
14894 int
14895 main ()
14896 {
14897 return socket ();
14898   ;
14899   return 0;
14900 }
14901 _ACEOF
14902 for ac_lib in '' socket; do
14903   if test -z "$ac_lib"; then
14904     ac_res="none required"
14905   else
14906     ac_res=-l$ac_lib
14907     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14908   fi
14909   if ac_fn_c_try_link "$LINENO"; then :
14910   ac_cv_search_socket=$ac_res
14911 fi
14912 rm -f core conftest.err conftest.$ac_objext \
14913     conftest$ac_exeext
14914   if ${ac_cv_search_socket+:} false; then :
14915   break
14916 fi
14917 done
14918 if ${ac_cv_search_socket+:} false; then :
14919
14920 else
14921   ac_cv_search_socket=no
14922 fi
14923 rm conftest.$ac_ext
14924 LIBS=$ac_func_search_save_LIBS
14925 fi
14926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
14927 $as_echo "$ac_cv_search_socket" >&6; }
14928 ac_res=$ac_cv_search_socket
14929 if test "$ac_res" != no; then :
14930   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14931
14932 fi
14933
14934
14935 # check wether strptime also works
14936
14937 # check some functions of the OS before linking libs (while still runnable).
14938 for ac_header in unistd.h
14939 do :
14940   ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
14941 if test "x$ac_cv_header_unistd_h" = xyes; then :
14942   cat >>confdefs.h <<_ACEOF
14943 #define HAVE_UNISTD_H 1
14944 _ACEOF
14945
14946 fi
14947
14948 done
14949
14950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
14951 $as_echo_n "checking for working chown... " >&6; }
14952 if ${ac_cv_func_chown_works+:} false; then :
14953   $as_echo_n "(cached) " >&6
14954 else
14955   if test "$cross_compiling" = yes; then :
14956   ac_cv_func_chown_works=no
14957 else
14958   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14959 /* end confdefs.h.  */
14960 $ac_includes_default
14961 #include <fcntl.h>
14962
14963 int
14964 main ()
14965 {
14966   char *f = "conftest.chown";
14967   struct stat before, after;
14968
14969   if (creat (f, 0600) < 0)
14970     return 1;
14971   if (stat (f, &before) < 0)
14972     return 1;
14973   if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
14974     return 1;
14975   if (stat (f, &after) < 0)
14976     return 1;
14977   return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
14978
14979   ;
14980   return 0;
14981 }
14982 _ACEOF
14983 if ac_fn_c_try_run "$LINENO"; then :
14984   ac_cv_func_chown_works=yes
14985 else
14986   ac_cv_func_chown_works=no
14987 fi
14988 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14989   conftest.$ac_objext conftest.beam conftest.$ac_ext
14990 fi
14991
14992 rm -f conftest.chown
14993
14994 fi
14995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
14996 $as_echo "$ac_cv_func_chown_works" >&6; }
14997 if test $ac_cv_func_chown_works = yes; then
14998
14999 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
15000
15001 fi
15002
15003 for ac_header in vfork.h
15004 do :
15005   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15006 if test "x$ac_cv_header_vfork_h" = xyes; then :
15007   cat >>confdefs.h <<_ACEOF
15008 #define HAVE_VFORK_H 1
15009 _ACEOF
15010
15011 fi
15012
15013 done
15014
15015 for ac_func in fork vfork
15016 do :
15017   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15018 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15019 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15020   cat >>confdefs.h <<_ACEOF
15021 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15022 _ACEOF
15023
15024 fi
15025 done
15026
15027 if test "x$ac_cv_func_fork" = xyes; then
15028   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15029 $as_echo_n "checking for working fork... " >&6; }
15030 if ${ac_cv_func_fork_works+:} false; then :
15031   $as_echo_n "(cached) " >&6
15032 else
15033   if test "$cross_compiling" = yes; then :
15034   ac_cv_func_fork_works=cross
15035 else
15036   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15037 /* end confdefs.h.  */
15038 $ac_includes_default
15039 int
15040 main ()
15041 {
15042
15043           /* By Ruediger Kuhlmann. */
15044           return fork () < 0;
15045
15046   ;
15047   return 0;
15048 }
15049 _ACEOF
15050 if ac_fn_c_try_run "$LINENO"; then :
15051   ac_cv_func_fork_works=yes
15052 else
15053   ac_cv_func_fork_works=no
15054 fi
15055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15056   conftest.$ac_objext conftest.beam conftest.$ac_ext
15057 fi
15058
15059 fi
15060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15061 $as_echo "$ac_cv_func_fork_works" >&6; }
15062
15063 else
15064   ac_cv_func_fork_works=$ac_cv_func_fork
15065 fi
15066 if test "x$ac_cv_func_fork_works" = xcross; then
15067   case $host in
15068     *-*-amigaos* | *-*-msdosdjgpp*)
15069       # Override, as these systems have only a dummy fork() stub
15070       ac_cv_func_fork_works=no
15071       ;;
15072     *)
15073       ac_cv_func_fork_works=yes
15074       ;;
15075   esac
15076   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15077 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15078 fi
15079 ac_cv_func_vfork_works=$ac_cv_func_vfork
15080 if test "x$ac_cv_func_vfork" = xyes; then
15081   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15082 $as_echo_n "checking for working vfork... " >&6; }
15083 if ${ac_cv_func_vfork_works+:} false; then :
15084   $as_echo_n "(cached) " >&6
15085 else
15086   if test "$cross_compiling" = yes; then :
15087   ac_cv_func_vfork_works=cross
15088 else
15089   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15090 /* end confdefs.h.  */
15091 /* Thanks to Paul Eggert for this test.  */
15092 $ac_includes_default
15093 #include <sys/wait.h>
15094 #ifdef HAVE_VFORK_H
15095 # include <vfork.h>
15096 #endif
15097 /* On some sparc systems, changes by the child to local and incoming
15098    argument registers are propagated back to the parent.  The compiler
15099    is told about this with #include <vfork.h>, but some compilers
15100    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
15101    static variable whose address is put into a register that is
15102    clobbered by the vfork.  */
15103 static void
15104 #ifdef __cplusplus
15105 sparc_address_test (int arg)
15106 # else
15107 sparc_address_test (arg) int arg;
15108 #endif
15109 {
15110   static pid_t child;
15111   if (!child) {
15112     child = vfork ();
15113     if (child < 0) {
15114       perror ("vfork");
15115       _exit(2);
15116     }
15117     if (!child) {
15118       arg = getpid();
15119       write(-1, "", 0);
15120       _exit (arg);
15121     }
15122   }
15123 }
15124
15125 int
15126 main ()
15127 {
15128   pid_t parent = getpid ();
15129   pid_t child;
15130
15131   sparc_address_test (0);
15132
15133   child = vfork ();
15134
15135   if (child == 0) {
15136     /* Here is another test for sparc vfork register problems.  This
15137        test uses lots of local variables, at least as many local
15138        variables as main has allocated so far including compiler
15139        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
15140        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
15141        reuse the register of parent for one of the local variables,
15142        since it will think that parent can't possibly be used any more
15143        in this routine.  Assigning to the local variable will thus
15144        munge parent in the parent process.  */
15145     pid_t
15146       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15147       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15148     /* Convince the compiler that p..p7 are live; otherwise, it might
15149        use the same hardware register for all 8 local variables.  */
15150     if (p != p1 || p != p2 || p != p3 || p != p4
15151         || p != p5 || p != p6 || p != p7)
15152       _exit(1);
15153
15154     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15155        from child file descriptors.  If the child closes a descriptor
15156        before it execs or exits, this munges the parent's descriptor
15157        as well.  Test for this by closing stdout in the child.  */
15158     _exit(close(fileno(stdout)) != 0);
15159   } else {
15160     int status;
15161     struct stat st;
15162
15163     while (wait(&status) != child)
15164       ;
15165     return (
15166          /* Was there some problem with vforking?  */
15167          child < 0
15168
15169          /* Did the child fail?  (This shouldn't happen.)  */
15170          || status
15171
15172          /* Did the vfork/compiler bug occur?  */
15173          || parent != getpid()
15174
15175          /* Did the file descriptor bug occur?  */
15176          || fstat(fileno(stdout), &st) != 0
15177          );
15178   }
15179 }
15180 _ACEOF
15181 if ac_fn_c_try_run "$LINENO"; then :
15182   ac_cv_func_vfork_works=yes
15183 else
15184   ac_cv_func_vfork_works=no
15185 fi
15186 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15187   conftest.$ac_objext conftest.beam conftest.$ac_ext
15188 fi
15189
15190 fi
15191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15192 $as_echo "$ac_cv_func_vfork_works" >&6; }
15193
15194 fi;
15195 if test "x$ac_cv_func_fork_works" = xcross; then
15196   ac_cv_func_vfork_works=$ac_cv_func_vfork
15197   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15198 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15199 fi
15200
15201 if test "x$ac_cv_func_vfork_works" = xyes; then
15202
15203 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15204
15205 else
15206
15207 $as_echo "#define vfork fork" >>confdefs.h
15208
15209 fi
15210 if test "x$ac_cv_func_fork_works" = xyes; then
15211
15212 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15213
15214 fi
15215
15216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
15217 $as_echo_n "checking return type of signal handlers... " >&6; }
15218 if ${ac_cv_type_signal+:} false; then :
15219   $as_echo_n "(cached) " >&6
15220 else
15221   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15222 /* end confdefs.h.  */
15223 #include <sys/types.h>
15224 #include <signal.h>
15225
15226 int
15227 main ()
15228 {
15229 return *(signal (0, 0)) (0) == 1;
15230   ;
15231   return 0;
15232 }
15233 _ACEOF
15234 if ac_fn_c_try_compile "$LINENO"; then :
15235   ac_cv_type_signal=int
15236 else
15237   ac_cv_type_signal=void
15238 fi
15239 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15240 fi
15241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
15242 $as_echo "$ac_cv_type_signal" >&6; }
15243
15244 cat >>confdefs.h <<_ACEOF
15245 #define RETSIGTYPE $ac_cv_type_signal
15246 _ACEOF
15247
15248
15249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15250 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15251 if ${ac_cv_sys_largefile_source+:} false; then :
15252   $as_echo_n "(cached) " >&6
15253 else
15254   while :; do
15255   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15256 /* end confdefs.h.  */
15257 #include <sys/types.h> /* for off_t */
15258      #include <stdio.h>
15259 int
15260 main ()
15261 {
15262 int (*fp) (FILE *, off_t, int) = fseeko;
15263      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15264   ;
15265   return 0;
15266 }
15267 _ACEOF
15268 if ac_fn_c_try_link "$LINENO"; then :
15269   ac_cv_sys_largefile_source=no; break
15270 fi
15271 rm -f core conftest.err conftest.$ac_objext \
15272     conftest$ac_exeext conftest.$ac_ext
15273   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15274 /* end confdefs.h.  */
15275 #define _LARGEFILE_SOURCE 1
15276 #include <sys/types.h> /* for off_t */
15277      #include <stdio.h>
15278 int
15279 main ()
15280 {
15281 int (*fp) (FILE *, off_t, int) = fseeko;
15282      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15283   ;
15284   return 0;
15285 }
15286 _ACEOF
15287 if ac_fn_c_try_link "$LINENO"; then :
15288   ac_cv_sys_largefile_source=1; break
15289 fi
15290 rm -f core conftest.err conftest.$ac_objext \
15291     conftest$ac_exeext conftest.$ac_ext
15292   ac_cv_sys_largefile_source=unknown
15293   break
15294 done
15295 fi
15296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15297 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15298 case $ac_cv_sys_largefile_source in #(
15299   no | unknown) ;;
15300   *)
15301 cat >>confdefs.h <<_ACEOF
15302 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15303 _ACEOF
15304 ;;
15305 esac
15306 rm -rf conftest*
15307
15308 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15309 # in glibc 2.1.3, but that breaks too many other things.
15310 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15311 if test $ac_cv_sys_largefile_source != unknown; then
15312
15313 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15314
15315 fi
15316
15317
15318 # Check whether --enable-largefile was given.
15319 if test "${enable_largefile+set}" = set; then :
15320   enableval=$enable_largefile;
15321 fi
15322
15323 if test "$enable_largefile" != no; then
15324
15325   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15326 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
15327 if ${ac_cv_sys_largefile_CC+:} false; then :
15328   $as_echo_n "(cached) " >&6
15329 else
15330   ac_cv_sys_largefile_CC=no
15331      if test "$GCC" != yes; then
15332        ac_save_CC=$CC
15333        while :; do
15334          # IRIX 6.2 and later do not support large files by default,
15335          # so use the C compiler's -n32 option if that helps.
15336          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15337 /* end confdefs.h.  */
15338 #include <sys/types.h>
15339  /* Check that off_t can represent 2**63 - 1 correctly.
15340     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15341     since some C++ compilers masquerading as C compilers
15342     incorrectly reject 9223372036854775807.  */
15343 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15344   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15345                        && LARGE_OFF_T % 2147483647 == 1)
15346                       ? 1 : -1];
15347 int
15348 main ()
15349 {
15350
15351   ;
15352   return 0;
15353 }
15354 _ACEOF
15355          if ac_fn_c_try_compile "$LINENO"; then :
15356   break
15357 fi
15358 rm -f core conftest.err conftest.$ac_objext
15359          CC="$CC -n32"
15360          if ac_fn_c_try_compile "$LINENO"; then :
15361   ac_cv_sys_largefile_CC=' -n32'; break
15362 fi
15363 rm -f core conftest.err conftest.$ac_objext
15364          break
15365        done
15366        CC=$ac_save_CC
15367        rm -f conftest.$ac_ext
15368     fi
15369 fi
15370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15371 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
15372   if test "$ac_cv_sys_largefile_CC" != no; then
15373     CC=$CC$ac_cv_sys_largefile_CC
15374   fi
15375
15376   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15377 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15378 if ${ac_cv_sys_file_offset_bits+:} false; then :
15379   $as_echo_n "(cached) " >&6
15380 else
15381   while :; do
15382   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15383 /* end confdefs.h.  */
15384 #include <sys/types.h>
15385  /* Check that off_t can represent 2**63 - 1 correctly.
15386     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15387     since some C++ compilers masquerading as C compilers
15388     incorrectly reject 9223372036854775807.  */
15389 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15390   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15391                        && LARGE_OFF_T % 2147483647 == 1)
15392                       ? 1 : -1];
15393 int
15394 main ()
15395 {
15396
15397   ;
15398   return 0;
15399 }
15400 _ACEOF
15401 if ac_fn_c_try_compile "$LINENO"; then :
15402   ac_cv_sys_file_offset_bits=no; break
15403 fi
15404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15405   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15406 /* end confdefs.h.  */
15407 #define _FILE_OFFSET_BITS 64
15408 #include <sys/types.h>
15409  /* Check that off_t can represent 2**63 - 1 correctly.
15410     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15411     since some C++ compilers masquerading as C compilers
15412     incorrectly reject 9223372036854775807.  */
15413 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15414   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15415                        && LARGE_OFF_T % 2147483647 == 1)
15416                       ? 1 : -1];
15417 int
15418 main ()
15419 {
15420
15421   ;
15422   return 0;
15423 }
15424 _ACEOF
15425 if ac_fn_c_try_compile "$LINENO"; then :
15426   ac_cv_sys_file_offset_bits=64; break
15427 fi
15428 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15429   ac_cv_sys_file_offset_bits=unknown
15430   break
15431 done
15432 fi
15433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15434 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
15435 case $ac_cv_sys_file_offset_bits in #(
15436   no | unknown) ;;
15437   *)
15438 cat >>confdefs.h <<_ACEOF
15439 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
15440 _ACEOF
15441 ;;
15442 esac
15443 rm -rf conftest*
15444   if test $ac_cv_sys_file_offset_bits = unknown; then
15445     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15446 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
15447 if ${ac_cv_sys_large_files+:} false; then :
15448   $as_echo_n "(cached) " >&6
15449 else
15450   while :; do
15451   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15452 /* end confdefs.h.  */
15453 #include <sys/types.h>
15454  /* Check that off_t can represent 2**63 - 1 correctly.
15455     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15456     since some C++ compilers masquerading as C compilers
15457     incorrectly reject 9223372036854775807.  */
15458 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15459   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15460                        && LARGE_OFF_T % 2147483647 == 1)
15461                       ? 1 : -1];
15462 int
15463 main ()
15464 {
15465
15466   ;
15467   return 0;
15468 }
15469 _ACEOF
15470 if ac_fn_c_try_compile "$LINENO"; then :
15471   ac_cv_sys_large_files=no; break
15472 fi
15473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15474   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15475 /* end confdefs.h.  */
15476 #define _LARGE_FILES 1
15477 #include <sys/types.h>
15478  /* Check that off_t can represent 2**63 - 1 correctly.
15479     We can't simply define LARGE_OFF_T to be 9223372036854775807,
15480     since some C++ compilers masquerading as C compilers
15481     incorrectly reject 9223372036854775807.  */
15482 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15483   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15484                        && LARGE_OFF_T % 2147483647 == 1)
15485                       ? 1 : -1];
15486 int
15487 main ()
15488 {
15489
15490   ;
15491   return 0;
15492 }
15493 _ACEOF
15494 if ac_fn_c_try_compile "$LINENO"; then :
15495   ac_cv_sys_large_files=1; break
15496 fi
15497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15498   ac_cv_sys_large_files=unknown
15499   break
15500 done
15501 fi
15502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15503 $as_echo "$ac_cv_sys_large_files" >&6; }
15504 case $ac_cv_sys_large_files in #(
15505   no | unknown) ;;
15506   *)
15507 cat >>confdefs.h <<_ACEOF
15508 #define _LARGE_FILES $ac_cv_sys_large_files
15509 _ACEOF
15510 ;;
15511 esac
15512 rm -rf conftest*
15513   fi
15514
15515
15516 fi
15517
15518
15519
15520
15521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC" >&5
15522 $as_echo_n "checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC... " >&6; }
15523 cache=_D_LARGEFILE_SOURCE_1
15524 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
15525   $as_echo_n "(cached) " >&6
15526 else
15527
15528 echo '
15529 #include <stdio.h>
15530 int test() {
15531         int a = fseeko(stdin, 0, 0);
15532         return a;
15533 }
15534 ' > conftest.c
15535 echo 'void f(){}' >>conftest.c
15536 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
15537 eval "cv_prog_cc_flag_needed_$cache=no"
15538 else
15539
15540 if test -z "`$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`"; then
15541 eval "cv_prog_cc_flag_needed_$cache=yes"
15542 else
15543 eval "cv_prog_cc_flag_needed_$cache=fail"
15544 #echo 'Test with flag fails too!'
15545 #cat conftest.c
15546 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15547 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15548 #exit 1
15549 fi
15550
15551 fi
15552 rm -f conftest conftest.c conftest.o
15553
15554 fi
15555
15556 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
15557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15558 $as_echo "yes" >&6; }
15559 :
15560 CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE=1"
15561 else
15562 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
15563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15564 $as_echo "no" >&6; }
15565 #echo 'Test with flag is no!'
15566 #cat conftest.c
15567 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15568 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15569 #exit 1
15570 :
15571
15572 else
15573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
15574 $as_echo "failed" >&6; }
15575 :
15576
15577 fi
15578 fi
15579
15580
15581
15582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nonblocking sockets work" >&5
15583 $as_echo_n "checking if nonblocking sockets work... " >&6; }
15584 if echo $target | grep mingw32 >/dev/null; then
15585         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (windows)" >&5
15586 $as_echo "no (windows)" >&6; }
15587
15588 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
15589
15590 else
15591 if test "$cross_compiling" = yes; then :
15592
15593         { $as_echo "$as_me:${as_lineno-$LINENO}: result: crosscompile(yes)" >&5
15594 $as_echo "crosscompile(yes)" >&6; }
15595
15596 else
15597   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15598 /* end confdefs.h.  */
15599
15600
15601 #include <stdio.h>
15602 #include <string.h>
15603 #include <stdlib.h>
15604 #include <fcntl.h>
15605 #include <errno.h>
15606 #ifdef HAVE_SYS_TYPES_H
15607 #include <sys/types.h>
15608 #endif
15609 #ifdef HAVE_SYS_SOCKET_H
15610 #include <sys/socket.h>
15611 #endif
15612 #ifdef HAVE_NETINET_IN_H
15613 #include <netinet/in.h>
15614 #endif
15615 #ifdef HAVE_ARPA_INET_H
15616 #include <arpa/inet.h>
15617 #endif
15618 #ifdef HAVE_UNISTD_H
15619 #include <unistd.h>
15620 #endif
15621 #ifdef HAVE_TIME_H
15622 #include <time.h>
15623 #endif
15624
15625 int main(void)
15626 {
15627         int port;
15628         int sfd, cfd;
15629         int num = 10;
15630         int i, p;
15631         struct sockaddr_in a;
15632         /* test if select and nonblocking reads work well together */
15633         /* open port.
15634            fork child to send 10 messages.
15635            select to read.
15636            then try to nonblocking read the 10 messages
15637            then, nonblocking read must give EAGAIN
15638         */
15639
15640         port = 12345 + (time(0)%32);
15641         sfd = socket(PF_INET, SOCK_DGRAM, 0);
15642         if(sfd == -1) {
15643                 perror("socket");
15644                 return 1;
15645         }
15646         memset(&a, 0, sizeof(a));
15647         a.sin_family = AF_INET;
15648         a.sin_port = htons(port);
15649         a.sin_addr.s_addr = inet_addr("127.0.0.1");
15650         if(bind(sfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
15651                 perror("bind");
15652                 return 1;
15653         }
15654         if(fcntl(sfd, F_SETFL, O_NONBLOCK) == -1) {
15655                 perror("fcntl");
15656                 return 1;
15657         }
15658
15659         cfd = socket(PF_INET, SOCK_DGRAM, 0);
15660         if(cfd == -1) {
15661                 perror("client socket");
15662                 return 1;
15663         }
15664         a.sin_port = 0;
15665         if(bind(cfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
15666                 perror("client bind");
15667                 return 1;
15668         }
15669         a.sin_port = htons(port);
15670
15671         /* no handler, causes exit in 10 seconds */
15672         alarm(10);
15673
15674         /* send and receive on the socket */
15675         if((p=fork()) == 0) {
15676                 for(i=0; i<num; i++) {
15677                         if(sendto(cfd, &i, sizeof(i), 0,
15678                                 (struct sockaddr*)&a, sizeof(a)) < 0) {
15679                                 perror("sendto");
15680                                 return 1;
15681                         }
15682                 }
15683         } else {
15684                 /* parent */
15685                 fd_set rset;
15686                 int x;
15687                 if(p == -1) {
15688                         perror("fork");
15689                         return 1;
15690                 }
15691                 FD_ZERO(&rset);
15692                 FD_SET(sfd, &rset);
15693                 if(select(sfd+1, &rset, NULL, NULL, NULL) < 1) {
15694                         perror("select");
15695                         return 1;
15696                 }
15697                 i = 0;
15698                 while(i < num) {
15699                         if(recv(sfd, &x, sizeof(x), 0) != sizeof(x)) {
15700                                 if(errno == EAGAIN)
15701                                         continue;
15702                                 perror("recv");
15703                                 return 1;
15704                         }
15705                         i++;
15706                 }
15707                 /* now we want to get EAGAIN: nonblocking goodness */
15708                 errno = 0;
15709                 recv(sfd, &x, sizeof(x), 0);
15710                 if(errno != EAGAIN) {
15711                         perror("trying to recv again");
15712                         return 1;
15713                 }
15714                 /* EAGAIN encountered */
15715         }
15716
15717         close(sfd);
15718         close(cfd);
15719         return 0;
15720 }
15721
15722 _ACEOF
15723 if ac_fn_c_try_run "$LINENO"; then :
15724
15725         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15726 $as_echo "yes" >&6; }
15727
15728 else
15729
15730         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15731 $as_echo "no" >&6; }
15732
15733 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
15734
15735
15736 fi
15737 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15738   conftest.$ac_objext conftest.beam conftest.$ac_ext
15739 fi
15740
15741 fi
15742
15743
15744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir has one arg" >&5
15745 $as_echo_n "checking whether mkdir has one arg... " >&6; }
15746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15747 /* end confdefs.h.  */
15748
15749 #include <stdio.h>
15750 #include <unistd.h>
15751 #ifdef HAVE_WINSOCK2_H
15752 #include <winsock2.h>
15753 #endif
15754 #ifdef HAVE_SYS_STAT_H
15755 #include <sys/stat.h>
15756 #endif
15757
15758 int
15759 main ()
15760 {
15761
15762         (void)mkdir("directory");
15763
15764   ;
15765   return 0;
15766 }
15767 _ACEOF
15768 if ac_fn_c_try_compile "$LINENO"; then :
15769   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15770 $as_echo "yes" >&6; }
15771
15772 $as_echo "#define MKDIR_HAS_ONE_ARG 1" >>confdefs.h
15773
15774
15775 else
15776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15777 $as_echo "no" >&6; }
15778
15779 fi
15780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15781
15782 for ac_func in strptime
15783 do :
15784   ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
15785 if test "x$ac_cv_func_strptime" = xyes; then :
15786   cat >>confdefs.h <<_ACEOF
15787 #define HAVE_STRPTIME 1
15788 _ACEOF
15789
15790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strptime works" >&5
15791 $as_echo_n "checking whether strptime works... " >&6; }
15792 if test c${cross_compiling} = cno; then
15793 if test "$cross_compiling" = yes; then :
15794   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15795 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15796 as_fn_error $? "cannot run test program while cross compiling
15797 See \`config.log' for more details" "$LINENO" 5; }
15798 else
15799   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15800 /* end confdefs.h.  */
15801
15802 #define _XOPEN_SOURCE 600
15803 #include <time.h>
15804 int main(void) { struct tm tm; char *res;
15805 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);
15806 if (!res) return 2;
15807 res = strptime("20070207111842", "%Y%m%d%H%M%S", &tm);
15808 if (!res) return 1; return 0; }
15809
15810 _ACEOF
15811 if ac_fn_c_try_run "$LINENO"; then :
15812   eval "ac_cv_c_strptime_works=yes"
15813 else
15814   eval "ac_cv_c_strptime_works=no"
15815 fi
15816 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15817   conftest.$ac_objext conftest.beam conftest.$ac_ext
15818 fi
15819
15820 else
15821 eval "ac_cv_c_strptime_works=maybe"
15822 fi
15823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_strptime_works" >&5
15824 $as_echo "$ac_cv_c_strptime_works" >&6; }
15825 if test $ac_cv_c_strptime_works = no; then
15826 case " $LIBOBJS " in
15827   *" strptime.$ac_objext "* ) ;;
15828   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
15829  ;;
15830 esac
15831
15832 else
15833
15834 cat >>confdefs.h <<_ACEOF
15835 #define STRPTIME_WORKS 1
15836 _ACEOF
15837
15838 fi
15839
15840 else
15841   case " $LIBOBJS " in
15842   *" strptime.$ac_objext "* ) ;;
15843   *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
15844  ;;
15845 esac
15846
15847 fi
15848 done
15849
15850
15851 # set memory allocation checking if requested
15852 # Check whether --enable-alloc-checks was given.
15853 if test "${enable_alloc_checks+set}" = set; then :
15854   enableval=$enable_alloc_checks;
15855 fi
15856
15857 # Check whether --enable-alloc-lite was given.
15858 if test "${enable_alloc_lite+set}" = set; then :
15859   enableval=$enable_alloc_lite;
15860 fi
15861
15862 # Check whether --enable-alloc-nonregional was given.
15863 if test "${enable_alloc_nonregional+set}" = set; then :
15864   enableval=$enable_alloc_nonregional;
15865 fi
15866
15867 if test x_$enable_alloc_nonregional = x_yes; then
15868
15869 $as_echo "#define UNBOUND_ALLOC_NONREGIONAL 1" >>confdefs.h
15870
15871 fi
15872 if test x_$enable_alloc_checks = x_yes; then
15873
15874 $as_echo "#define UNBOUND_ALLOC_STATS 1" >>confdefs.h
15875
15876 else
15877         if test x_$enable_alloc_lite = x_yes; then
15878
15879 $as_echo "#define UNBOUND_ALLOC_LITE 1" >>confdefs.h
15880
15881         else
15882
15883         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
15884 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
15885         if test "$cross_compiling" = yes; then :
15886   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (crosscompile)" >&5
15887 $as_echo "no (crosscompile)" >&6; }
15888         case " $LIBOBJS " in
15889   *" malloc.$ac_objext "* ) ;;
15890   *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
15891  ;;
15892 esac
15893
15894
15895 cat >>confdefs.h <<_ACEOF
15896 #define malloc rpl_malloc_unbound
15897 _ACEOF
15898
15899 else
15900   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15901 /* end confdefs.h.  */
15902 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
15903 #include <stdlib.h>
15904 #else
15905 char *malloc ();
15906 #endif
15907
15908 int
15909 main ()
15910 {
15911  if(malloc(0) != 0) return 1;
15912   ;
15913   return 0;
15914 }
15915
15916 _ACEOF
15917 if ac_fn_c_try_run "$LINENO"; then :
15918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15919 $as_echo "no" >&6; }
15920         case " $LIBOBJS " in
15921   *" malloc.$ac_objext "* ) ;;
15922   *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
15923  ;;
15924 esac
15925
15926
15927 cat >>confdefs.h <<_ACEOF
15928 #define malloc rpl_malloc_unbound
15929 _ACEOF
15930
15931 else
15932   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15933 $as_echo "yes" >&6; }
15934
15935 $as_echo "#define HAVE_MALLOC 1" >>confdefs.h
15936
15937 fi
15938 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15939   conftest.$ac_objext conftest.beam conftest.$ac_ext
15940 fi
15941
15942
15943         fi
15944 fi
15945
15946 # check windows threads (we use them, not pthreads, on windows).
15947 if test "$on_mingw" = "yes"; then
15948 # check windows threads
15949         for ac_header in windows.h
15950 do :
15951   ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
15952 "
15953 if test "x$ac_cv_header_windows_h" = xyes; then :
15954   cat >>confdefs.h <<_ACEOF
15955 #define HAVE_WINDOWS_H 1
15956 _ACEOF
15957
15958 fi
15959
15960 done
15961
15962         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CreateThread" >&5
15963 $as_echo_n "checking for CreateThread... " >&6; }
15964         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15965 /* end confdefs.h.  */
15966
15967 #ifdef HAVE_WINDOWS_H
15968 #include <windows.h>
15969 #endif
15970
15971 int
15972 main ()
15973 {
15974
15975         HANDLE t = CreateThread(NULL, 0, NULL, NULL, 0, NULL);
15976
15977   ;
15978   return 0;
15979 }
15980 _ACEOF
15981 if ac_fn_c_try_compile "$LINENO"; then :
15982   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15983 $as_echo "yes" >&6; }
15984
15985 $as_echo "#define HAVE_WINDOWS_THREADS 1" >>confdefs.h
15986
15987
15988 else
15989   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15990 $as_echo "no" >&6; }
15991
15992 fi
15993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15994
15995 else
15996 # not on mingw, check thread libraries.
15997
15998 # check for thread library.
15999 # check this first, so that the pthread lib does not get linked in via
16000 # libssl or libpython, and thus distorts the tests, and we end up using
16001 # the non-threadsafe C libraries.
16002
16003 # Check whether --with-pthreads was given.
16004 if test "${with_pthreads+set}" = set; then :
16005   withval=$with_pthreads;
16006 else
16007    withval="yes"
16008 fi
16009
16010 ub_have_pthreads=no
16011 if test x_$withval != x_no; then
16012
16013
16014 ac_ext=c
16015 ac_cpp='$CPP $CPPFLAGS'
16016 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16017 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16018 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16019
16020 ax_pthread_ok=no
16021
16022 # We used to check for pthread.h first, but this fails if pthread.h
16023 # requires special compiler flags (e.g. on True64 or Sequent).
16024 # It gets checked for in the link test anyway.
16025
16026 # First of all, check if the user has set any of the PTHREAD_LIBS,
16027 # etcetera environment variables, and if threads linking works using
16028 # them:
16029 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16030         save_CFLAGS="$CFLAGS"
16031         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16032         save_LIBS="$LIBS"
16033         LIBS="$PTHREAD_LIBS $LIBS"
16034         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16035 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
16036         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16037 /* end confdefs.h.  */
16038
16039 /* Override any GCC internal prototype to avoid an error.
16040    Use char because int might match the return type of a GCC
16041    builtin and then its argument prototype would still apply.  */
16042 #ifdef __cplusplus
16043 extern "C"
16044 #endif
16045 char pthread_join ();
16046 int
16047 main ()
16048 {
16049 return pthread_join ();
16050   ;
16051   return 0;
16052 }
16053 _ACEOF
16054 if ac_fn_c_try_link "$LINENO"; then :
16055   ax_pthread_ok=yes
16056 fi
16057 rm -f core conftest.err conftest.$ac_objext \
16058     conftest$ac_exeext conftest.$ac_ext
16059         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16060 $as_echo "$ax_pthread_ok" >&6; }
16061         if test x"$ax_pthread_ok" = xno; then
16062                 PTHREAD_LIBS=""
16063                 PTHREAD_CFLAGS=""
16064         fi
16065         LIBS="$save_LIBS"
16066         CFLAGS="$save_CFLAGS"
16067 fi
16068
16069 # We must check for the threads library under a number of different
16070 # names; the ordering is very important because some systems
16071 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16072 # libraries is broken (non-POSIX).
16073
16074 # Create a list of thread flags to try.  Items starting with a "-" are
16075 # C compiler flags, and other items are library names, except for "none"
16076 # which indicates that we try without any flags at all, and "pthread-config"
16077 # which is a program returning the flags for the Pth emulation library.
16078
16079 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
16080
16081 # The ordering *is* (sometimes) important.  Some notes on the
16082 # individual items follow:
16083
16084 # pthreads: AIX (must check this before -lpthread)
16085 # none: in case threads are in libc; should be tried before -Kthread and
16086 #       other compiler flags to prevent continual compiler warnings
16087 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16088 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16089 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16090 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16091 # -pthreads: Solaris/gcc
16092 # -mthreads: Mingw32/gcc, Lynx/gcc
16093 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16094 #      doesn't hurt to check since this sometimes defines pthreads too;
16095 #      also defines -D_REENTRANT)
16096 #      ... -mt is also the pthreads flag for HP/aCC
16097 # pthread: Linux, etcetera
16098 # --thread-safe: KAI C++
16099 # pthread-config: use pthread-config program (for GNU Pth library)
16100
16101 case ${host_os} in
16102         solaris*)
16103
16104         # On Solaris (at least, for some versions), libc contains stubbed
16105         # (non-functional) versions of the pthreads routines, so link-based
16106         # tests will erroneously succeed.  (We need to link with -pthreads/-mt/
16107         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
16108         # a function called by this macro, so we could check for that, but
16109         # who knows whether they'll stub that too in a future libc.)  So,
16110         # we'll just look for -pthreads and -lpthread first:
16111
16112         ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
16113         ;;
16114
16115         darwin*)
16116         ax_pthread_flags="-pthread $ax_pthread_flags"
16117         ;;
16118 esac
16119
16120 # Clang doesn't consider unrecognized options an error unless we specify
16121 # -Werror. We throw in some extra Clang-specific options to ensure that
16122 # this doesn't happen for GCC, which also accepts -Werror.
16123
16124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs -Werror to reject unknown flags" >&5
16125 $as_echo_n "checking if compiler needs -Werror to reject unknown flags... " >&6; }
16126 save_CFLAGS="$CFLAGS"
16127 ax_pthread_extra_flags="-Werror"
16128 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wunknown-warning-option -Wsizeof-array-argument"
16129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16130 /* end confdefs.h.  */
16131 int foo(void);
16132 int
16133 main ()
16134 {
16135 foo()
16136   ;
16137   return 0;
16138 }
16139 _ACEOF
16140 if ac_fn_c_try_compile "$LINENO"; then :
16141   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16142 $as_echo "yes" >&6; }
16143 else
16144   ax_pthread_extra_flags=
16145                    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16146 $as_echo "no" >&6; }
16147 fi
16148 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16149 CFLAGS="$save_CFLAGS"
16150
16151 if test x"$ax_pthread_ok" = xno; then
16152 for flag in $ax_pthread_flags; do
16153
16154         case $flag in
16155                 none)
16156                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
16157 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
16158                 ;;
16159
16160                 -*)
16161                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
16162 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
16163                 PTHREAD_CFLAGS="$flag"
16164                 ;;
16165
16166                 pthread-config)
16167                 # Extract the first word of "pthread-config", so it can be a program name with args.
16168 set dummy pthread-config; ac_word=$2
16169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16170 $as_echo_n "checking for $ac_word... " >&6; }
16171 if ${ac_cv_prog_ax_pthread_config+:} false; then :
16172   $as_echo_n "(cached) " >&6
16173 else
16174   if test -n "$ax_pthread_config"; then
16175   ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
16176 else
16177 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16178 for as_dir in $PATH
16179 do
16180   IFS=$as_save_IFS
16181   test -z "$as_dir" && as_dir=.
16182     for ac_exec_ext in '' $ac_executable_extensions; do
16183   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16184     ac_cv_prog_ax_pthread_config="yes"
16185     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16186     break 2
16187   fi
16188 done
16189   done
16190 IFS=$as_save_IFS
16191
16192   test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
16193 fi
16194 fi
16195 ax_pthread_config=$ac_cv_prog_ax_pthread_config
16196 if test -n "$ax_pthread_config"; then
16197   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
16198 $as_echo "$ax_pthread_config" >&6; }
16199 else
16200   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16201 $as_echo "no" >&6; }
16202 fi
16203
16204
16205                 if test x"$ax_pthread_config" = xno; then continue; fi
16206                 PTHREAD_CFLAGS="`pthread-config --cflags`"
16207                 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16208                 ;;
16209
16210                 *)
16211                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
16212 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
16213                 PTHREAD_LIBS="-l$flag"
16214                 ;;
16215         esac
16216
16217         save_LIBS="$LIBS"
16218         save_CFLAGS="$CFLAGS"
16219         LIBS="$PTHREAD_LIBS $LIBS"
16220         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
16221
16222         # Check for various functions.  We must include pthread.h,
16223         # since some functions may be macros.  (On the Sequent, we
16224         # need a special flag -Kthread to make this header compile.)
16225         # We check for pthread_join because it is in -lpthread on IRIX
16226         # while pthread_create is in libc.  We check for pthread_attr_init
16227         # due to DEC craziness with -lpthreads.  We check for
16228         # pthread_cleanup_push because it is one of the few pthread
16229         # functions on Solaris that doesn't have a non-functional libc stub.
16230         # We try pthread_create on general principles.
16231         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16232 /* end confdefs.h.  */
16233 #include <pthread.h>
16234                         static void routine(void *a) { *((int*)a) = 0; }
16235                         static void *start_routine(void *a) { return a; }
16236 int
16237 main ()
16238 {
16239 pthread_t th; pthread_attr_t attr;
16240                         pthread_create(&th, 0, start_routine, 0);
16241                         pthread_join(th, 0);
16242                         pthread_attr_init(&attr);
16243                         pthread_cleanup_push(routine, 0);
16244                         pthread_cleanup_pop(0) /* ; */
16245   ;
16246   return 0;
16247 }
16248 _ACEOF
16249 if ac_fn_c_try_link "$LINENO"; then :
16250   ax_pthread_ok=yes
16251 fi
16252 rm -f core conftest.err conftest.$ac_objext \
16253     conftest$ac_exeext conftest.$ac_ext
16254
16255         LIBS="$save_LIBS"
16256         CFLAGS="$save_CFLAGS"
16257
16258         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16259 $as_echo "$ax_pthread_ok" >&6; }
16260         if test "x$ax_pthread_ok" = xyes; then
16261                 break;
16262         fi
16263
16264         PTHREAD_LIBS=""
16265         PTHREAD_CFLAGS=""
16266 done
16267 fi
16268
16269 # Various other checks:
16270 if test "x$ax_pthread_ok" = xyes; then
16271         save_LIBS="$LIBS"
16272         LIBS="$PTHREAD_LIBS $LIBS"
16273         save_CFLAGS="$CFLAGS"
16274         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16275
16276         # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
16277         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
16278 $as_echo_n "checking for joinable pthread attribute... " >&6; }
16279         attr_name=unknown
16280         for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
16281             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16282 /* end confdefs.h.  */
16283 #include <pthread.h>
16284 int
16285 main ()
16286 {
16287 int attr = $attr; return attr /* ; */
16288   ;
16289   return 0;
16290 }
16291 _ACEOF
16292 if ac_fn_c_try_link "$LINENO"; then :
16293   attr_name=$attr; break
16294 fi
16295 rm -f core conftest.err conftest.$ac_objext \
16296     conftest$ac_exeext conftest.$ac_ext
16297         done
16298         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
16299 $as_echo "$attr_name" >&6; }
16300         if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
16301
16302 cat >>confdefs.h <<_ACEOF
16303 #define PTHREAD_CREATE_JOINABLE $attr_name
16304 _ACEOF
16305
16306         fi
16307
16308         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
16309 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
16310         flag=no
16311         case ${host_os} in
16312             aix* | freebsd* | darwin*) flag="-D_THREAD_SAFE";;
16313             osf* | hpux*) flag="-D_REENTRANT";;
16314             solaris*)
16315             if test "$GCC" = "yes"; then
16316                 flag="-D_REENTRANT"
16317             else
16318                 # TODO: What about Clang on Solaris?
16319                 flag="-mt -D_REENTRANT"
16320             fi
16321             ;;
16322         esac
16323         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $flag" >&5
16324 $as_echo "$flag" >&6; }
16325         if test "x$flag" != xno; then
16326             PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16327         fi
16328
16329         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
16330 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
16331 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
16332   $as_echo_n "(cached) " >&6
16333 else
16334
16335                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16336 /* end confdefs.h.  */
16337 #include <pthread.h>
16338 int
16339 main ()
16340 {
16341 int i = PTHREAD_PRIO_INHERIT;
16342   ;
16343   return 0;
16344 }
16345 _ACEOF
16346 if ac_fn_c_try_link "$LINENO"; then :
16347   ax_cv_PTHREAD_PRIO_INHERIT=yes
16348 else
16349   ax_cv_PTHREAD_PRIO_INHERIT=no
16350 fi
16351 rm -f core conftest.err conftest.$ac_objext \
16352     conftest$ac_exeext conftest.$ac_ext
16353
16354 fi
16355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
16356 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
16357         if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
16358
16359 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
16360
16361 fi
16362
16363         LIBS="$save_LIBS"
16364         CFLAGS="$save_CFLAGS"
16365
16366         # More AIX lossage: compile with *_r variant
16367         if test "x$GCC" != xyes; then
16368             case $host_os in
16369                 aix*)
16370                 case "x/$CC" in #(
16371   x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
16372     #handle absolute path differently from PATH based program lookup
16373                    case "x$CC" in #(
16374   x/*) :
16375     if as_fn_executable_p ${CC}_r; then :
16376   PTHREAD_CC="${CC}_r"
16377 fi ;; #(
16378   *) :
16379     for ac_prog in ${CC}_r
16380 do
16381   # Extract the first word of "$ac_prog", so it can be a program name with args.
16382 set dummy $ac_prog; ac_word=$2
16383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16384 $as_echo_n "checking for $ac_word... " >&6; }
16385 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
16386   $as_echo_n "(cached) " >&6
16387 else
16388   if test -n "$PTHREAD_CC"; then
16389   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16390 else
16391 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16392 for as_dir in $PATH
16393 do
16394   IFS=$as_save_IFS
16395   test -z "$as_dir" && as_dir=.
16396     for ac_exec_ext in '' $ac_executable_extensions; do
16397   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16398     ac_cv_prog_PTHREAD_CC="$ac_prog"
16399     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16400     break 2
16401   fi
16402 done
16403   done
16404 IFS=$as_save_IFS
16405
16406 fi
16407 fi
16408 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16409 if test -n "$PTHREAD_CC"; then
16410   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
16411 $as_echo "$PTHREAD_CC" >&6; }
16412 else
16413   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16414 $as_echo "no" >&6; }
16415 fi
16416
16417
16418   test -n "$PTHREAD_CC" && break
16419 done
16420 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
16421  ;;
16422 esac ;; #(
16423   *) :
16424      ;;
16425 esac
16426                 ;;
16427             esac
16428         fi
16429 fi
16430
16431 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
16432
16433
16434
16435
16436
16437 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16438 if test x"$ax_pthread_ok" = xyes; then
16439
16440
16441 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
16442
16443                 LIBS="$PTHREAD_LIBS $LIBS"
16444                 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16445                 CC="$PTHREAD_CC"
16446                 ub_have_pthreads=yes
16447                 ac_fn_c_check_type "$LINENO" "pthread_spinlock_t" "ac_cv_type_pthread_spinlock_t" "#include <pthread.h>
16448 "
16449 if test "x$ac_cv_type_pthread_spinlock_t" = xyes; then :
16450
16451 cat >>confdefs.h <<_ACEOF
16452 #define HAVE_PTHREAD_SPINLOCK_T 1
16453 _ACEOF
16454
16455
16456 fi
16457 ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
16458 "
16459 if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then :
16460
16461 cat >>confdefs.h <<_ACEOF
16462 #define HAVE_PTHREAD_RWLOCK_T 1
16463 _ACEOF
16464
16465
16466 fi
16467
16468
16469                 if echo "$CFLAGS" | $GREP -e "-pthread" >/dev/null; then
16470                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread unused during linking" >&5
16471 $as_echo_n "checking if -pthread unused during linking... " >&6; }
16472                 # catch clang warning 'argument unused during compilation'
16473                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16474 /* end confdefs.h.  */
16475 $ac_includes_default
16476
16477 int main(void) {return 0;}
16478
16479 _ACEOF
16480                 pthread_unused="yes"
16481                 # first compile
16482                 echo "$CC $CFLAGS -c conftest.c -o conftest.o" >&5
16483                 $CC $CFLAGS -c conftest.c -o conftest.o 2>&5 >&5
16484                 if test $? = 0; then
16485                         # then link
16486                         echo "$CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest contest.o" >&5
16487                         $CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest conftest.o 2>&5 >&5
16488                         if test $? -ne 0; then
16489                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16490 $as_echo "yes" >&6; }
16491                                 CFLAGS=`echo "$CFLAGS" | sed -e 's/-pthread//'`
16492                                 PTHREAD_CFLAGS_ONLY="-pthread"
16493
16494                         else
16495                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16496 $as_echo "no" >&6; }
16497                         fi
16498                 else
16499                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16500 $as_echo "no" >&6; }
16501                 fi # endif cc successful
16502                 rm -f conftest conftest.c conftest.o
16503                 fi # endif -pthread in CFLAGS
16504
16505
16506         :
16507 else
16508         ax_pthread_ok=no
16509
16510 fi
16511 ac_ext=c
16512 ac_cpp='$CPP $CPPFLAGS'
16513 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16514 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16515 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16516
16517
16518 fi
16519
16520 # check solaris thread library
16521
16522 # Check whether --with-solaris-threads was given.
16523 if test "${with_solaris_threads+set}" = set; then :
16524   withval=$with_solaris_threads;
16525 else
16526    withval="no"
16527 fi
16528
16529 ub_have_sol_threads=no
16530 if test x_$withval != x_no; then
16531         if test x_$ub_have_pthreads != x_no; then
16532             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&5
16533 $as_echo "$as_me: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&2;}
16534         else
16535         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing thr_create" >&5
16536 $as_echo_n "checking for library containing thr_create... " >&6; }
16537 if ${ac_cv_search_thr_create+:} false; then :
16538   $as_echo_n "(cached) " >&6
16539 else
16540   ac_func_search_save_LIBS=$LIBS
16541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16542 /* end confdefs.h.  */
16543
16544 /* Override any GCC internal prototype to avoid an error.
16545    Use char because int might match the return type of a GCC
16546    builtin and then its argument prototype would still apply.  */
16547 #ifdef __cplusplus
16548 extern "C"
16549 #endif
16550 char thr_create ();
16551 int
16552 main ()
16553 {
16554 return thr_create ();
16555   ;
16556   return 0;
16557 }
16558 _ACEOF
16559 for ac_lib in '' thread; do
16560   if test -z "$ac_lib"; then
16561     ac_res="none required"
16562   else
16563     ac_res=-l$ac_lib
16564     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16565   fi
16566   if ac_fn_c_try_link "$LINENO"; then :
16567   ac_cv_search_thr_create=$ac_res
16568 fi
16569 rm -f core conftest.err conftest.$ac_objext \
16570     conftest$ac_exeext
16571   if ${ac_cv_search_thr_create+:} false; then :
16572   break
16573 fi
16574 done
16575 if ${ac_cv_search_thr_create+:} false; then :
16576
16577 else
16578   ac_cv_search_thr_create=no
16579 fi
16580 rm conftest.$ac_ext
16581 LIBS=$ac_func_search_save_LIBS
16582 fi
16583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_thr_create" >&5
16584 $as_echo "$ac_cv_search_thr_create" >&6; }
16585 ac_res=$ac_cv_search_thr_create
16586 if test "$ac_res" != no; then :
16587   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
16588
16589
16590 $as_echo "#define HAVE_SOLARIS_THREADS 1" >>confdefs.h
16591
16592
16593
16594
16595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -mt" >&5
16596 $as_echo_n "checking whether $CC supports -mt... " >&6; }
16597 cache=`echo mt | sed 'y%.=/+-%___p_%'`
16598 if eval \${cv_prog_cc_flag_$cache+:} false; then :
16599   $as_echo_n "(cached) " >&6
16600 else
16601
16602 echo 'void f(void){}' >conftest.c
16603 if test -z "`$CC $CPPFLAGS $CFLAGS -mt -c conftest.c 2>&1`"; then
16604 eval "cv_prog_cc_flag_$cache=yes"
16605 else
16606 eval "cv_prog_cc_flag_$cache=no"
16607 fi
16608 rm -f conftest conftest.o conftest.c
16609
16610 fi
16611
16612 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
16613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16614 $as_echo "yes" >&6; }
16615 :
16616 CFLAGS="$CFLAGS -mt"
16617 else
16618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16619 $as_echo "no" >&6; }
16620 :
16621 CFLAGS="$CFLAGS -D_REENTRANT"
16622 fi
16623
16624                 ub_have_sol_threads=yes
16625
16626 else
16627
16628                 as_fn_error $? "no solaris threads found." "$LINENO" 5
16629
16630 fi
16631
16632         fi
16633 fi
16634
16635 fi # end of non-mingw check of thread libraries
16636
16637 # Check for PyUnbound
16638
16639 # Check whether --with-pyunbound was given.
16640 if test "${with_pyunbound+set}" = set; then :
16641   withval=$with_pyunbound;
16642 else
16643    withval="no"
16644 fi
16645
16646
16647 ub_test_python=no
16648 ub_with_pyunbound=no
16649 if test x_$withval != x_no; then
16650    ub_with_pyunbound=yes
16651    ub_test_python=yes
16652 fi
16653
16654 # Check for Python module
16655
16656 # Check whether --with-pythonmodule was given.
16657 if test "${with_pythonmodule+set}" = set; then :
16658   withval=$with_pythonmodule;
16659 else
16660    withval="no"
16661 fi
16662
16663
16664 ub_with_pythonmod=no
16665 if test x_$withval != x_no; then
16666    ub_with_pythonmod=yes
16667    ub_test_python=yes
16668 fi
16669
16670 # Check for Python & SWIG only on PyUnbound or PyModule
16671 if test x_$ub_test_python != x_no; then
16672
16673    # Check for Python
16674    ub_have_python=no
16675    ac_save_LIBS="$LIBS"
16676         #
16677         # Allow the use of a (user set) custom python version
16678         #
16679
16680
16681         # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
16682 set dummy python$PYTHON_VERSION; ac_word=$2
16683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16684 $as_echo_n "checking for $ac_word... " >&6; }
16685 if ${ac_cv_path_PYTHON+:} false; then :
16686   $as_echo_n "(cached) " >&6
16687 else
16688   case $PYTHON in
16689   [\\/]* | ?:[\\/]*)
16690   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
16691   ;;
16692   *)
16693   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16694 for as_dir in $PATH
16695 do
16696   IFS=$as_save_IFS
16697   test -z "$as_dir" && as_dir=.
16698     for ac_exec_ext in '' $ac_executable_extensions; do
16699   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16700     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
16701     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16702     break 2
16703   fi
16704 done
16705   done
16706 IFS=$as_save_IFS
16707
16708   ;;
16709 esac
16710 fi
16711 PYTHON=$ac_cv_path_PYTHON
16712 if test -n "$PYTHON"; then
16713   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
16714 $as_echo "$PYTHON" >&6; }
16715 else
16716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16717 $as_echo "no" >&6; }
16718 fi
16719
16720
16721         if test -z "$PYTHON"; then
16722            as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
16723            PYTHON_VERSION=""
16724         fi
16725
16726         if test -z "$PYTHON_VERSION"; then
16727                 PYTHON_VERSION=`$PYTHON -c "import sys; \
16728                         print(sys.version.split()[0])"`
16729         fi
16730
16731         #
16732         # Check if you have distutils, else fail
16733         #
16734         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
16735 $as_echo_n "checking for the distutils Python package... " >&6; }
16736         if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then
16737                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16738 $as_echo "yes" >&6; }
16739         else
16740                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16741 $as_echo "no" >&6; }
16742                 as_fn_error $? "cannot import Python module \"distutils\".
16743 Please check your Python installation. The error was:
16744 $ac_distutils_result" "$LINENO" 5
16745                 PYTHON_VERSION=""
16746         fi
16747
16748         #
16749         # Check for Python include path
16750         #
16751         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
16752 $as_echo_n "checking for Python include path... " >&6; }
16753         if test -z "$PYTHON_CPPFLAGS"; then
16754                 python_path=`$PYTHON -c "import distutils.sysconfig; \
16755                         print(distutils.sysconfig.get_python_inc());"`
16756                 if test -n "${python_path}"; then
16757                         python_path="-I$python_path"
16758                 fi
16759                 PYTHON_CPPFLAGS=$python_path
16760         fi
16761         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
16762 $as_echo "$PYTHON_CPPFLAGS" >&6; }
16763
16764
16765         #
16766         # Check for Python library path
16767         #
16768         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
16769 $as_echo_n "checking for Python library path... " >&6; }
16770         if test -z "$PYTHON_LDFLAGS"; then
16771                 PYTHON_LDFLAGS=`$PYTHON -c "from distutils.sysconfig import *; \
16772                         print('-L'+get_config_var('LIBDIR')+' -L'+get_config_var('LIBDEST')+' '+get_config_var('BLDLIBRARY'));"`
16773         fi
16774         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
16775 $as_echo "$PYTHON_LDFLAGS" >&6; }
16776
16777
16778         #
16779         # Check for site packages
16780         #
16781         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
16782 $as_echo_n "checking for Python site-packages path... " >&6; }
16783         if test -z "$PYTHON_SITE_PKG"; then
16784                 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
16785                         print(distutils.sysconfig.get_python_lib(1,0));"`
16786         fi
16787         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
16788 $as_echo "$PYTHON_SITE_PKG" >&6; }
16789
16790
16791         #
16792         # final check to see if everything compiles alright
16793         #
16794         { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
16795 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
16796         ac_ext=c
16797 ac_cpp='$CPP $CPPFLAGS'
16798 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16799 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16800 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16801
16802         # save current global flags
16803         ac_save_LIBS="$LIBS"
16804         ac_save_CPPFLAGS="$CPPFLAGS"
16805
16806         LIBS="$LIBS $PYTHON_LDFLAGS"
16807         CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
16808         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16809 /* end confdefs.h.  */
16810
16811                 #include <Python.h>
16812
16813 int
16814 main ()
16815 {
16816
16817                 Py_Initialize();
16818
16819   ;
16820   return 0;
16821 }
16822 _ACEOF
16823 if ac_fn_c_try_link "$LINENO"; then :
16824   pythonexists=yes
16825 else
16826   pythonexists=no
16827 fi
16828 rm -f core conftest.err conftest.$ac_objext \
16829     conftest$ac_exeext conftest.$ac_ext
16830
16831         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
16832 $as_echo "$pythonexists" >&6; }
16833
16834         if test ! "$pythonexists" = "yes"; then
16835            as_fn_error $? "
16836   Could not link test program to Python. Maybe the main Python library has been
16837   installed in some non-standard library path. If so, pass it to configure,
16838   via the LDFLAGS environment variable.
16839   Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
16840   ============================================================================
16841    ERROR!
16842    You probably have to install the development version of the Python package
16843    for your distribution.  The exact name of this package varies among them.
16844   ============================================================================
16845            " "$LINENO" 5
16846           PYTHON_VERSION=""
16847         fi
16848         ac_ext=c
16849 ac_cpp='$CPP $CPPFLAGS'
16850 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16851 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16852 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16853
16854         # turn back to default flags
16855         CPPFLAGS="$ac_save_CPPFLAGS"
16856         LIBS="$ac_save_LIBS"
16857
16858         #
16859         # all done!
16860         #
16861
16862    if test ! -z "$PYTHON_VERSION"; then
16863         if test `$PYTHON -c "print('$PYTHON_VERSION' >= '2.4.0')"` = "False"; then
16864                 as_fn_error $? "Python version >= 2.4.0 is required" "$LINENO" 5
16865         fi
16866
16867       PY_MAJOR_VERSION="`$PYTHON -c \"import sys; print(sys.version_info[0])\"`"
16868
16869       # Have Python
16870
16871 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
16872
16873       LIBS="$PYTHON_LDFLAGS $LIBS"
16874       CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
16875       ub_have_python=yes
16876       PC_PY_DEPENDENCY="python"
16877
16878
16879       # Check for SWIG
16880       ub_have_swig=no
16881
16882         # Extract the first word of "swig", so it can be a program name with args.
16883 set dummy swig; ac_word=$2
16884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16885 $as_echo_n "checking for $ac_word... " >&6; }
16886 if ${ac_cv_path_SWIG+:} false; then :
16887   $as_echo_n "(cached) " >&6
16888 else
16889   case $SWIG in
16890   [\\/]* | ?:[\\/]*)
16891   ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
16892   ;;
16893   *)
16894   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16895 for as_dir in $PATH
16896 do
16897   IFS=$as_save_IFS
16898   test -z "$as_dir" && as_dir=.
16899     for ac_exec_ext in '' $ac_executable_extensions; do
16900   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16901     ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
16902     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16903     break 2
16904   fi
16905 done
16906   done
16907 IFS=$as_save_IFS
16908
16909   ;;
16910 esac
16911 fi
16912 SWIG=$ac_cv_path_SWIG
16913 if test -n "$SWIG"; then
16914   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
16915 $as_echo "$SWIG" >&6; }
16916 else
16917   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16918 $as_echo "no" >&6; }
16919 fi
16920
16921
16922         if test -z "$SWIG" ; then
16923                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
16924 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
16925                 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
16926         elif test -n "2.0.1" ; then
16927                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
16928 $as_echo_n "checking for SWIG version... " >&6; }
16929                 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'`
16930                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
16931 $as_echo "$swig_version" >&6; }
16932                 if test -n "$swig_version" ; then
16933                         # Calculate the required version number components
16934                         required=2.0.1
16935                         required_major=`echo $required | sed 's/[^0-9].*//'`
16936                         if test -z "$required_major" ; then
16937                                 required_major=0
16938                         fi
16939                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
16940                         required_minor=`echo $required | sed 's/[^0-9].*//'`
16941                         if test -z "$required_minor" ; then
16942                                 required_minor=0
16943                         fi
16944                         required=`echo $required | sed 's/[0-9]*[^0-9]//'`
16945                         required_patch=`echo $required | sed 's/[^0-9].*//'`
16946                         if test -z "$required_patch" ; then
16947                                 required_patch=0
16948                         fi
16949                         # Calculate the available version number components
16950                         available=$swig_version
16951                         available_major=`echo $available | sed 's/[^0-9].*//'`
16952                         if test -z "$available_major" ; then
16953                                 available_major=0
16954                         fi
16955                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
16956                         available_minor=`echo $available | sed 's/[^0-9].*//'`
16957                         if test -z "$available_minor" ; then
16958                                 available_minor=0
16959                         fi
16960                         available=`echo $available | sed 's/[0-9]*[^0-9]//'`
16961                         available_patch=`echo $available | sed 's/[^0-9].*//'`
16962                         if test -z "$available_patch" ; then
16963                                 available_patch=0
16964                         fi
16965                         badversion=0
16966                         if test $available_major -lt $required_major ; then
16967                                 badversion=1
16968                         fi
16969                         if test $available_major -eq $required_major \
16970                                 -a $available_minor -lt $required_minor ; then
16971                                 badversion=1
16972                         fi
16973                         if test $available_major -eq $required_major \
16974                                 -a $available_minor -eq $required_minor \
16975                                 -a $available_patch -lt $required_patch ; then
16976                                 badversion=1
16977                         fi
16978                         if test $badversion -eq 1 ; then
16979                                 { $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
16980 $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;}
16981                                 SWIG='echo "Error: SWIG version >= 2.0.1 is required.  You have '"$swig_version"'.  You should look at http://www.swig.org" ; false'
16982                         else
16983                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
16984 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
16985                                 SWIG_LIB=`$SWIG -swiglib`
16986                                 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
16987 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
16988                         fi
16989                 else
16990                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
16991 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
16992                         SWIG='echo "Error: Cannot determine SWIG version.  You should look at http://www.swig.org" ; false'
16993                 fi
16994         fi
16995
16996
16997       { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG" >&5
16998 $as_echo_n "checking SWIG... " >&6; }
16999       if test ! -x "$SWIG"; then
17000          as_fn_error $? "failed to find swig tool, install it, or do not build Python module and PyUnbound" "$LINENO" 5
17001       else
17002
17003 $as_echo "#define HAVE_SWIG 1" >>confdefs.h
17004
17005          swig="$SWIG"
17006
17007          { $as_echo "$as_me:${as_lineno-$LINENO}: result: present" >&5
17008 $as_echo "present" >&6; }
17009
17010          # If have Python & SWIG
17011          # Declare PythonMod
17012          if test x_$ub_with_pythonmod != x_no; then
17013
17014 $as_echo "#define WITH_PYTHONMODULE 1" >>confdefs.h
17015
17016             WITH_PYTHONMODULE=yes
17017
17018             PYTHONMOD_OBJ="pythonmod.lo pythonmod_utils.lo"
17019
17020             PYTHONMOD_HEADER='$(srcdir)/pythonmod/pythonmod.h'
17021
17022             PYTHONMOD_INSTALL=pythonmod-install
17023
17024             PYTHONMOD_UNINSTALL=pythonmod-uninstall
17025
17026          fi
17027
17028          # Declare PyUnbound
17029          if test x_$ub_with_pyunbound != x_no; then
17030
17031 $as_echo "#define WITH_PYUNBOUND 1" >>confdefs.h
17032
17033             WITH_PYUNBOUND=yes
17034
17035             PYUNBOUND_OBJ="libunbound_wrap.lo"
17036
17037             PYUNBOUND_TARGET="_unbound.la"
17038
17039             PYUNBOUND_INSTALL=pyunbound-install
17040
17041             PYUNBOUND_UNINSTALL=pyunbound-uninstall
17042
17043          fi
17044       fi
17045    else
17046       { $as_echo "$as_me:${as_lineno-$LINENO}: result: *** Python libraries not found, won't build PythonMod or PyUnbound ***" >&5
17047 $as_echo "*** Python libraries not found, won't build PythonMod or PyUnbound ***" >&6; }
17048       ub_with_pyunbound=no
17049       ub_with_pythonmod=no
17050    fi
17051 fi
17052
17053 if test "`uname`" = "NetBSD"; then
17054         NETBSD_LINTFLAGS='"-D__RENAME(x)=" -D_NETINET_IN_H_'
17055
17056 fi
17057 CONFIG_DATE=`date +%Y%m%d`
17058
17059
17060 # Checks for libraries.
17061
17062 # libnss
17063 USE_NSS="no"
17064
17065 # Check whether --with-nss was given.
17066 if test "${with_nss+set}" = set; then :
17067   withval=$with_nss;
17068         USE_NSS="yes"
17069
17070 $as_echo "#define HAVE_NSS 1" >>confdefs.h
17071
17072         if test "$withval" != "" -a "$withval" != "yes"; then
17073                 CPPFLAGS="$CPPFLAGS -I$withval/include/nss3"
17074                 LDFLAGS="$LDFLAGS -L$withval/lib"
17075
17076         if test "x$enable_rpath" = xyes; then
17077                 if echo "$withval/lib" | grep "^/" >/dev/null; then
17078                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
17079                 fi
17080         fi
17081
17082                 CPPFLAGS="-I$withval/include/nspr4 $CPPFLAGS"
17083         else
17084                 CPPFLAGS="$CPPFLAGS -I/usr/include/nss3"
17085                 CPPFLAGS="-I/usr/include/nspr4 $CPPFLAGS"
17086         fi
17087         LIBS="$LIBS -lnss3 -lnspr4"
17088         SSLLIB=""
17089
17090
17091 fi
17092
17093
17094 # libnettle
17095 USE_NETTLE="no"
17096
17097 # Check whether --with-nettle was given.
17098 if test "${with_nettle+set}" = set; then :
17099   withval=$with_nettle;
17100         USE_NETTLE="yes"
17101
17102 $as_echo "#define HAVE_NETTLE 1" >>confdefs.h
17103
17104         for ac_header in nettle/dsa-compat.h
17105 do :
17106   ac_fn_c_check_header_compile "$LINENO" "nettle/dsa-compat.h" "ac_cv_header_nettle_dsa_compat_h" "$ac_includes_default
17107 "
17108 if test "x$ac_cv_header_nettle_dsa_compat_h" = xyes; then :
17109   cat >>confdefs.h <<_ACEOF
17110 #define HAVE_NETTLE_DSA_COMPAT_H 1
17111 _ACEOF
17112
17113 fi
17114
17115 done
17116
17117         if test "$withval" != "" -a "$withval" != "yes"; then
17118                 CPPFLAGS="$CPPFLAGS -I$withval/include/nettle"
17119                 LDFLAGS="$LDFLAGS -L$withval/lib"
17120
17121         if test "x$enable_rpath" = xyes; then
17122                 if echo "$withval/lib" | grep "^/" >/dev/null; then
17123                         RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
17124                 fi
17125         fi
17126
17127         else
17128                 CPPFLAGS="$CPPFLAGS -I/usr/include/nettle"
17129         fi
17130         LIBS="$LIBS -lhogweed -lnettle -lgmp"
17131         SSLLIB=""
17132
17133
17134 fi
17135
17136
17137 # openssl
17138 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
17139
17140
17141 # Check whether --with-ssl was given.
17142 if test "${with_ssl+set}" = set; then :
17143   withval=$with_ssl;
17144
17145 else
17146
17147             withval="yes"
17148
17149 fi
17150
17151     if test x_$withval = x_no; then
17152         as_fn_error $? "Need SSL library to do digital signature cryptography" "$LINENO" 5
17153     fi
17154
17155     withval=$withval
17156     if test x_$withval != x_no; then
17157         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL" >&5
17158 $as_echo_n "checking for SSL... " >&6; }
17159         if test x_$withval = x_ -o x_$withval = x_yes; then
17160             withval="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw /usr"
17161         fi
17162         for dir in $withval; do
17163             ssldir="$dir"
17164             if test -f "$dir/include/openssl/ssl.h"; then
17165                 found_ssl="yes"
17166
17167 cat >>confdefs.h <<_ACEOF
17168 #define HAVE_SSL /**/
17169 _ACEOF
17170
17171                                 if test "$ssldir" != "/usr"; then
17172                         CPPFLAGS="$CPPFLAGS -I$ssldir/include"
17173                         LIBSSL_CPPFLAGS="$LIBSSL_CPPFLAGS -I$ssldir/include"
17174                 fi
17175                 break;
17176             fi
17177         done
17178         if test x_$found_ssl != x_yes; then
17179             as_fn_error $? "Cannot find the SSL libraries in $withval" "$LINENO" 5
17180         else
17181             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $ssldir" >&5
17182 $as_echo "found in $ssldir" >&6; }
17183             HAVE_SSL=yes
17184                         if test "$ssldir" != "/usr" -a "$ssldir" != ""; then
17185                 LDFLAGS="$LDFLAGS -L$ssldir/lib"
17186                 LIBSSL_LDFLAGS="$LIBSSL_LDFLAGS -L$ssldir/lib"
17187
17188         if test "x$enable_rpath" = xyes; then
17189                 if echo "$ssldir/lib" | grep "^/" >/dev/null; then
17190                         RUNTIME_PATH="$RUNTIME_PATH -R$ssldir/lib"
17191                 fi
17192         fi
17193
17194             fi
17195
17196             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Update in -lcrypto" >&5
17197 $as_echo_n "checking for HMAC_Update in -lcrypto... " >&6; }
17198             LIBS="$LIBS -lcrypto"
17199             LIBSSL_LIBS="$LIBSSL_LIBS -lcrypto"
17200             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17201 /* end confdefs.h.  */
17202
17203 int
17204 main ()
17205 {
17206
17207                 int HMAC_Update(void);
17208                 (void)HMAC_Update();
17209
17210   ;
17211   return 0;
17212 }
17213 _ACEOF
17214 if ac_fn_c_try_link "$LINENO"; then :
17215
17216                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17217 $as_echo "yes" >&6; }
17218
17219 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17220
17221
17222 else
17223
17224                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17225 $as_echo "no" >&6; }
17226                 # check if -lwsock32 or -lgdi32 are needed.
17227                 BAKLIBS="$LIBS"
17228                 BAKSSLLIBS="$LIBSSL_LIBS"
17229                 LIBS="$LIBS -lgdi32"
17230                 LIBSSL_LIBS="$LIBSSL_LIBS -lgdi32"
17231                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -lgdi32" >&5
17232 $as_echo_n "checking if -lcrypto needs -lgdi32... " >&6; }
17233                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17234 /* end confdefs.h.  */
17235
17236 int
17237 main ()
17238 {
17239
17240                     int HMAC_Update(void);
17241                     (void)HMAC_Update();
17242
17243   ;
17244   return 0;
17245 }
17246 _ACEOF
17247 if ac_fn_c_try_link "$LINENO"; then :
17248
17249
17250 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17251
17252                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17253 $as_echo "yes" >&6; }
17254
17255 else
17256
17257                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17258 $as_echo "no" >&6; }
17259                     LIBS="$BAKLIBS"
17260                     LIBSSL_LIBS="$BAKSSLLIBS"
17261                     LIBS="$LIBS -ldl"
17262                     LIBSSL_LIBS="$LIBSSL_LIBS -ldl"
17263                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl" >&5
17264 $as_echo_n "checking if -lcrypto needs -ldl... " >&6; }
17265                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17266 /* end confdefs.h.  */
17267
17268 int
17269 main ()
17270 {
17271
17272                         int HMAC_Update(void);
17273                         (void)HMAC_Update();
17274
17275   ;
17276   return 0;
17277 }
17278 _ACEOF
17279 if ac_fn_c_try_link "$LINENO"; then :
17280
17281
17282 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17283
17284                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17285 $as_echo "yes" >&6; }
17286
17287 else
17288
17289                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17290 $as_echo "no" >&6; }
17291                         LIBS="$BAKLIBS"
17292                         LIBSSL_LIBS="$BAKSSLLIBS"
17293                         LIBS="$LIBS -ldl -pthread"
17294                         LIBSSL_LIBS="$LIBSSL_LIBS -ldl -pthread"
17295                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl -pthread" >&5
17296 $as_echo_n "checking if -lcrypto needs -ldl -pthread... " >&6; }
17297                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17298 /* end confdefs.h.  */
17299
17300 int
17301 main ()
17302 {
17303
17304                             int HMAC_Update(void);
17305                             (void)HMAC_Update();
17306
17307   ;
17308   return 0;
17309 }
17310 _ACEOF
17311 if ac_fn_c_try_link "$LINENO"; then :
17312
17313
17314 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17315
17316                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17317 $as_echo "yes" >&6; }
17318
17319 else
17320
17321                             { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17322 $as_echo "no" >&6; }
17323                             as_fn_error $? "OpenSSL found in $ssldir, but version 0.9.7 or higher is required" "$LINENO" 5
17324
17325 fi
17326 rm -f core conftest.err conftest.$ac_objext \
17327     conftest$ac_exeext conftest.$ac_ext
17328
17329 fi
17330 rm -f core conftest.err conftest.$ac_objext \
17331     conftest$ac_exeext conftest.$ac_ext
17332
17333 fi
17334 rm -f core conftest.err conftest.$ac_objext \
17335     conftest$ac_exeext conftest.$ac_ext
17336
17337 fi
17338 rm -f core conftest.err conftest.$ac_objext \
17339     conftest$ac_exeext conftest.$ac_ext
17340         fi
17341
17342
17343     fi
17344 for ac_header in openssl/ssl.h
17345 do :
17346   ac_fn_c_check_header_compile "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default
17347 "
17348 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
17349   cat >>confdefs.h <<_ACEOF
17350 #define HAVE_OPENSSL_SSL_H 1
17351 _ACEOF
17352
17353 fi
17354
17355 done
17356
17357 for ac_header in openssl/err.h
17358 do :
17359   ac_fn_c_check_header_compile "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default
17360 "
17361 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
17362   cat >>confdefs.h <<_ACEOF
17363 #define HAVE_OPENSSL_ERR_H 1
17364 _ACEOF
17365
17366 fi
17367
17368 done
17369
17370 for ac_header in openssl/rand.h
17371 do :
17372   ac_fn_c_check_header_compile "$LINENO" "openssl/rand.h" "ac_cv_header_openssl_rand_h" "$ac_includes_default
17373 "
17374 if test "x$ac_cv_header_openssl_rand_h" = xyes; then :
17375   cat >>confdefs.h <<_ACEOF
17376 #define HAVE_OPENSSL_RAND_H 1
17377 _ACEOF
17378
17379 fi
17380
17381 done
17382
17383
17384
17385
17386 # check if libssl needs libdl
17387 BAKLIBS="$LIBS"
17388 LIBS="-lssl $LIBS"
17389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs libdl" >&5
17390 $as_echo_n "checking if libssl needs libdl... " >&6; }
17391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17392 /* end confdefs.h.  */
17393
17394 /* Override any GCC internal prototype to avoid an error.
17395    Use char because int might match the return type of a GCC
17396    builtin and then its argument prototype would still apply.  */
17397 #ifdef __cplusplus
17398 extern "C"
17399 #endif
17400 char SSL_CTX_new ();
17401 int
17402 main ()
17403 {
17404 return SSL_CTX_new ();
17405   ;
17406   return 0;
17407 }
17408 _ACEOF
17409 if ac_fn_c_try_link "$LINENO"; then :
17410
17411         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17412 $as_echo "no" >&6; }
17413         LIBS="$BAKLIBS"
17414
17415 else
17416
17417         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17418 $as_echo "yes" >&6; }
17419         LIBS="$BAKLIBS"
17420         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
17421 $as_echo_n "checking for library containing dlopen... " >&6; }
17422 if ${ac_cv_search_dlopen+:} false; then :
17423   $as_echo_n "(cached) " >&6
17424 else
17425   ac_func_search_save_LIBS=$LIBS
17426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17427 /* end confdefs.h.  */
17428
17429 /* Override any GCC internal prototype to avoid an error.
17430    Use char because int might match the return type of a GCC
17431    builtin and then its argument prototype would still apply.  */
17432 #ifdef __cplusplus
17433 extern "C"
17434 #endif
17435 char dlopen ();
17436 int
17437 main ()
17438 {
17439 return dlopen ();
17440   ;
17441   return 0;
17442 }
17443 _ACEOF
17444 for ac_lib in '' dl; do
17445   if test -z "$ac_lib"; then
17446     ac_res="none required"
17447   else
17448     ac_res=-l$ac_lib
17449     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17450   fi
17451   if ac_fn_c_try_link "$LINENO"; then :
17452   ac_cv_search_dlopen=$ac_res
17453 fi
17454 rm -f core conftest.err conftest.$ac_objext \
17455     conftest$ac_exeext
17456   if ${ac_cv_search_dlopen+:} false; then :
17457   break
17458 fi
17459 done
17460 if ${ac_cv_search_dlopen+:} false; then :
17461
17462 else
17463   ac_cv_search_dlopen=no
17464 fi
17465 rm conftest.$ac_ext
17466 LIBS=$ac_func_search_save_LIBS
17467 fi
17468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
17469 $as_echo "$ac_cv_search_dlopen" >&6; }
17470 ac_res=$ac_cv_search_dlopen
17471 if test "$ac_res" != no; then :
17472   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17473
17474 fi
17475
17476
17477 fi
17478 rm -f core conftest.err conftest.$ac_objext \
17479     conftest$ac_exeext conftest.$ac_ext
17480 SSLLIB="-lssl"
17481
17482 # check if -lcrypt32 is needed because CAPIENG needs that. (on windows)
17483 BAKLIBS="$LIBS"
17484 LIBS="-lssl $LIBS"
17485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs -lcrypt32" >&5
17486 $as_echo_n "checking if libssl needs -lcrypt32... " >&6; }
17487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17488 /* end confdefs.h.  */
17489
17490 /* Override any GCC internal prototype to avoid an error.
17491    Use char because int might match the return type of a GCC
17492    builtin and then its argument prototype would still apply.  */
17493 #ifdef __cplusplus
17494 extern "C"
17495 #endif
17496 char HMAC_Update ();
17497 int
17498 main ()
17499 {
17500 return HMAC_Update ();
17501   ;
17502   return 0;
17503 }
17504 _ACEOF
17505 if ac_fn_c_try_link "$LINENO"; then :
17506
17507         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17508 $as_echo "no" >&6; }
17509         LIBS="$BAKLIBS"
17510
17511 else
17512
17513         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17514 $as_echo "yes" >&6; }
17515         LIBS="$BAKLIBS"
17516         LIBS="$LIBS -lcrypt32"
17517
17518 fi
17519 rm -f core conftest.err conftest.$ac_objext \
17520     conftest$ac_exeext conftest.$ac_ext
17521
17522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LibreSSL" >&5
17523 $as_echo_n "checking for LibreSSL... " >&6; }
17524 if grep VERSION_TEXT $ssldir/include/openssl/opensslv.h | grep "LibreSSL" >/dev/null; then
17525         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17526 $as_echo "yes" >&6; }
17527
17528 $as_echo "#define HAVE_LIBRESSL 1" >>confdefs.h
17529
17530         # libressl provides these compat functions, but they may also be
17531         # declared by the OS in libc.  See if they have been declared.
17532         ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
17533 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
17534   ac_have_decl=1
17535 else
17536   ac_have_decl=0
17537 fi
17538
17539 cat >>confdefs.h <<_ACEOF
17540 #define HAVE_DECL_STRLCPY $ac_have_decl
17541 _ACEOF
17542 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
17543 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
17544   ac_have_decl=1
17545 else
17546   ac_have_decl=0
17547 fi
17548
17549 cat >>confdefs.h <<_ACEOF
17550 #define HAVE_DECL_STRLCAT $ac_have_decl
17551 _ACEOF
17552 ac_fn_c_check_decl "$LINENO" "arc4random" "ac_cv_have_decl_arc4random" "$ac_includes_default"
17553 if test "x$ac_cv_have_decl_arc4random" = xyes; then :
17554   ac_have_decl=1
17555 else
17556   ac_have_decl=0
17557 fi
17558
17559 cat >>confdefs.h <<_ACEOF
17560 #define HAVE_DECL_ARC4RANDOM $ac_have_decl
17561 _ACEOF
17562 ac_fn_c_check_decl "$LINENO" "arc4random_uniform" "ac_cv_have_decl_arc4random_uniform" "$ac_includes_default"
17563 if test "x$ac_cv_have_decl_arc4random_uniform" = xyes; then :
17564   ac_have_decl=1
17565 else
17566   ac_have_decl=0
17567 fi
17568
17569 cat >>confdefs.h <<_ACEOF
17570 #define HAVE_DECL_ARC4RANDOM_UNIFORM $ac_have_decl
17571 _ACEOF
17572 ac_fn_c_check_decl "$LINENO" "reallocarray" "ac_cv_have_decl_reallocarray" "$ac_includes_default"
17573 if test "x$ac_cv_have_decl_reallocarray" = xyes; then :
17574   ac_have_decl=1
17575 else
17576   ac_have_decl=0
17577 fi
17578
17579 cat >>confdefs.h <<_ACEOF
17580 #define HAVE_DECL_REALLOCARRAY $ac_have_decl
17581 _ACEOF
17582
17583 else
17584         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17585 $as_echo "no" >&6; }
17586 fi
17587 for ac_header in openssl/conf.h openssl/engine.h openssl/bn.h openssl/dh.h openssl/dsa.h openssl/rsa.h
17588 do :
17589   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17590 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
17591 "
17592 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
17593   cat >>confdefs.h <<_ACEOF
17594 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17595 _ACEOF
17596
17597 fi
17598
17599 done
17600
17601 for ac_func in OPENSSL_config EVP_sha1 EVP_sha256 EVP_sha512 FIPS_mode EVP_MD_CTX_new OpenSSL_add_all_digests OPENSSL_init_crypto EVP_cleanup ERR_load_crypto_strings CRYPTO_cleanup_all_ex_data ERR_free_strings RAND_cleanup DSA_SIG_set0 EVP_dss1
17602 do :
17603   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17604 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17605 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17606   cat >>confdefs.h <<_ACEOF
17607 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17608 _ACEOF
17609
17610 fi
17611 done
17612
17613
17614 # these check_funcs need -lssl
17615 BAKLIBS="$LIBS"
17616 LIBS="-lssl $LIBS"
17617 for ac_func in OPENSSL_init_ssl SSL_CTX_set_security_level
17618 do :
17619   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17620 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17621 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17622   cat >>confdefs.h <<_ACEOF
17623 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17624 _ACEOF
17625
17626 fi
17627 done
17628
17629 LIBS="$BAKLIBS"
17630
17631 ac_fn_c_check_decl "$LINENO" "SSL_COMP_get_compression_methods" "ac_cv_have_decl_SSL_COMP_get_compression_methods" "
17632 $ac_includes_default
17633 #ifdef HAVE_OPENSSL_ERR_H
17634 #include <openssl/err.h>
17635 #endif
17636
17637 #ifdef HAVE_OPENSSL_RAND_H
17638 #include <openssl/rand.h>
17639 #endif
17640
17641 #ifdef HAVE_OPENSSL_CONF_H
17642 #include <openssl/conf.h>
17643 #endif
17644
17645 #ifdef HAVE_OPENSSL_ENGINE_H
17646 #include <openssl/engine.h>
17647 #endif
17648 #include <openssl/ssl.h>
17649 #include <openssl/evp.h>
17650
17651 "
17652 if test "x$ac_cv_have_decl_SSL_COMP_get_compression_methods" = xyes; then :
17653   ac_have_decl=1
17654 else
17655   ac_have_decl=0
17656 fi
17657
17658 cat >>confdefs.h <<_ACEOF
17659 #define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS $ac_have_decl
17660 _ACEOF
17661 ac_fn_c_check_decl "$LINENO" "sk_SSL_COMP_pop_free" "ac_cv_have_decl_sk_SSL_COMP_pop_free" "
17662 $ac_includes_default
17663 #ifdef HAVE_OPENSSL_ERR_H
17664 #include <openssl/err.h>
17665 #endif
17666
17667 #ifdef HAVE_OPENSSL_RAND_H
17668 #include <openssl/rand.h>
17669 #endif
17670
17671 #ifdef HAVE_OPENSSL_CONF_H
17672 #include <openssl/conf.h>
17673 #endif
17674
17675 #ifdef HAVE_OPENSSL_ENGINE_H
17676 #include <openssl/engine.h>
17677 #endif
17678 #include <openssl/ssl.h>
17679 #include <openssl/evp.h>
17680
17681 "
17682 if test "x$ac_cv_have_decl_sk_SSL_COMP_pop_free" = xyes; then :
17683   ac_have_decl=1
17684 else
17685   ac_have_decl=0
17686 fi
17687
17688 cat >>confdefs.h <<_ACEOF
17689 #define HAVE_DECL_SK_SSL_COMP_POP_FREE $ac_have_decl
17690 _ACEOF
17691 ac_fn_c_check_decl "$LINENO" "SSL_CTX_set_ecdh_auto" "ac_cv_have_decl_SSL_CTX_set_ecdh_auto" "
17692 $ac_includes_default
17693 #ifdef HAVE_OPENSSL_ERR_H
17694 #include <openssl/err.h>
17695 #endif
17696
17697 #ifdef HAVE_OPENSSL_RAND_H
17698 #include <openssl/rand.h>
17699 #endif
17700
17701 #ifdef HAVE_OPENSSL_CONF_H
17702 #include <openssl/conf.h>
17703 #endif
17704
17705 #ifdef HAVE_OPENSSL_ENGINE_H
17706 #include <openssl/engine.h>
17707 #endif
17708 #include <openssl/ssl.h>
17709 #include <openssl/evp.h>
17710
17711 "
17712 if test "x$ac_cv_have_decl_SSL_CTX_set_ecdh_auto" = xyes; then :
17713   ac_have_decl=1
17714 else
17715   ac_have_decl=0
17716 fi
17717
17718 cat >>confdefs.h <<_ACEOF
17719 #define HAVE_DECL_SSL_CTX_SET_ECDH_AUTO $ac_have_decl
17720 _ACEOF
17721
17722 fi
17723
17724
17725
17726 # Check whether --enable-sha1 was given.
17727 if test "${enable_sha1+set}" = set; then :
17728   enableval=$enable_sha1;
17729 fi
17730
17731 case "$enable_sha1" in
17732         no)
17733         ;;
17734         yes|*)
17735
17736 $as_echo "#define USE_SHA1 1" >>confdefs.h
17737
17738         ;;
17739 esac
17740
17741
17742 # Check whether --enable-sha2 was given.
17743 if test "${enable_sha2+set}" = set; then :
17744   enableval=$enable_sha2;
17745 fi
17746
17747 case "$enable_sha2" in
17748         no)
17749         ;;
17750         yes|*)
17751
17752 $as_echo "#define USE_SHA2 1" >>confdefs.h
17753
17754         ;;
17755 esac
17756
17757 # Check whether --enable-subnet was given.
17758 if test "${enable_subnet+set}" = set; then :
17759   enableval=$enable_subnet;
17760 fi
17761
17762 case "$enable_subnet" in
17763         yes)
17764
17765 $as_echo "#define CLIENT_SUBNET 1" >>confdefs.h
17766
17767         SUBNET_OBJ="edns-subnet.lo subnetmod.lo addrtree.lo subnet-whitelist.lo"
17768
17769         SUBNET_HEADER='$(srcdir)/edns-subnet/subnetmod.h $(srcdir)/edns-subnet/edns-subnet.h $(srcdir)/edns-subnet/subnet-whitelist.h $(srcdir)/edns-subnet/addrtree.h'
17770
17771         ;;
17772         no|*)
17773         ;;
17774 esac
17775
17776 # check wether gost also works
17777
17778 # Check whether --enable-gost was given.
17779 if test "${enable_gost+set}" = set; then :
17780   enableval=$enable_gost;
17781 fi
17782
17783 use_gost="no"
17784 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
17785 case "$enable_gost" in
17786         no)
17787         ;;
17788         *)
17789         ac_fn_c_check_func "$LINENO" "EVP_PKEY_set_type_str" "ac_cv_func_EVP_PKEY_set_type_str"
17790 if test "x$ac_cv_func_EVP_PKEY_set_type_str" = xyes; then :
17791   :
17792 else
17793   as_fn_error $? "OpenSSL 1.0.0 is needed for GOST support" "$LINENO" 5
17794 fi
17795
17796         ac_fn_c_check_func "$LINENO" "EC_KEY_new" "ac_cv_func_EC_KEY_new"
17797 if test "x$ac_cv_func_EC_KEY_new" = xyes; then :
17798
17799 else
17800   as_fn_error $? "OpenSSL does not support ECC, needed for GOST support" "$LINENO" 5
17801 fi
17802
17803
17804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GOST works" >&5
17805 $as_echo_n "checking if GOST works... " >&6; }
17806 if test c${cross_compiling} = cno; then
17807 BAKCFLAGS="$CFLAGS"
17808 if test -n "$ssldir"; then
17809         CFLAGS="$CFLAGS -Wl,-rpath,$ssldir/lib"
17810 fi
17811 if test "$cross_compiling" = yes; then :
17812   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17813 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17814 as_fn_error $? "cannot run test program while cross compiling
17815 See \`config.log' for more details" "$LINENO" 5; }
17816 else
17817   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17818 /* end confdefs.h.  */
17819
17820 #include <string.h>
17821 #include <openssl/ssl.h>
17822 #include <openssl/evp.h>
17823 #include <openssl/engine.h>
17824 #include <openssl/conf.h>
17825 /* routine to load gost (from sldns) */
17826 int load_gost_id(void)
17827 {
17828         static int gost_id = 0;
17829         const EVP_PKEY_ASN1_METHOD* meth;
17830         ENGINE* e;
17831
17832         if(gost_id) return gost_id;
17833
17834         /* see if configuration loaded gost implementation from other engine*/
17835         meth = EVP_PKEY_asn1_find_str(NULL, "gost2001", -1);
17836         if(meth) {
17837                 EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
17838                 return gost_id;
17839         }
17840
17841         /* see if engine can be loaded already */
17842         e = ENGINE_by_id("gost");
17843         if(!e) {
17844                 /* load it ourself, in case statically linked */
17845                 ENGINE_load_builtin_engines();
17846                 ENGINE_load_dynamic();
17847                 e = ENGINE_by_id("gost");
17848         }
17849         if(!e) {
17850                 /* no gost engine in openssl */
17851                 return 0;
17852         }
17853         if(!ENGINE_set_default(e, ENGINE_METHOD_ALL)) {
17854                 ENGINE_finish(e);
17855                 ENGINE_free(e);
17856                 return 0;
17857         }
17858
17859         meth = EVP_PKEY_asn1_find_str(&e, "gost2001", -1);
17860         if(!meth) {
17861                 /* algo not found */
17862                 ENGINE_finish(e);
17863                 ENGINE_free(e);
17864                 return 0;
17865         }
17866         EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
17867         return gost_id;
17868 }
17869 int main(void) {
17870         EVP_MD_CTX* ctx;
17871         const EVP_MD* md;
17872         unsigned char digest[64]; /* its a 256-bit digest, so uses 32 bytes */
17873         const char* str = "Hello world";
17874         const unsigned char check[] = {
17875                 0x40 , 0xed , 0xf8 , 0x56 , 0x5a , 0xc5 , 0x36 , 0xe1 ,
17876                 0x33 , 0x7c , 0x7e , 0x87 , 0x62 , 0x1c , 0x42 , 0xe0 ,
17877                 0x17 , 0x1b , 0x5e , 0xce , 0xa8 , 0x46 , 0x65 , 0x4d ,
17878                 0x8d , 0x3e , 0x22 , 0x9b , 0xe1 , 0x30 , 0x19 , 0x9d
17879         };
17880         OPENSSL_config(NULL);
17881         (void)load_gost_id();
17882         md = EVP_get_digestbyname("md_gost94");
17883         if(!md) return 1;
17884         memset(digest, 0, sizeof(digest));
17885         ctx = EVP_MD_CTX_create();
17886         if(!ctx) return 2;
17887         if(!EVP_DigestInit_ex(ctx, md, NULL)) return 3;
17888         if(!EVP_DigestUpdate(ctx, str, 10)) return 4;
17889         if(!EVP_DigestFinal_ex(ctx, digest, NULL)) return 5;
17890         /* uncomment to see the hash calculated.
17891                 {int i;
17892                 for(i=0; i<32; i++)
17893                         printf(" %2.2x", (int)digest[i]);
17894                 printf("\n");}
17895         */
17896         if(memcmp(digest, check, sizeof(check)) != 0)
17897                 return 6;
17898         return 0;
17899 }
17900
17901 _ACEOF
17902 if ac_fn_c_try_run "$LINENO"; then :
17903   eval "ac_cv_c_gost_works=yes"
17904 else
17905   eval "ac_cv_c_gost_works=no"
17906 fi
17907 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17908   conftest.$ac_objext conftest.beam conftest.$ac_ext
17909 fi
17910
17911 CFLAGS="$BAKCFLAGS"
17912 else
17913 eval "ac_cv_c_gost_works=maybe"
17914 fi
17915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_gost_works" >&5
17916 $as_echo "$ac_cv_c_gost_works" >&6; }
17917
17918         if test "$ac_cv_c_gost_works" != no; then
17919                 use_gost="yes"
17920
17921 $as_echo "#define USE_GOST 1" >>confdefs.h
17922
17923         fi
17924         ;;
17925 esac
17926 fi
17927 # Check whether --enable-ecdsa was given.
17928 if test "${enable_ecdsa+set}" = set; then :
17929   enableval=$enable_ecdsa;
17930 fi
17931
17932 use_ecdsa="no"
17933 case "$enable_ecdsa" in
17934     no)
17935       ;;
17936     *)
17937       if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
17938               ac_fn_c_check_func "$LINENO" "ECDSA_sign" "ac_cv_func_ECDSA_sign"
17939 if test "x$ac_cv_func_ECDSA_sign" = xyes; then :
17940
17941 else
17942   as_fn_error $? "OpenSSL does not support ECDSA: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
17943 fi
17944
17945               ac_fn_c_check_func "$LINENO" "SHA384_Init" "ac_cv_func_SHA384_Init"
17946 if test "x$ac_cv_func_SHA384_Init" = xyes; then :
17947
17948 else
17949   as_fn_error $? "OpenSSL does not support SHA384: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
17950 fi
17951
17952               ac_fn_c_check_decl "$LINENO" "NID_X9_62_prime256v1" "ac_cv_have_decl_NID_X9_62_prime256v1" "$ac_includes_default
17953 #include <openssl/evp.h>
17954
17955 "
17956 if test "x$ac_cv_have_decl_NID_X9_62_prime256v1" = xyes; then :
17957   ac_have_decl=1
17958 else
17959   ac_have_decl=0
17960 fi
17961
17962 cat >>confdefs.h <<_ACEOF
17963 #define HAVE_DECL_NID_X9_62_PRIME256V1 $ac_have_decl
17964 _ACEOF
17965 if test $ac_have_decl = 1; then :
17966
17967 else
17968   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
17969 fi
17970 ac_fn_c_check_decl "$LINENO" "NID_secp384r1" "ac_cv_have_decl_NID_secp384r1" "$ac_includes_default
17971 #include <openssl/evp.h>
17972
17973 "
17974 if test "x$ac_cv_have_decl_NID_secp384r1" = xyes; then :
17975   ac_have_decl=1
17976 else
17977   ac_have_decl=0
17978 fi
17979
17980 cat >>confdefs.h <<_ACEOF
17981 #define HAVE_DECL_NID_SECP384R1 $ac_have_decl
17982 _ACEOF
17983 if test $ac_have_decl = 1; then :
17984
17985 else
17986   as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
17987 fi
17988
17989               # see if OPENSSL 1.0.0 or later (has EVP MD and Verify independency)
17990               { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openssl supports SHA2 and ECDSA with EVP" >&5
17991 $as_echo_n "checking if openssl supports SHA2 and ECDSA with EVP... " >&6; }
17992               if grep OPENSSL_VERSION_TEXT $ssldir/include/openssl/opensslv.h | grep "OpenSSL" >/dev/null; then
17993                 if grep OPENSSL_VERSION_NUMBER $ssldir/include/openssl/opensslv.h | grep 0x0 >/dev/null; then
17994                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17995 $as_echo "no" >&6; }
17996
17997 cat >>confdefs.h <<_ACEOF
17998 #define USE_ECDSA_EVP_WORKAROUND 1
17999 _ACEOF
18000
18001                 else
18002                   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18003 $as_echo "yes" >&6; }
18004                 fi
18005               else
18006                 # not OpenSSL, thus likely LibreSSL, which supports it
18007                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18008 $as_echo "yes" >&6; }
18009               fi
18010       fi
18011       # we now know we have ECDSA and the required curves.
18012
18013 cat >>confdefs.h <<_ACEOF
18014 #define USE_ECDSA 1
18015 _ACEOF
18016
18017       use_ecdsa="yes"
18018       ;;
18019 esac
18020
18021 # Check whether --enable-dsa was given.
18022 if test "${enable_dsa+set}" = set; then :
18023   enableval=$enable_dsa;
18024 fi
18025
18026 use_dsa="no"
18027 case "$enable_dsa" in
18028     no)
18029       ;;
18030     *)
18031       # detect if DSA is supported, and turn it off if not.
18032       ac_fn_c_check_func "$LINENO" "DSA_SIG_new" "ac_cv_func_DSA_SIG_new"
18033 if test "x$ac_cv_func_DSA_SIG_new" = xyes; then :
18034
18035
18036 cat >>confdefs.h <<_ACEOF
18037 #define USE_DSA 1
18038 _ACEOF
18039
18040
18041 else
18042   if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
18043                fi
18044 fi
18045
18046       ;;
18047 esac
18048
18049
18050 # Check whether --enable-event-api was given.
18051 if test "${enable_event_api+set}" = set; then :
18052   enableval=$enable_event_api;
18053 fi
18054
18055 case "$enable_event_api" in
18056     yes)
18057       UNBOUND_EVENT_INSTALL=unbound-event-install
18058
18059       UNBOUND_EVENT_UNINSTALL=unbound-event-uninstall
18060
18061       ;;
18062     *)
18063       ;;
18064 esac
18065
18066 # Check whether --enable-tfo-client was given.
18067 if test "${enable_tfo_client+set}" = set; then :
18068   enableval=$enable_tfo_client;
18069 fi
18070
18071 case "$enable_tfo_client" in
18072         yes)
18073                 case `uname` in
18074                         Linux) ac_fn_c_check_decl "$LINENO" "MSG_FASTOPEN" "ac_cv_have_decl_MSG_FASTOPEN" "$ac_includes_default
18075 #include <netinet/tcp.h>
18076
18077 "
18078 if test "x$ac_cv_have_decl_MSG_FASTOPEN" = xyes; then :
18079   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
18080 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
18081 else
18082   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
18083 fi
18084
18085
18086 cat >>confdefs.h <<_ACEOF
18087 #define USE_MSG_FASTOPEN 1
18088 _ACEOF
18089
18090                           ;;
18091                         Darwin) ac_fn_c_check_decl "$LINENO" "CONNECT_RESUME_ON_READ_WRITE" "ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" "$ac_includes_default
18092 #include <sys/socket.h>
18093
18094 "
18095 if test "x$ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" = xyes; then :
18096   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
18097 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
18098 else
18099   as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
18100 fi
18101
18102
18103 cat >>confdefs.h <<_ACEOF
18104 #define USE_OSX_MSG_FASTOPEN 1
18105 _ACEOF
18106
18107                           ;;
18108                 esac
18109         ;;
18110         no|*)
18111                 ;;
18112 esac
18113
18114 # Check whether --enable-tfo-server was given.
18115 if test "${enable_tfo_server+set}" = set; then :
18116   enableval=$enable_tfo_server;
18117 fi
18118
18119 case "$enable_tfo_server" in
18120         yes)
18121               ac_fn_c_check_decl "$LINENO" "TCP_FASTOPEN" "ac_cv_have_decl_TCP_FASTOPEN" "$ac_includes_default
18122 #include <netinet/tcp.h>
18123
18124 "
18125 if test "x$ac_cv_have_decl_TCP_FASTOPEN" = xyes; then :
18126   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&5
18127 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&2;}
18128 else
18129   as_fn_error $? "TCP Fast Open is not available for server mode: please rerun without --enable-tfo-server" "$LINENO" 5
18130 fi
18131
18132
18133 cat >>confdefs.h <<_ACEOF
18134 #define USE_TCP_FASTOPEN 1
18135 _ACEOF
18136
18137                 ;;
18138         no|*)
18139                 ;;
18140 esac
18141
18142 # check for libevent
18143
18144 # Check whether --with-libevent was given.
18145 if test "${with_libevent+set}" = set; then :
18146   withval=$with_libevent;
18147 else
18148    withval="no"
18149 fi
18150
18151 if test x_$withval = x_yes -o x_$withval != x_no; then
18152         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libevent" >&5
18153 $as_echo_n "checking for libevent... " >&6; }
18154         if test x_$withval = x_ -o x_$withval = x_yes; then
18155             withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
18156         fi
18157         for dir in $withval; do
18158             thedir="$dir"
18159             if test -f "$dir/include/event.h" -o -f "$dir/include/event2/event.h"; then
18160                 found_libevent="yes"
18161                                 if test "$thedir" != "/usr"; then
18162                     CPPFLAGS="$CPPFLAGS -I$thedir/include"
18163                 fi
18164                 break;
18165             fi
18166         done
18167         if test x_$found_libevent != x_yes; then
18168                 if test -f "$dir/event.h" -a \( -f "$dir/libevent.la" -o -f "$dir/libev.la" \) ; then
18169                         # libevent source directory
18170                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
18171 $as_echo "found in $thedir" >&6; }
18172                         CPPFLAGS="$CPPFLAGS -I$thedir -I$thedir/include"
18173                         BAK_LDFLAGS_SET="1"
18174                         BAK_LDFLAGS="$LDFLAGS"
18175                         # remove evdns from linking
18176                         mkdir build >/dev/null 2>&1
18177                         mkdir build/libevent >/dev/null 2>&1
18178                         mkdir build/libevent/.libs >/dev/null 2>&1
18179                         ev_files_o=`ls $thedir/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
18180                         ev_files_lo=`ls $thedir/*.lo | grep -v evdns\.lo | grep -v bufferevent_openssl\.lo`
18181                         ev_files_libso=`ls $thedir/.libs/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
18182                         cp $ev_files_o build/libevent
18183                         cp $ev_files_lo build/libevent
18184                         cp $ev_files_libso build/libevent/.libs
18185                         LATE_LDFLAGS="build/libevent/*.lo -lm"
18186                         LDFLAGS="build/libevent/*.o $LDFLAGS -lm"
18187                 else
18188                         as_fn_error $? "Cannot find the libevent library in $withval
18189 You can restart ./configure --with-libevent=no to use a builtin alternative.
18190 Please note that this alternative is not as capable as libevent when using
18191 large outgoing port ranges.  " "$LINENO" 5
18192                 fi
18193         else
18194             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
18195 $as_echo "found in $thedir" >&6; }
18196                     if test ! -f $thedir/lib/libevent.a -a ! -f $thedir/lib/libevent.so -a -d "$thedir/lib/event2"; then
18197                     LDFLAGS="$LDFLAGS -L$thedir/lib/event2"
18198
18199         if test "x$enable_rpath" = xyes; then
18200                 if echo "$thedir/lib/event2" | grep "^/" >/dev/null; then
18201                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib/event2"
18202                 fi
18203         fi
18204
18205             else
18206                                     if test "$thedir" != "/usr" -a "$thedir" != ""; then
18207                         LDFLAGS="$LDFLAGS -L$thedir/lib"
18208
18209         if test "x$enable_rpath" = xyes; then
18210                 if echo "$thedir/lib" | grep "^/" >/dev/null; then
18211                         RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib"
18212                 fi
18213         fi
18214
18215                     fi
18216             fi
18217         fi
18218         # check for library used by libevent after 1.3c
18219         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
18220 $as_echo_n "checking for library containing clock_gettime... " >&6; }
18221 if ${ac_cv_search_clock_gettime+:} false; then :
18222   $as_echo_n "(cached) " >&6
18223 else
18224   ac_func_search_save_LIBS=$LIBS
18225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18226 /* end confdefs.h.  */
18227
18228 /* Override any GCC internal prototype to avoid an error.
18229    Use char because int might match the return type of a GCC
18230    builtin and then its argument prototype would still apply.  */
18231 #ifdef __cplusplus
18232 extern "C"
18233 #endif
18234 char clock_gettime ();
18235 int
18236 main ()
18237 {
18238 return clock_gettime ();
18239   ;
18240   return 0;
18241 }
18242 _ACEOF
18243 for ac_lib in '' rt; do
18244   if test -z "$ac_lib"; then
18245     ac_res="none required"
18246   else
18247     ac_res=-l$ac_lib
18248     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18249   fi
18250   if ac_fn_c_try_link "$LINENO"; then :
18251   ac_cv_search_clock_gettime=$ac_res
18252 fi
18253 rm -f core conftest.err conftest.$ac_objext \
18254     conftest$ac_exeext
18255   if ${ac_cv_search_clock_gettime+:} false; then :
18256   break
18257 fi
18258 done
18259 if ${ac_cv_search_clock_gettime+:} false; then :
18260
18261 else
18262   ac_cv_search_clock_gettime=no
18263 fi
18264 rm conftest.$ac_ext
18265 LIBS=$ac_func_search_save_LIBS
18266 fi
18267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
18268 $as_echo "$ac_cv_search_clock_gettime" >&6; }
18269 ac_res=$ac_cv_search_clock_gettime
18270 if test "$ac_res" != no; then :
18271   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18272
18273 fi
18274
18275
18276         # is the event.h header libev or libevent?
18277         for ac_header in event.h
18278 do :
18279   ac_fn_c_check_header_compile "$LINENO" "event.h" "ac_cv_header_event_h" "$ac_includes_default
18280 "
18281 if test "x$ac_cv_header_event_h" = xyes; then :
18282   cat >>confdefs.h <<_ACEOF
18283 #define HAVE_EVENT_H 1
18284 _ACEOF
18285
18286 fi
18287
18288 done
18289
18290         ac_fn_c_check_decl "$LINENO" "EV_VERSION_MAJOR" "ac_cv_have_decl_EV_VERSION_MAJOR" "$ac_includes_default
18291 #include <event.h>
18292
18293 "
18294 if test "x$ac_cv_have_decl_EV_VERSION_MAJOR" = xyes; then :
18295
18296                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
18297 $as_echo_n "checking for library containing event_set... " >&6; }
18298 if ${ac_cv_search_event_set+:} false; then :
18299   $as_echo_n "(cached) " >&6
18300 else
18301   ac_func_search_save_LIBS=$LIBS
18302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18303 /* end confdefs.h.  */
18304
18305 /* Override any GCC internal prototype to avoid an error.
18306    Use char because int might match the return type of a GCC
18307    builtin and then its argument prototype would still apply.  */
18308 #ifdef __cplusplus
18309 extern "C"
18310 #endif
18311 char event_set ();
18312 int
18313 main ()
18314 {
18315 return event_set ();
18316   ;
18317   return 0;
18318 }
18319 _ACEOF
18320 for ac_lib in '' ev; do
18321   if test -z "$ac_lib"; then
18322     ac_res="none required"
18323   else
18324     ac_res=-l$ac_lib
18325     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18326   fi
18327   if ac_fn_c_try_link "$LINENO"; then :
18328   ac_cv_search_event_set=$ac_res
18329 fi
18330 rm -f core conftest.err conftest.$ac_objext \
18331     conftest$ac_exeext
18332   if ${ac_cv_search_event_set+:} false; then :
18333   break
18334 fi
18335 done
18336 if ${ac_cv_search_event_set+:} false; then :
18337
18338 else
18339   ac_cv_search_event_set=no
18340 fi
18341 rm conftest.$ac_ext
18342 LIBS=$ac_func_search_save_LIBS
18343 fi
18344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
18345 $as_echo "$ac_cv_search_event_set" >&6; }
18346 ac_res=$ac_cv_search_event_set
18347 if test "$ac_res" != no; then :
18348   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18349
18350 fi
18351
18352
18353 else
18354
18355                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
18356 $as_echo_n "checking for library containing event_set... " >&6; }
18357 if ${ac_cv_search_event_set+:} false; then :
18358   $as_echo_n "(cached) " >&6
18359 else
18360   ac_func_search_save_LIBS=$LIBS
18361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18362 /* end confdefs.h.  */
18363
18364 /* Override any GCC internal prototype to avoid an error.
18365    Use char because int might match the return type of a GCC
18366    builtin and then its argument prototype would still apply.  */
18367 #ifdef __cplusplus
18368 extern "C"
18369 #endif
18370 char event_set ();
18371 int
18372 main ()
18373 {
18374 return event_set ();
18375   ;
18376   return 0;
18377 }
18378 _ACEOF
18379 for ac_lib in '' event; do
18380   if test -z "$ac_lib"; then
18381     ac_res="none required"
18382   else
18383     ac_res=-l$ac_lib
18384     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18385   fi
18386   if ac_fn_c_try_link "$LINENO"; then :
18387   ac_cv_search_event_set=$ac_res
18388 fi
18389 rm -f core conftest.err conftest.$ac_objext \
18390     conftest$ac_exeext
18391   if ${ac_cv_search_event_set+:} false; then :
18392   break
18393 fi
18394 done
18395 if ${ac_cv_search_event_set+:} false; then :
18396
18397 else
18398   ac_cv_search_event_set=no
18399 fi
18400 rm conftest.$ac_ext
18401 LIBS=$ac_func_search_save_LIBS
18402 fi
18403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
18404 $as_echo "$ac_cv_search_event_set" >&6; }
18405 ac_res=$ac_cv_search_event_set
18406 if test "$ac_res" != no; then :
18407   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18408
18409 fi
18410
18411
18412 fi
18413
18414         for ac_func in event_base_free
18415 do :
18416   ac_fn_c_check_func "$LINENO" "event_base_free" "ac_cv_func_event_base_free"
18417 if test "x$ac_cv_func_event_base_free" = xyes; then :
18418   cat >>confdefs.h <<_ACEOF
18419 #define HAVE_EVENT_BASE_FREE 1
18420 _ACEOF
18421
18422 fi
18423 done
18424  # only in libevent 1.2 and later
18425         for ac_func in event_base_once
18426 do :
18427   ac_fn_c_check_func "$LINENO" "event_base_once" "ac_cv_func_event_base_once"
18428 if test "x$ac_cv_func_event_base_once" = xyes; then :
18429   cat >>confdefs.h <<_ACEOF
18430 #define HAVE_EVENT_BASE_ONCE 1
18431 _ACEOF
18432
18433 fi
18434 done
18435  # only in libevent 1.4.1 and later
18436         for ac_func in event_base_new
18437 do :
18438   ac_fn_c_check_func "$LINENO" "event_base_new" "ac_cv_func_event_base_new"
18439 if test "x$ac_cv_func_event_base_new" = xyes; then :
18440   cat >>confdefs.h <<_ACEOF
18441 #define HAVE_EVENT_BASE_NEW 1
18442 _ACEOF
18443
18444 fi
18445 done
18446  # only in libevent 1.4.1 and later
18447         for ac_func in event_base_get_method
18448 do :
18449   ac_fn_c_check_func "$LINENO" "event_base_get_method" "ac_cv_func_event_base_get_method"
18450 if test "x$ac_cv_func_event_base_get_method" = xyes; then :
18451   cat >>confdefs.h <<_ACEOF
18452 #define HAVE_EVENT_BASE_GET_METHOD 1
18453 _ACEOF
18454
18455 fi
18456 done
18457  # only in libevent 1.4.3 and later
18458         for ac_func in ev_loop
18459 do :
18460   ac_fn_c_check_func "$LINENO" "ev_loop" "ac_cv_func_ev_loop"
18461 if test "x$ac_cv_func_ev_loop" = xyes; then :
18462   cat >>confdefs.h <<_ACEOF
18463 #define HAVE_EV_LOOP 1
18464 _ACEOF
18465
18466 fi
18467 done
18468  # only in libev. (tested on 3.51)
18469         for ac_func in ev_default_loop
18470 do :
18471   ac_fn_c_check_func "$LINENO" "ev_default_loop" "ac_cv_func_ev_default_loop"
18472 if test "x$ac_cv_func_ev_default_loop" = xyes; then :
18473   cat >>confdefs.h <<_ACEOF
18474 #define HAVE_EV_DEFAULT_LOOP 1
18475 _ACEOF
18476
18477 fi
18478 done
18479  # only in libev. (tested on 4.00)
18480         PC_LIBEVENT_DEPENDENCY="libevent"
18481
18482         if test -n "$BAK_LDFLAGS_SET"; then
18483                 LDFLAGS="$BAK_LDFLAGS"
18484         fi
18485 else
18486
18487 $as_echo "#define USE_MINI_EVENT 1" >>confdefs.h
18488
18489 fi
18490
18491 # check for libexpat
18492
18493 # Check whether --with-libexpat was given.
18494 if test "${with_libexpat+set}" = set; then :
18495   withval=$with_libexpat;
18496 else
18497    withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
18498 fi
18499
18500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
18501 $as_echo_n "checking for libexpat... " >&6; }
18502 found_libexpat="no"
18503 for dir in $withval ; do
18504             if test -f "$dir/include/expat.h"; then
18505                 found_libexpat="yes"
18506                                 if test "$dir" != "/usr"; then
18507                     CPPFLAGS="$CPPFLAGS -I$dir/include"
18508                     LDFLAGS="$LDFLAGS -L$dir/lib"
18509                 fi
18510                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
18511 $as_echo "found in $dir" >&6; }
18512                 break;
18513             fi
18514 done
18515 if test x_$found_libexpat != x_yes; then
18516         as_fn_error $? "Could not find libexpat, expat.h" "$LINENO" 5
18517 fi
18518 for ac_header in expat.h
18519 do :
18520   ac_fn_c_check_header_compile "$LINENO" "expat.h" "ac_cv_header_expat_h" "$ac_includes_default
18521 "
18522 if test "x$ac_cv_header_expat_h" = xyes; then :
18523   cat >>confdefs.h <<_ACEOF
18524 #define HAVE_EXPAT_H 1
18525 _ACEOF
18526
18527 fi
18528
18529 done
18530
18531 ac_fn_c_check_decl "$LINENO" "XML_StopParser" "ac_cv_have_decl_XML_StopParser" "$ac_includes_default
18532 #include <expat.h>
18533
18534 "
18535 if test "x$ac_cv_have_decl_XML_StopParser" = xyes; then :
18536   ac_have_decl=1
18537 else
18538   ac_have_decl=0
18539 fi
18540
18541 cat >>confdefs.h <<_ACEOF
18542 #define HAVE_DECL_XML_STOPPARSER $ac_have_decl
18543 _ACEOF
18544
18545
18546 # set static linking if requested
18547
18548 staticexe=""
18549 # Check whether --enable-static-exe was given.
18550 if test "${enable_static_exe+set}" = set; then :
18551   enableval=$enable_static_exe;
18552 fi
18553
18554 if test x_$enable_static_exe = x_yes; then
18555         staticexe="-static"
18556         if test "$on_mingw" = yes; then
18557                 staticexe="-all-static"
18558                 # for static compile, include gdi32 and zlib here.
18559                 LIBS="$LIBS -lgdi32 -lz"
18560         fi
18561 fi
18562
18563 # Include systemd.m4 - begin
18564 #   macros for configuring systemd
18565 #   Copyright 2015, Sami Kerola, CloudFlare.
18566 #   BSD licensed.
18567 # Check whether --enable-systemd was given.
18568 if test "${enable_systemd+set}" = set; then :
18569   enableval=$enable_systemd;
18570 else
18571   enable_systemd=no
18572 fi
18573
18574 have_systemd=no
18575
18576
18577
18578
18579
18580
18581
18582 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
18583         if test -n "$ac_tool_prefix"; then
18584   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
18585 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
18586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18587 $as_echo_n "checking for $ac_word... " >&6; }
18588 if ${ac_cv_path_PKG_CONFIG+:} false; then :
18589   $as_echo_n "(cached) " >&6
18590 else
18591   case $PKG_CONFIG in
18592   [\\/]* | ?:[\\/]*)
18593   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
18594   ;;
18595   *)
18596   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18597 for as_dir in $PATH
18598 do
18599   IFS=$as_save_IFS
18600   test -z "$as_dir" && as_dir=.
18601     for ac_exec_ext in '' $ac_executable_extensions; do
18602   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18603     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
18604     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18605     break 2
18606   fi
18607 done
18608   done
18609 IFS=$as_save_IFS
18610
18611   ;;
18612 esac
18613 fi
18614 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
18615 if test -n "$PKG_CONFIG"; then
18616   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
18617 $as_echo "$PKG_CONFIG" >&6; }
18618 else
18619   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18620 $as_echo "no" >&6; }
18621 fi
18622
18623
18624 fi
18625 if test -z "$ac_cv_path_PKG_CONFIG"; then
18626   ac_pt_PKG_CONFIG=$PKG_CONFIG
18627   # Extract the first word of "pkg-config", so it can be a program name with args.
18628 set dummy pkg-config; ac_word=$2
18629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18630 $as_echo_n "checking for $ac_word... " >&6; }
18631 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
18632   $as_echo_n "(cached) " >&6
18633 else
18634   case $ac_pt_PKG_CONFIG in
18635   [\\/]* | ?:[\\/]*)
18636   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
18637   ;;
18638   *)
18639   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18640 for as_dir in $PATH
18641 do
18642   IFS=$as_save_IFS
18643   test -z "$as_dir" && as_dir=.
18644     for ac_exec_ext in '' $ac_executable_extensions; do
18645   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18646     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
18647     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18648     break 2
18649   fi
18650 done
18651   done
18652 IFS=$as_save_IFS
18653
18654   ;;
18655 esac
18656 fi
18657 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
18658 if test -n "$ac_pt_PKG_CONFIG"; then
18659   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
18660 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
18661 else
18662   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18663 $as_echo "no" >&6; }
18664 fi
18665
18666   if test "x$ac_pt_PKG_CONFIG" = x; then
18667     PKG_CONFIG=""
18668   else
18669     case $cross_compiling:$ac_tool_warned in
18670 yes:)
18671 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18672 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18673 ac_tool_warned=yes ;;
18674 esac
18675     PKG_CONFIG=$ac_pt_PKG_CONFIG
18676   fi
18677 else
18678   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
18679 fi
18680
18681 fi
18682 if test -n "$PKG_CONFIG"; then
18683         _pkg_min_version=0.9.0
18684         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
18685 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
18686         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
18687                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18688 $as_echo "yes" >&6; }
18689         else
18690                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18691 $as_echo "no" >&6; }
18692                 PKG_CONFIG=""
18693         fi
18694 fi
18695 if test "x$enable_systemd" != xno; then :
18696
18697
18698
18699 pkg_failed=no
18700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD" >&5
18701 $as_echo_n "checking for SYSTEMD... " >&6; }
18702
18703 if test -n "$SYSTEMD_CFLAGS"; then
18704     pkg_cv_SYSTEMD_CFLAGS="$SYSTEMD_CFLAGS"
18705  elif test -n "$PKG_CONFIG"; then
18706     if test -n "$PKG_CONFIG" && \
18707     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
18708   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
18709   ac_status=$?
18710   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18711   test $ac_status = 0; }; then
18712   pkg_cv_SYSTEMD_CFLAGS=`$PKG_CONFIG --cflags "libsystemd" 2>/dev/null`
18713                       test "x$?" != "x0" && pkg_failed=yes
18714 else
18715   pkg_failed=yes
18716 fi
18717  else
18718     pkg_failed=untried
18719 fi
18720 if test -n "$SYSTEMD_LIBS"; then
18721     pkg_cv_SYSTEMD_LIBS="$SYSTEMD_LIBS"
18722  elif test -n "$PKG_CONFIG"; then
18723     if test -n "$PKG_CONFIG" && \
18724     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
18725   ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
18726   ac_status=$?
18727   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18728   test $ac_status = 0; }; then
18729   pkg_cv_SYSTEMD_LIBS=`$PKG_CONFIG --libs "libsystemd" 2>/dev/null`
18730                       test "x$?" != "x0" && pkg_failed=yes
18731 else
18732   pkg_failed=yes
18733 fi
18734  else
18735     pkg_failed=untried
18736 fi
18737
18738
18739
18740 if test $pkg_failed = yes; then
18741         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18742 $as_echo "no" >&6; }
18743
18744 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18745         _pkg_short_errors_supported=yes
18746 else
18747         _pkg_short_errors_supported=no
18748 fi
18749         if test $_pkg_short_errors_supported = yes; then
18750                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd" 2>&1`
18751         else
18752                 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd" 2>&1`
18753         fi
18754         # Put the nasty error message in config.log where it belongs
18755         echo "$SYSTEMD_PKG_ERRORS" >&5
18756
18757         have_systemd=no
18758 elif test $pkg_failed = untried; then
18759         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18760 $as_echo "no" >&6; }
18761         have_systemd=no
18762 else
18763         SYSTEMD_CFLAGS=$pkg_cv_SYSTEMD_CFLAGS
18764         SYSTEMD_LIBS=$pkg_cv_SYSTEMD_LIBS
18765         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18766 $as_echo "yes" >&6; }
18767         have_systemd=yes
18768 fi
18769                 if test "x$have_systemd" != "xyes"; then :
18770
18771
18772 pkg_failed=no
18773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD_DAEMON" >&5
18774 $as_echo_n "checking for SYSTEMD_DAEMON... " >&6; }
18775
18776 if test -n "$SYSTEMD_DAEMON_CFLAGS"; then
18777     pkg_cv_SYSTEMD_DAEMON_CFLAGS="$SYSTEMD_DAEMON_CFLAGS"
18778  elif test -n "$PKG_CONFIG"; then
18779     if test -n "$PKG_CONFIG" && \
18780     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
18781   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
18782   ac_status=$?
18783   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18784   test $ac_status = 0; }; then
18785   pkg_cv_SYSTEMD_DAEMON_CFLAGS=`$PKG_CONFIG --cflags "libsystemd-daemon" 2>/dev/null`
18786                       test "x$?" != "x0" && pkg_failed=yes
18787 else
18788   pkg_failed=yes
18789 fi
18790  else
18791     pkg_failed=untried
18792 fi
18793 if test -n "$SYSTEMD_DAEMON_LIBS"; then
18794     pkg_cv_SYSTEMD_DAEMON_LIBS="$SYSTEMD_DAEMON_LIBS"
18795  elif test -n "$PKG_CONFIG"; then
18796     if test -n "$PKG_CONFIG" && \
18797     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
18798   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
18799   ac_status=$?
18800   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18801   test $ac_status = 0; }; then
18802   pkg_cv_SYSTEMD_DAEMON_LIBS=`$PKG_CONFIG --libs "libsystemd-daemon" 2>/dev/null`
18803                       test "x$?" != "x0" && pkg_failed=yes
18804 else
18805   pkg_failed=yes
18806 fi
18807  else
18808     pkg_failed=untried
18809 fi
18810
18811
18812
18813 if test $pkg_failed = yes; then
18814         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18815 $as_echo "no" >&6; }
18816
18817 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
18818         _pkg_short_errors_supported=yes
18819 else
18820         _pkg_short_errors_supported=no
18821 fi
18822         if test $_pkg_short_errors_supported = yes; then
18823                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
18824         else
18825                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
18826         fi
18827         # Put the nasty error message in config.log where it belongs
18828         echo "$SYSTEMD_DAEMON_PKG_ERRORS" >&5
18829
18830         have_systemd_daemon=no
18831 elif test $pkg_failed = untried; then
18832         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18833 $as_echo "no" >&6; }
18834         have_systemd_daemon=no
18835 else
18836         SYSTEMD_DAEMON_CFLAGS=$pkg_cv_SYSTEMD_DAEMON_CFLAGS
18837         SYSTEMD_DAEMON_LIBS=$pkg_cv_SYSTEMD_DAEMON_LIBS
18838         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18839 $as_echo "yes" >&6; }
18840         have_systemd_daemon=yes
18841 fi
18842                 if test "x$have_systemd_daemon" = "xyes"; then :
18843   have_systemd=yes
18844 fi
18845
18846 fi
18847         case $enable_systemd:$have_systemd in #(
18848   yes:no) :
18849     as_fn_error $? "systemd enabled but libsystemd not found" "$LINENO" 5 ;; #(
18850   *:yes) :
18851
18852 $as_echo "#define HAVE_SYSTEMD 1" >>confdefs.h
18853
18854                 LIBS="$LIBS $SYSTEMD_LIBS"
18855
18856          ;; #(
18857   *) :
18858      ;;
18859 esac
18860
18861
18862 fi
18863  if test "x$have_systemd" = xyes; then
18864   USE_SYSTEMD_TRUE=
18865   USE_SYSTEMD_FALSE='#'
18866 else
18867   USE_SYSTEMD_TRUE='#'
18868   USE_SYSTEMD_FALSE=
18869 fi
18870
18871
18872 # Include systemd.m4 - end
18873
18874 # set lock checking if requested
18875 # Check whether --enable-lock_checks was given.
18876 if test "${enable_lock_checks+set}" = set; then :
18877   enableval=$enable_lock_checks;
18878 fi
18879
18880 if test x_$enable_lock_checks = x_yes; then
18881
18882 $as_echo "#define ENABLE_LOCK_CHECKS 1" >>confdefs.h
18883
18884         CHECKLOCK_OBJ="checklocks.lo"
18885
18886 fi
18887
18888
18889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
18890 $as_echo_n "checking for getaddrinfo... " >&6; }
18891 ac_cv_func_getaddrinfo=no
18892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18893 /* end confdefs.h.  */
18894
18895 #ifdef __cplusplus
18896 extern "C"
18897 {
18898 #endif
18899 char* getaddrinfo();
18900 char* (*f) () = getaddrinfo;
18901 #ifdef __cplusplus
18902 }
18903 #endif
18904 int main() {
18905         ;
18906         return 0;
18907 }
18908
18909 _ACEOF
18910 if ac_fn_c_try_link "$LINENO"; then :
18911   ac_cv_func_getaddrinfo="yes"
18912 if test "$ac_cv_header_windows_h" = "yes"; then
18913
18914 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
18915
18916         USE_WINSOCK="1"
18917         LIBS="$LIBS -lws2_32"
18918 fi
18919
18920 else
18921   ORIGLIBS="$LIBS"
18922 LIBS="$LIBS -lws2_32"
18923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18924 /* end confdefs.h.  */
18925
18926 #ifdef HAVE_WS2TCPIP_H
18927 #include <ws2tcpip.h>
18928 #endif
18929
18930 int
18931 main ()
18932 {
18933
18934         (void)getaddrinfo(NULL, NULL, NULL, NULL);
18935
18936
18937   ;
18938   return 0;
18939 }
18940 _ACEOF
18941 if ac_fn_c_try_link "$LINENO"; then :
18942
18943 ac_cv_func_getaddrinfo="yes"
18944
18945 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
18946
18947 USE_WINSOCK="1"
18948
18949 else
18950
18951 ac_cv_func_getaddrinfo="no"
18952 LIBS="$ORIGLIBS"
18953
18954 fi
18955 rm -f core conftest.err conftest.$ac_objext \
18956     conftest$ac_exeext conftest.$ac_ext
18957
18958 fi
18959 rm -f core conftest.err conftest.$ac_objext \
18960     conftest$ac_exeext conftest.$ac_ext
18961
18962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getaddrinfo" >&5
18963 $as_echo "$ac_cv_func_getaddrinfo" >&6; }
18964 if test $ac_cv_func_getaddrinfo = yes; then
18965
18966 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
18967
18968 fi
18969
18970 if test "$USE_WINSOCK" = 1; then
18971
18972 $as_echo "#define UB_ON_WINDOWS 1" >>confdefs.h
18973
18974         for ac_header in iphlpapi.h
18975 do :
18976   ac_fn_c_check_header_compile "$LINENO" "iphlpapi.h" "ac_cv_header_iphlpapi_h" "$ac_includes_default
18977 #include <windows.h>
18978
18979 "
18980 if test "x$ac_cv_header_iphlpapi_h" = xyes; then :
18981   cat >>confdefs.h <<_ACEOF
18982 #define HAVE_IPHLPAPI_H 1
18983 _ACEOF
18984
18985 fi
18986
18987 done
18988
18989         if test -n "$ac_tool_prefix"; then
18990   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
18991 set dummy ${ac_tool_prefix}windres; ac_word=$2
18992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18993 $as_echo_n "checking for $ac_word... " >&6; }
18994 if ${ac_cv_prog_WINDRES+:} false; then :
18995   $as_echo_n "(cached) " >&6
18996 else
18997   if test -n "$WINDRES"; then
18998   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
18999 else
19000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19001 for as_dir in $PATH
19002 do
19003   IFS=$as_save_IFS
19004   test -z "$as_dir" && as_dir=.
19005     for ac_exec_ext in '' $ac_executable_extensions; do
19006   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19007     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
19008     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19009     break 2
19010   fi
19011 done
19012   done
19013 IFS=$as_save_IFS
19014
19015 fi
19016 fi
19017 WINDRES=$ac_cv_prog_WINDRES
19018 if test -n "$WINDRES"; then
19019   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
19020 $as_echo "$WINDRES" >&6; }
19021 else
19022   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19023 $as_echo "no" >&6; }
19024 fi
19025
19026
19027 fi
19028 if test -z "$ac_cv_prog_WINDRES"; then
19029   ac_ct_WINDRES=$WINDRES
19030   # Extract the first word of "windres", so it can be a program name with args.
19031 set dummy windres; ac_word=$2
19032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19033 $as_echo_n "checking for $ac_word... " >&6; }
19034 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
19035   $as_echo_n "(cached) " >&6
19036 else
19037   if test -n "$ac_ct_WINDRES"; then
19038   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
19039 else
19040 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19041 for as_dir in $PATH
19042 do
19043   IFS=$as_save_IFS
19044   test -z "$as_dir" && as_dir=.
19045     for ac_exec_ext in '' $ac_executable_extensions; do
19046   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19047     ac_cv_prog_ac_ct_WINDRES="windres"
19048     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19049     break 2
19050   fi
19051 done
19052   done
19053 IFS=$as_save_IFS
19054
19055 fi
19056 fi
19057 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
19058 if test -n "$ac_ct_WINDRES"; then
19059   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
19060 $as_echo "$ac_ct_WINDRES" >&6; }
19061 else
19062   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19063 $as_echo "no" >&6; }
19064 fi
19065
19066   if test "x$ac_ct_WINDRES" = x; then
19067     WINDRES=""
19068   else
19069     case $cross_compiling:$ac_tool_warned in
19070 yes:)
19071 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19072 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19073 ac_tool_warned=yes ;;
19074 esac
19075     WINDRES=$ac_ct_WINDRES
19076   fi
19077 else
19078   WINDRES="$ac_cv_prog_WINDRES"
19079 fi
19080
19081         LIBS="$LIBS -liphlpapi"
19082         WINAPPS="unbound-service-install.exe unbound-service-remove.exe anchor-update.exe"
19083
19084         WIN_DAEMON_SRC="winrc/win_svc.c winrc/w_inst.c"
19085
19086         WIN_DAEMON_OBJ="win_svc.lo w_inst.lo"
19087
19088         WIN_DAEMON_OBJ_LINK="rsrc_unbound.o"
19089
19090         WIN_HOST_OBJ_LINK="rsrc_unbound_host.o"
19091
19092         WIN_UBANCHOR_OBJ_LINK="rsrc_unbound_anchor.o log.lo locks.lo"
19093
19094         WIN_CONTROL_OBJ_LINK="rsrc_unbound_control.o"
19095
19096         WIN_CHECKCONF_OBJ_LINK="rsrc_unbound_checkconf.o"
19097
19098 fi
19099 if test $ac_cv_func_getaddrinfo = no; then
19100         case " $LIBOBJS " in
19101   *" fake-rfc2553.$ac_objext "* ) ;;
19102   *) LIBOBJS="$LIBOBJS fake-rfc2553.$ac_objext"
19103  ;;
19104 esac
19105
19106 fi
19107 # check after getaddrinfo for its libraries
19108
19109 # check ioctlsocket
19110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctlsocket" >&5
19111 $as_echo_n "checking for ioctlsocket... " >&6; }
19112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19113 /* end confdefs.h.  */
19114
19115 #ifdef HAVE_WINSOCK2_H
19116 #include <winsock2.h>
19117 #endif
19118
19119 int
19120 main ()
19121 {
19122
19123         (void)ioctlsocket(0, 0, NULL);
19124
19125   ;
19126   return 0;
19127 }
19128 _ACEOF
19129 if ac_fn_c_try_link "$LINENO"; then :
19130
19131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19132 $as_echo "yes" >&6; }
19133
19134 $as_echo "#define HAVE_IOCTLSOCKET 1" >>confdefs.h
19135
19136
19137 else
19138   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19139 $as_echo "no" >&6; }
19140 fi
19141 rm -f core conftest.err conftest.$ac_objext \
19142     conftest$ac_exeext conftest.$ac_ext
19143
19144
19145 # see if daemon(3) exists, and if it is deprecated.
19146 for ac_func in daemon
19147 do :
19148   ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
19149 if test "x$ac_cv_func_daemon" = xyes; then :
19150   cat >>confdefs.h <<_ACEOF
19151 #define HAVE_DAEMON 1
19152 _ACEOF
19153
19154 fi
19155 done
19156
19157 if test $ac_cv_func_daemon = yes; then
19158
19159
19160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if daemon is deprecated" >&5
19161 $as_echo_n "checking if daemon is deprecated... " >&6; }
19162 cache=`echo daemon | sed 'y%.=/+-%___p_%'`
19163 if eval \${cv_cc_deprecated_$cache+:} false; then :
19164   $as_echo_n "(cached) " >&6
19165 else
19166
19167 echo '
19168 #include <stdlib.h>
19169 ' >conftest.c
19170 echo 'void f(){ (void)daemon(0, 0); }' >>conftest.c
19171 if test -z "`$CC -c conftest.c 2>&1 | grep deprecated`"; then
19172 eval "cv_cc_deprecated_$cache=no"
19173 else
19174 eval "cv_cc_deprecated_$cache=yes"
19175 fi
19176 rm -f conftest conftest.o conftest.c
19177
19178 fi
19179
19180 if eval "test \"`echo '$cv_cc_deprecated_'$cache`\" = yes"; then
19181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19182 $as_echo "yes" >&6; }
19183
19184 cat >>confdefs.h <<_ACEOF
19185 #define DEPRECATED_DAEMON 1
19186 _ACEOF
19187
19188 :
19189
19190 else
19191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19192 $as_echo "no" >&6; }
19193 :
19194
19195 fi
19196
19197 fi
19198
19199 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_len" "ac_cv_member_struct_sockaddr_un_sun_len" "
19200 $ac_includes_default
19201 #ifdef HAVE_SYS_UN_H
19202 #include <sys/un.h>
19203 #endif
19204
19205 "
19206 if test "x$ac_cv_member_struct_sockaddr_un_sun_len" = xyes; then :
19207
19208 cat >>confdefs.h <<_ACEOF
19209 #define HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 1
19210 _ACEOF
19211
19212
19213 fi
19214
19215 ac_fn_c_check_member "$LINENO" "struct in_pktinfo" "ipi_spec_dst" "ac_cv_member_struct_in_pktinfo_ipi_spec_dst" "
19216 $ac_includes_default
19217 #if HAVE_SYS_PARAM_H
19218 #include <sys/param.h>
19219 #endif
19220
19221 #ifdef HAVE_SYS_SOCKET_H
19222 #include <sys/socket.h>
19223 #endif
19224
19225 #ifdef HAVE_SYS_UIO_H
19226 #include <sys/uio.h>
19227 #endif
19228
19229 #ifdef HAVE_NETINET_IN_H
19230 #include <netinet/in.h>
19231 #endif
19232
19233 #ifdef HAVE_NETINET_TCP_H
19234 #include <netinet/tcp.h>
19235 #endif
19236
19237 #ifdef HAVE_ARPA_INET_H
19238 #include <arpa/inet.h>
19239 #endif
19240
19241 #ifdef HAVE_WINSOCK2_H
19242 #include <winsock2.h>
19243 #endif
19244
19245 #ifdef HAVE_WS2TCPIP_H
19246 #include <ws2tcpip.h>
19247 #endif
19248
19249 "
19250 if test "x$ac_cv_member_struct_in_pktinfo_ipi_spec_dst" = xyes; then :
19251
19252 cat >>confdefs.h <<_ACEOF
19253 #define HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST 1
19254 _ACEOF
19255
19256
19257 fi
19258
19259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setusercontext" >&5
19260 $as_echo_n "checking for library containing setusercontext... " >&6; }
19261 if ${ac_cv_search_setusercontext+:} false; then :
19262   $as_echo_n "(cached) " >&6
19263 else
19264   ac_func_search_save_LIBS=$LIBS
19265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19266 /* end confdefs.h.  */
19267
19268 /* Override any GCC internal prototype to avoid an error.
19269    Use char because int might match the return type of a GCC
19270    builtin and then its argument prototype would still apply.  */
19271 #ifdef __cplusplus
19272 extern "C"
19273 #endif
19274 char setusercontext ();
19275 int
19276 main ()
19277 {
19278 return setusercontext ();
19279   ;
19280   return 0;
19281 }
19282 _ACEOF
19283 for ac_lib in '' util; do
19284   if test -z "$ac_lib"; then
19285     ac_res="none required"
19286   else
19287     ac_res=-l$ac_lib
19288     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19289   fi
19290   if ac_fn_c_try_link "$LINENO"; then :
19291   ac_cv_search_setusercontext=$ac_res
19292 fi
19293 rm -f core conftest.err conftest.$ac_objext \
19294     conftest$ac_exeext
19295   if ${ac_cv_search_setusercontext+:} false; then :
19296   break
19297 fi
19298 done
19299 if ${ac_cv_search_setusercontext+:} false; then :
19300
19301 else
19302   ac_cv_search_setusercontext=no
19303 fi
19304 rm conftest.$ac_ext
19305 LIBS=$ac_func_search_save_LIBS
19306 fi
19307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setusercontext" >&5
19308 $as_echo "$ac_cv_search_setusercontext" >&6; }
19309 ac_res=$ac_cv_search_setusercontext
19310 if test "$ac_res" != no; then :
19311   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19312
19313 fi
19314
19315 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
19316 do :
19317   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19318 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
19319 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
19320   cat >>confdefs.h <<_ACEOF
19321 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19322 _ACEOF
19323
19324 fi
19325 done
19326
19327 for ac_func in setresuid
19328 do :
19329   ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
19330 if test "x$ac_cv_func_setresuid" = xyes; then :
19331   cat >>confdefs.h <<_ACEOF
19332 #define HAVE_SETRESUID 1
19333 _ACEOF
19334
19335 else
19336   for ac_func in setreuid
19337 do :
19338   ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid"
19339 if test "x$ac_cv_func_setreuid" = xyes; then :
19340   cat >>confdefs.h <<_ACEOF
19341 #define HAVE_SETREUID 1
19342 _ACEOF
19343
19344 fi
19345 done
19346
19347 fi
19348 done
19349
19350 for ac_func in setresgid
19351 do :
19352   ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
19353 if test "x$ac_cv_func_setresgid" = xyes; then :
19354   cat >>confdefs.h <<_ACEOF
19355 #define HAVE_SETRESGID 1
19356 _ACEOF
19357
19358 else
19359   for ac_func in setregid
19360 do :
19361   ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid"
19362 if test "x$ac_cv_func_setregid" = xyes; then :
19363   cat >>confdefs.h <<_ACEOF
19364 #define HAVE_SETREGID 1
19365 _ACEOF
19366
19367 fi
19368 done
19369
19370 fi
19371 done
19372
19373
19374 # check if setreuid en setregid fail, on MacOSX10.4(darwin8).
19375 if echo $build_os | grep darwin8 > /dev/null; then
19376
19377 $as_echo "#define DARWIN_BROKEN_SETREUID 1" >>confdefs.h
19378
19379 fi
19380 ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "
19381 $ac_includes_default
19382 #ifdef HAVE_NETINET_IN_H
19383 #include <netinet/in.h>
19384 #endif
19385
19386 #ifdef HAVE_NETINET_TCP_H
19387 #include <netinet/tcp.h>
19388 #endif
19389
19390 #ifdef HAVE_ARPA_INET_H
19391 #include <arpa/inet.h>
19392 #endif
19393
19394 #ifdef HAVE_WINSOCK2_H
19395 #include <winsock2.h>
19396 #endif
19397
19398 #ifdef HAVE_WS2TCPIP_H
19399 #include <ws2tcpip.h>
19400 #endif
19401
19402 "
19403 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
19404   ac_have_decl=1
19405 else
19406   ac_have_decl=0
19407 fi
19408
19409 cat >>confdefs.h <<_ACEOF
19410 #define HAVE_DECL_INET_PTON $ac_have_decl
19411 _ACEOF
19412 ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "
19413 $ac_includes_default
19414 #ifdef HAVE_NETINET_IN_H
19415 #include <netinet/in.h>
19416 #endif
19417
19418 #ifdef HAVE_NETINET_TCP_H
19419 #include <netinet/tcp.h>
19420 #endif
19421
19422 #ifdef HAVE_ARPA_INET_H
19423 #include <arpa/inet.h>
19424 #endif
19425
19426 #ifdef HAVE_WINSOCK2_H
19427 #include <winsock2.h>
19428 #endif
19429
19430 #ifdef HAVE_WS2TCPIP_H
19431 #include <ws2tcpip.h>
19432 #endif
19433
19434 "
19435 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
19436   ac_have_decl=1
19437 else
19438   ac_have_decl=0
19439 fi
19440
19441 cat >>confdefs.h <<_ACEOF
19442 #define HAVE_DECL_INET_NTOP $ac_have_decl
19443 _ACEOF
19444
19445 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
19446 if test "x$ac_cv_func_inet_aton" = xyes; then :
19447   $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
19448
19449 else
19450   case " $LIBOBJS " in
19451   *" inet_aton.$ac_objext "* ) ;;
19452   *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
19453  ;;
19454 esac
19455
19456 fi
19457
19458
19459 ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
19460 if test "x$ac_cv_func_inet_pton" = xyes; then :
19461   $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h
19462
19463 else
19464   case " $LIBOBJS " in
19465   *" inet_pton.$ac_objext "* ) ;;
19466   *) LIBOBJS="$LIBOBJS inet_pton.$ac_objext"
19467  ;;
19468 esac
19469
19470 fi
19471
19472
19473 ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
19474 if test "x$ac_cv_func_inet_ntop" = xyes; then :
19475   $as_echo "#define HAVE_INET_NTOP 1" >>confdefs.h
19476
19477 else
19478   case " $LIBOBJS " in
19479   *" inet_ntop.$ac_objext "* ) ;;
19480   *) LIBOBJS="$LIBOBJS inet_ntop.$ac_objext"
19481  ;;
19482 esac
19483
19484 fi
19485
19486
19487 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
19488 if test "x$ac_cv_func_snprintf" = xyes; then :
19489   $as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
19490
19491 else
19492   case " $LIBOBJS " in
19493   *" snprintf.$ac_objext "* ) ;;
19494   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
19495  ;;
19496 esac
19497
19498 fi
19499
19500
19501 # test if snprintf return the proper length
19502 if test "x$ac_cv_func_snprintf" = xyes; then
19503     if test c${cross_compiling} = cno; then
19504         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for correct snprintf return value" >&5
19505 $as_echo_n "checking for correct snprintf return value... " >&6; }
19506         if test "$cross_compiling" = yes; then :
19507   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19508 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19509 as_fn_error $? "cannot run test program while cross compiling
19510 See \`config.log' for more details" "$LINENO" 5; }
19511 else
19512   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19513 /* end confdefs.h.  */
19514 $ac_includes_default
19515
19516 int main(void) { return !(snprintf(NULL, 0, "test") == 4); }
19517
19518 _ACEOF
19519 if ac_fn_c_try_run "$LINENO"; then :
19520   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19521 $as_echo "yes" >&6; }
19522 else
19523
19524                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19525 $as_echo "no" >&6; }
19526
19527 $as_echo "#define SNPRINTF_RET_BROKEN /**/" >>confdefs.h
19528
19529                 case " $LIBOBJS " in
19530   *" snprintf.$ac_objext "* ) ;;
19531   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
19532  ;;
19533 esac
19534
19535
19536 fi
19537 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19538   conftest.$ac_objext conftest.beam conftest.$ac_ext
19539 fi
19540
19541     fi
19542 fi
19543 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
19544 if test "x$ac_cv_func_strlcat" = xyes; then :
19545   $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
19546
19547 else
19548   case " $LIBOBJS " in
19549   *" strlcat.$ac_objext "* ) ;;
19550   *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
19551  ;;
19552 esac
19553
19554 fi
19555
19556
19557 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
19558 if test "x$ac_cv_func_strlcpy" = xyes; then :
19559   $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
19560
19561 else
19562   case " $LIBOBJS " in
19563   *" strlcpy.$ac_objext "* ) ;;
19564   *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
19565  ;;
19566 esac
19567
19568 fi
19569
19570
19571 ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
19572 if test "x$ac_cv_func_memmove" = xyes; then :
19573   $as_echo "#define HAVE_MEMMOVE 1" >>confdefs.h
19574
19575 else
19576   case " $LIBOBJS " in
19577   *" memmove.$ac_objext "* ) ;;
19578   *) LIBOBJS="$LIBOBJS memmove.$ac_objext"
19579  ;;
19580 esac
19581
19582 fi
19583
19584
19585 ac_fn_c_check_func "$LINENO" "gmtime_r" "ac_cv_func_gmtime_r"
19586 if test "x$ac_cv_func_gmtime_r" = xyes; then :
19587   $as_echo "#define HAVE_GMTIME_R 1" >>confdefs.h
19588
19589 else
19590   case " $LIBOBJS " in
19591   *" gmtime_r.$ac_objext "* ) ;;
19592   *) LIBOBJS="$LIBOBJS gmtime_r.$ac_objext"
19593  ;;
19594 esac
19595
19596 fi
19597
19598
19599 ac_fn_c_check_func "$LINENO" "isblank" "ac_cv_func_isblank"
19600 if test "x$ac_cv_func_isblank" = xyes; then :
19601   $as_echo "#define HAVE_ISBLANK 1" >>confdefs.h
19602
19603 else
19604   case " $LIBOBJS " in
19605   *" isblank.$ac_objext "* ) ;;
19606   *) LIBOBJS="$LIBOBJS isblank.$ac_objext"
19607  ;;
19608 esac
19609
19610 fi
19611
19612
19613 LIBOBJ_WITHOUT_CTIMEARC4="$LIBOBJS"
19614
19615 ac_fn_c_check_func "$LINENO" "reallocarray" "ac_cv_func_reallocarray"
19616 if test "x$ac_cv_func_reallocarray" = xyes; then :
19617   $as_echo "#define HAVE_REALLOCARRAY 1" >>confdefs.h
19618
19619 else
19620   case " $LIBOBJS " in
19621   *" reallocarray.$ac_objext "* ) ;;
19622   *) LIBOBJS="$LIBOBJS reallocarray.$ac_objext"
19623  ;;
19624 esac
19625
19626 fi
19627
19628
19629 if test "$USE_NSS" = "no"; then
19630         ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
19631 if test "x$ac_cv_func_arc4random" = xyes; then :
19632   $as_echo "#define HAVE_ARC4RANDOM 1" >>confdefs.h
19633
19634 else
19635   case " $LIBOBJS " in
19636   *" arc4random.$ac_objext "* ) ;;
19637   *) LIBOBJS="$LIBOBJS arc4random.$ac_objext"
19638  ;;
19639 esac
19640
19641 fi
19642
19643
19644         ac_fn_c_check_func "$LINENO" "arc4random_uniform" "ac_cv_func_arc4random_uniform"
19645 if test "x$ac_cv_func_arc4random_uniform" = xyes; then :
19646   $as_echo "#define HAVE_ARC4RANDOM_UNIFORM 1" >>confdefs.h
19647
19648 else
19649   case " $LIBOBJS " in
19650   *" arc4random_uniform.$ac_objext "* ) ;;
19651   *) LIBOBJS="$LIBOBJS arc4random_uniform.$ac_objext"
19652  ;;
19653 esac
19654
19655 fi
19656
19657
19658         if test "$ac_cv_func_arc4random" = "no"; then
19659                 case " $LIBOBJS " in
19660   *" explicit_bzero.$ac_objext "* ) ;;
19661   *) LIBOBJS="$LIBOBJS explicit_bzero.$ac_objext"
19662  ;;
19663 esac
19664
19665                 case " $LIBOBJS " in
19666   *" arc4_lock.$ac_objext "* ) ;;
19667   *) LIBOBJS="$LIBOBJS arc4_lock.$ac_objext"
19668  ;;
19669 esac
19670
19671                 for ac_func in getentropy
19672 do :
19673   ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
19674 if test "x$ac_cv_func_getentropy" = xyes; then :
19675   cat >>confdefs.h <<_ACEOF
19676 #define HAVE_GETENTROPY 1
19677 _ACEOF
19678
19679 else
19680
19681                     if test "$USE_WINSOCK" = 1; then
19682                         case " $LIBOBJS " in
19683   *" getentropy_win.$ac_objext "* ) ;;
19684   *) LIBOBJS="$LIBOBJS getentropy_win.$ac_objext"
19685  ;;
19686 esac
19687
19688                     else
19689                         case "$host" in
19690                         Darwin|*darwin*)
19691                                 case " $LIBOBJS " in
19692   *" getentropy_osx.$ac_objext "* ) ;;
19693   *) LIBOBJS="$LIBOBJS getentropy_osx.$ac_objext"
19694  ;;
19695 esac
19696
19697                         ;;
19698                         *solaris*|*sunos*|SunOS)
19699                                 case " $LIBOBJS " in
19700   *" getentropy_solaris.$ac_objext "* ) ;;
19701   *) LIBOBJS="$LIBOBJS getentropy_solaris.$ac_objext"
19702  ;;
19703 esac
19704
19705                                 for ac_header in sys/sha2.h
19706 do :
19707   ac_fn_c_check_header_compile "$LINENO" "sys/sha2.h" "ac_cv_header_sys_sha2_h" "$ac_includes_default
19708 "
19709 if test "x$ac_cv_header_sys_sha2_h" = xyes; then :
19710   cat >>confdefs.h <<_ACEOF
19711 #define HAVE_SYS_SHA2_H 1
19712 _ACEOF
19713
19714 else
19715
19716                                         for ac_func in SHA512_Update
19717 do :
19718   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
19719 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
19720   cat >>confdefs.h <<_ACEOF
19721 #define HAVE_SHA512_UPDATE 1
19722 _ACEOF
19723
19724 else
19725
19726                                                 case " $LIBOBJS " in
19727   *" sha512.$ac_objext "* ) ;;
19728   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
19729  ;;
19730 esac
19731
19732
19733 fi
19734 done
19735
19736
19737 fi
19738
19739 done
19740
19741                                 if test "$ac_cv_header_sys_sha2_h" = "yes"; then
19742                                         # this lib needed for sha2 on solaris
19743                                         LIBS="$LIBS -lmd"
19744                                 fi
19745                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19746 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19747 if ${ac_cv_search_clock_gettime+:} false; then :
19748   $as_echo_n "(cached) " >&6
19749 else
19750   ac_func_search_save_LIBS=$LIBS
19751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19752 /* end confdefs.h.  */
19753
19754 /* Override any GCC internal prototype to avoid an error.
19755    Use char because int might match the return type of a GCC
19756    builtin and then its argument prototype would still apply.  */
19757 #ifdef __cplusplus
19758 extern "C"
19759 #endif
19760 char clock_gettime ();
19761 int
19762 main ()
19763 {
19764 return clock_gettime ();
19765   ;
19766   return 0;
19767 }
19768 _ACEOF
19769 for ac_lib in '' rt; do
19770   if test -z "$ac_lib"; then
19771     ac_res="none required"
19772   else
19773     ac_res=-l$ac_lib
19774     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19775   fi
19776   if ac_fn_c_try_link "$LINENO"; then :
19777   ac_cv_search_clock_gettime=$ac_res
19778 fi
19779 rm -f core conftest.err conftest.$ac_objext \
19780     conftest$ac_exeext
19781   if ${ac_cv_search_clock_gettime+:} false; then :
19782   break
19783 fi
19784 done
19785 if ${ac_cv_search_clock_gettime+:} false; then :
19786
19787 else
19788   ac_cv_search_clock_gettime=no
19789 fi
19790 rm conftest.$ac_ext
19791 LIBS=$ac_func_search_save_LIBS
19792 fi
19793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19794 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19795 ac_res=$ac_cv_search_clock_gettime
19796 if test "$ac_res" != no; then :
19797   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19798
19799 fi
19800
19801                         ;;
19802                         *linux*|Linux|*)
19803                                 case " $LIBOBJS " in
19804   *" getentropy_linux.$ac_objext "* ) ;;
19805   *) LIBOBJS="$LIBOBJS getentropy_linux.$ac_objext"
19806  ;;
19807 esac
19808
19809                                 for ac_func in SHA512_Update
19810 do :
19811   ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
19812 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
19813   cat >>confdefs.h <<_ACEOF
19814 #define HAVE_SHA512_UPDATE 1
19815 _ACEOF
19816
19817 else
19818
19819
19820 $as_echo "#define COMPAT_SHA512 1" >>confdefs.h
19821
19822                                         case " $LIBOBJS " in
19823   *" sha512.$ac_objext "* ) ;;
19824   *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
19825  ;;
19826 esac
19827
19828
19829 fi
19830 done
19831
19832                                 for ac_header in sys/sysctl.h
19833 do :
19834   ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default
19835 "
19836 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
19837   cat >>confdefs.h <<_ACEOF
19838 #define HAVE_SYS_SYSCTL_H 1
19839 _ACEOF
19840
19841 fi
19842
19843 done
19844
19845                                 for ac_func in getauxval
19846 do :
19847   ac_fn_c_check_func "$LINENO" "getauxval" "ac_cv_func_getauxval"
19848 if test "x$ac_cv_func_getauxval" = xyes; then :
19849   cat >>confdefs.h <<_ACEOF
19850 #define HAVE_GETAUXVAL 1
19851 _ACEOF
19852
19853 fi
19854 done
19855
19856                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19857 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19858 if ${ac_cv_search_clock_gettime+:} false; then :
19859   $as_echo_n "(cached) " >&6
19860 else
19861   ac_func_search_save_LIBS=$LIBS
19862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19863 /* end confdefs.h.  */
19864
19865 /* Override any GCC internal prototype to avoid an error.
19866    Use char because int might match the return type of a GCC
19867    builtin and then its argument prototype would still apply.  */
19868 #ifdef __cplusplus
19869 extern "C"
19870 #endif
19871 char clock_gettime ();
19872 int
19873 main ()
19874 {
19875 return clock_gettime ();
19876   ;
19877   return 0;
19878 }
19879 _ACEOF
19880 for ac_lib in '' rt; do
19881   if test -z "$ac_lib"; then
19882     ac_res="none required"
19883   else
19884     ac_res=-l$ac_lib
19885     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
19886   fi
19887   if ac_fn_c_try_link "$LINENO"; then :
19888   ac_cv_search_clock_gettime=$ac_res
19889 fi
19890 rm -f core conftest.err conftest.$ac_objext \
19891     conftest$ac_exeext
19892   if ${ac_cv_search_clock_gettime+:} false; then :
19893   break
19894 fi
19895 done
19896 if ${ac_cv_search_clock_gettime+:} false; then :
19897
19898 else
19899   ac_cv_search_clock_gettime=no
19900 fi
19901 rm conftest.$ac_ext
19902 LIBS=$ac_func_search_save_LIBS
19903 fi
19904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19905 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19906 ac_res=$ac_cv_search_clock_gettime
19907 if test "$ac_res" != no; then :
19908   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19909
19910 fi
19911
19912                         ;;
19913                         esac
19914                     fi
19915
19916 fi
19917 done
19918
19919         fi
19920 fi
19921 LIBOBJ_WITHOUT_CTIME="$LIBOBJS"
19922
19923 ac_fn_c_check_func "$LINENO" "ctime_r" "ac_cv_func_ctime_r"
19924 if test "x$ac_cv_func_ctime_r" = xyes; then :
19925   $as_echo "#define HAVE_CTIME_R 1" >>confdefs.h
19926
19927 else
19928   case " $LIBOBJS " in
19929   *" ctime_r.$ac_objext "* ) ;;
19930   *) LIBOBJS="$LIBOBJS ctime_r.$ac_objext"
19931  ;;
19932 esac
19933
19934 fi
19935
19936
19937 ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
19938 if test "x$ac_cv_func_strsep" = xyes; then :
19939   $as_echo "#define HAVE_STRSEP 1" >>confdefs.h
19940
19941 else
19942   case " $LIBOBJS " in
19943   *" strsep.$ac_objext "* ) ;;
19944   *) LIBOBJS="$LIBOBJS strsep.$ac_objext"
19945  ;;
19946 esac
19947
19948 fi
19949
19950
19951
19952 # Check whether --enable-allsymbols was given.
19953 if test "${enable_allsymbols+set}" = set; then :
19954   enableval=$enable_allsymbols;
19955 fi
19956
19957 case "$enable_allsymbols" in
19958         yes)
19959         COMMON_OBJ_ALL_SYMBOLS=""
19960         UBSYMS=""
19961         EXTRALINK="-L. -L.libs -lunbound"
19962
19963 $as_echo "#define EXPORT_ALL_SYMBOLS 1" >>confdefs.h
19964
19965         ;;
19966         no|*)
19967         COMMON_OBJ_ALL_SYMBOLS='$(COMMON_OBJ)'
19968         UBSYMS='-export-symbols $(srcdir)/libunbound/ubsyms.def'
19969         EXTRALINK=""
19970         ;;
19971 esac
19972
19973
19974
19975 if test x_$enable_lock_checks = x_yes; then
19976         UBSYMS="-export-symbols clubsyms.def"
19977         cp ${srcdir}/libunbound/ubsyms.def clubsyms.def
19978         echo lock_protect >> clubsyms.def
19979         echo lock_unprotect >> clubsyms.def
19980         echo lock_get_mem >> clubsyms.def
19981         echo checklock_start >> clubsyms.def
19982         echo checklock_stop >> clubsyms.def
19983         echo checklock_lock >> clubsyms.def
19984         echo checklock_unlock >> clubsyms.def
19985         echo checklock_init >> clubsyms.def
19986         echo checklock_thrcreate >> clubsyms.def
19987         echo checklock_thrjoin >> clubsyms.def
19988 fi
19989
19990 # check for dnstap if requested
19991
19992   # Check whether --enable-dnstap was given.
19993 if test "${enable_dnstap+set}" = set; then :
19994   enableval=$enable_dnstap; opt_dnstap=$enableval
19995 else
19996   opt_dnstap=no
19997 fi
19998
19999
20000
20001 # Check whether --with-dnstap-socket-path was given.
20002 if test "${with_dnstap_socket_path+set}" = set; then :
20003   withval=$with_dnstap_socket_path; opt_dnstap_socket_path=$withval
20004 else
20005   opt_dnstap_socket_path="$UNBOUND_RUN_DIR/dnstap.sock"
20006 fi
20007
20008
20009   if test "x$opt_dnstap" != "xno"; then
20010     # Extract the first word of "protoc-c", so it can be a program name with args.
20011 set dummy protoc-c; ac_word=$2
20012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20013 $as_echo_n "checking for $ac_word... " >&6; }
20014 if ${ac_cv_path_PROTOC_C+:} false; then :
20015   $as_echo_n "(cached) " >&6
20016 else
20017   case $PROTOC_C in
20018   [\\/]* | ?:[\\/]*)
20019   ac_cv_path_PROTOC_C="$PROTOC_C" # Let the user override the test with a path.
20020   ;;
20021   *)
20022   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20023 for as_dir in $PATH
20024 do
20025   IFS=$as_save_IFS
20026   test -z "$as_dir" && as_dir=.
20027     for ac_exec_ext in '' $ac_executable_extensions; do
20028   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20029     ac_cv_path_PROTOC_C="$as_dir/$ac_word$ac_exec_ext"
20030     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20031     break 2
20032   fi
20033 done
20034   done
20035 IFS=$as_save_IFS
20036
20037   ;;
20038 esac
20039 fi
20040 PROTOC_C=$ac_cv_path_PROTOC_C
20041 if test -n "$PROTOC_C"; then
20042   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROTOC_C" >&5
20043 $as_echo "$PROTOC_C" >&6; }
20044 else
20045   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20046 $as_echo "no" >&6; }
20047 fi
20048
20049
20050     if test -z "$PROTOC_C"; then
20051       as_fn_error $? "The protoc-c program was not found. Please install protobuf-c!" "$LINENO" 5
20052     fi
20053
20054 # Check whether --with-protobuf-c was given.
20055 if test "${with_protobuf_c+set}" = set; then :
20056   withval=$with_protobuf_c;
20057           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
20058           if test -f $withval/include/google/protobuf-c/protobuf-c.h; then
20059             CFLAGS="$CFLAGS -I$withval/include/google"
20060           else
20061             CFLAGS="$CFLAGS -I$withval/include"
20062           fi
20063           LDFLAGS="$LDFLAGS -L$withval/lib"
20064
20065 else
20066
20067           # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
20068           if test -f /usr/include/google/protobuf-c/protobuf-c.h; then
20069             CFLAGS="$CFLAGS -I/usr/include/google"
20070           else
20071             if test -f /usr/local/include/google/protobuf-c/protobuf-c.h; then
20072               CFLAGS="$CFLAGS -I/usr/local/include/google"
20073               LDFLAGS="$LDFLAGS -L/usr/local/lib"
20074             fi
20075           fi
20076
20077 fi
20078
20079
20080 # Check whether --with-libfstrm was given.
20081 if test "${with_libfstrm+set}" = set; then :
20082   withval=$with_libfstrm;
20083         CFLAGS="$CFLAGS -I$withval/include"
20084         LDFLAGS="$LDFLAGS -L$withval/lib"
20085
20086 fi
20087
20088     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fstrm_iothr_init" >&5
20089 $as_echo_n "checking for library containing fstrm_iothr_init... " >&6; }
20090 if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20091   $as_echo_n "(cached) " >&6
20092 else
20093   ac_func_search_save_LIBS=$LIBS
20094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20095 /* end confdefs.h.  */
20096
20097 /* Override any GCC internal prototype to avoid an error.
20098    Use char because int might match the return type of a GCC
20099    builtin and then its argument prototype would still apply.  */
20100 #ifdef __cplusplus
20101 extern "C"
20102 #endif
20103 char fstrm_iothr_init ();
20104 int
20105 main ()
20106 {
20107 return fstrm_iothr_init ();
20108   ;
20109   return 0;
20110 }
20111 _ACEOF
20112 for ac_lib in '' fstrm; do
20113   if test -z "$ac_lib"; then
20114     ac_res="none required"
20115   else
20116     ac_res=-l$ac_lib
20117     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20118   fi
20119   if ac_fn_c_try_link "$LINENO"; then :
20120   ac_cv_search_fstrm_iothr_init=$ac_res
20121 fi
20122 rm -f core conftest.err conftest.$ac_objext \
20123     conftest$ac_exeext
20124   if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20125   break
20126 fi
20127 done
20128 if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20129
20130 else
20131   ac_cv_search_fstrm_iothr_init=no
20132 fi
20133 rm conftest.$ac_ext
20134 LIBS=$ac_func_search_save_LIBS
20135 fi
20136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fstrm_iothr_init" >&5
20137 $as_echo "$ac_cv_search_fstrm_iothr_init" >&6; }
20138 ac_res=$ac_cv_search_fstrm_iothr_init
20139 if test "$ac_res" != no; then :
20140   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20141
20142 else
20143   as_fn_error $? "The fstrm library was not found. Please install fstrm!" "$LINENO" 5
20144 fi
20145
20146     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing protobuf_c_message_pack" >&5
20147 $as_echo_n "checking for library containing protobuf_c_message_pack... " >&6; }
20148 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20149   $as_echo_n "(cached) " >&6
20150 else
20151   ac_func_search_save_LIBS=$LIBS
20152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20153 /* end confdefs.h.  */
20154
20155 /* Override any GCC internal prototype to avoid an error.
20156    Use char because int might match the return type of a GCC
20157    builtin and then its argument prototype would still apply.  */
20158 #ifdef __cplusplus
20159 extern "C"
20160 #endif
20161 char protobuf_c_message_pack ();
20162 int
20163 main ()
20164 {
20165 return protobuf_c_message_pack ();
20166   ;
20167   return 0;
20168 }
20169 _ACEOF
20170 for ac_lib in '' protobuf-c; do
20171   if test -z "$ac_lib"; then
20172     ac_res="none required"
20173   else
20174     ac_res=-l$ac_lib
20175     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20176   fi
20177   if ac_fn_c_try_link "$LINENO"; then :
20178   ac_cv_search_protobuf_c_message_pack=$ac_res
20179 fi
20180 rm -f core conftest.err conftest.$ac_objext \
20181     conftest$ac_exeext
20182   if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20183   break
20184 fi
20185 done
20186 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20187
20188 else
20189   ac_cv_search_protobuf_c_message_pack=no
20190 fi
20191 rm conftest.$ac_ext
20192 LIBS=$ac_func_search_save_LIBS
20193 fi
20194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_protobuf_c_message_pack" >&5
20195 $as_echo "$ac_cv_search_protobuf_c_message_pack" >&6; }
20196 ac_res=$ac_cv_search_protobuf_c_message_pack
20197 if test "$ac_res" != no; then :
20198   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20199
20200 else
20201   as_fn_error $? "The protobuf-c library was not found. Please install protobuf-c!" "$LINENO" 5
20202 fi
20203
20204
20205
20206 $as_echo "#define USE_DNSTAP 1" >>confdefs.h
20207
20208         ENABLE_DNSTAP=1
20209
20210
20211
20212         hdr_dnstap_socket_path="`echo $opt_dnstap_socket_path | sed -e 's/\\\\/\\\\\\\\/g'`"
20213
20214
20215 cat >>confdefs.h <<_ACEOF
20216 #define DNSTAP_SOCKET_PATH "$hdr_dnstap_socket_path"
20217 _ACEOF
20218
20219
20220         DNSTAP_SRC="dnstap/dnstap.c dnstap/dnstap.pb-c.c"
20221
20222         DNSTAP_OBJ="dnstap.lo dnstap.pb-c.lo"
20223
20224
20225   else
20226
20227         ENABLE_DNSTAP=0
20228
20229
20230
20231   fi
20232
20233
20234 # check for dnscrypt if requested
20235
20236   # Check whether --enable-dnscrypt was given.
20237 if test "${enable_dnscrypt+set}" = set; then :
20238   enableval=$enable_dnscrypt; opt_dnscrypt=$enableval
20239 else
20240   opt_dnscrypt=no
20241 fi
20242
20243
20244   if test "x$opt_dnscrypt" != "xno"; then
20245
20246 # Check whether --with-libsodium was given.
20247 if test "${with_libsodium+set}" = set; then :
20248   withval=$with_libsodium;
20249         CFLAGS="$CFLAGS -I$withval/include"
20250         LDFLAGS="$LDFLAGS -L$withval/lib"
20251
20252 fi
20253
20254     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_init" >&5
20255 $as_echo_n "checking for library containing sodium_init... " >&6; }
20256 if ${ac_cv_search_sodium_init+:} false; then :
20257   $as_echo_n "(cached) " >&6
20258 else
20259   ac_func_search_save_LIBS=$LIBS
20260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20261 /* end confdefs.h.  */
20262
20263 /* Override any GCC internal prototype to avoid an error.
20264    Use char because int might match the return type of a GCC
20265    builtin and then its argument prototype would still apply.  */
20266 #ifdef __cplusplus
20267 extern "C"
20268 #endif
20269 char sodium_init ();
20270 int
20271 main ()
20272 {
20273 return sodium_init ();
20274   ;
20275   return 0;
20276 }
20277 _ACEOF
20278 for ac_lib in '' sodium; do
20279   if test -z "$ac_lib"; then
20280     ac_res="none required"
20281   else
20282     ac_res=-l$ac_lib
20283     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20284   fi
20285   if ac_fn_c_try_link "$LINENO"; then :
20286   ac_cv_search_sodium_init=$ac_res
20287 fi
20288 rm -f core conftest.err conftest.$ac_objext \
20289     conftest$ac_exeext
20290   if ${ac_cv_search_sodium_init+:} false; then :
20291   break
20292 fi
20293 done
20294 if ${ac_cv_search_sodium_init+:} false; then :
20295
20296 else
20297   ac_cv_search_sodium_init=no
20298 fi
20299 rm conftest.$ac_ext
20300 LIBS=$ac_func_search_save_LIBS
20301 fi
20302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_init" >&5
20303 $as_echo "$ac_cv_search_sodium_init" >&6; }
20304 ac_res=$ac_cv_search_sodium_init
20305 if test "$ac_res" != no; then :
20306   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20307
20308 else
20309   as_fn_error $? "The sodium library was not found. Please install sodium!" "$LINENO" 5
20310 fi
20311
20312
20313
20314 $as_echo "#define USE_DNSCRYPT 1" >>confdefs.h
20315
20316         ENABLE_DNSCRYPT=1
20317
20318
20319         DNSCRYPT_SRC="dnscrypt/dnscrypt.c"
20320
20321         DNSCRYPT_OBJ="dnscrypt.lo"
20322
20323
20324   else
20325
20326         ENABLE_DNSCRYPT=0
20327
20328
20329
20330   fi
20331
20332
20333 # check for cachedb if requested
20334 # Check whether --enable-cachedb was given.
20335 if test "${enable_cachedb+set}" = set; then :
20336   enableval=$enable_cachedb;
20337 fi
20338
20339 case "$enable_cachedb" in
20340     yes)
20341
20342 $as_echo "#define USE_CACHEDB 1" >>confdefs.h
20343
20344         ;;
20345     no|*)
20346         # nothing
20347         ;;
20348 esac
20349
20350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ${MAKE:-make} supports $< with implicit rule in scope" >&5
20351 $as_echo_n "checking if ${MAKE:-make} supports $< with implicit rule in scope... " >&6; }
20352 # on openBSD, the implicit rule make $< work.
20353 # on Solaris, it does not work ($? is changed sources, $^ lists dependencies).
20354 # gmake works.
20355 cat >conftest.make <<EOF
20356 all:    conftest.lo
20357
20358 conftest.lo foo.lo bla.lo:
20359         if test -f "\$<"; then touch \$@; fi
20360
20361 .SUFFIXES: .lo
20362 .c.lo:
20363         if test -f "\$<"; then touch \$@; fi
20364
20365 conftest.lo:        conftest.dir/conftest.c
20366 EOF
20367 mkdir conftest.dir
20368 touch conftest.dir/conftest.c
20369 rm -f conftest.lo conftest.c
20370 ${MAKE:-make} -f conftest.make >/dev/null
20371 rm -f conftest.make conftest.c conftest.dir/conftest.c
20372 rm -rf conftest.dir
20373 if test ! -f conftest.lo; then
20374         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20375 $as_echo "no" >&6; }
20376         SOURCEDETERMINE='echo "$^" | awk "-F " "{print \$$1;}" > .source'
20377         SOURCEFILE='`cat .source`'
20378 else
20379         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20380 $as_echo "yes" >&6; }
20381         SOURCEDETERMINE=':'
20382         SOURCEFILE='$<'
20383 fi
20384 rm -f conftest.lo
20385
20386
20387
20388 # see if we want to build the library or everything
20389 ALLTARGET="alltargets"
20390 INSTALLTARGET="install-all"
20391
20392 # Check whether --with-libunbound-only was given.
20393 if test "${with_libunbound_only+set}" = set; then :
20394   withval=$with_libunbound_only;
20395         if test "$withval" = "yes"; then
20396                 ALLTARGET="lib"
20397                 INSTALLTARGET="install-lib"
20398         fi
20399
20400 fi
20401
20402
20403
20404
20405
20406   { $as_echo "$as_me:${as_lineno-$LINENO}: Stripping extension flags..." >&5
20407 $as_echo "$as_me: Stripping extension flags..." >&6;}
20408
20409   if echo $CFLAGS | grep " -D_GNU_SOURCE" >/dev/null 2>&1; then
20410     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_GNU_SOURCE//g'`"
20411
20412 $as_echo "#define OMITTED__D_GNU_SOURCE 1" >>confdefs.h
20413
20414   fi
20415
20416
20417   if echo $CFLAGS | grep " -D_BSD_SOURCE" >/dev/null 2>&1; then
20418     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_BSD_SOURCE//g'`"
20419
20420 $as_echo "#define OMITTED__D_BSD_SOURCE 1" >>confdefs.h
20421
20422   fi
20423
20424
20425   if echo $CFLAGS | grep " -D_DEFAULT_SOURCE" >/dev/null 2>&1; then
20426     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_DEFAULT_SOURCE//g'`"
20427
20428 $as_echo "#define OMITTED__D_DEFAULT_SOURCE 1" >>confdefs.h
20429
20430   fi
20431
20432
20433   if echo $CFLAGS | grep " -D__EXTENSIONS__" >/dev/null 2>&1; then
20434     CFLAGS="`echo $CFLAGS | sed -e 's/ -D__EXTENSIONS__//g'`"
20435
20436 $as_echo "#define OMITTED__D__EXTENSIONS__ 1" >>confdefs.h
20437
20438   fi
20439
20440
20441   if echo $CFLAGS | grep " -D_POSIX_C_SOURCE=200112" >/dev/null 2>&1; then
20442     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_POSIX_C_SOURCE=200112//g'`"
20443
20444 $as_echo "#define OMITTED__D_POSIX_C_SOURCE_200112 1" >>confdefs.h
20445
20446   fi
20447
20448
20449   if echo $CFLAGS | grep " -D_XOPEN_SOURCE=600" >/dev/null 2>&1; then
20450     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE=600//g'`"
20451
20452 $as_echo "#define OMITTED__D_XOPEN_SOURCE_600 1" >>confdefs.h
20453
20454   fi
20455
20456
20457   if echo $CFLAGS | grep " -D_XOPEN_SOURCE_EXTENDED=1" >/dev/null 2>&1; then
20458     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE_EXTENDED=1//g'`"
20459
20460 $as_echo "#define OMITTED__D_XOPEN_SOURCE_EXTENDED_1 1" >>confdefs.h
20461
20462   fi
20463
20464
20465   if echo $CFLAGS | grep " -D_ALL_SOURCE" >/dev/null 2>&1; then
20466     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_ALL_SOURCE//g'`"
20467
20468 $as_echo "#define OMITTED__D_ALL_SOURCE 1" >>confdefs.h
20469
20470   fi
20471
20472
20473   if echo $CFLAGS | grep " -D_LARGEFILE_SOURCE=1" >/dev/null 2>&1; then
20474     CFLAGS="`echo $CFLAGS | sed -e 's/ -D_LARGEFILE_SOURCE=1//g'`"
20475
20476 $as_echo "#define OMITTED__D_LARGEFILE_SOURCE_1 1" >>confdefs.h
20477
20478   fi
20479
20480
20481 LDFLAGS="$LATE_LDFLAGS $LDFLAGS"
20482
20483
20484 cat >>confdefs.h <<_ACEOF
20485 #define MAXSYSLOGMSGLEN 10240
20486 _ACEOF
20487
20488
20489
20490
20491 version=1.6.3
20492
20493 date=`date +'%b %e, %Y'`
20494
20495
20496 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"
20497
20498 ac_config_headers="$ac_config_headers config.h"
20499
20500 cat >confcache <<\_ACEOF
20501 # This file is a shell script that caches the results of configure
20502 # tests run on this system so they can be shared between configure
20503 # scripts and configure runs, see configure's option --config-cache.
20504 # It is not useful on other systems.  If it contains results you don't
20505 # want to keep, you may remove or edit it.
20506 #
20507 # config.status only pays attention to the cache file if you give it
20508 # the --recheck option to rerun configure.
20509 #
20510 # `ac_cv_env_foo' variables (set or unset) will be overridden when
20511 # loading this file, other *unset* `ac_cv_foo' will be assigned the
20512 # following values.
20513
20514 _ACEOF
20515
20516 # The following way of writing the cache mishandles newlines in values,
20517 # but we know of no workaround that is simple, portable, and efficient.
20518 # So, we kill variables containing newlines.
20519 # Ultrix sh set writes to stderr and can't be redirected directly,
20520 # and sets the high bit in the cache file unless we assign to the vars.
20521 (
20522   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
20523     eval ac_val=\$$ac_var
20524     case $ac_val in #(
20525     *${as_nl}*)
20526       case $ac_var in #(
20527       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
20528 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
20529       esac
20530       case $ac_var in #(
20531       _ | IFS | as_nl) ;; #(
20532       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
20533       *) { eval $ac_var=; unset $ac_var;} ;;
20534       esac ;;
20535     esac
20536   done
20537
20538   (set) 2>&1 |
20539     case $as_nl`(ac_space=' '; set) 2>&1` in #(
20540     *${as_nl}ac_space=\ *)
20541       # `set' does not quote correctly, so add quotes: double-quote
20542       # substitution turns \\\\ into \\, and sed turns \\ into \.
20543       sed -n \
20544         "s/'/'\\\\''/g;
20545           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
20546       ;; #(
20547     *)
20548       # `set' quotes correctly as required by POSIX, so do not add quotes.
20549       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
20550       ;;
20551     esac |
20552     sort
20553 ) |
20554   sed '
20555      /^ac_cv_env_/b end
20556      t clear
20557      :clear
20558      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
20559      t end
20560      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
20561      :end' >>confcache
20562 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
20563   if test -w "$cache_file"; then
20564     if test "x$cache_file" != "x/dev/null"; then
20565       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
20566 $as_echo "$as_me: updating cache $cache_file" >&6;}
20567       if test ! -f "$cache_file" || test -h "$cache_file"; then
20568         cat confcache >"$cache_file"
20569       else
20570         case $cache_file in #(
20571         */* | ?:*)
20572           mv -f confcache "$cache_file"$$ &&
20573           mv -f "$cache_file"$$ "$cache_file" ;; #(
20574         *)
20575           mv -f confcache "$cache_file" ;;
20576         esac
20577       fi
20578     fi
20579   else
20580     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
20581 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
20582   fi
20583 fi
20584 rm -f confcache
20585
20586 test "x$prefix" = xNONE && prefix=$ac_default_prefix
20587 # Let make expand exec_prefix.
20588 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
20589
20590 DEFS=-DHAVE_CONFIG_H
20591
20592 ac_libobjs=
20593 ac_ltlibobjs=
20594 U=
20595 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
20596   # 1. Remove the extension, and $U if already installed.
20597   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
20598   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
20599   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
20600   #    will be set to the directory where LIBOBJS objects are built.
20601   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
20602   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
20603 done
20604 LIBOBJS=$ac_libobjs
20605
20606 LTLIBOBJS=$ac_ltlibobjs
20607
20608
20609 if test -z "${USE_SYSTEMD_TRUE}" && test -z "${USE_SYSTEMD_FALSE}"; then
20610   as_fn_error $? "conditional \"USE_SYSTEMD\" was never defined.
20611 Usually this means the macro was only invoked conditionally." "$LINENO" 5
20612 fi
20613
20614 : "${CONFIG_STATUS=./config.status}"
20615 ac_write_fail=0
20616 ac_clean_files_save=$ac_clean_files
20617 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
20618 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
20619 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
20620 as_write_fail=0
20621 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
20622 #! $SHELL
20623 # Generated by $as_me.
20624 # Run this file to recreate the current configuration.
20625 # Compiler output produced by configure, useful for debugging
20626 # configure, is in config.log if it exists.
20627
20628 debug=false
20629 ac_cs_recheck=false
20630 ac_cs_silent=false
20631
20632 SHELL=\${CONFIG_SHELL-$SHELL}
20633 export SHELL
20634 _ASEOF
20635 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
20636 ## -------------------- ##
20637 ## M4sh Initialization. ##
20638 ## -------------------- ##
20639
20640 # Be more Bourne compatible
20641 DUALCASE=1; export DUALCASE # for MKS sh
20642 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20643   emulate sh
20644   NULLCMD=:
20645   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
20646   # is contrary to our usage.  Disable this feature.
20647   alias -g '${1+"$@"}'='"$@"'
20648   setopt NO_GLOB_SUBST
20649 else
20650   case `(set -o) 2>/dev/null` in #(
20651   *posix*) :
20652     set -o posix ;; #(
20653   *) :
20654      ;;
20655 esac
20656 fi
20657
20658
20659 as_nl='
20660 '
20661 export as_nl
20662 # Printing a long string crashes Solaris 7 /usr/bin/printf.
20663 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
20664 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
20665 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
20666 # Prefer a ksh shell builtin over an external printf program on Solaris,
20667 # but without wasting forks for bash or zsh.
20668 if test -z "$BASH_VERSION$ZSH_VERSION" \
20669     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
20670   as_echo='print -r --'
20671   as_echo_n='print -rn --'
20672 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
20673   as_echo='printf %s\n'
20674   as_echo_n='printf %s'
20675 else
20676   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
20677     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
20678     as_echo_n='/usr/ucb/echo -n'
20679   else
20680     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
20681     as_echo_n_body='eval
20682       arg=$1;
20683       case $arg in #(
20684       *"$as_nl"*)
20685         expr "X$arg" : "X\\(.*\\)$as_nl";
20686         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
20687       esac;
20688       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
20689     '
20690     export as_echo_n_body
20691     as_echo_n='sh -c $as_echo_n_body as_echo'
20692   fi
20693   export as_echo_body
20694   as_echo='sh -c $as_echo_body as_echo'
20695 fi
20696
20697 # The user is always right.
20698 if test "${PATH_SEPARATOR+set}" != set; then
20699   PATH_SEPARATOR=:
20700   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
20701     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
20702       PATH_SEPARATOR=';'
20703   }
20704 fi
20705
20706
20707 # IFS
20708 # We need space, tab and new line, in precisely that order.  Quoting is
20709 # there to prevent editors from complaining about space-tab.
20710 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
20711 # splitting by setting IFS to empty value.)
20712 IFS=" ""        $as_nl"
20713
20714 # Find who we are.  Look in the path if we contain no directory separator.
20715 as_myself=
20716 case $0 in #((
20717   *[\\/]* ) as_myself=$0 ;;
20718   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20719 for as_dir in $PATH
20720 do
20721   IFS=$as_save_IFS
20722   test -z "$as_dir" && as_dir=.
20723     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
20724   done
20725 IFS=$as_save_IFS
20726
20727      ;;
20728 esac
20729 # We did not find ourselves, most probably we were run as `sh COMMAND'
20730 # in which case we are not to be found in the path.
20731 if test "x$as_myself" = x; then
20732   as_myself=$0
20733 fi
20734 if test ! -f "$as_myself"; then
20735   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
20736   exit 1
20737 fi
20738
20739 # Unset variables that we do not need and which cause bugs (e.g. in
20740 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
20741 # suppresses any "Segmentation fault" message there.  '((' could
20742 # trigger a bug in pdksh 5.2.14.
20743 for as_var in BASH_ENV ENV MAIL MAILPATH
20744 do eval test x\${$as_var+set} = xset \
20745   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
20746 done
20747 PS1='$ '
20748 PS2='> '
20749 PS4='+ '
20750
20751 # NLS nuisances.
20752 LC_ALL=C
20753 export LC_ALL
20754 LANGUAGE=C
20755 export LANGUAGE
20756
20757 # CDPATH.
20758 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
20759
20760
20761 # as_fn_error STATUS ERROR [LINENO LOG_FD]
20762 # ----------------------------------------
20763 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
20764 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
20765 # script with STATUS, using 1 if that was 0.
20766 as_fn_error ()
20767 {
20768   as_status=$1; test $as_status -eq 0 && as_status=1
20769   if test "$4"; then
20770     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
20771     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
20772   fi
20773   $as_echo "$as_me: error: $2" >&2
20774   as_fn_exit $as_status
20775 } # as_fn_error
20776
20777
20778 # as_fn_set_status STATUS
20779 # -----------------------
20780 # Set $? to STATUS, without forking.
20781 as_fn_set_status ()
20782 {
20783   return $1
20784 } # as_fn_set_status
20785
20786 # as_fn_exit STATUS
20787 # -----------------
20788 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
20789 as_fn_exit ()
20790 {
20791   set +e
20792   as_fn_set_status $1
20793   exit $1
20794 } # as_fn_exit
20795
20796 # as_fn_unset VAR
20797 # ---------------
20798 # Portably unset VAR.
20799 as_fn_unset ()
20800 {
20801   { eval $1=; unset $1;}
20802 }
20803 as_unset=as_fn_unset
20804 # as_fn_append VAR VALUE
20805 # ----------------------
20806 # Append the text in VALUE to the end of the definition contained in VAR. Take
20807 # advantage of any shell optimizations that allow amortized linear growth over
20808 # repeated appends, instead of the typical quadratic growth present in naive
20809 # implementations.
20810 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
20811   eval 'as_fn_append ()
20812   {
20813     eval $1+=\$2
20814   }'
20815 else
20816   as_fn_append ()
20817   {
20818     eval $1=\$$1\$2
20819   }
20820 fi # as_fn_append
20821
20822 # as_fn_arith ARG...
20823 # ------------------
20824 # Perform arithmetic evaluation on the ARGs, and store the result in the
20825 # global $as_val. Take advantage of shells that can avoid forks. The arguments
20826 # must be portable across $(()) and expr.
20827 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
20828   eval 'as_fn_arith ()
20829   {
20830     as_val=$(( $* ))
20831   }'
20832 else
20833   as_fn_arith ()
20834   {
20835     as_val=`expr "$@" || test $? -eq 1`
20836   }
20837 fi # as_fn_arith
20838
20839
20840 if expr a : '\(a\)' >/dev/null 2>&1 &&
20841    test "X`expr 00001 : '.*\(...\)'`" = X001; then
20842   as_expr=expr
20843 else
20844   as_expr=false
20845 fi
20846
20847 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
20848   as_basename=basename
20849 else
20850   as_basename=false
20851 fi
20852
20853 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
20854   as_dirname=dirname
20855 else
20856   as_dirname=false
20857 fi
20858
20859 as_me=`$as_basename -- "$0" ||
20860 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
20861          X"$0" : 'X\(//\)$' \| \
20862          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
20863 $as_echo X/"$0" |
20864     sed '/^.*\/\([^/][^/]*\)\/*$/{
20865             s//\1/
20866             q
20867           }
20868           /^X\/\(\/\/\)$/{
20869             s//\1/
20870             q
20871           }
20872           /^X\/\(\/\).*/{
20873             s//\1/
20874             q
20875           }
20876           s/.*/./; q'`
20877
20878 # Avoid depending upon Character Ranges.
20879 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
20880 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
20881 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
20882 as_cr_digits='0123456789'
20883 as_cr_alnum=$as_cr_Letters$as_cr_digits
20884
20885 ECHO_C= ECHO_N= ECHO_T=
20886 case `echo -n x` in #(((((
20887 -n*)
20888   case `echo 'xy\c'` in
20889   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
20890   xy)  ECHO_C='\c';;
20891   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
20892        ECHO_T=' ';;
20893   esac;;
20894 *)
20895   ECHO_N='-n';;
20896 esac
20897
20898 rm -f conf$$ conf$$.exe conf$$.file
20899 if test -d conf$$.dir; then
20900   rm -f conf$$.dir/conf$$.file
20901 else
20902   rm -f conf$$.dir
20903   mkdir conf$$.dir 2>/dev/null
20904 fi
20905 if (echo >conf$$.file) 2>/dev/null; then
20906   if ln -s conf$$.file conf$$ 2>/dev/null; then
20907     as_ln_s='ln -s'
20908     # ... but there are two gotchas:
20909     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
20910     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
20911     # In both cases, we have to default to `cp -pR'.
20912     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
20913       as_ln_s='cp -pR'
20914   elif ln conf$$.file conf$$ 2>/dev/null; then
20915     as_ln_s=ln
20916   else
20917     as_ln_s='cp -pR'
20918   fi
20919 else
20920   as_ln_s='cp -pR'
20921 fi
20922 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
20923 rmdir conf$$.dir 2>/dev/null
20924
20925
20926 # as_fn_mkdir_p
20927 # -------------
20928 # Create "$as_dir" as a directory, including parents if necessary.
20929 as_fn_mkdir_p ()
20930 {
20931
20932   case $as_dir in #(
20933   -*) as_dir=./$as_dir;;
20934   esac
20935   test -d "$as_dir" || eval $as_mkdir_p || {
20936     as_dirs=
20937     while :; do
20938       case $as_dir in #(
20939       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
20940       *) as_qdir=$as_dir;;
20941       esac
20942       as_dirs="'$as_qdir' $as_dirs"
20943       as_dir=`$as_dirname -- "$as_dir" ||
20944 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20945          X"$as_dir" : 'X\(//\)[^/]' \| \
20946          X"$as_dir" : 'X\(//\)$' \| \
20947          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
20948 $as_echo X"$as_dir" |
20949     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20950             s//\1/
20951             q
20952           }
20953           /^X\(\/\/\)[^/].*/{
20954             s//\1/
20955             q
20956           }
20957           /^X\(\/\/\)$/{
20958             s//\1/
20959             q
20960           }
20961           /^X\(\/\).*/{
20962             s//\1/
20963             q
20964           }
20965           s/.*/./; q'`
20966       test -d "$as_dir" && break
20967     done
20968     test -z "$as_dirs" || eval "mkdir $as_dirs"
20969   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
20970
20971
20972 } # as_fn_mkdir_p
20973 if mkdir -p . 2>/dev/null; then
20974   as_mkdir_p='mkdir -p "$as_dir"'
20975 else
20976   test -d ./-p && rmdir ./-p
20977   as_mkdir_p=false
20978 fi
20979
20980
20981 # as_fn_executable_p FILE
20982 # -----------------------
20983 # Test if FILE is an executable regular file.
20984 as_fn_executable_p ()
20985 {
20986   test -f "$1" && test -x "$1"
20987 } # as_fn_executable_p
20988 as_test_x='test -x'
20989 as_executable_p=as_fn_executable_p
20990
20991 # Sed expression to map a string onto a valid CPP name.
20992 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
20993
20994 # Sed expression to map a string onto a valid variable name.
20995 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
20996
20997
20998 exec 6>&1
20999 ## ----------------------------------- ##
21000 ## Main body of $CONFIG_STATUS script. ##
21001 ## ----------------------------------- ##
21002 _ASEOF
21003 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
21004
21005 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21006 # Save the log message, to keep $0 and so on meaningful, and to
21007 # report actual input values of CONFIG_FILES etc. instead of their
21008 # values after options handling.
21009 ac_log="
21010 This file was extended by unbound $as_me 1.6.3, which was
21011 generated by GNU Autoconf 2.69.  Invocation command line was
21012
21013   CONFIG_FILES    = $CONFIG_FILES
21014   CONFIG_HEADERS  = $CONFIG_HEADERS
21015   CONFIG_LINKS    = $CONFIG_LINKS
21016   CONFIG_COMMANDS = $CONFIG_COMMANDS
21017   $ $0 $@
21018
21019 on `(hostname || uname -n) 2>/dev/null | sed 1q`
21020 "
21021
21022 _ACEOF
21023
21024 case $ac_config_files in *"
21025 "*) set x $ac_config_files; shift; ac_config_files=$*;;
21026 esac
21027
21028 case $ac_config_headers in *"
21029 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
21030 esac
21031
21032
21033 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21034 # Files that config.status was made for.
21035 config_files="$ac_config_files"
21036 config_headers="$ac_config_headers"
21037 config_commands="$ac_config_commands"
21038
21039 _ACEOF
21040
21041 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21042 ac_cs_usage="\
21043 \`$as_me' instantiates files and other configuration actions
21044 from templates according to the current configuration.  Unless the files
21045 and actions are specified as TAGs, all are instantiated by default.
21046
21047 Usage: $0 [OPTION]... [TAG]...
21048
21049   -h, --help       print this help, then exit
21050   -V, --version    print version number and configuration settings, then exit
21051       --config     print configuration, then exit
21052   -q, --quiet, --silent
21053                    do not print progress messages
21054   -d, --debug      don't remove temporary files
21055       --recheck    update $as_me by reconfiguring in the same conditions
21056       --file=FILE[:TEMPLATE]
21057                    instantiate the configuration file FILE
21058       --header=FILE[:TEMPLATE]
21059                    instantiate the configuration header FILE
21060
21061 Configuration files:
21062 $config_files
21063
21064 Configuration headers:
21065 $config_headers
21066
21067 Configuration commands:
21068 $config_commands
21069
21070 Report bugs to <unbound-bugs@nlnetlabs.nl>."
21071
21072 _ACEOF
21073 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21074 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
21075 ac_cs_version="\\
21076 unbound config.status 1.6.3
21077 configured by $0, generated by GNU Autoconf 2.69,
21078   with options \\"\$ac_cs_config\\"
21079
21080 Copyright (C) 2012 Free Software Foundation, Inc.
21081 This config.status script is free software; the Free Software Foundation
21082 gives unlimited permission to copy, distribute and modify it."
21083
21084 ac_pwd='$ac_pwd'
21085 srcdir='$srcdir'
21086 AWK='$AWK'
21087 test -n "\$AWK" || AWK=awk
21088 _ACEOF
21089
21090 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21091 # The default lists apply if the user does not specify any file.
21092 ac_need_defaults=:
21093 while test $# != 0
21094 do
21095   case $1 in
21096   --*=?*)
21097     ac_option=`expr "X$1" : 'X\([^=]*\)='`
21098     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
21099     ac_shift=:
21100     ;;
21101   --*=)
21102     ac_option=`expr "X$1" : 'X\([^=]*\)='`
21103     ac_optarg=
21104     ac_shift=:
21105     ;;
21106   *)
21107     ac_option=$1
21108     ac_optarg=$2
21109     ac_shift=shift
21110     ;;
21111   esac
21112
21113   case $ac_option in
21114   # Handling of the options.
21115   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
21116     ac_cs_recheck=: ;;
21117   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
21118     $as_echo "$ac_cs_version"; exit ;;
21119   --config | --confi | --conf | --con | --co | --c )
21120     $as_echo "$ac_cs_config"; exit ;;
21121   --debug | --debu | --deb | --de | --d | -d )
21122     debug=: ;;
21123   --file | --fil | --fi | --f )
21124     $ac_shift
21125     case $ac_optarg in
21126     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
21127     '') as_fn_error $? "missing file argument" ;;
21128     esac
21129     as_fn_append CONFIG_FILES " '$ac_optarg'"
21130     ac_need_defaults=false;;
21131   --header | --heade | --head | --hea )
21132     $ac_shift
21133     case $ac_optarg in
21134     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
21135     esac
21136     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
21137     ac_need_defaults=false;;
21138   --he | --h)
21139     # Conflict between --help and --header
21140     as_fn_error $? "ambiguous option: \`$1'
21141 Try \`$0 --help' for more information.";;
21142   --help | --hel | -h )
21143     $as_echo "$ac_cs_usage"; exit ;;
21144   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
21145   | -silent | --silent | --silen | --sile | --sil | --si | --s)
21146     ac_cs_silent=: ;;
21147
21148   # This is an error.
21149   -*) as_fn_error $? "unrecognized option: \`$1'
21150 Try \`$0 --help' for more information." ;;
21151
21152   *) as_fn_append ac_config_targets " $1"
21153      ac_need_defaults=false ;;
21154
21155   esac
21156   shift
21157 done
21158
21159 ac_configure_extra_args=
21160
21161 if $ac_cs_silent; then
21162   exec 6>/dev/null
21163   ac_configure_extra_args="$ac_configure_extra_args --silent"
21164 fi
21165
21166 _ACEOF
21167 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21168 if \$ac_cs_recheck; then
21169   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
21170   shift
21171   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
21172   CONFIG_SHELL='$SHELL'
21173   export CONFIG_SHELL
21174   exec "\$@"
21175 fi
21176
21177 _ACEOF
21178 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21179 exec 5>>config.log
21180 {
21181   echo
21182   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
21183 ## Running $as_me. ##
21184 _ASBOX
21185   $as_echo "$ac_log"
21186 } >&5
21187
21188 _ACEOF
21189 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21190 #
21191 # INIT-COMMANDS
21192 #
21193
21194
21195 # The HP-UX ksh and POSIX shell print the target directory to stdout
21196 # if CDPATH is set.
21197 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
21198
21199 sed_quote_subst='$sed_quote_subst'
21200 double_quote_subst='$double_quote_subst'
21201 delay_variable_subst='$delay_variable_subst'
21202 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
21203 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
21204 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
21205 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
21206 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
21207 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
21208 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
21209 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
21210 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
21211 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
21212 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
21213 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
21214 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
21215 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
21216 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
21217 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
21218 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
21219 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
21220 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
21221 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
21222 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
21223 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
21224 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
21225 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
21226 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
21227 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
21228 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
21229 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
21230 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
21231 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
21232 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
21233 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
21234 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
21235 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
21236 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
21237 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
21238 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
21239 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
21240 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
21241 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
21242 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
21243 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
21244 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
21245 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
21246 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
21247 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
21248 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
21249 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
21250 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
21251 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
21252 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
21253 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
21254 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
21255 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
21256 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
21257 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
21258 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
21259 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
21260 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"`'
21261 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
21262 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
21263 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
21264 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
21265 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
21266 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
21267 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
21268 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
21269 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
21270 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
21271 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
21272 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
21273 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
21274 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
21275 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
21276 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
21277 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
21278 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
21279 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
21280 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
21281 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
21282 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
21283 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
21284 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
21285 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
21286 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
21287 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
21288 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
21289 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
21290 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
21291 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
21292 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
21293 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
21294 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
21295 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
21296 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
21297 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
21298 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
21299 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
21300 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
21301 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
21302 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
21303 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
21304 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
21305 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
21306 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
21307 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
21308 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
21309 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
21310 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
21311 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
21312 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
21313 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
21314 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
21315 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
21316 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
21317 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
21318 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
21319 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
21320 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
21321 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
21322 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
21323 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
21324 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
21325 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
21326 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
21327 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
21328 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
21329 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
21330 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
21331 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
21332 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
21333 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
21334 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
21335 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
21336 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
21337
21338 LTCC='$LTCC'
21339 LTCFLAGS='$LTCFLAGS'
21340 compiler='$compiler_DEFAULT'
21341
21342 # A function that is used when there is no print builtin or printf.
21343 func_fallback_echo ()
21344 {
21345   eval 'cat <<_LTECHO_EOF
21346 \$1
21347 _LTECHO_EOF'
21348 }
21349
21350 # Quote evaled strings.
21351 for var in SHELL \
21352 ECHO \
21353 PATH_SEPARATOR \
21354 SED \
21355 GREP \
21356 EGREP \
21357 FGREP \
21358 LD \
21359 NM \
21360 LN_S \
21361 lt_SP2NL \
21362 lt_NL2SP \
21363 reload_flag \
21364 OBJDUMP \
21365 deplibs_check_method \
21366 file_magic_cmd \
21367 file_magic_glob \
21368 want_nocaseglob \
21369 DLLTOOL \
21370 sharedlib_from_linklib_cmd \
21371 AR \
21372 AR_FLAGS \
21373 archiver_list_spec \
21374 STRIP \
21375 RANLIB \
21376 CC \
21377 CFLAGS \
21378 compiler \
21379 lt_cv_sys_global_symbol_pipe \
21380 lt_cv_sys_global_symbol_to_cdecl \
21381 lt_cv_sys_global_symbol_to_import \
21382 lt_cv_sys_global_symbol_to_c_name_address \
21383 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
21384 lt_cv_nm_interface \
21385 nm_file_list_spec \
21386 lt_cv_truncate_bin \
21387 lt_prog_compiler_no_builtin_flag \
21388 lt_prog_compiler_pic \
21389 lt_prog_compiler_wl \
21390 lt_prog_compiler_static \
21391 lt_cv_prog_compiler_c_o \
21392 need_locks \
21393 MANIFEST_TOOL \
21394 DSYMUTIL \
21395 NMEDIT \
21396 LIPO \
21397 OTOOL \
21398 OTOOL64 \
21399 shrext_cmds \
21400 export_dynamic_flag_spec \
21401 whole_archive_flag_spec \
21402 compiler_needs_object \
21403 with_gnu_ld \
21404 allow_undefined_flag \
21405 no_undefined_flag \
21406 hardcode_libdir_flag_spec \
21407 hardcode_libdir_separator \
21408 exclude_expsyms \
21409 include_expsyms \
21410 file_list_spec \
21411 variables_saved_for_relink \
21412 libname_spec \
21413 library_names_spec \
21414 soname_spec \
21415 install_override_mode \
21416 finish_eval \
21417 old_striplib \
21418 striplib; do
21419     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
21420     *[\\\\\\\`\\"\\\$]*)
21421       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
21422       ;;
21423     *)
21424       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
21425       ;;
21426     esac
21427 done
21428
21429 # Double-quote double-evaled strings.
21430 for var in reload_cmds \
21431 old_postinstall_cmds \
21432 old_postuninstall_cmds \
21433 old_archive_cmds \
21434 extract_expsyms_cmds \
21435 old_archive_from_new_cmds \
21436 old_archive_from_expsyms_cmds \
21437 archive_cmds \
21438 archive_expsym_cmds \
21439 module_cmds \
21440 module_expsym_cmds \
21441 export_symbols_cmds \
21442 prelink_cmds \
21443 postlink_cmds \
21444 postinstall_cmds \
21445 postuninstall_cmds \
21446 finish_cmds \
21447 sys_lib_search_path_spec \
21448 configure_time_dlsearch_path \
21449 configure_time_lt_sys_library_path; do
21450     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
21451     *[\\\\\\\`\\"\\\$]*)
21452       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
21453       ;;
21454     *)
21455       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
21456       ;;
21457     esac
21458 done
21459
21460 ac_aux_dir='$ac_aux_dir'
21461
21462 # See if we are running on zsh, and set the options that allow our
21463 # commands through without removal of \ escapes INIT.
21464 if test -n "\${ZSH_VERSION+set}"; then
21465    setopt NO_GLOB_SUBST
21466 fi
21467
21468
21469     PACKAGE='$PACKAGE'
21470     VERSION='$VERSION'
21471     RM='$RM'
21472     ofile='$ofile'
21473
21474
21475
21476
21477 _ACEOF
21478
21479 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21480
21481 # Handling of arguments.
21482 for ac_config_target in $ac_config_targets
21483 do
21484   case $ac_config_target in
21485     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
21486     "disable-rpath") CONFIG_COMMANDS="$CONFIG_COMMANDS disable-rpath" ;;
21487     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
21488     "doc/example.conf") CONFIG_FILES="$CONFIG_FILES doc/example.conf" ;;
21489     "doc/libunbound.3") CONFIG_FILES="$CONFIG_FILES doc/libunbound.3" ;;
21490     "doc/unbound.8") CONFIG_FILES="$CONFIG_FILES doc/unbound.8" ;;
21491     "doc/unbound-anchor.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-anchor.8" ;;
21492     "doc/unbound-checkconf.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-checkconf.8" ;;
21493     "doc/unbound.conf.5") CONFIG_FILES="$CONFIG_FILES doc/unbound.conf.5" ;;
21494     "doc/unbound-control.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-control.8" ;;
21495     "doc/unbound-host.1") CONFIG_FILES="$CONFIG_FILES doc/unbound-host.1" ;;
21496     "smallapp/unbound-control-setup.sh") CONFIG_FILES="$CONFIG_FILES smallapp/unbound-control-setup.sh" ;;
21497     "dnstap/dnstap_config.h") CONFIG_FILES="$CONFIG_FILES dnstap/dnstap_config.h" ;;
21498     "dnscrypt/dnscrypt_config.h") CONFIG_FILES="$CONFIG_FILES dnscrypt/dnscrypt_config.h" ;;
21499     "contrib/libunbound.pc") CONFIG_FILES="$CONFIG_FILES contrib/libunbound.pc" ;;
21500     "contrib/unbound.socket") CONFIG_FILES="$CONFIG_FILES contrib/unbound.socket" ;;
21501     "contrib/unbound.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound.service" ;;
21502     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
21503
21504   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
21505   esac
21506 done
21507
21508
21509 # If the user did not use the arguments to specify the items to instantiate,
21510 # then the envvar interface is used.  Set only those that are not.
21511 # We use the long form for the default assignment because of an extremely
21512 # bizarre bug on SunOS 4.1.3.
21513 if $ac_need_defaults; then
21514   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
21515   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
21516   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
21517 fi
21518
21519 # Have a temporary directory for convenience.  Make it in the build tree
21520 # simply because there is no reason against having it here, and in addition,
21521 # creating and moving files from /tmp can sometimes cause problems.
21522 # Hook for its removal unless debugging.
21523 # Note that there is a small window in which the directory will not be cleaned:
21524 # after its creation but before its name has been assigned to `$tmp'.
21525 $debug ||
21526 {
21527   tmp= ac_tmp=
21528   trap 'exit_status=$?
21529   : "${ac_tmp:=$tmp}"
21530   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
21531 ' 0
21532   trap 'as_fn_exit 1' 1 2 13 15
21533 }
21534 # Create a (secure) tmp directory for tmp files.
21535
21536 {
21537   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
21538   test -d "$tmp"
21539 }  ||
21540 {
21541   tmp=./conf$$-$RANDOM
21542   (umask 077 && mkdir "$tmp")
21543 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
21544 ac_tmp=$tmp
21545
21546 # Set up the scripts for CONFIG_FILES section.
21547 # No need to generate them if there are no CONFIG_FILES.
21548 # This happens for instance with `./config.status config.h'.
21549 if test -n "$CONFIG_FILES"; then
21550
21551
21552 ac_cr=`echo X | tr X '\015'`
21553 # On cygwin, bash can eat \r inside `` if the user requested igncr.
21554 # But we know of no other shell where ac_cr would be empty at this
21555 # point, so we can use a bashism as a fallback.
21556 if test "x$ac_cr" = x; then
21557   eval ac_cr=\$\'\\r\'
21558 fi
21559 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
21560 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
21561   ac_cs_awk_cr='\\r'
21562 else
21563   ac_cs_awk_cr=$ac_cr
21564 fi
21565
21566 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
21567 _ACEOF
21568
21569
21570 {
21571   echo "cat >conf$$subs.awk <<_ACEOF" &&
21572   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
21573   echo "_ACEOF"
21574 } >conf$$subs.sh ||
21575   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
21576 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
21577 ac_delim='%!_!# '
21578 for ac_last_try in false false false false false :; do
21579   . ./conf$$subs.sh ||
21580     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
21581
21582   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
21583   if test $ac_delim_n = $ac_delim_num; then
21584     break
21585   elif $ac_last_try; then
21586     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
21587   else
21588     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
21589   fi
21590 done
21591 rm -f conf$$subs.sh
21592
21593 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21594 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
21595 _ACEOF
21596 sed -n '
21597 h
21598 s/^/S["/; s/!.*/"]=/
21599 p
21600 g
21601 s/^[^!]*!//
21602 :repl
21603 t repl
21604 s/'"$ac_delim"'$//
21605 t delim
21606 :nl
21607 h
21608 s/\(.\{148\}\)..*/\1/
21609 t more1
21610 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
21611 p
21612 n
21613 b repl
21614 :more1
21615 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
21616 p
21617 g
21618 s/.\{148\}//
21619 t nl
21620 :delim
21621 h
21622 s/\(.\{148\}\)..*/\1/
21623 t more2
21624 s/["\\]/\\&/g; s/^/"/; s/$/"/
21625 p
21626 b
21627 :more2
21628 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
21629 p
21630 g
21631 s/.\{148\}//
21632 t delim
21633 ' <conf$$subs.awk | sed '
21634 /^[^""]/{
21635   N
21636   s/\n//
21637 }
21638 ' >>$CONFIG_STATUS || ac_write_fail=1
21639 rm -f conf$$subs.awk
21640 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21641 _ACAWK
21642 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
21643   for (key in S) S_is_set[key] = 1
21644   FS = "\a"
21645
21646 }
21647 {
21648   line = $ 0
21649   nfields = split(line, field, "@")
21650   substed = 0
21651   len = length(field[1])
21652   for (i = 2; i < nfields; i++) {
21653     key = field[i]
21654     keylen = length(key)
21655     if (S_is_set[key]) {
21656       value = S[key]
21657       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
21658       len += length(value) + length(field[++i])
21659       substed = 1
21660     } else
21661       len += 1 + keylen
21662   }
21663
21664   print line
21665 }
21666
21667 _ACAWK
21668 _ACEOF
21669 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21670 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
21671   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
21672 else
21673   cat
21674 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
21675   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
21676 _ACEOF
21677
21678 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
21679 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
21680 # trailing colons and then remove the whole line if VPATH becomes empty
21681 # (actually we leave an empty line to preserve line numbers).
21682 if test "x$srcdir" = x.; then
21683   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
21684 h
21685 s///
21686 s/^/:/
21687 s/[      ]*$/:/
21688 s/:\$(srcdir):/:/g
21689 s/:\${srcdir}:/:/g
21690 s/:@srcdir@:/:/g
21691 s/^:*//
21692 s/:*$//
21693 x
21694 s/\(=[   ]*\).*/\1/
21695 G
21696 s/\n//
21697 s/^[^=]*=[       ]*$//
21698 }'
21699 fi
21700
21701 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21702 fi # test -n "$CONFIG_FILES"
21703
21704 # Set up the scripts for CONFIG_HEADERS section.
21705 # No need to generate them if there are no CONFIG_HEADERS.
21706 # This happens for instance with `./config.status Makefile'.
21707 if test -n "$CONFIG_HEADERS"; then
21708 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
21709 BEGIN {
21710 _ACEOF
21711
21712 # Transform confdefs.h into an awk script `defines.awk', embedded as
21713 # here-document in config.status, that substitutes the proper values into
21714 # config.h.in to produce config.h.
21715
21716 # Create a delimiter string that does not exist in confdefs.h, to ease
21717 # handling of long lines.
21718 ac_delim='%!_!# '
21719 for ac_last_try in false false :; do
21720   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
21721   if test -z "$ac_tt"; then
21722     break
21723   elif $ac_last_try; then
21724     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
21725   else
21726     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
21727   fi
21728 done
21729
21730 # For the awk script, D is an array of macro values keyed by name,
21731 # likewise P contains macro parameters if any.  Preserve backslash
21732 # newline sequences.
21733
21734 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
21735 sed -n '
21736 s/.\{148\}/&'"$ac_delim"'/g
21737 t rset
21738 :rset
21739 s/^[     ]*#[    ]*define[       ][      ]*/ /
21740 t def
21741 d
21742 :def
21743 s/\\$//
21744 t bsnl
21745 s/["\\]/\\&/g
21746 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
21747 D["\1"]=" \3"/p
21748 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
21749 d
21750 :bsnl
21751 s/["\\]/\\&/g
21752 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
21753 D["\1"]=" \3\\\\\\n"\\/p
21754 t cont
21755 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
21756 t cont
21757 d
21758 :cont
21759 n
21760 s/.\{148\}/&'"$ac_delim"'/g
21761 t clear
21762 :clear
21763 s/\\$//
21764 t bsnlc
21765 s/["\\]/\\&/g; s/^/"/; s/$/"/p
21766 d
21767 :bsnlc
21768 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
21769 b cont
21770 ' <confdefs.h | sed '
21771 s/'"$ac_delim"'/"\\\
21772 "/g' >>$CONFIG_STATUS || ac_write_fail=1
21773
21774 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21775   for (key in D) D_is_set[key] = 1
21776   FS = "\a"
21777 }
21778 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
21779   line = \$ 0
21780   split(line, arg, " ")
21781   if (arg[1] == "#") {
21782     defundef = arg[2]
21783     mac1 = arg[3]
21784   } else {
21785     defundef = substr(arg[1], 2)
21786     mac1 = arg[2]
21787   }
21788   split(mac1, mac2, "(") #)
21789   macro = mac2[1]
21790   prefix = substr(line, 1, index(line, defundef) - 1)
21791   if (D_is_set[macro]) {
21792     # Preserve the white space surrounding the "#".
21793     print prefix "define", macro P[macro] D[macro]
21794     next
21795   } else {
21796     # Replace #undef with comments.  This is necessary, for example,
21797     # in the case of _POSIX_SOURCE, which is predefined and required
21798     # on some systems where configure will not decide to define it.
21799     if (defundef == "undef") {
21800       print "/*", prefix defundef, macro, "*/"
21801       next
21802     }
21803   }
21804 }
21805 { print }
21806 _ACAWK
21807 _ACEOF
21808 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21809   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
21810 fi # test -n "$CONFIG_HEADERS"
21811
21812
21813 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
21814 shift
21815 for ac_tag
21816 do
21817   case $ac_tag in
21818   :[FHLC]) ac_mode=$ac_tag; continue;;
21819   esac
21820   case $ac_mode$ac_tag in
21821   :[FHL]*:*);;
21822   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
21823   :[FH]-) ac_tag=-:-;;
21824   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
21825   esac
21826   ac_save_IFS=$IFS
21827   IFS=:
21828   set x $ac_tag
21829   IFS=$ac_save_IFS
21830   shift
21831   ac_file=$1
21832   shift
21833
21834   case $ac_mode in
21835   :L) ac_source=$1;;
21836   :[FH])
21837     ac_file_inputs=
21838     for ac_f
21839     do
21840       case $ac_f in
21841       -) ac_f="$ac_tmp/stdin";;
21842       *) # Look for the file first in the build tree, then in the source tree
21843          # (if the path is not absolute).  The absolute path cannot be DOS-style,
21844          # because $ac_f cannot contain `:'.
21845          test -f "$ac_f" ||
21846            case $ac_f in
21847            [\\/$]*) false;;
21848            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
21849            esac ||
21850            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
21851       esac
21852       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
21853       as_fn_append ac_file_inputs " '$ac_f'"
21854     done
21855
21856     # Let's still pretend it is `configure' which instantiates (i.e., don't
21857     # use $as_me), people would be surprised to read:
21858     #    /* config.h.  Generated by config.status.  */
21859     configure_input='Generated from '`
21860           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
21861         `' by configure.'
21862     if test x"$ac_file" != x-; then
21863       configure_input="$ac_file.  $configure_input"
21864       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
21865 $as_echo "$as_me: creating $ac_file" >&6;}
21866     fi
21867     # Neutralize special characters interpreted by sed in replacement strings.
21868     case $configure_input in #(
21869     *\&* | *\|* | *\\* )
21870        ac_sed_conf_input=`$as_echo "$configure_input" |
21871        sed 's/[\\\\&|]/\\\\&/g'`;; #(
21872     *) ac_sed_conf_input=$configure_input;;
21873     esac
21874
21875     case $ac_tag in
21876     *:-:* | *:-) cat >"$ac_tmp/stdin" \
21877       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
21878     esac
21879     ;;
21880   esac
21881
21882   ac_dir=`$as_dirname -- "$ac_file" ||
21883 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21884          X"$ac_file" : 'X\(//\)[^/]' \| \
21885          X"$ac_file" : 'X\(//\)$' \| \
21886          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
21887 $as_echo X"$ac_file" |
21888     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21889             s//\1/
21890             q
21891           }
21892           /^X\(\/\/\)[^/].*/{
21893             s//\1/
21894             q
21895           }
21896           /^X\(\/\/\)$/{
21897             s//\1/
21898             q
21899           }
21900           /^X\(\/\).*/{
21901             s//\1/
21902             q
21903           }
21904           s/.*/./; q'`
21905   as_dir="$ac_dir"; as_fn_mkdir_p
21906   ac_builddir=.
21907
21908 case "$ac_dir" in
21909 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
21910 *)
21911   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
21912   # A ".." for each directory in $ac_dir_suffix.
21913   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
21914   case $ac_top_builddir_sub in
21915   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
21916   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
21917   esac ;;
21918 esac
21919 ac_abs_top_builddir=$ac_pwd
21920 ac_abs_builddir=$ac_pwd$ac_dir_suffix
21921 # for backward compatibility:
21922 ac_top_builddir=$ac_top_build_prefix
21923
21924 case $srcdir in
21925   .)  # We are building in place.
21926     ac_srcdir=.
21927     ac_top_srcdir=$ac_top_builddir_sub
21928     ac_abs_top_srcdir=$ac_pwd ;;
21929   [\\/]* | ?:[\\/]* )  # Absolute name.
21930     ac_srcdir=$srcdir$ac_dir_suffix;
21931     ac_top_srcdir=$srcdir
21932     ac_abs_top_srcdir=$srcdir ;;
21933   *) # Relative name.
21934     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
21935     ac_top_srcdir=$ac_top_build_prefix$srcdir
21936     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
21937 esac
21938 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
21939
21940
21941   case $ac_mode in
21942   :F)
21943   #
21944   # CONFIG_FILE
21945   #
21946
21947 _ACEOF
21948
21949 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21950 # If the template does not know about datarootdir, expand it.
21951 # FIXME: This hack should be removed a few years after 2.60.
21952 ac_datarootdir_hack=; ac_datarootdir_seen=
21953 ac_sed_dataroot='
21954 /datarootdir/ {
21955   p
21956   q
21957 }
21958 /@datadir@/p
21959 /@docdir@/p
21960 /@infodir@/p
21961 /@localedir@/p
21962 /@mandir@/p'
21963 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
21964 *datarootdir*) ac_datarootdir_seen=yes;;
21965 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
21966   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
21967 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
21968 _ACEOF
21969 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21970   ac_datarootdir_hack='
21971   s&@datadir@&$datadir&g
21972   s&@docdir@&$docdir&g
21973   s&@infodir@&$infodir&g
21974   s&@localedir@&$localedir&g
21975   s&@mandir@&$mandir&g
21976   s&\\\${datarootdir}&$datarootdir&g' ;;
21977 esac
21978 _ACEOF
21979
21980 # Neutralize VPATH when `$srcdir' = `.'.
21981 # Shell code in configure.ac might set extrasub.
21982 # FIXME: do we really want to maintain this feature?
21983 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21984 ac_sed_extra="$ac_vpsub
21985 $extrasub
21986 _ACEOF
21987 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21988 :t
21989 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
21990 s|@configure_input@|$ac_sed_conf_input|;t t
21991 s&@top_builddir@&$ac_top_builddir_sub&;t t
21992 s&@top_build_prefix@&$ac_top_build_prefix&;t t
21993 s&@srcdir@&$ac_srcdir&;t t
21994 s&@abs_srcdir@&$ac_abs_srcdir&;t t
21995 s&@top_srcdir@&$ac_top_srcdir&;t t
21996 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
21997 s&@builddir@&$ac_builddir&;t t
21998 s&@abs_builddir@&$ac_abs_builddir&;t t
21999 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
22000 $ac_datarootdir_hack
22001 "
22002 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
22003   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22004
22005 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
22006   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
22007   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
22008       "$ac_tmp/out"`; test -z "$ac_out"; } &&
22009   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22010 which seems to be undefined.  Please make sure it is defined" >&5
22011 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22012 which seems to be undefined.  Please make sure it is defined" >&2;}
22013
22014   rm -f "$ac_tmp/stdin"
22015   case $ac_file in
22016   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
22017   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
22018   esac \
22019   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22020  ;;
22021   :H)
22022   #
22023   # CONFIG_HEADER
22024   #
22025   if test x"$ac_file" != x-; then
22026     {
22027       $as_echo "/* $configure_input  */" \
22028       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
22029     } >"$ac_tmp/config.h" \
22030       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22031     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
22032       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
22033 $as_echo "$as_me: $ac_file is unchanged" >&6;}
22034     else
22035       rm -f "$ac_file"
22036       mv "$ac_tmp/config.h" "$ac_file" \
22037         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22038     fi
22039   else
22040     $as_echo "/* $configure_input  */" \
22041       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
22042       || as_fn_error $? "could not create -" "$LINENO" 5
22043   fi
22044  ;;
22045
22046   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
22047 $as_echo "$as_me: executing $ac_file commands" >&6;}
22048  ;;
22049   esac
22050
22051
22052   case $ac_file$ac_mode in
22053     "libtool":C)
22054
22055     # See if we are running on zsh, and set the options that allow our
22056     # commands through without removal of \ escapes.
22057     if test -n "${ZSH_VERSION+set}"; then
22058       setopt NO_GLOB_SUBST
22059     fi
22060
22061     cfgfile=${ofile}T
22062     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
22063     $RM "$cfgfile"
22064
22065     cat <<_LT_EOF >> "$cfgfile"
22066 #! $SHELL
22067 # Generated automatically by $as_me ($PACKAGE) $VERSION
22068 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
22069 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
22070
22071 # Provide generalized library-building support services.
22072 # Written by Gordon Matzigkeit, 1996
22073
22074 # Copyright (C) 2014 Free Software Foundation, Inc.
22075 # This is free software; see the source for copying conditions.  There is NO
22076 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
22077
22078 # GNU Libtool is free software; you can redistribute it and/or modify
22079 # it under the terms of the GNU General Public License as published by
22080 # the Free Software Foundation; either version 2 of of the License, or
22081 # (at your option) any later version.
22082 #
22083 # As a special exception to the GNU General Public License, if you
22084 # distribute this file as part of a program or library that is built
22085 # using GNU Libtool, you may include this file under the  same
22086 # distribution terms that you use for the rest of that program.
22087 #
22088 # GNU Libtool is distributed in the hope that it will be useful, but
22089 # WITHOUT ANY WARRANTY; without even the implied warranty of
22090 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
22091 # GNU General Public License for more details.
22092 #
22093 # You should have received a copy of the GNU General Public License
22094 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
22095
22096
22097 # The names of the tagged configurations supported by this script.
22098 available_tags=''
22099
22100 # Configured defaults for sys_lib_dlsearch_path munging.
22101 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
22102
22103 # ### BEGIN LIBTOOL CONFIG
22104
22105 # Which release of libtool.m4 was used?
22106 macro_version=$macro_version
22107 macro_revision=$macro_revision
22108
22109 # Whether or not to build shared libraries.
22110 build_libtool_libs=$enable_shared
22111
22112 # Whether or not to build static libraries.
22113 build_old_libs=$enable_static
22114
22115 # What type of objects to build.
22116 pic_mode=$pic_mode
22117
22118 # Whether or not to optimize for fast installation.
22119 fast_install=$enable_fast_install
22120
22121 # Shared archive member basename,for filename based shared library versioning on AIX.
22122 shared_archive_member_spec=$shared_archive_member_spec
22123
22124 # Shell to use when invoking shell scripts.
22125 SHELL=$lt_SHELL
22126
22127 # An echo program that protects backslashes.
22128 ECHO=$lt_ECHO
22129
22130 # The PATH separator for the build system.
22131 PATH_SEPARATOR=$lt_PATH_SEPARATOR
22132
22133 # The host system.
22134 host_alias=$host_alias
22135 host=$host
22136 host_os=$host_os
22137
22138 # The build system.
22139 build_alias=$build_alias
22140 build=$build
22141 build_os=$build_os
22142
22143 # A sed program that does not truncate output.
22144 SED=$lt_SED
22145
22146 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
22147 Xsed="\$SED -e 1s/^X//"
22148
22149 # A grep program that handles long lines.
22150 GREP=$lt_GREP
22151
22152 # An ERE matcher.
22153 EGREP=$lt_EGREP
22154
22155 # A literal string matcher.
22156 FGREP=$lt_FGREP
22157
22158 # A BSD- or MS-compatible name lister.
22159 NM=$lt_NM
22160
22161 # Whether we need soft or hard links.
22162 LN_S=$lt_LN_S
22163
22164 # What is the maximum length of a command?
22165 max_cmd_len=$max_cmd_len
22166
22167 # Object file suffix (normally "o").
22168 objext=$ac_objext
22169
22170 # Executable file suffix (normally "").
22171 exeext=$exeext
22172
22173 # whether the shell understands "unset".
22174 lt_unset=$lt_unset
22175
22176 # turn spaces into newlines.
22177 SP2NL=$lt_lt_SP2NL
22178
22179 # turn newlines into spaces.
22180 NL2SP=$lt_lt_NL2SP
22181
22182 # convert \$build file names to \$host format.
22183 to_host_file_cmd=$lt_cv_to_host_file_cmd
22184
22185 # convert \$build files to toolchain format.
22186 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
22187
22188 # An object symbol dumper.
22189 OBJDUMP=$lt_OBJDUMP
22190
22191 # Method to check whether dependent libraries are shared objects.
22192 deplibs_check_method=$lt_deplibs_check_method
22193
22194 # Command to use when deplibs_check_method = "file_magic".
22195 file_magic_cmd=$lt_file_magic_cmd
22196
22197 # How to find potential files when deplibs_check_method = "file_magic".
22198 file_magic_glob=$lt_file_magic_glob
22199
22200 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
22201 want_nocaseglob=$lt_want_nocaseglob
22202
22203 # DLL creation program.
22204 DLLTOOL=$lt_DLLTOOL
22205
22206 # Command to associate shared and link libraries.
22207 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
22208
22209 # The archiver.
22210 AR=$lt_AR
22211
22212 # Flags to create an archive.
22213 AR_FLAGS=$lt_AR_FLAGS
22214
22215 # How to feed a file listing to the archiver.
22216 archiver_list_spec=$lt_archiver_list_spec
22217
22218 # A symbol stripping program.
22219 STRIP=$lt_STRIP
22220
22221 # Commands used to install an old-style archive.
22222 RANLIB=$lt_RANLIB
22223 old_postinstall_cmds=$lt_old_postinstall_cmds
22224 old_postuninstall_cmds=$lt_old_postuninstall_cmds
22225
22226 # Whether to use a lock for old archive extraction.
22227 lock_old_archive_extraction=$lock_old_archive_extraction
22228
22229 # A C compiler.
22230 LTCC=$lt_CC
22231
22232 # LTCC compiler flags.
22233 LTCFLAGS=$lt_CFLAGS
22234
22235 # Take the output of nm and produce a listing of raw symbols and C names.
22236 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
22237
22238 # Transform the output of nm in a proper C declaration.
22239 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
22240
22241 # Transform the output of nm into a list of symbols to manually relocate.
22242 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
22243
22244 # Transform the output of nm in a C name address pair.
22245 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
22246
22247 # Transform the output of nm in a C name address pair when lib prefix is needed.
22248 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
22249
22250 # The name lister interface.
22251 nm_interface=$lt_lt_cv_nm_interface
22252
22253 # Specify filename containing input files for \$NM.
22254 nm_file_list_spec=$lt_nm_file_list_spec
22255
22256 # The root where to search for dependent libraries,and where our libraries should be installed.
22257 lt_sysroot=$lt_sysroot
22258
22259 # Command to truncate a binary pipe.
22260 lt_truncate_bin=$lt_lt_cv_truncate_bin
22261
22262 # The name of the directory that contains temporary libtool files.
22263 objdir=$objdir
22264
22265 # Used to examine libraries when file_magic_cmd begins with "file".
22266 MAGIC_CMD=$MAGIC_CMD
22267
22268 # Must we lock files when doing compilation?
22269 need_locks=$lt_need_locks
22270
22271 # Manifest tool.
22272 MANIFEST_TOOL=$lt_MANIFEST_TOOL
22273
22274 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
22275 DSYMUTIL=$lt_DSYMUTIL
22276
22277 # Tool to change global to local symbols on Mac OS X.
22278 NMEDIT=$lt_NMEDIT
22279
22280 # Tool to manipulate fat objects and archives on Mac OS X.
22281 LIPO=$lt_LIPO
22282
22283 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
22284 OTOOL=$lt_OTOOL
22285
22286 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
22287 OTOOL64=$lt_OTOOL64
22288
22289 # Old archive suffix (normally "a").
22290 libext=$libext
22291
22292 # Shared library suffix (normally ".so").
22293 shrext_cmds=$lt_shrext_cmds
22294
22295 # The commands to extract the exported symbol list from a shared archive.
22296 extract_expsyms_cmds=$lt_extract_expsyms_cmds
22297
22298 # Variables whose values should be saved in libtool wrapper scripts and
22299 # restored at link time.
22300 variables_saved_for_relink=$lt_variables_saved_for_relink
22301
22302 # Do we need the "lib" prefix for modules?
22303 need_lib_prefix=$need_lib_prefix
22304
22305 # Do we need a version for libraries?
22306 need_version=$need_version
22307
22308 # Library versioning type.
22309 version_type=$version_type
22310
22311 # Shared library runtime path variable.
22312 runpath_var=$runpath_var
22313
22314 # Shared library path variable.
22315 shlibpath_var=$shlibpath_var
22316
22317 # Is shlibpath searched before the hard-coded library search path?
22318 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
22319
22320 # Format of library name prefix.
22321 libname_spec=$lt_libname_spec
22322
22323 # List of archive names.  First name is the real one, the rest are links.
22324 # The last name is the one that the linker finds with -lNAME
22325 library_names_spec=$lt_library_names_spec
22326
22327 # The coded name of the library, if different from the real name.
22328 soname_spec=$lt_soname_spec
22329
22330 # Permission mode override for installation of shared libraries.
22331 install_override_mode=$lt_install_override_mode
22332
22333 # Command to use after installation of a shared archive.
22334 postinstall_cmds=$lt_postinstall_cmds
22335
22336 # Command to use after uninstallation of a shared archive.
22337 postuninstall_cmds=$lt_postuninstall_cmds
22338
22339 # Commands used to finish a libtool library installation in a directory.
22340 finish_cmds=$lt_finish_cmds
22341
22342 # As "finish_cmds", except a single script fragment to be evaled but
22343 # not shown.
22344 finish_eval=$lt_finish_eval
22345
22346 # Whether we should hardcode library paths into libraries.
22347 hardcode_into_libs=$hardcode_into_libs
22348
22349 # Compile-time system search path for libraries.
22350 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
22351
22352 # Detected run-time system search path for libraries.
22353 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
22354
22355 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
22356 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
22357
22358 # Whether dlopen is supported.
22359 dlopen_support=$enable_dlopen
22360
22361 # Whether dlopen of programs is supported.
22362 dlopen_self=$enable_dlopen_self
22363
22364 # Whether dlopen of statically linked programs is supported.
22365 dlopen_self_static=$enable_dlopen_self_static
22366
22367 # Commands to strip libraries.
22368 old_striplib=$lt_old_striplib
22369 striplib=$lt_striplib
22370
22371
22372 # The linker used to build libraries.
22373 LD=$lt_LD
22374
22375 # How to create reloadable object files.
22376 reload_flag=$lt_reload_flag
22377 reload_cmds=$lt_reload_cmds
22378
22379 # Commands used to build an old-style archive.
22380 old_archive_cmds=$lt_old_archive_cmds
22381
22382 # A language specific compiler.
22383 CC=$lt_compiler
22384
22385 # Is the compiler the GNU compiler?
22386 with_gcc=$GCC
22387
22388 # Compiler flag to turn off builtin functions.
22389 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
22390
22391 # Additional compiler flags for building library objects.
22392 pic_flag=$lt_lt_prog_compiler_pic
22393
22394 # How to pass a linker flag through the compiler.
22395 wl=$lt_lt_prog_compiler_wl
22396
22397 # Compiler flag to prevent dynamic linking.
22398 link_static_flag=$lt_lt_prog_compiler_static
22399
22400 # Does compiler simultaneously support -c and -o options?
22401 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
22402
22403 # Whether or not to add -lc for building shared libraries.
22404 build_libtool_need_lc=$archive_cmds_need_lc
22405
22406 # Whether or not to disallow shared libs when runtime libs are static.
22407 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
22408
22409 # Compiler flag to allow reflexive dlopens.
22410 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
22411
22412 # Compiler flag to generate shared objects directly from archives.
22413 whole_archive_flag_spec=$lt_whole_archive_flag_spec
22414
22415 # Whether the compiler copes with passing no objects directly.
22416 compiler_needs_object=$lt_compiler_needs_object
22417
22418 # Create an old-style archive from a shared archive.
22419 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
22420
22421 # Create a temporary old-style archive to link instead of a shared archive.
22422 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
22423
22424 # Commands used to build a shared archive.
22425 archive_cmds=$lt_archive_cmds
22426 archive_expsym_cmds=$lt_archive_expsym_cmds
22427
22428 # Commands used to build a loadable module if different from building
22429 # a shared archive.
22430 module_cmds=$lt_module_cmds
22431 module_expsym_cmds=$lt_module_expsym_cmds
22432
22433 # Whether we are building with GNU ld or not.
22434 with_gnu_ld=$lt_with_gnu_ld
22435
22436 # Flag that allows shared libraries with undefined symbols to be built.
22437 allow_undefined_flag=$lt_allow_undefined_flag
22438
22439 # Flag that enforces no undefined symbols.
22440 no_undefined_flag=$lt_no_undefined_flag
22441
22442 # Flag to hardcode \$libdir into a binary during linking.
22443 # This must work even if \$libdir does not exist
22444 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
22445
22446 # Whether we need a single "-rpath" flag with a separated argument.
22447 hardcode_libdir_separator=$lt_hardcode_libdir_separator
22448
22449 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
22450 # DIR into the resulting binary.
22451 hardcode_direct=$hardcode_direct
22452
22453 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
22454 # DIR into the resulting binary and the resulting library dependency is
22455 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
22456 # library is relocated.
22457 hardcode_direct_absolute=$hardcode_direct_absolute
22458
22459 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
22460 # into the resulting binary.
22461 hardcode_minus_L=$hardcode_minus_L
22462
22463 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
22464 # into the resulting binary.
22465 hardcode_shlibpath_var=$hardcode_shlibpath_var
22466
22467 # Set to "yes" if building a shared library automatically hardcodes DIR
22468 # into the library and all subsequent libraries and executables linked
22469 # against it.
22470 hardcode_automatic=$hardcode_automatic
22471
22472 # Set to yes if linker adds runtime paths of dependent libraries
22473 # to runtime path list.
22474 inherit_rpath=$inherit_rpath
22475
22476 # Whether libtool must link a program against all its dependency libraries.
22477 link_all_deplibs=$link_all_deplibs
22478
22479 # Set to "yes" if exported symbols are required.
22480 always_export_symbols=$always_export_symbols
22481
22482 # The commands to list exported symbols.
22483 export_symbols_cmds=$lt_export_symbols_cmds
22484
22485 # Symbols that should not be listed in the preloaded symbols.
22486 exclude_expsyms=$lt_exclude_expsyms
22487
22488 # Symbols that must always be exported.
22489 include_expsyms=$lt_include_expsyms
22490
22491 # Commands necessary for linking programs (against libraries) with templates.
22492 prelink_cmds=$lt_prelink_cmds
22493
22494 # Commands necessary for finishing linking programs.
22495 postlink_cmds=$lt_postlink_cmds
22496
22497 # Specify filename containing input files.
22498 file_list_spec=$lt_file_list_spec
22499
22500 # How to hardcode a shared library path into an executable.
22501 hardcode_action=$hardcode_action
22502
22503 # ### END LIBTOOL CONFIG
22504
22505 _LT_EOF
22506
22507     cat <<'_LT_EOF' >> "$cfgfile"
22508
22509 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
22510
22511 # func_munge_path_list VARIABLE PATH
22512 # -----------------------------------
22513 # VARIABLE is name of variable containing _space_ separated list of
22514 # directories to be munged by the contents of PATH, which is string
22515 # having a format:
22516 # "DIR[:DIR]:"
22517 #       string "DIR[ DIR]" will be prepended to VARIABLE
22518 # ":DIR[:DIR]"
22519 #       string "DIR[ DIR]" will be appended to VARIABLE
22520 # "DIRP[:DIRP]::[DIRA:]DIRA"
22521 #       string "DIRP[ DIRP]" will be prepended to VARIABLE and string
22522 #       "DIRA[ DIRA]" will be appended to VARIABLE
22523 # "DIR[:DIR]"
22524 #       VARIABLE will be replaced by "DIR[ DIR]"
22525 func_munge_path_list ()
22526 {
22527     case x$2 in
22528     x)
22529         ;;
22530     *:)
22531         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
22532         ;;
22533     x:*)
22534         eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
22535         ;;
22536     *::*)
22537         eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
22538         eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
22539         ;;
22540     *)
22541         eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
22542         ;;
22543     esac
22544 }
22545
22546
22547 # Calculate cc_basename.  Skip known compiler wrappers and cross-prefix.
22548 func_cc_basename ()
22549 {
22550     for cc_temp in $*""; do
22551       case $cc_temp in
22552         compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
22553         distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
22554         \-*) ;;
22555         *) break;;
22556       esac
22557     done
22558     func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
22559 }
22560
22561
22562 # ### END FUNCTIONS SHARED WITH CONFIGURE
22563
22564 _LT_EOF
22565
22566   case $host_os in
22567   aix3*)
22568     cat <<\_LT_EOF >> "$cfgfile"
22569 # AIX sometimes has problems with the GCC collect2 program.  For some
22570 # reason, if we set the COLLECT_NAMES environment variable, the problems
22571 # vanish in a puff of smoke.
22572 if test set != "${COLLECT_NAMES+set}"; then
22573   COLLECT_NAMES=
22574   export COLLECT_NAMES
22575 fi
22576 _LT_EOF
22577     ;;
22578   esac
22579
22580
22581 ltmain=$ac_aux_dir/ltmain.sh
22582
22583
22584   # We use sed instead of cat because bash on DJGPP gets confused if
22585   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
22586   # text mode, it properly converts lines to CR/LF.  This bash problem
22587   # is reportedly fixed, but why not run on old versions too?
22588   sed '$q' "$ltmain" >> "$cfgfile" \
22589      || (rm -f "$cfgfile"; exit 1)
22590
22591    mv -f "$cfgfile" "$ofile" ||
22592     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
22593   chmod +x "$ofile"
22594
22595  ;;
22596     "disable-rpath":C)
22597         sed < libtool > libtool-2 \
22598         's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_RPATH_SED__ "/'
22599         mv libtool-2 libtool
22600         chmod 755 libtool
22601         libtool="./libtool"
22602          ;;
22603
22604   esac
22605 done # for ac_tag
22606
22607
22608 as_fn_exit 0
22609 _ACEOF
22610 ac_clean_files=$ac_clean_files_save
22611
22612 test $ac_write_fail = 0 ||
22613   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
22614
22615
22616 # configure is writing to config.log, and then calls config.status.
22617 # config.status does its own redirection, appending to config.log.
22618 # Unfortunately, on DOS this fails, as config.log is still kept open
22619 # by configure, so config.status won't be able to write to it; its
22620 # output is simply discarded.  So we exec the FD to /dev/null,
22621 # effectively closing config.log, so it can be properly (re)opened and
22622 # appended to by config.status.  When coming back to configure, we
22623 # need to make the FD available again.
22624 if test "$no_create" != yes; then
22625   ac_cs_success=:
22626   ac_config_status_args=
22627   test "$silent" = yes &&
22628     ac_config_status_args="$ac_config_status_args --quiet"
22629   exec 5>/dev/null
22630   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
22631   exec 5>>config.log
22632   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
22633   # would make configure fail if this is the last instruction.
22634   $ac_cs_success || as_fn_exit 1
22635 fi
22636 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
22637   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
22638 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
22639 fi
22640